Skip to content

Commit 58b00b0

Browse files
Rollup merge of #144548 - Oneirical:uncountable-integer-2, r=jieyouxu
Rehome 21 `tests/ui/issues/` tests to other subdirectories under `tests/ui/` #143902 divided into smaller, easier to review chunks. Part of #133895 Methodology: 1. Refer to the previously written `tests/ui/SUMMARY.md` 2. Find an appropriate category for the test, using the original issue thread and the test contents. 3. Add the issue URL at the bottom (not at the top, as that would mess up stderr line numbers) 4. Rename the tests to make their purpose clearer Inspired by the methodology that ``@Kivooeo`` was using. r? ``@jieyouxu``
2 parents 2e97165 + 807d340 commit 58b00b0

File tree

34 files changed

+87
-78
lines changed

34 files changed

+87
-78
lines changed

tests/ui/issues/issue-26095.rs renamed to tests/ui/associated-consts/constant-trait-item-reference-selection-26095.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1+
// https://github.com/rust-lang/rust/issues/26095
12
//@ check-pass
23
#![allow(dead_code)]
34
#![allow(non_upper_case_globals)]
45

5-
66
trait HasNumber<T> {
77
const Number: usize;
88
}

tests/ui/issues/issue-54044.rs renamed to tests/ui/attributes/cold-attribute-application-54044.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// https://github.com/rust-lang/rust/issues/54044
12
#![deny(unused_attributes)] //~ NOTE lint level is defined here
23

34
#[cold]

tests/ui/issues/issue-54044.stderr renamed to tests/ui/attributes/cold-attribute-application-54044.stderr

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
error: attribute should be applied to a function definition
2-
--> $DIR/issue-54044.rs:3:1
2+
--> $DIR/cold-attribute-application-54044.rs:4:1
33
|
44
LL | #[cold]
55
| ^^^^^^^
@@ -9,13 +9,13 @@ LL | struct Foo;
99
|
1010
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
1111
note: the lint level is defined here
12-
--> $DIR/issue-54044.rs:1:9
12+
--> $DIR/cold-attribute-application-54044.rs:2:9
1313
|
1414
LL | #![deny(unused_attributes)]
1515
| ^^^^^^^^^^^^^^^^^
1616

1717
error: attribute should be applied to a function definition
18-
--> $DIR/issue-54044.rs:9:5
18+
--> $DIR/cold-attribute-application-54044.rs:10:5
1919
|
2020
LL | #[cold]
2121
| ^^^^^^^

tests/ui/issues/issue-36786-resolve-call.rs renamed to tests/ui/autoref-autoderef/autoderef-vec-box-fn-36786.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// https://github.com/rust-lang/rust/issues/36786
12
//@ run-pass
23
// Ensure that types that rely on obligations are autoderefed
34
// correctly

tests/ui/issues/issue-46471-1.rs renamed to tests/ui/borrowck/borrow-checker-lifetime-error-46471.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// https://github.com/rust-lang/rust/issues/46471
12
fn main() {
23
let y = {
34
let mut z = 0;

tests/ui/issues/issue-46471-1.stderr renamed to tests/ui/borrowck/borrow-checker-lifetime-error-46471.stderr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
error[E0597]: `z` does not live long enough
2-
--> $DIR/issue-46471-1.rs:4:9
2+
--> $DIR/borrow-checker-lifetime-error-46471.rs:5:9
33
|
44
LL | let mut z = 0;
55
| ----- binding `z` declared here
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
// https://github.com/rust-lang/rust/issues/11869
2+
//@ check-pass
3+
#![allow(dead_code)]
4+
5+
struct A {
6+
a: String
7+
}
8+
9+
fn borrow<'a>(binding: &'a A) -> &'a str {
10+
match &*binding.a {
11+
"in" => "in_",
12+
"ref" => "ref_",
13+
ident => ident
14+
}
15+
}
16+
17+
fn main() {}

tests/ui/issues/issue-9918.rs renamed to tests/ui/cast/u8-to-char-cast-9918.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// https://github.com/rust-lang/rust/issues/9918
12
//@ run-pass
23

34
pub fn main() {

tests/ui/issues/issue-36023.rs renamed to tests/ui/codegen/llvm-miscompile-metadata-invalidation-36023.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// https://github.com/rust-lang/rust/issues/36023
12
//@ run-pass
23
#![allow(unused_variables)]
34
use std::ops::Deref;

tests/ui/issues/issue-18058.rs renamed to tests/ui/coherence/impl-coherence-error-for-undefined-type-18058.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// https://github.com/rust-lang/rust/issues/18058
12
impl Undefined {}
23
//~^ ERROR cannot find type `Undefined` in this scope
34

0 commit comments

Comments
 (0)