diff options
Diffstat (limited to 'tests/ui/macros/lint-trailing-macro-call.rs')
-rw-r--r-- | tests/ui/macros/lint-trailing-macro-call.rs | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/tests/ui/macros/lint-trailing-macro-call.rs b/tests/ui/macros/lint-trailing-macro-call.rs new file mode 100644 index 000000000..f8e847563 --- /dev/null +++ b/tests/ui/macros/lint-trailing-macro-call.rs @@ -0,0 +1,16 @@ +// check-pass +// +// Ensures that we properly lint +// a removed 'expression' resulting from a macro +// in trailing expression position + +macro_rules! expand_it { + () => { + #[cfg(FALSE)] 25; //~ WARN trailing semicolon in macro + //~| WARN this was previously + } +} + +fn main() { + expand_it!() +} |