recover wrong-cased uses (Use, USE, etc)

This commit is contained in:
Maybe Waffle 2022-07-29 23:06:13 +04:00
parent de341fe668
commit 3694429d09
5 changed files with 77 additions and 3 deletions

View file

@ -0,0 +1,7 @@
// run-rustfix
#![allow(unused_imports)]
fn main() {}
use std::ptr::read; //~ ERROR keyword `use` is written in a wrong case
use std::ptr::write; //~ ERROR keyword `use` is written in a wrong case

View file

@ -0,0 +1,7 @@
// run-rustfix
#![allow(unused_imports)]
fn main() {}
Use std::ptr::read; //~ ERROR keyword `use` is written in a wrong case
USE std::ptr::write; //~ ERROR keyword `use` is written in a wrong case

View file

@ -0,0 +1,14 @@
error: keyword `use` is written in a wrong case
--> $DIR/item-kw-case-mismatch.rs:6:1
|
LL | Use std::ptr::read;
| ^^^ help: write it in the correct case (notice the capitalization): `use`
error: keyword `use` is written in a wrong case
--> $DIR/item-kw-case-mismatch.rs:7:1
|
LL | USE std::ptr::write;
| ^^^ help: write it in the correct case: `use`
error: aborting due to 2 previous errors