aboutsummaryrefslogtreecommitdiff
path: root/crates
diff options
context:
space:
mode:
authorEmmanuel Thompson <[email protected]>2021-04-07 04:22:44 +0100
committerEmmanuel Thompson <[email protected]>2021-04-07 04:22:44 +0100
commit35bec31bca7356d6ae4ef9bfc4f813ebeeb4c971 (patch)
tree3c0caf3950f164bbebe1cc5796488d34eb6160a7 /crates
parentcf41e1410a0cf87a05b2dd632e3b5d67f8d55327 (diff)
Add space after lifetime
In macro expansion, this lead to invalid syntax
Diffstat (limited to 'crates')
-rw-r--r--crates/ide/src/expand_macro.rs3
1 files changed, 3 insertions, 0 deletions
diff --git a/crates/ide/src/expand_macro.rs b/crates/ide/src/expand_macro.rs
index 9eeabbeda..d5628e3df 100644
--- a/crates/ide/src/expand_macro.rs
+++ b/crates/ide/src/expand_macro.rs
@@ -103,6 +103,9 @@ fn insert_whitespaces(syn: SyntaxNode) -> String {
103 format!("\n{}}}", " ".repeat(indent)) 103 format!("\n{}}}", " ".repeat(indent))
104 } 104 }
105 R_CURLY => format!("}}\n{}", " ".repeat(indent)), 105 R_CURLY => format!("}}\n{}", " ".repeat(indent)),
106 LIFETIME_IDENT if is_next(|it| it == IDENT, true) => {
107 format!("{} ", token.text().to_string())
108 }
106 T![;] => format!(";\n{}", " ".repeat(indent)), 109 T![;] => format!(";\n{}", " ".repeat(indent)),
107 T![->] => " -> ".to_string(), 110 T![->] => " -> ".to_string(),
108 T![=] => " = ".to_string(), 111 T![=] => " = ".to_string(),