diff options
| author | 许杰友 Jieyou Xu (Joe) <jieyouxu@outlook.com> | 2024-02-16 20:02:50 +0000 |
|---|---|---|
| committer | 许杰友 Jieyou Xu (Joe) <jieyouxu@outlook.com> | 2024-02-16 20:02:50 +0000 |
| commit | ec2cc761bc7067712ecc7734502f703fe3b024c8 (patch) | |
| tree | 7ab55cd9562da45b86c959f1b98c199b2b03ca92 /tests/ui/try-block | |
| parent | e53d6dd35bb38b81dff4b00497f4c152e9009499 (diff) | |
| download | rust-ec2cc761bc7067712ecc7734502f703fe3b024c8.tar.gz rust-ec2cc761bc7067712ecc7734502f703fe3b024c8.zip | |
[AUTO-GENERATED] Migrate ui tests from `//` to `//@` directives
Diffstat (limited to 'tests/ui/try-block')
| -rw-r--r-- | tests/ui/try-block/issue-45124.rs | 4 | ||||
| -rw-r--r-- | tests/ui/try-block/try-block-bad-lifetime.rs | 2 | ||||
| -rw-r--r-- | tests/ui/try-block/try-block-bad-type.rs | 2 | ||||
| -rw-r--r-- | tests/ui/try-block/try-block-catch.rs | 2 | ||||
| -rw-r--r-- | tests/ui/try-block/try-block-in-edition2015.rs | 2 | ||||
| -rw-r--r-- | tests/ui/try-block/try-block-in-match-arm.rs | 4 | ||||
| -rw-r--r-- | tests/ui/try-block/try-block-in-match.rs | 4 | ||||
| -rw-r--r-- | tests/ui/try-block/try-block-in-return.rs | 4 | ||||
| -rw-r--r-- | tests/ui/try-block/try-block-in-while.rs | 2 | ||||
| -rw-r--r-- | tests/ui/try-block/try-block-maybe-bad-lifetime.rs | 2 | ||||
| -rw-r--r-- | tests/ui/try-block/try-block-opt-init.rs | 2 | ||||
| -rw-r--r-- | tests/ui/try-block/try-block-type-error.rs | 2 | ||||
| -rw-r--r-- | tests/ui/try-block/try-block-unreachable-code-lint.rs | 4 | ||||
| -rw-r--r-- | tests/ui/try-block/try-block-unused-delims.fixed | 6 | ||||
| -rw-r--r-- | tests/ui/try-block/try-block-unused-delims.rs | 6 | ||||
| -rw-r--r-- | tests/ui/try-block/try-block.rs | 4 | ||||
| -rw-r--r-- | tests/ui/try-block/try-is-identifier-edition2015.rs | 4 |
17 files changed, 28 insertions, 28 deletions
diff --git a/tests/ui/try-block/issue-45124.rs b/tests/ui/try-block/issue-45124.rs index 2cf2ade65e9..e9e0e767efa 100644 --- a/tests/ui/try-block/issue-45124.rs +++ b/tests/ui/try-block/issue-45124.rs @@ -1,6 +1,6 @@ -// run-pass +//@ run-pass #![allow(unreachable_code)] -// compile-flags: --edition 2018 +//@ compile-flags: --edition 2018 #![feature(try_blocks)] diff --git a/tests/ui/try-block/try-block-bad-lifetime.rs b/tests/ui/try-block/try-block-bad-lifetime.rs index d9524e99f9a..bfff757a2df 100644 --- a/tests/ui/try-block/try-block-bad-lifetime.rs +++ b/tests/ui/try-block/try-block-bad-lifetime.rs @@ -1,4 +1,4 @@ -// compile-flags: --edition 2018 +//@ compile-flags: --edition 2018 #![feature(try_blocks)] diff --git a/tests/ui/try-block/try-block-bad-type.rs b/tests/ui/try-block/try-block-bad-type.rs index 30ae96763c0..71eb832dd4e 100644 --- a/tests/ui/try-block/try-block-bad-type.rs +++ b/tests/ui/try-block/try-block-bad-type.rs @@ -1,4 +1,4 @@ -// compile-flags: --edition 2018 +//@ compile-flags: --edition 2018 #![feature(try_blocks)] diff --git a/tests/ui/try-block/try-block-catch.rs b/tests/ui/try-block/try-block-catch.rs index d165015611d..c3aa442ba66 100644 --- a/tests/ui/try-block/try-block-catch.rs +++ b/tests/ui/try-block/try-block-catch.rs @@ -1,4 +1,4 @@ -// compile-flags: --edition 2018 +//@ compile-flags: --edition 2018 #![feature(try_blocks)] diff --git a/tests/ui/try-block/try-block-in-edition2015.rs b/tests/ui/try-block/try-block-in-edition2015.rs index 00964297308..423269df12d 100644 --- a/tests/ui/try-block/try-block-in-edition2015.rs +++ b/tests/ui/try-block/try-block-in-edition2015.rs @@ -1,4 +1,4 @@ -// compile-flags: --edition 2015 +//@ compile-flags: --edition 2015 pub fn main() { let try_result: Option<_> = try { diff --git a/tests/ui/try-block/try-block-in-match-arm.rs b/tests/ui/try-block/try-block-in-match-arm.rs index ea004ebe29f..cecbf724916 100644 --- a/tests/ui/try-block/try-block-in-match-arm.rs +++ b/tests/ui/try-block/try-block-in-match-arm.rs @@ -1,5 +1,5 @@ -// check-pass -// compile-flags: --edition 2018 +//@ check-pass +//@ compile-flags: --edition 2018 #![feature(try_blocks)] diff --git a/tests/ui/try-block/try-block-in-match.rs b/tests/ui/try-block/try-block-in-match.rs index cd0b967e79d..5c62f41efdb 100644 --- a/tests/ui/try-block/try-block-in-match.rs +++ b/tests/ui/try-block/try-block-in-match.rs @@ -1,5 +1,5 @@ -// run-pass -// compile-flags: --edition 2018 +//@ run-pass +//@ compile-flags: --edition 2018 #![feature(try_blocks)] diff --git a/tests/ui/try-block/try-block-in-return.rs b/tests/ui/try-block/try-block-in-return.rs index a15bfeef1c1..ee5ca696b6d 100644 --- a/tests/ui/try-block/try-block-in-return.rs +++ b/tests/ui/try-block/try-block-in-return.rs @@ -1,5 +1,5 @@ -// run-pass -// compile-flags: --edition 2018 +//@ run-pass +//@ compile-flags: --edition 2018 #![feature(try_blocks)] diff --git a/tests/ui/try-block/try-block-in-while.rs b/tests/ui/try-block/try-block-in-while.rs index 69793df525e..88a97136c59 100644 --- a/tests/ui/try-block/try-block-in-while.rs +++ b/tests/ui/try-block/try-block-in-while.rs @@ -1,4 +1,4 @@ -// compile-flags: --edition 2018 +//@ compile-flags: --edition 2018 #![feature(try_blocks)] diff --git a/tests/ui/try-block/try-block-maybe-bad-lifetime.rs b/tests/ui/try-block/try-block-maybe-bad-lifetime.rs index cd2ddf63a2f..52ec0c44a05 100644 --- a/tests/ui/try-block/try-block-maybe-bad-lifetime.rs +++ b/tests/ui/try-block/try-block-maybe-bad-lifetime.rs @@ -1,4 +1,4 @@ -// compile-flags: --edition 2018 +//@ compile-flags: --edition 2018 #![feature(try_blocks)] diff --git a/tests/ui/try-block/try-block-opt-init.rs b/tests/ui/try-block/try-block-opt-init.rs index f4f45abcc75..fbe7f90d030 100644 --- a/tests/ui/try-block/try-block-opt-init.rs +++ b/tests/ui/try-block/try-block-opt-init.rs @@ -1,4 +1,4 @@ -// compile-flags: --edition 2018 +//@ compile-flags: --edition 2018 #![feature(try_blocks)] diff --git a/tests/ui/try-block/try-block-type-error.rs b/tests/ui/try-block/try-block-type-error.rs index fe1993a37f6..79cdb7a2e48 100644 --- a/tests/ui/try-block/try-block-type-error.rs +++ b/tests/ui/try-block/try-block-type-error.rs @@ -1,4 +1,4 @@ -// compile-flags: --edition 2018 +//@ compile-flags: --edition 2018 #![feature(try_blocks)] diff --git a/tests/ui/try-block/try-block-unreachable-code-lint.rs b/tests/ui/try-block/try-block-unreachable-code-lint.rs index e1d82ea360d..62c74b76d59 100644 --- a/tests/ui/try-block/try-block-unreachable-code-lint.rs +++ b/tests/ui/try-block/try-block-unreachable-code-lint.rs @@ -1,7 +1,7 @@ // Test unreachable_code lint for `try {}` block ok-wrapping. See issues #54165, #63324. -// compile-flags: --edition 2018 -// check-pass +//@ compile-flags: --edition 2018 +//@ check-pass #![feature(try_blocks)] #![warn(unreachable_code)] diff --git a/tests/ui/try-block/try-block-unused-delims.fixed b/tests/ui/try-block/try-block-unused-delims.fixed index 756081738c3..348eb8f7965 100644 --- a/tests/ui/try-block/try-block-unused-delims.fixed +++ b/tests/ui/try-block/try-block-unused-delims.fixed @@ -1,6 +1,6 @@ -// check-pass -// compile-flags: --edition 2018 -// run-rustfix +//@ check-pass +//@ compile-flags: --edition 2018 +//@ run-rustfix #![feature(try_blocks)] #![warn(unused_parens, unused_braces)] diff --git a/tests/ui/try-block/try-block-unused-delims.rs b/tests/ui/try-block/try-block-unused-delims.rs index ce087fb351d..f119e1074f6 100644 --- a/tests/ui/try-block/try-block-unused-delims.rs +++ b/tests/ui/try-block/try-block-unused-delims.rs @@ -1,6 +1,6 @@ -// check-pass -// compile-flags: --edition 2018 -// run-rustfix +//@ check-pass +//@ compile-flags: --edition 2018 +//@ run-rustfix #![feature(try_blocks)] #![warn(unused_parens, unused_braces)] diff --git a/tests/ui/try-block/try-block.rs b/tests/ui/try-block/try-block.rs index c29ccc70427..7520cbaad37 100644 --- a/tests/ui/try-block/try-block.rs +++ b/tests/ui/try-block/try-block.rs @@ -1,8 +1,8 @@ -// run-pass +//@ run-pass #![allow(non_camel_case_types)] #![allow(dead_code)] -// compile-flags: --edition 2018 +//@ compile-flags: --edition 2018 #![feature(try_blocks)] diff --git a/tests/ui/try-block/try-is-identifier-edition2015.rs b/tests/ui/try-block/try-is-identifier-edition2015.rs index 90f56d5fa71..54bd049442f 100644 --- a/tests/ui/try-block/try-is-identifier-edition2015.rs +++ b/tests/ui/try-block/try-is-identifier-edition2015.rs @@ -1,7 +1,7 @@ -// run-pass +//@ run-pass #![allow(non_camel_case_types)] -// compile-flags: --edition 2015 +//@ compile-flags: --edition 2015 fn main() { let try = 2; |
