diff options
Diffstat (limited to 'src/test/incremental/issue-49043.rs')
-rw-r--r-- | src/test/incremental/issue-49043.rs | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/test/incremental/issue-49043.rs b/src/test/incremental/issue-49043.rs new file mode 100644 index 000000000..50d8fb869 --- /dev/null +++ b/src/test/incremental/issue-49043.rs @@ -0,0 +1,12 @@ +// Regression test for hashing involving canonical variables. In this +// test -- which has an intensional error -- the type of the value +// being dropped winds up including a type variable. Canonicalization +// would then produce a `?0` which -- in turn -- triggered an ICE in +// hashing. + +// revisions:cfail1 + +fn main() { + println!("Hello, world! {}",*thread_rng().choose(&[0, 1, 2, 3]).unwrap()); + //[cfail1]~^ ERROR cannot find function `thread_rng` +} |