Skip to content

Commit ae7c982

Browse files
committed
Add make utility for empty associated item lists
1 parent 4362297 commit ae7c982

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

crates/syntax/src/ast/make.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,10 @@ pub fn ty(text: &str) -> ast::Type {
2121
ast_from_text(&format!("impl {} for D {{}};", text))
2222
}
2323

24+
pub fn assoc_item_list() -> ast::AssocItemList {
25+
ast_from_text("impl C for D {};")
26+
}
27+
2428
pub fn path_segment(name_ref: ast::NameRef) -> ast::PathSegment {
2529
ast_from_text(&format!("use {};", name_ref))
2630
}

0 commit comments

Comments
 (0)