diff options
| author | mejrs <> | 2022-10-24 20:52:51 +0200 |
|---|---|---|
| committer | mejrs <> | 2022-10-24 20:52:51 +0200 |
| commit | beae0d298e5682f12bbf09ba12619751ec9548ea (patch) | |
| tree | 9b5907f37fb10e061353cae804a1a136a34b4a02 | |
| parent | 831b99436c3dc47eafdaf363acd1d4e9e230551d (diff) | |
| download | rust-beae0d298e5682f12bbf09ba12619751ec9548ea.tar.gz rust-beae0d298e5682f12bbf09ba12619751ec9548ea.zip | |
Address some comments
| -rw-r--r-- | tests/ui/track-diagnostics.rs | 8 | ||||
| -rw-r--r-- | tests/ui/track-diagnostics.stderr | 10 |
2 files changed, 18 insertions, 0 deletions
diff --git a/tests/ui/track-diagnostics.rs b/tests/ui/track-diagnostics.rs new file mode 100644 index 00000000000..8c96f46d57a --- /dev/null +++ b/tests/ui/track-diagnostics.rs @@ -0,0 +1,8 @@ +// compile-flags: -Z track-diagnostics +// error-pattern: created at + +struct A; +struct B; +const S: A = B; + +fn main() {} diff --git a/tests/ui/track-diagnostics.stderr b/tests/ui/track-diagnostics.stderr new file mode 100644 index 00000000000..76453cfe220 --- /dev/null +++ b/tests/ui/track-diagnostics.stderr @@ -0,0 +1,10 @@ +error[E0308]: mismatched types + --> $DIR/track-diagnostics.rs:6:14 + | +LL | const S: A = B; + | ^ expected struct `A`, found struct `B` +-Ztrack-diagnostics: created at compiler/rustc_infer/src/infer/error_reporting/mod.rs:2275:31 + +error: aborting due to previous error + +For more information about this error, try `rustc --explain E0308`. |
