Skip to content

Commit 9f614cb

Browse files
committed
add test for panicking attribute macros
1 parent 23a3d77 commit 9f614cb

File tree

2 files changed

+18
-0
lines changed

2 files changed

+18
-0
lines changed
+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
//@ aux-build: test-macros.rs
2+
3+
extern crate test_macros;
4+
5+
#[test_macros::panic_attr] //~ ERROR custom attribute panicked
6+
fn foo() {}
7+
8+
fn main() {}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
error: custom attribute panicked
2+
--> $DIR/custom-attr-panic.rs:5:1
3+
|
4+
LL | #[test_macros::panic_attr]
5+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
6+
|
7+
= help: message: panic-attr
8+
9+
error: aborting due to 1 previous error
10+

0 commit comments

Comments
 (0)