]> git.proxmox.com Git - rustc.git/blob - tests/incremental/issue-49043.rs
New upstream version 1.68.2+dfsg1
[rustc.git] / tests / incremental / issue-49043.rs
1 // Regression test for hashing involving canonical variables. In this
2 // test -- which has an intentional error -- the type of the value
3 // being dropped winds up including a type variable. Canonicalization
4 // would then produce a `?0` which -- in turn -- triggered an ICE in
5 // hashing.
6
7 // revisions:cfail1
8
9 fn main() {
10 println!("Hello, world! {}",*thread_rng().choose(&[0, 1, 2, 3]).unwrap());
11 //[cfail1]~^ ERROR cannot find function `thread_rng`
12 }