File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed
crates/ide-assists/src/handlers Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -389,6 +389,7 @@ impl Module {
389
389
| SyntaxKind :: ENUM_KW
390
390
| SyntaxKind :: TRAIT_KW
391
391
| SyntaxKind :: TYPE_KW
392
+ | SyntaxKind :: CONST_KW
392
393
| SyntaxKind :: MOD_KW => true ,
393
394
// If we didn't find a keyword, we want to cover the record fields in a struct
394
395
SyntaxKind :: NAME => true ,
@@ -1682,7 +1683,10 @@ mod modname {
1682
1683
A,
1683
1684
/// Another variant
1684
1685
B { x: i32, y: i32 }
1685
- }$0
1686
+ }
1687
+
1688
+ /// Documented const
1689
+ const MY_CONST: i32 = 0;$0
1686
1690
" ,
1687
1691
r"
1688
1692
mod modname {
@@ -1765,6 +1769,9 @@ mod modname {
1765
1769
/// Another variant
1766
1770
B { x: i32, y: i32 }
1767
1771
}
1772
+
1773
+ /// Documented const
1774
+ pub(crate) const MY_CONST: i32 = 0;
1768
1775
}
1769
1776
" ,
1770
1777
)
You can’t perform that action at this time.
0 commit comments