about summary refs log tree commit diff
path: root/src/test
diff options
context:
space:
mode:
Diffstat (limited to 'src/test')
-rw-r--r--src/test/ui/parser/shebang/shebang-doc-comment.rs5
-rw-r--r--src/test/ui/parser/shebang/shebang-doc-comment.stderr8
2 files changed, 5 insertions, 8 deletions
diff --git a/src/test/ui/parser/shebang/shebang-doc-comment.rs b/src/test/ui/parser/shebang/shebang-doc-comment.rs
index 7dbb9eebc75..72866753e0e 100644
--- a/src/test/ui/parser/shebang/shebang-doc-comment.rs
+++ b/src/test/ui/parser/shebang/shebang-doc-comment.rs
@@ -1,6 +1,3 @@
 #!///bin/bash
 [allow(unused_variables)]
-//~^^ ERROR expected `[`, found doc comment
-
-// Doc comment is misinterpreted as a whitespace (regular comment) during shebang detection.
-// Even if it wasn't, it would still result in an error, just a different one.
+//~^ ERROR expected item, found `[`
diff --git a/src/test/ui/parser/shebang/shebang-doc-comment.stderr b/src/test/ui/parser/shebang/shebang-doc-comment.stderr
index f524f556837..2227d45ec5a 100644
--- a/src/test/ui/parser/shebang/shebang-doc-comment.stderr
+++ b/src/test/ui/parser/shebang/shebang-doc-comment.stderr
@@ -1,8 +1,8 @@
-error: expected `[`, found doc comment `///bin/bash`
-  --> $DIR/shebang-doc-comment.rs:1:3
+error: expected item, found `[`
+  --> $DIR/shebang-doc-comment.rs:2:1
    |
-LL | #!///bin/bash
-   |   ^^^^^^^^^^^ expected `[`
+LL | [allow(unused_variables)]
+   | ^ expected item
 
 error: aborting due to previous error