aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_def
diff options
context:
space:
mode:
authorAleksey Kladov <[email protected]>2021-06-15 09:58:39 +0100
committerAleksey Kladov <[email protected]>2021-06-15 09:58:39 +0100
commit7786ab2d44518a1f78d4b1e750cab401740ecb80 (patch)
treebeaa5b3579eb862e38ac6d217940cbd9bf5c0359 /crates/hir_def
parentfa4c851619f245b2fdd2bf9b135d5ecf5efb4bc7 (diff)
minor: add a test variation
Diffstat (limited to 'crates/hir_def')
-rw-r--r--crates/hir_def/src/nameres/collector.rs18
1 files changed, 13 insertions, 5 deletions
diff --git a/crates/hir_def/src/nameres/collector.rs b/crates/hir_def/src/nameres/collector.rs
index 4ae02e576..fc2c50fb8 100644
--- a/crates/hir_def/src/nameres/collector.rs
+++ b/crates/hir_def/src/nameres/collector.rs
@@ -2005,11 +2005,19 @@ mod tests {
2005 fn test_macro_expand_will_stop_1() { 2005 fn test_macro_expand_will_stop_1() {
2006 do_resolve( 2006 do_resolve(
2007 r#" 2007 r#"
2008 macro_rules! foo { 2008macro_rules! foo {
2009 ($($ty:ty)*) => { foo!($($ty)*); } 2009 ($($ty:ty)*) => { foo!($($ty)*); }
2010 } 2010}
2011 foo!(KABOOM); 2011foo!(KABOOM);
2012 "#, 2012"#,
2013 );
2014 do_resolve(
2015 r#"
2016macro_rules! foo {
2017 ($($ty:ty)*) => { foo!(() $($ty)*); }
2018}
2019foo!(KABOOM);
2020"#,
2013 ); 2021 );
2014 } 2022 }
2015 2023