diff --git a/tests/ui/builtin-type-shadow.rs b/tests/ui/builtin-type-shadow.rs index 66a7e318f8af..e9df0992c5eb 100644 --- a/tests/ui/builtin-type-shadow.rs +++ b/tests/ui/builtin-type-shadow.rs @@ -8,6 +8,7 @@ // except according to those terms. #![warn(clippy::builtin_type_shadow)] +#![allow(non_camel_case_types)] fn foo(a: u32) -> u32 { 42 diff --git a/tests/ui/builtin-type-shadow.stderr b/tests/ui/builtin-type-shadow.stderr index 540d9f4f4584..f6ee513820e8 100644 --- a/tests/ui/builtin-type-shadow.stderr +++ b/tests/ui/builtin-type-shadow.stderr @@ -1,17 +1,17 @@ error: This generic shadows the built-in type `u32` - --> $DIR/builtin-type-shadow.rs:12:8 + --> $DIR/builtin-type-shadow.rs:13:8 | -12 | fn foo(a: u32) -> u32 { +13 | fn foo(a: u32) -> u32 { | ^^^ | = note: `-D clippy::builtin-type-shadow` implied by `-D warnings` error[E0308]: mismatched types - --> $DIR/builtin-type-shadow.rs:13:5 + --> $DIR/builtin-type-shadow.rs:14:5 | -12 | fn foo(a: u32) -> u32 { +13 | fn foo(a: u32) -> u32 { | --- expected `u32` because of return type -13 | 42 +14 | 42 | ^^ expected type parameter, found integral variable | = note: expected type `u32` diff --git a/tests/ui/enum_variants.rs b/tests/ui/enum_variants.rs index 0c8f3a36a3d9..33472a7f83c3 100644 --- a/tests/ui/enum_variants.rs +++ b/tests/ui/enum_variants.rs @@ -9,6 +9,7 @@ #![feature(non_ascii_idents)] #![warn(clippy::all, clippy::pub_enum_variant_names)] +#![allow(non_camel_case_types)] enum FakeCallType { CALL, diff --git a/tests/ui/enum_variants.stderr b/tests/ui/enum_variants.stderr index ff8f9b82ae6d..1f554e2c33a2 100644 --- a/tests/ui/enum_variants.stderr +++ b/tests/ui/enum_variants.stderr @@ -1,97 +1,97 @@ error: Variant name ends with the enum's name - --> $DIR/enum_variants.rs:24:5 + --> $DIR/enum_variants.rs:25:5 | -24 | cFoo, +25 | cFoo, | ^^^^ | = note: `-D clippy::enum-variant-names` implied by `-D warnings` error: Variant name starts with the enum's name - --> $DIR/enum_variants.rs:35:5 + --> $DIR/enum_variants.rs:36:5 | -35 | FoodGood, +36 | FoodGood, | ^^^^^^^^ error: Variant name starts with the enum's name - --> $DIR/enum_variants.rs:36:5 + --> $DIR/enum_variants.rs:37:5 | -36 | FoodMiddle, +37 | FoodMiddle, | ^^^^^^^^^^ error: Variant name starts with the enum's name - --> $DIR/enum_variants.rs:37:5 + --> $DIR/enum_variants.rs:38:5 | -37 | FoodBad, +38 | FoodBad, | ^^^^^^^ error: All variants have the same prefix: `Food` - --> $DIR/enum_variants.rs:34:1 + --> $DIR/enum_variants.rs:35:1 | -34 | / enum Food { -35 | | FoodGood, -36 | | FoodMiddle, -37 | | FoodBad, -38 | | } +35 | / enum Food { +36 | | FoodGood, +37 | | FoodMiddle, +38 | | FoodBad, +39 | | } | |_^ | = help: remove the prefixes and use full paths to the variants instead of glob imports error: All variants have the same prefix: `CallType` - --> $DIR/enum_variants.rs:44:1 + --> $DIR/enum_variants.rs:45:1 | -44 | / enum BadCallType { -45 | | CallTypeCall, -46 | | CallTypeCreate, -47 | | CallTypeDestroy, -48 | | } +45 | / enum BadCallType { +46 | | CallTypeCall, +47 | | CallTypeCreate, +48 | | CallTypeDestroy, +49 | | } | |_^ | = help: remove the prefixes and use full paths to the variants instead of glob imports error: All variants have the same prefix: `Constant` - --> $DIR/enum_variants.rs:56:1 + --> $DIR/enum_variants.rs:57:1 | -56 | / enum Consts { -57 | | ConstantInt, -58 | | ConstantCake, -59 | | ConstantLie, -60 | | } +57 | / enum Consts { +58 | | ConstantInt, +59 | | ConstantCake, +60 | | ConstantLie, +61 | | } | |_^ | = help: remove the prefixes and use full paths to the variants instead of glob imports error: All variants have the same prefix: `With` - --> $DIR/enum_variants.rs:90:1 + --> $DIR/enum_variants.rs:91:1 | -90 | / enum Seallll { -91 | | WithOutCake, -92 | | WithOutTea, -93 | | WithOut, -94 | | } +91 | / enum Seallll { +92 | | WithOutCake, +93 | | WithOutTea, +94 | | WithOut, +95 | | } | |_^ | = help: remove the prefixes and use full paths to the variants instead of glob imports error: All variants have the same prefix: `Prefix` - --> $DIR/enum_variants.rs:96:1 + --> $DIR/enum_variants.rs:97:1 | -96 | / enum NonCaps { -97 | | Prefix的, -98 | | PrefixTea, -99 | | PrefixCake, -100 | | } +97 | / enum NonCaps { +98 | | Prefix的, +99 | | PrefixTea, +100 | | PrefixCake, +101 | | } | |_^ | = help: remove the prefixes and use full paths to the variants instead of glob imports error: All variants have the same prefix: `With` - --> $DIR/enum_variants.rs:102:1 + --> $DIR/enum_variants.rs:103:1 | -102 | / pub enum PubSeall { -103 | | WithOutCake, -104 | | WithOutTea, -105 | | WithOut, -106 | | } +103 | / pub enum PubSeall { +104 | | WithOutCake, +105 | | WithOutTea, +106 | | WithOut, +107 | | } | |_^ | = note: `-D clippy::pub-enum-variant-names` implied by `-D warnings`