Skip to content

Commit 9bf2cd6

Browse files
committed
Align naming
1 parent 8617fe6 commit 9bf2cd6

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

crates/ra_assists/src/handlers/add_missing_impl_members.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ fn add_missing_impl_members_inner(
151151
ast::ImplItem::FnDef(def) => ast::ImplItem::FnDef(add_body(def)),
152152
_ => it,
153153
})
154-
.map(|it| edit::strip_attrs_and_docs(&it));
154+
.map(|it| edit::remove_attrs_and_docs(&it));
155155
let new_impl_item_list = impl_item_list.append_items(items);
156156
let cursor_position = {
157157
let first_new_item = new_impl_item_list.impl_items().nth(n_existing_items).unwrap();

crates/ra_ide/src/completion/complete_trait_impl.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,7 @@ fn add_const_impl(
193193
}
194194

195195
fn make_const_compl_syntax(const_: &ast::ConstDef) -> String {
196-
let const_ = edit::strip_attrs_and_docs(const_);
196+
let const_ = edit::remove_attrs_and_docs(const_);
197197

198198
let const_start = const_.syntax().text_range().start();
199199
let const_end = const_.syntax().text_range().end();

crates/ra_syntax/src/ast/edit.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -296,11 +296,11 @@ impl ast::UseTree {
296296
}
297297

298298
#[must_use]
299-
pub fn strip_attrs_and_docs<N: ast::AttrsOwner>(node: &N) -> N {
300-
N::cast(strip_attrs_and_docs_inner(node.syntax().clone())).unwrap()
299+
pub fn remove_attrs_and_docs<N: ast::AttrsOwner>(node: &N) -> N {
300+
N::cast(remove_attrs_and_docs_inner(node.syntax().clone())).unwrap()
301301
}
302302

303-
fn strip_attrs_and_docs_inner(mut node: SyntaxNode) -> SyntaxNode {
303+
fn remove_attrs_and_docs_inner(mut node: SyntaxNode) -> SyntaxNode {
304304
while let Some(start) =
305305
node.children_with_tokens().find(|it| it.kind() == ATTR || it.kind() == COMMENT)
306306
{

0 commit comments

Comments
 (0)