Skip to content

Commit d5bd2cd

Browse files
committed
update name in tests: ui, mir-opt, std, llvm cg
1 parent 9961959 commit d5bd2cd

File tree

12 files changed

+21
-17
lines changed

12 files changed

+21
-17
lines changed

library/std/tests/type-name-unsized.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ impl Trait for i32 {
4848
}
4949

5050
fn bar<T: Trait>() {
51-
check!(T::Assoc, "alloc::string::String");
51+
check!(T::Assoc, "alloc::string::generic::String");
5252
check!(T, "i32");
5353
}
5454

tests/codegen-llvm/annotate-moves/integration.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ pub fn test_copy_ref(x: &ExplicitCopy) {
163163
// CHECK-DAG: ![[#ASSIGN_COPY2_SCOPE]] = {{(distinct )?}}!DISubprogram(name: "compiler_move<{{(array\$<|\[)u64[,;].*}},{{ *[0-9]+}}>"
164164

165165
// CHECK-DAG: ![[#INIT_STRUCT_LOC]] = !DILocation({{.*}}scope: ![[#INIT_STRUCT_SCOPE:]]
166-
// CHECK-DAG: ![[#INIT_STRUCT_SCOPE]] = {{(distinct )?}}!DISubprogram(name: "compiler_move<alloc::string::String,{{ *[0-9]+}}>"
166+
// CHECK-DAG: ![[#INIT_STRUCT_SCOPE]] = {{(distinct )?}}!DISubprogram(name: "compiler_move<{{alloc::([a-z_]+::)+String<.+>}},{{ *[0-9]+}}>"
167167

168168
// CHECK-DAG: ![[#TUPLE_MOVE_LOC]] = !DILocation({{.*}}scope: ![[#TUPLE_MOVE_SCOPE:]]
169169
// CHECK-DAG: ![[#TUPLE_MOVE_SCOPE]] = {{(distinct )?}}!DISubprogram(name: "compiler_move<{{(array\$<|\[)u64[,;].*}},{{ *[0-9]+}}>"
@@ -175,7 +175,7 @@ pub fn test_copy_ref(x: &ExplicitCopy) {
175175
// CHECK-DAG: ![[#COPY2_SCOPE]] = {{(distinct )?}}!DISubprogram(name: "compiler_move<{{(array\$<|\[)u64[,;].*}},{{ *[0-9]+}}>"
176176

177177
// CHECK-DAG: ![[#ARRAY_MOVE_LOC]] = !DILocation({{.*}}scope: ![[#ARRAY_MOVE_SCOPE:]]
178-
// CHECK-DAG: ![[#ARRAY_MOVE_SCOPE]] = {{(distinct )?}}!DISubprogram(name: "compiler_move<{{(array\$<|\[)alloc::string::String[,;].*}},{{ *[0-9]+}}>"
178+
// CHECK-DAG: ![[#ARRAY_MOVE_SCOPE]] = {{(distinct )?}}!DISubprogram(name: "compiler_move<{{(array\$<|\[)alloc::([a-z_]+::)+String<.+>[,;].*}},{{ *[0-9]+}}>"
179179

180180
// CHECK-DAG: ![[#FIELD_MOVE_LOC]] = !DILocation({{.*}}scope: ![[#FIELD_MOVE_SCOPE:]]
181181
// CHECK-DAG: ![[#FIELD_MOVE_SCOPE]] = {{(distinct )?}}!DISubprogram(name: "compiler_move<{{(array\$<|\[)u64[,;].*}},{{ *[0-9]+}}>"

tests/mir-opt/box_partial_move.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
// EMIT_MIR box_partial_move.maybe_move.ElaborateDrops.diff
77
fn maybe_move(cond: bool, thing: Box<String>) -> Option<String> {
88
// CHECK-LABEL: fn maybe_move(
9-
// CHECK: let mut [[PTR:_[0-9]+]]: *const std::string::String;
10-
// CHECK: [[PTR]] = copy ((_2.0: std::ptr::Unique<std::string::String>).0: std::ptr::NonNull<std::string::String>) as *const std::string::String (Transmute);
9+
// CHECK: let mut [[PTR:_[0-9]+]]: *const std::string::generic::String;
10+
// CHECK: [[PTR]] = copy ((_2.0: std::ptr::Unique<std::string::generic::String>).0: std::ptr::NonNull<std::string::generic::String>) as *const std::string::generic::String (Transmute);
1111
// CHECK: drop((*[[PTR]]))
1212
if cond { Some(*thing) } else { None }
1313
}

tests/mir-opt/ergonomic-clones/closure.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ use std::clone::UseCloned;
66

77
pub fn ergonomic_clone_closure_move() -> String {
88
// CHECK-LABEL: fn ergonomic_clone_closure_move(
9-
// CHECK: _0 = move (_1.0: std::string::String);
9+
// CHECK: _0 = move (_1.0: std::string::generic::String);
1010
// CHECK-NOT: <String as Clone>::clone
1111
let s = String::from("hi");
1212

tests/ui/issues/issue-53348.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ fn main() {
1010
a = *i.to_string();
1111
//~^ ERROR mismatched types
1212
//~| NOTE expected `String`, found `str`
13+
//~| NOTE expected struct `String`
1314
v2.push(a);
1415
}
1516
}

tests/ui/pattern/issue-115599.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
1+
// Check that we do not ICE when matching uninitialized constant with constant pattern
2+
13
const CONST_STRING: String = String::new();
24

35
fn main() {
46
let empty_str = String::from("");
57
if let CONST_STRING = empty_str {}
6-
//~^ ERROR constant of non-structural type `Vec<u8>` in a pattern
8+
//~^ ERROR constant of non-structural type `String` in a pattern
79
}

tests/ui/resolve/dot-notation-type-namespace-suggest-path-sep.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,11 @@ mod foo {
88

99
fn main() {
1010
let _ = String.new();
11-
//~^ ERROR expected value, found struct `String`
11+
//~^ ERROR expected value, found type alias `String`
1212
//~| HELP use the path separator
1313

1414
let _ = String.default;
15-
//~^ ERROR expected value, found struct `String`
15+
//~^ ERROR expected value, found type alias `String`
1616
//~| HELP use the path separator
1717

1818
let _ = Vec::<()>.with_capacity(1);

tests/ui/resolve/unresolved-segments-visibility.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,6 @@ extern crate alloc as b;
66
mod foo {
77
mod bar {
88
pub(in crate::b::string::String::newy) extern crate alloc as e;
9-
//~^ ERROR failed to resolve: `String` is a struct, not a module [E0433]
9+
//~^ ERROR failed to resolve: `String` is a type alias, not a module [E0433]
1010
}
1111
}

tests/ui/static/bad-const-type.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
static i: String = 10;
22
//~^ ERROR mismatched types
33
//~| NOTE expected `String`, found integer
4+
//~| NOTE expected struct `String`
45
fn main() { println!("{}", i); }

tests/ui/traits/associated_type_bound/assoc_type_bound_with_struct.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,22 +2,22 @@ trait Bar {
22
type Baz;
33
}
44

5-
struct Foo<T> where T: Bar, <T as Bar>::Baz: String { //~ ERROR expected trait, found struct
5+
struct Foo<T> where T: Bar, <T as Bar>::Baz: String { //~ ERROR expected trait, found
66
t: T,
77
}
88

9-
struct Qux<'a, T> where T: Bar, <&'a T as Bar>::Baz: String { //~ ERROR expected trait, found struct
9+
struct Qux<'a, T> where T: Bar, <&'a T as Bar>::Baz: String { //~ ERROR expected trait, found
1010
t: &'a T,
1111
}
1212

13-
fn foo<T: Bar>(_: T) where <T as Bar>::Baz: String { //~ ERROR expected trait, found struct
13+
fn foo<T: Bar>(_: T) where <T as Bar>::Baz: String { //~ ERROR expected trait, found
1414
}
1515

1616
fn qux<'a, T: Bar>(_: &'a T) where <&'a T as Bar>::Baz: String { //~ ERROR expected trait, found
1717
}
1818

1919
fn issue_95327() where <u8 as Unresolved>::Assoc: String {}
20-
//~^ ERROR expected trait, found struct
20+
//~^ ERROR expected trait, found
2121
//~| ERROR cannot find trait `Unresolved` in this scope
2222

2323
fn main() {}

0 commit comments

Comments
 (0)