diff options
Diffstat (limited to 'tests/ui/consts/const-eval/issue-85907.rs')
-rw-r--r-- | tests/ui/consts/const-eval/issue-85907.rs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/ui/consts/const-eval/issue-85907.rs b/tests/ui/consts/const-eval/issue-85907.rs new file mode 100644 index 000000000..6ae40ae6d --- /dev/null +++ b/tests/ui/consts/const-eval/issue-85907.rs @@ -0,0 +1,7 @@ +const fn hey() -> usize { + panic!(123); //~ ERROR argument to `panic!()` in a const context must have type `&str` +} + +fn main() { + let _: [u8; hey()] = todo!(); +} |