Skip to content

Commit 5ae9847

Browse files
committed
Auto merge of rust-lang#12262 - jhgg:fix-whitespace-between-mut-self-in-macro-expansion, r=lnicola
ide: insert whitespace between 'mut' and 'self' in macro expansion fixes rust-lang#12260
2 parents fa133d0 + 4efc2a9 commit 5ae9847

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

crates/ide-db/src/syntax_helpers/insert_whitespace_into_node.rs

+3
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,9 @@ pub fn insert_ws_into(syn: SyntaxNode) -> SyntaxNode {
8888
LIFETIME_IDENT if is_next(is_text, true) => {
8989
mods.push(do_ws(after, tok));
9090
}
91+
MUT_KW if is_next(|it| it == SELF_KW, false) => {
92+
mods.push(do_ws(after, tok));
93+
}
9194
AS_KW | DYN_KW | IMPL_KW | CONST_KW => {
9295
mods.push(do_ws(after, tok));
9396
}

0 commit comments

Comments
 (0)