]> git.lizzy.rs Git - rust.git/blob - tests/ui/mir/mir_ascription_coercion.rs
Auto merge of #106520 - ehuss:update-mdbook, r=Mark-Simulacrum
[rust.git] / tests / ui / mir / mir_ascription_coercion.rs
1 // run-pass
2 // Tests that the result of type ascription has adjustments applied
3
4 #![feature(type_ascription)]
5
6 fn main() {
7     let x = [1, 2, 3];
8     // The RHS should coerce to &[i32]
9     let _y : &[i32] = type_ascribe!(&x, &[i32; 3]);
10 }