From c6aeda7bd52e490148ae34242f09de66d0af9841 Mon Sep 17 00:00:00 2001 From: Yuki Okushi Date: Fri, 3 Jan 2020 17:03:07 +0900 Subject: [PATCH] Move `use_self_macro` into `crashes/auxiliary` --- tests/ui/crashes/auxiliary/use_self_macro.rs | 15 +++++++++++++++ tests/ui/crashes/ice-4671.rs | 2 +- 2 files changed, 16 insertions(+), 1 deletion(-) create mode 100644 tests/ui/crashes/auxiliary/use_self_macro.rs diff --git a/tests/ui/crashes/auxiliary/use_self_macro.rs b/tests/ui/crashes/auxiliary/use_self_macro.rs new file mode 100644 index 00000000000..a8a85b4baef --- /dev/null +++ b/tests/ui/crashes/auxiliary/use_self_macro.rs @@ -0,0 +1,15 @@ +macro_rules! use_self { + ( + impl $ty:ident { + fn func(&$this:ident) { + [fields($($field:ident)*)] + } + } + ) => ( + impl $ty { + fn func(&$this) { + let $ty { $($field),* } = $this; + } + } + ) +} diff --git a/tests/ui/crashes/ice-4671.rs b/tests/ui/crashes/ice-4671.rs index 2014cdfc77c..64e8e776941 100644 --- a/tests/ui/crashes/ice-4671.rs +++ b/tests/ui/crashes/ice-4671.rs @@ -1,7 +1,7 @@ #![warn(clippy::use_self)] #[macro_use] -#[path = "../auxiliary/use_self_macro.rs"] +#[path = "auxiliary/use_self_macro.rs"] mod use_self_macro; struct Foo {