From 14c5900a701bf5d08f9512cbac52a8bf7dc8f4ef Mon Sep 17 00:00:00 2001 From: Brian Anderson Date: Wed, 15 Jun 2011 14:00:27 -0700 Subject: [PATCH] test: Add a compile-fail test for attribute/syntax parsing I don't currently know how to deal with syntax extensions that appear betweeen an attribute and an item, so this test captures the error that occurs. Issue #487 --- src/test/compile-fail/ext-after-attrib.rs | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 src/test/compile-fail/ext-after-attrib.rs diff --git a/src/test/compile-fail/ext-after-attrib.rs b/src/test/compile-fail/ext-after-attrib.rs new file mode 100644 index 00000000000..31786fcaf65 --- /dev/null +++ b/src/test/compile-fail/ext-after-attrib.rs @@ -0,0 +1,8 @@ +// xfail-stage0 +// error-pattern:expecting \[, found fmt + +// Don't know how to deal with a syntax extension appearing after an +// item attribute. Probably could use a better error message. +#[foo = "bar"] +#fmt("baz") +fn main() { } \ No newline at end of file