granite-rust/compiler/rustc_builtin_macros
Nicholas Nethercote 00207ead61 Improve derived discriminant testing.
Currently the generated code for methods like `eq`, `ne`, and `partial_cmp`
includes stuff like this:
```
let __self_vi = ::core::intrinsics::discriminant_value(&*self);
let __arg_1_vi = ::core::intrinsics::discriminant_value(&*other);
if true && __self_vi == __arg_1_vi {
    ...
}
```
This commit removes the unnecessary `true &&`, and makes the generating
code a little easier to read in the process. It also fixes some errors
in comments.
2022-06-27 08:14:09 +10:00
..
src Improve derived discriminant testing. 2022-06-27 08:14:09 +10:00
Cargo.toml Migrate builtin-macros-requires-cfg-pattern to SessionDiagnostic 2022-06-21 20:10:31 +01:00