blob: df9b1e695b1e449c46fcb2a95c8b6491951caff7 [file] [log] [blame] [edit]
warning: irrefutable `if let` pattern
--> $DIR/let-offset-of.rs:14:8
|
LL | if let x = offset_of!(Foo, field) {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: this pattern will always match, so the `if let` is useless
= help: consider replacing the `if let` with a `let`
= note: `#[warn(irrefutable_let_patterns)]` on by default
warning: irrefutable `let...else` pattern
--> $DIR/let-offset-of.rs:17:5
|
LL | let x = offset_of!(Foo, field) else { return; };
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: this pattern always matches, so the else clause is unreachable
help: remove this `else` block
--> $DIR/let-offset-of.rs:17:41
|
LL | let x = offset_of!(Foo, field) else { return; };
| ^^^^^^^^^^^
warning: 2 warnings emitted