Skip to content

Commit c44a5fe

Browse files
committed
Add help assertion for async pub test
1 parent 9321efd commit c44a5fe

6 files changed

+6
-0
lines changed

src/test/ui/parser/issue-76437-async.rs

+1
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,5 @@
33
mod t {
44
async pub fn t() {}
55
//~^ ERROR expected one of `extern`, `fn`, or `unsafe`, found keyword `pub`
6+
//~| HELP visibility `pub` must come before `async`
67
}

src/test/ui/parser/issue-76437-const-async-unsafe.rs

+1
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,5 @@
33
mod t {
44
const async unsafe pub fn t() {}
55
//~^ ERROR expected one of `extern` or `fn`, found keyword `pub`
6+
//~| HELP visibility `pub` must come before `const async unsafe`
67
}

src/test/ui/parser/issue-76437-const-async.rs

+1
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,5 @@
33
mod t {
44
const async pub fn t() {}
55
//~^ ERROR expected one of `extern`, `fn`, or `unsafe`, found keyword `pub`
6+
//~| HELP visibility `pub` must come before `const async`
67
}

src/test/ui/parser/issue-76437-const.rs

+1
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,5 @@
33
mod t {
44
const pub fn t() {}
55
//~^ ERROR expected one of `async`, `extern`, `fn`, or `unsafe`, found keyword `pub`
6+
//~| HELP visibility `pub` must come before `const`
67
}

src/test/ui/parser/issue-76437-pub-crate-unsafe.rs

+1
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,5 @@
33
mod t {
44
unsafe pub(crate) fn t() {}
55
//~^ ERROR expected one of `extern` or `fn`, found keyword `pub`
6+
//~| HELP visibility `pub(crate)` must come before `unsafe`
67
}

src/test/ui/parser/issue-76437-unsafe.rs

+1
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,5 @@
33
mod t {
44
unsafe pub fn t() {}
55
//~^ ERROR expected one of `extern` or `fn`, found keyword `pub`
6+
//~| HELP visibility `pub` must come before `unsafe`
67
}

0 commit comments

Comments
 (0)