]> git.lizzy.rs Git - rust.git/commit
Rollup merge of #99026 - anall:buffix/clippy-9131, r=xFrednet
authorMatthias Krüger <matthias.krueger@famsik.de>
Fri, 8 Jul 2022 06:00:41 +0000 (08:00 +0200)
committerGitHub <noreply@github.com>
Fri, 8 Jul 2022 06:00:41 +0000 (08:00 +0200)
commit445702d0cb4c47b1c95c0756c0d189ff539ca7bb
tree202b412781a793d655e75b9c24d215aa2034fe39
parente58c2d4f52b6dfcd7095c4f12a7ef8879d282189
parent98b84195a217f53659d8f88ff9427ac7e463ccfb
Rollup merge of #99026 - anall:buffix/clippy-9131, r=xFrednet

Add test for and fix rust-lang/rust-clippy#9131

This lint seems to have been broken by #98446 -- but of course, there was no clippy test for this case at the time.

`expr.span.ctxt().outer_expn_data()` now has `MacroKind::Derive` instead of `MacroKind::Attr` for something like:

```
#[derive(Clone, Debug)]
pub struct UnderscoreInStruct {
    _foo: u32,
}
```

---

changelog: none

closes: https://github.com/rust-lang/rust-clippy/issues/9131