about summary refs log tree commit diff
path: root/compiler/rustc_errors/src/snippet.rs
diff options
context:
space:
mode:
authorNicholas Nethercote <n.nethercote@gmail.com>2022-10-18 13:07:20 +1100
committerNicholas Nethercote <n.nethercote@gmail.com>2022-10-18 15:51:23 +1100
commit9a23f60f9c801dd0b4686cc75c6a9979bd8928fa (patch)
tree448ae0dd90b2574f41263fee1e607869b40058d2 /compiler/rustc_errors/src/snippet.rs
parentdfa9d5c971d74aa5bdf6b99253fe4b7db39f9b67 (diff)
downloadrust-9a23f60f9c801dd0b4686cc75c6a9979bd8928fa.tar.gz
rust-9a23f60f9c801dd0b4686cc75c6a9979bd8928fa.zip
Fix `TyKind::is_simple_path`.
PR #98758 introduced code to avoid redundant assertions in derived code
like this:
```
let _: ::core::clone::AssertParamIsClone<u32>;
let _: ::core::clone::AssertParamIsClone<u32>;
```
But the predicate `is_simple_path` introduced as part of this failed to
account for generic arguments. Therefore the deriving code erroneously
considers types like `Option<bool>` and `Option<f32>` to be the same.

This commit fixes `is_simple_path`.

Fixes #103157.
Diffstat (limited to 'compiler/rustc_errors/src/snippet.rs')
0 files changed, 0 insertions, 0 deletions