File tree Expand file tree Collapse file tree 2 files changed +33
-2
lines changed Expand file tree Collapse file tree 2 files changed +33
-2
lines changed Original file line number Diff line number Diff line change @@ -1234,6 +1234,37 @@ fn f() { fo$0o!(); }
12341234 )
12351235 }
12361236
1237+ #[ test]
1238+ fn test_hover_macro2_invocation ( ) {
1239+ check (
1240+ r#"
1241+ /// foo bar
1242+ ///
1243+ /// foo bar baz
1244+ macro foo() {}
1245+
1246+ fn f() { fo$0o!(); }
1247+ "# ,
1248+ expect ! [ [ r#"
1249+ *foo*
1250+
1251+ ```rust
1252+ test
1253+ ```
1254+
1255+ ```rust
1256+ macro foo
1257+ ```
1258+
1259+ ---
1260+
1261+ foo bar
1262+
1263+ foo bar baz
1264+ "# ] ] ,
1265+ )
1266+ }
1267+
12371268 #[ test]
12381269 fn test_hover_tuple_field ( ) {
12391270 check (
Original file line number Diff line number Diff line change @@ -147,8 +147,8 @@ fn n_attached_trivias<'a>(
147147 trivias : impl Iterator < Item = ( SyntaxKind , & ' a str ) > ,
148148) -> usize {
149149 match kind {
150- MACRO_CALL | MACRO_RULES | CONST | TYPE_ALIAS | STRUCT | UNION | ENUM | VARIANT | FN
151- | TRAIT | MODULE | RECORD_FIELD | STATIC | USE => {
150+ MACRO_CALL | MACRO_RULES | MACRO_DEF | CONST | TYPE_ALIAS | STRUCT | UNION | ENUM
151+ | VARIANT | FN | TRAIT | MODULE | RECORD_FIELD | STATIC | USE => {
152152 let mut res = 0 ;
153153 let mut trivias = trivias. enumerate ( ) . peekable ( ) ;
154154
You can’t perform that action at this time.
0 commit comments