diff options
Diffstat (limited to 'crates/ra_syntax/src/ast/edit.rs')
-rw-r--r-- | crates/ra_syntax/src/ast/edit.rs | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/crates/ra_syntax/src/ast/edit.rs b/crates/ra_syntax/src/ast/edit.rs index 8d3e42f25..667a9294f 100644 --- a/crates/ra_syntax/src/ast/edit.rs +++ b/crates/ra_syntax/src/ast/edit.rs | |||
@@ -237,17 +237,17 @@ impl ast::Path { | |||
237 | 237 | ||
238 | impl ast::PathSegment { | 238 | impl ast::PathSegment { |
239 | #[must_use] | 239 | #[must_use] |
240 | pub fn with_type_args(&self, type_args: ast::TypeArgList) -> ast::PathSegment { | 240 | pub fn with_type_args(&self, type_args: ast::GenericArgList) -> ast::PathSegment { |
241 | self._with_type_args(type_args, false) | 241 | self._with_type_args(type_args, false) |
242 | } | 242 | } |
243 | 243 | ||
244 | #[must_use] | 244 | #[must_use] |
245 | pub fn with_turbo_fish(&self, type_args: ast::TypeArgList) -> ast::PathSegment { | 245 | pub fn with_turbo_fish(&self, type_args: ast::GenericArgList) -> ast::PathSegment { |
246 | self._with_type_args(type_args, true) | 246 | self._with_type_args(type_args, true) |
247 | } | 247 | } |
248 | 248 | ||
249 | fn _with_type_args(&self, type_args: ast::TypeArgList, turbo: bool) -> ast::PathSegment { | 249 | fn _with_type_args(&self, type_args: ast::GenericArgList, turbo: bool) -> ast::PathSegment { |
250 | if let Some(old) = self.type_arg_list() { | 250 | if let Some(old) = self.generic_arg_list() { |
251 | return self.replace_children( | 251 | return self.replace_children( |
252 | single_node(old.syntax().clone()), | 252 | single_node(old.syntax().clone()), |
253 | iter::once(type_args.syntax().clone().into()), | 253 | iter::once(type_args.syntax().clone().into()), |
@@ -390,7 +390,7 @@ impl ast::MatchArmList { | |||
390 | #[must_use] | 390 | #[must_use] |
391 | pub fn remove_placeholder(&self) -> ast::MatchArmList { | 391 | pub fn remove_placeholder(&self) -> ast::MatchArmList { |
392 | let placeholder = | 392 | let placeholder = |
393 | self.arms().find(|arm| matches!(arm.pat(), Some(ast::Pat::PlaceholderPat(_)))); | 393 | self.arms().find(|arm| matches!(arm.pat(), Some(ast::Pat::WildcardPat(_)))); |
394 | if let Some(placeholder) = placeholder { | 394 | if let Some(placeholder) = placeholder { |
395 | self.remove_arm(&placeholder) | 395 | self.remove_arm(&placeholder) |
396 | } else { | 396 | } else { |