From 218caa410aa38c29984be31a5229b9fa717560ee Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Wed, 17 Apr 2024 14:19:13 +0200 Subject: Merging upstream version 1.68.2+dfsg1. Signed-off-by: Daniel Baumann --- tests/ui/issues/issue-44239.fixed | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 tests/ui/issues/issue-44239.fixed (limited to 'tests/ui/issues/issue-44239.fixed') diff --git a/tests/ui/issues/issue-44239.fixed b/tests/ui/issues/issue-44239.fixed new file mode 100644 index 000000000..e6c29cee9 --- /dev/null +++ b/tests/ui/issues/issue-44239.fixed @@ -0,0 +1,11 @@ +// run-rustfix +#![allow(dead_code, non_upper_case_globals)] +fn main() { + const n: usize = 0; + + struct Foo; + impl Foo { + const N: usize = n; + //~^ ERROR attempt to use a non-constant value + } +} -- cgit v1.2.3