Skip to content

Commit c6ac70c

Browse files
authored
Change camel case warning to upper camel case
Rust structs should be named in upper camel case aka PascalCase. "Upper camel case" was decided upon as the preferred phrase over PascalCase per: rust-lang/rfcs#2389
1 parent 7821ee2 commit c6ac70c

File tree

1 file changed

+21
-21
lines changed

1 file changed

+21
-21
lines changed

src/test/ui/lint/lint-non-camel-case-types.stderr

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
error: type `ONE_TWO_THREE` should have a camel case name such as `OneTwoThree`
1+
error: type `ONE_TWO_THREE` should have an upper camel case name such as `OneTwoThree`
22
--> $DIR/lint-non-camel-case-types.rs:4:1
33
|
44
LL | struct ONE_TWO_THREE;
@@ -10,72 +10,72 @@ note: lint level defined here
1010
LL | #![forbid(non_camel_case_types)]
1111
| ^^^^^^^^^^^^^^^^^^^^
1212

13-
error: type `foo` should have a camel case name such as `Foo`
13+
error: type `foo` should have an upper camel case name such as `Foo`
1414
--> $DIR/lint-non-camel-case-types.rs:7:1
1515
|
16-
LL | / struct foo { //~ ERROR type `foo` should have a camel case name such as `Foo`
16+
LL | / struct foo { //~ ERROR type `foo` should have an upper camel case name such as `Foo`
1717
LL | | bar: isize,
1818
LL | | }
1919
| |_^
2020

21-
error: type `foo2` should have a camel case name such as `Foo2`
21+
error: type `foo2` should have an upper camel case name such as `Foo2`
2222
--> $DIR/lint-non-camel-case-types.rs:11:1
2323
|
24-
LL | / enum foo2 { //~ ERROR type `foo2` should have a camel case name such as `Foo2`
24+
LL | / enum foo2 { //~ ERROR type `foo2` should have an upper camel case name such as `Foo2`
2525
LL | | Bar
2626
LL | | }
2727
| |_^
2828

29-
error: type `foo3` should have a camel case name such as `Foo3`
29+
error: type `foo3` should have an upper camel case name such as `Foo3`
3030
--> $DIR/lint-non-camel-case-types.rs:15:1
3131
|
32-
LL | / struct foo3 { //~ ERROR type `foo3` should have a camel case name such as `Foo3`
32+
LL | / struct foo3 { //~ ERROR type `foo3` should have an upper camel case name such as `Foo3`
3333
LL | | bar: isize
3434
LL | | }
3535
| |_^
3636

37-
error: type `foo4` should have a camel case name such as `Foo4`
37+
error: type `foo4` should have an upper camel case name such as `Foo4`
3838
--> $DIR/lint-non-camel-case-types.rs:19:1
3939
|
40-
LL | type foo4 = isize; //~ ERROR type `foo4` should have a camel case name such as `Foo4`
40+
LL | type foo4 = isize; //~ ERROR type `foo4` should have an upper camel case name such as `Foo4`
4141
| ^^^^^^^^^^^^^^^^^^
4242

43-
error: variant `bar` should have a camel case name such as `Bar`
43+
error: variant `bar` should have an upper camel case name such as `Bar`
4444
--> $DIR/lint-non-camel-case-types.rs:22:5
4545
|
46-
LL | bar //~ ERROR variant `bar` should have a camel case name such as `Bar`
46+
LL | bar //~ ERROR variant `bar` should have an upper camel case name such as `Bar`
4747
| ^^^
4848

49-
error: trait `foo6` should have a camel case name such as `Foo6`
49+
error: trait `foo6` should have an upper camel case name such as `Foo6`
5050
--> $DIR/lint-non-camel-case-types.rs:25:1
5151
|
52-
LL | / trait foo6 { //~ ERROR trait `foo6` should have a camel case name such as `Foo6`
52+
LL | / trait foo6 { //~ ERROR trait `foo6` should have an upper camel case name such as `Foo6`
5353
LL | | fn dummy(&self) { }
5454
LL | | }
5555
| |_^
5656

57-
error: type parameter `ty` should have a camel case name such as `Ty`
57+
error: type parameter `ty` should have an upper camel case name such as `Ty`
5858
--> $DIR/lint-non-camel-case-types.rs:29:6
5959
|
60-
LL | fn f<ty>(_: ty) {} //~ ERROR type parameter `ty` should have a camel case name such as `Ty`
60+
LL | fn f<ty>(_: ty) {} //~ ERROR type parameter `ty` should have an upper camel case name such as `Ty`
6161
| ^^
6262

63-
error: type `X86__64` should have a camel case name such as `X86_64`
63+
error: type `X86__64` should have an upper camel case name such as `X86_64`
6464
--> $DIR/lint-non-camel-case-types.rs:38:1
6565
|
66-
LL | struct X86__64; //~ ERROR type `X86__64` should have a camel case name such as `X86_64`
66+
LL | struct X86__64; //~ ERROR type `X86__64` should have an upper camel case name such as `X86_64`
6767
| ^^^^^^^^^^^^^^^
6868

69-
error: type `Abc_123` should have a camel case name such as `Abc123`
69+
error: type `Abc_123` should have an upper camel case name such as `Abc123`
7070
--> $DIR/lint-non-camel-case-types.rs:40:1
7171
|
72-
LL | struct Abc_123; //~ ERROR type `Abc_123` should have a camel case name such as `Abc123`
72+
LL | struct Abc_123; //~ ERROR type `Abc_123` should have an upper camel case name such as `Abc123`
7373
| ^^^^^^^^^^^^^^^
7474

75-
error: type `A1_b2_c3` should have a camel case name such as `A1B2C3`
75+
error: type `A1_b2_c3` should have an upper camel case name such as `A1B2C3`
7676
--> $DIR/lint-non-camel-case-types.rs:42:1
7777
|
78-
LL | struct A1_b2_c3; //~ ERROR type `A1_b2_c3` should have a camel case name such as `A1B2C3`
78+
LL | struct A1_b2_c3; //~ ERROR type `A1_b2_c3` should have an upper camel case name such as `A1B2C3`
7979
| ^^^^^^^^^^^^^^^^
8080

8181
error: aborting due to 11 previous errors

0 commit comments

Comments
 (0)