Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tests: ui/inline-consts: add issue number to a test, rename other tests #133078

Merged
merged 1 commit into from
Nov 21, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
error[E0767]: use of unreachable label `'a`
--> $DIR/cross_const_control_flow.rs:9:25
--> $DIR/cross-const-control-flow-125846.rs:9:25
|
LL | 'a: { const { break 'a } }
| -- ^^ unreachable label `'a`
Expand All @@ -9,7 +9,7 @@ LL | 'a: { const { break 'a } }
= note: labels are unreachable through functions, closures, async blocks and modules

error[E0767]: use of unreachable label `'a`
--> $DIR/cross_const_control_flow.rs:22:28
--> $DIR/cross-const-control-flow-125846.rs:22:28
|
LL | 'a: { const { continue 'a } }
| -- ^^ unreachable label `'a`
Expand All @@ -19,7 +19,7 @@ LL | 'a: { const { continue 'a } }
= note: labels are unreachable through functions, closures, async blocks and modules

error[E0435]: attempt to use a non-constant value in a constant
--> $DIR/cross_const_control_flow.rs:41:14
--> $DIR/cross-const-control-flow-125846.rs:41:14
|
LL | const { &x };
| ^ non-constant value
Expand All @@ -30,7 +30,7 @@ LL | const x: /* Type */ = 1;
| ~~~~~ ++++++++++++

error[E0728]: `await` is only allowed inside `async` functions and blocks
--> $DIR/cross_const_control_flow.rs:35:22
--> $DIR/cross-const-control-flow-125846.rs:35:22
|
LL | const { async {}.await }
| -----------^^^^^--
Expand All @@ -39,31 +39,31 @@ LL | const { async {}.await }
| this is not `async`

error[E0268]: `break` outside of a loop or labeled block
--> $DIR/cross_const_control_flow.rs:9:19
--> $DIR/cross-const-control-flow-125846.rs:9:19
|
LL | 'a: { const { break 'a } }
| ^^^^^^^^ cannot `break` outside of a loop or labeled block

error[E0268]: `break` outside of a loop or labeled block
--> $DIR/cross_const_control_flow.rs:16:17
--> $DIR/cross-const-control-flow-125846.rs:16:17
|
LL | const { break }
| ^^^^^ cannot `break` outside of a loop or labeled block

error[E0268]: `continue` outside of a loop
--> $DIR/cross_const_control_flow.rs:22:19
--> $DIR/cross-const-control-flow-125846.rs:22:19
|
LL | 'a: { const { continue 'a } }
| ^^^^^^^^^^^ cannot `continue` outside of a loop

error[E0268]: `continue` outside of a loop
--> $DIR/cross_const_control_flow.rs:29:17
--> $DIR/cross-const-control-flow-125846.rs:29:17
|
LL | const { continue }
| ^^^^^^^^ cannot `continue` outside of a loop

error[E0572]: return statement outside of function body
--> $DIR/cross_const_control_flow.rs:4:13
--> $DIR/cross-const-control-flow-125846.rs:4:13
|
LL | / fn foo() {
LL | | const { return }
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
error[E0435]: attempt to use a non-constant value in a constant
--> $DIR/referencing_local_variables.rs:2:13
--> $DIR/referencing-local-variables.rs:2:13
|
LL | const fn test_me<T>(a: usize) -> usize {
| - this would need to be a `const`
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
error[E0381]: used binding `x` isn't initialized
--> $DIR/uninit_local.rs:4:15
--> $DIR/uninit-local.rs:4:15
|
LL | let x: bool;
| - binding declared here but left uninitialized
Expand Down
Loading