Skip to content

Commit 5234d36

Browse files
committed
add test
1 parent a316f5b commit 5234d36

File tree

2 files changed

+25
-0
lines changed

2 files changed

+25
-0
lines changed
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
//@ needs-rustc-debug-assertions
2+
3+
// https://github.com/rust-lang/rust/issues/147365
4+
// Ensures we don't trigger debug assert by creating an empty Ident when determining whether
5+
// the single quote is a raw lifetime.
6+
7+
extern "'" {} //~ ERROR invalid ABI: found `'`
8+
9+
fn main() {}
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
error[E0703]: invalid ABI: found `'`
2+
--> $DIR/extern-single-quote-issue-147365.rs:7:8
3+
|
4+
LL | extern "'" {}
5+
| ^^^ invalid ABI
6+
|
7+
= note: invoke `rustc --print=calling-conventions` for a full list of supported calling conventions
8+
help: there's a similarly named valid ABI `C`
9+
|
10+
LL - extern "'" {}
11+
LL + extern "C" {}
12+
|
13+
14+
error: aborting due to 1 previous error
15+
16+
For more information about this error, try `rustc --explain E0703`.

0 commit comments

Comments
 (0)