]> git.lizzy.rs Git - rust.git/blob - src/test/ui/consts/issue-83182.rs
Rollup merge of #98609 - TaKO8Ki:fix-ice-for-associated-constant-generics, r=lcnr
[rust.git] / src / test / ui / consts / issue-83182.rs
1 // stderr-per-bitwidth
2
3 use std::mem;
4 struct MyStr(str);
5 const MYSTR_NO_INIT: &MyStr = unsafe { mem::transmute::<&[_], _>(&[&()]) };
6 //~^ ERROR: it is undefined behavior to use this value
7 //~| type validation failed at .<deref>.0: encountered a pointer in `str`
8 fn main() {}