aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_ty/src/tests
diff options
context:
space:
mode:
Diffstat (limited to 'crates/hir_ty/src/tests')
-rw-r--r--crates/hir_ty/src/tests/macros.rs14
1 files changed, 9 insertions, 5 deletions
diff --git a/crates/hir_ty/src/tests/macros.rs b/crates/hir_ty/src/tests/macros.rs
index 8de1e229f..6588aa46c 100644
--- a/crates/hir_ty/src/tests/macros.rs
+++ b/crates/hir_ty/src/tests/macros.rs
@@ -1248,14 +1248,18 @@ fn macros_in_type_generics() {
1248fn infinitely_recursive_macro_type() { 1248fn infinitely_recursive_macro_type() {
1249 check_infer( 1249 check_infer(
1250 r#" 1250 r#"
1251 struct Bar<T>(T); 1251 struct Bar<T, X>(T, X);
1252 1252
1253 macro_rules! Foo { 1253 macro_rules! Foo {
1254 () => { Foo!() } 1254 () => { Foo!() }
1255 } 1255 }
1256 1256
1257 macro_rules! U32 {
1258 () => { u32 }
1259 }
1260
1257 type A = Foo!(); 1261 type A = Foo!();
1258 type B = Bar<Foo!()>; 1262 type B = Bar<Foo!(), U32!()>;
1259 1263
1260 fn main() { 1264 fn main() {
1261 let a: A; 1265 let a: A;
@@ -1263,9 +1267,9 @@ fn infinitely_recursive_macro_type() {
1263 } 1267 }
1264 "#, 1268 "#,
1265 expect![[r#" 1269 expect![[r#"
1266 112..143 '{ ...: B; }': () 1270 166..197 '{ ...: B; }': ()
1267 122..123 'a': {unknown} 1271 176..177 'a': {unknown}
1268 136..137 'b': Bar<{unknown}> 1272 190..191 'b': Bar<{unknown}, u32>
1269 "#]], 1273 "#]],
1270 ); 1274 );
1271} 1275}