forked from dtolnay/async-trait
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Ignore unused_macro_rules warning in test macros
- Loading branch information
Showing
2 changed files
with
8 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
#![allow(unused_macro_rules)] | ||
|
||
use async_trait::async_trait; | ||
|
||
macro_rules! picky { | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,17 @@ | ||
error: no rules expected the token `{` | ||
--> tests/ui/delimiter-span.rs:17:16 | ||
--> tests/ui/delimiter-span.rs:19:16 | ||
| | ||
3 | macro_rules! picky { | ||
5 | macro_rules! picky { | ||
| ------------------ when calling this macro | ||
... | ||
17 | picky!({ 123, self }); | ||
19 | picky!({ 123, self }); | ||
| ^ no rules expected this token in macro call | ||
|
||
error: no rules expected the token `{` | ||
--> tests/ui/delimiter-span.rs:18:16 | ||
--> tests/ui/delimiter-span.rs:20:16 | ||
| | ||
3 | macro_rules! picky { | ||
5 | macro_rules! picky { | ||
| ------------------ when calling this macro | ||
... | ||
18 | picky!({ 123 }); | ||
20 | picky!({ 123 }); | ||
| ^ no rules expected this token in macro call | ||
|
||
warning: 1st rule of macro `picky` is never used | ||
--> tests/ui/delimiter-span.rs:4:5 | ||
| | ||
4 | ($(t:tt)*) => {}; | ||
| ^^^^^^^^^^ | ||
| | ||
= note: `#[warn(unused_macro_rules)]` on by default |