about summary refs log tree commit diff
path: root/tests/ui/macros/concat.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ui/macros/concat.rs')
-rw-r--r--tests/ui/macros/concat.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/ui/macros/concat.rs b/tests/ui/macros/concat.rs
new file mode 100644
index 00000000000..d7ab7d62625
--- /dev/null
+++ b/tests/ui/macros/concat.rs
@@ -0,0 +1,6 @@
+fn main() {
+    concat!(b'f');  //~ ERROR: cannot concatenate a byte string literal
+    concat!(b"foo");  //~ ERROR: cannot concatenate a byte string literal
+    concat!(foo);   //~ ERROR: expected a literal
+    concat!(foo()); //~ ERROR: expected a literal
+}