Skip to content

Commit ec43cb3

Browse files
Update UI tests for primitive type ambiguity error renaming
1 parent 95926b2 commit ec43cb3

9 files changed

+25
-25
lines changed

tests/rustdoc-ui/intra-doc/ambiguity.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,6 @@ pub mod foo {
3535
/// Ambiguous non-implied shortcut link [`foo::bar`]. //~ERROR `foo::bar`
3636
pub struct Docs {}
3737

38-
/// [true] //~ ERROR `true` is both a module and a builtin type
38+
/// [true] //~ ERROR `true` is both a module and a primitive type
3939
/// [primitive@true]
4040
pub mod r#true {}

tests/rustdoc-ui/intra-doc/ambiguity.stderr

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
error: `true` is both a module and a builtin type
1+
error: `true` is both a module and a primitive type
22
--> $DIR/ambiguity.rs:38:6
33
|
44
LL | /// [true]
@@ -13,7 +13,7 @@ help: to link to the module, prefix with `mod@`
1313
|
1414
LL | /// [mod@true]
1515
| ++++
16-
help: to link to the builtin type, prefix with `prim@`
16+
help: to link to the primitive type, prefix with `prim@`
1717
|
1818
LL | /// [prim@true]
1919
| +++++

tests/rustdoc-ui/intra-doc/errors.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -54,11 +54,11 @@
5454

5555
/// [u8::not_found]
5656
//~^ ERROR unresolved link
57-
//~| NOTE the builtin type `u8` has no associated item named `not_found`
57+
//~| NOTE the primitive type `u8` has no associated item named `not_found`
5858

5959
/// [std::primitive::u8::not_found]
6060
//~^ ERROR unresolved link
61-
//~| NOTE the builtin type `u8` has no associated item named `not_found`
61+
//~| NOTE the primitive type `u8` has no associated item named `not_found`
6262

6363
/// [type@Vec::into_iter]
6464
//~^ ERROR unresolved link

tests/rustdoc-ui/intra-doc/errors.stderr

+2-2
Original file line numberDiff line numberDiff line change
@@ -80,13 +80,13 @@ error: unresolved link to `u8::not_found`
8080
--> $DIR/errors.rs:55:6
8181
|
8282
LL | /// [u8::not_found]
83-
| ^^^^^^^^^^^^^ the builtin type `u8` has no associated item named `not_found`
83+
| ^^^^^^^^^^^^^ the primitive type `u8` has no associated item named `not_found`
8484

8585
error: unresolved link to `std::primitive::u8::not_found`
8686
--> $DIR/errors.rs:59:6
8787
|
8888
LL | /// [std::primitive::u8::not_found]
89-
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the builtin type `u8` has no associated item named `not_found`
89+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the primitive type `u8` has no associated item named `not_found`
9090

9191
error: unresolved link to `Vec::into_iter`
9292
--> $DIR/errors.rs:63:6

tests/rustdoc-ui/intra-doc/issue-108653-associated-items-6.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
#![allow(nonstandard_style)]
33

44
/// [`u32::MAX`]
5-
//~^ ERROR both an associated constant and a builtin type
5+
//~^ ERROR both an associated constant and a primitive type
66
pub mod u32 {
77
pub use std::primitive::u32 as MAX;
88
}

tests/rustdoc-ui/intra-doc/issue-108653-associated-items-6.stderr

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
error: `u32::MAX` is both an associated constant and a builtin type
1+
error: `u32::MAX` is both an associated constant and a primitive type
22
--> $DIR/issue-108653-associated-items-6.rs:4:7
33
|
44
LL | /// [`u32::MAX`]
@@ -13,7 +13,7 @@ help: to link to the associated constant, prefix with `const@`
1313
|
1414
LL | /// [`const@u32::MAX`]
1515
| ++++++
16-
help: to link to the builtin type, prefix with `prim@`
16+
help: to link to the primitive type, prefix with `prim@`
1717
|
1818
LL | /// [`prim@u32::MAX`]
1919
| +++++

tests/rustdoc-ui/intra-doc/non-path-primitives.stderr

+4-4
Original file line numberDiff line numberDiff line change
@@ -39,25 +39,25 @@ error: unresolved link to `unit::eq`
3939
--> $DIR/non-path-primitives.rs:28:6
4040
|
4141
LL | //! [unit::eq]
42-
| ^^^^^^^^ the builtin type `unit` has no associated item named `eq`
42+
| ^^^^^^^^ the primitive type `unit` has no associated item named `eq`
4343

4444
error: unresolved link to `tuple::eq`
4545
--> $DIR/non-path-primitives.rs:29:6
4646
|
4747
LL | //! [tuple::eq]
48-
| ^^^^^^^^^ the builtin type `tuple` has no associated item named `eq`
48+
| ^^^^^^^^^ the primitive type `tuple` has no associated item named `eq`
4949

5050
error: unresolved link to `fn::eq`
5151
--> $DIR/non-path-primitives.rs:30:6
5252
|
5353
LL | //! [fn::eq]
54-
| ^^^^^^ the builtin type `fn` has no associated item named `eq`
54+
| ^^^^^^ the primitive type `fn` has no associated item named `eq`
5555

5656
error: unresolved link to `reference::deref`
5757
--> $DIR/non-path-primitives.rs:34:6
5858
|
5959
LL | //! [reference::deref]
60-
| ^^^^^^^^^^^^^^^^ the builtin type `reference` has no associated item named `deref`
60+
| ^^^^^^^^^^^^^^^^ the primitive type `reference` has no associated item named `deref`
6161

6262
error: aborting due to 8 previous errors
6363

tests/rustdoc-ui/intra-doc/prim-conflict.rs

+5-5
Original file line numberDiff line numberDiff line change
@@ -2,16 +2,16 @@
22
//~^ NOTE lint level is defined
33

44
/// [char]
5-
//~^ ERROR both a module and a builtin type
5+
//~^ ERROR both a module and a primitive type
66
//~| NOTE ambiguous link
77
//~| HELP to link to the module
8-
//~| HELP to link to the builtin type
8+
//~| HELP to link to the primitive type
99

1010
/// [type@char]
11-
//~^ ERROR both a module and a builtin type
11+
//~^ ERROR both a module and a primitive type
1212
//~| NOTE ambiguous link
1313
//~| HELP to link to the module
14-
//~| HELP to link to the builtin type
14+
//~| HELP to link to the primitive type
1515

1616
/// [mod@char] // ok
1717
/// [prim@char] // ok
@@ -26,5 +26,5 @@ pub mod inner {
2626
//! [struct@char]
2727
//~^ ERROR incompatible link
2828
//~| HELP prefix with `prim@`
29-
//~| NOTE resolved to a builtin type
29+
//~| NOTE resolved to a primitive type
3030
}

tests/rustdoc-ui/intra-doc/prim-conflict.stderr

+6-6
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
error: `char` is both a module and a builtin type
1+
error: `char` is both a module and a primitive type
22
--> $DIR/prim-conflict.rs:4:6
33
|
44
LL | /// [char]
@@ -13,12 +13,12 @@ help: to link to the module, prefix with `mod@`
1313
|
1414
LL | /// [mod@char]
1515
| ++++
16-
help: to link to the builtin type, prefix with `prim@`
16+
help: to link to the primitive type, prefix with `prim@`
1717
|
1818
LL | /// [prim@char]
1919
| +++++
2020

21-
error: `char` is both a module and a builtin type
21+
error: `char` is both a module and a primitive type
2222
--> $DIR/prim-conflict.rs:10:6
2323
|
2424
LL | /// [type@char]
@@ -28,7 +28,7 @@ help: to link to the module, prefix with `mod@`
2828
|
2929
LL | /// [mod@char]
3030
| ~~~~
31-
help: to link to the builtin type, prefix with `prim@`
31+
help: to link to the primitive type, prefix with `prim@`
3232
|
3333
LL | /// [prim@char]
3434
| ~~~~~
@@ -48,9 +48,9 @@ error: incompatible link kind for `char`
4848
--> $DIR/prim-conflict.rs:26:10
4949
|
5050
LL | //! [struct@char]
51-
| ^^^^^^^^^^^ this link resolved to a builtin type, which is not a struct
51+
| ^^^^^^^^^^^ this link resolved to a primitive type, which is not a struct
5252
|
53-
help: to link to the builtin type, prefix with `prim@`
53+
help: to link to the primitive type, prefix with `prim@`
5454
|
5555
LL | //! [prim@char]
5656
| ~~~~~

0 commit comments

Comments
 (0)