From 85e2346b749c97181b9bac51490bbbc4bb648971 Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Fri, 6 Mar 2020 15:38:48 +0100 Subject: Simplify creation of `T[,]` --- crates/ra_syntax/src/ast/edit.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'crates/ra_syntax/src/ast/edit.rs') diff --git a/crates/ra_syntax/src/ast/edit.rs b/crates/ra_syntax/src/ast/edit.rs index e4cdccdb4..40a04b9c5 100644 --- a/crates/ra_syntax/src/ast/edit.rs +++ b/crates/ra_syntax/src/ast/edit.rs @@ -139,7 +139,7 @@ impl ast::RecordFieldList { let mut to_insert: ArrayVec<[SyntaxElement; 4]> = ArrayVec::new(); to_insert.push(space.into()); to_insert.push(field.syntax().clone().into()); - to_insert.push(tokens::comma().into()); + to_insert.push(make::token(T![,]).into()); macro_rules! after_l_curly { () => {{ @@ -160,7 +160,7 @@ impl ast::RecordFieldList { { InsertPosition::After(comma) } else { - to_insert.insert(0, tokens::comma().into()); + to_insert.insert(0, make::token(T![,]).into()); InsertPosition::After($anchor.syntax().clone().into()) } }; -- cgit v1.2.3