diff options
| author | Oliver Schneider <git-spam-no-reply9815368754983@oli-obk.de> | 2018-04-20 14:18:29 +0200 |
|---|---|---|
| committer | Oliver Schneider <git-spam-no-reply9815368754983@oli-obk.de> | 2018-04-24 13:11:48 +0200 |
| commit | cd6c186e4eb410413522e2be2ef6309edf3d0b32 (patch) | |
| tree | fe3f5e008cd252804e323c692124386384bf5197 /src/test/ui/const-eval/conditional_array_execution.rs | |
| parent | 52ed3d8761dc42e51429eb3bbf56a94d14fdd5c6 (diff) | |
Warn on all erroneous constants
Diffstat (limited to 'src/test/ui/const-eval/conditional_array_execution.rs')
| -rw-r--r-- | src/test/ui/const-eval/conditional_array_execution.rs | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/test/ui/const-eval/conditional_array_execution.rs b/src/test/ui/const-eval/conditional_array_execution.rs index e059c354d65..dbddee862e0 100644 --- a/src/test/ui/const-eval/conditional_array_execution.rs +++ b/src/test/ui/const-eval/conditional_array_execution.rs @@ -14,6 +14,7 @@ const X: u32 = 5; const Y: u32 = 6; const FOO: u32 = [X - Y, Y - X][(X < Y) as usize]; //~^ WARN attempt to subtract with overflow +//~| WARN this constant cannot be used fn main() { println!("{}", FOO); |
