Skip to content

Commit bffc3d8

Browse files
committed
test that extern lits accept raw strings annd escapes
1 parent b189dfe commit bffc3d8

File tree

2 files changed

+26
-0
lines changed

2 files changed

+26
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
// check-pass
2+
3+
// Check that the string literal in `extern lit` will accept raw strings.
4+
5+
fn main() {}
6+
7+
extern r#"C"# fn foo() {}
8+
9+
extern r#"C"# {
10+
fn bar();
11+
}
12+
13+
type T = extern r#"C"# fn();
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
// check-pass
2+
3+
// Check that the string literal in `extern lit` will escapes.
4+
5+
fn main() {}
6+
7+
extern "\x43" fn foo() {}
8+
9+
extern "\x43" {
10+
fn bar();
11+
}
12+
13+
type T = extern "\x43" fn();

0 commit comments

Comments
 (0)