diff options
| author | Matthias Krüger <matthias.krueger@famsik.de> | 2023-07-25 19:21:38 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-07-25 19:21:38 +0200 |
| commit | 99f404aa733982d081677ab11f5ae3181621babc (patch) | |
| tree | e21b5bf044c2681533bd67a2415cefc4fd2fd819 /compiler/rustc_interface/src | |
| parent | 91d1d7aa4401d03c431aed47f8a07240db2382e7 (diff) | |
| parent | 5d32fd1b0623651cca15acd71ecc901324f3170c (diff) | |
| download | rust-99f404aa733982d081677ab11f5ae3181621babc.tar.gz rust-99f404aa733982d081677ab11f5ae3181621babc.zip | |
Rollup merge of #114051 - Enselic:const-local-var, r=cjgillot
Add regression test for invalid "unused const" in method
The warning can be reproduced with 1.63 but not with 1.64.
$ rustc +1.63 tests/ui/lint/unused/const-local-var.rs
warning: constant `F` is never used
--> tests/ui/lint/unused/const-local-var.rs:14:9
|
14 | const F: i32 = 2;
| ^^^^^^^^^^^^^^^^^
|
= note: `#[warn(dead_code)]` on by default
$ rustc +1.64 tests/ui/lint/unused/const-local-var.rs
Add a regression test to prevent the problem from re-appearing.
Closes #69016
Diffstat (limited to 'compiler/rustc_interface/src')
0 files changed, 0 insertions, 0 deletions
