aboutsummaryrefslogtreecommitdiff
path: root/crates/syntax/src/ast/make.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/syntax/src/ast/make.rs')
-rw-r--r--crates/syntax/src/ast/make.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/crates/syntax/src/ast/make.rs b/crates/syntax/src/ast/make.rs
index d13926ded..0cf170626 100644
--- a/crates/syntax/src/ast/make.rs
+++ b/crates/syntax/src/ast/make.rs
@@ -106,6 +106,10 @@ pub fn impl_trait(trait_: ast::Path, ty: ast::Path) -> ast::Impl {
106 ast_from_text(&format!("impl {} for {} {{}}", trait_, ty)) 106 ast_from_text(&format!("impl {} for {} {{}}", trait_, ty))
107} 107}
108 108
109pub(crate) fn generic_arg_list() -> ast::GenericArgList {
110 ast_from_text("const S: T<> = ();")
111}
112
109pub fn path_segment(name_ref: ast::NameRef) -> ast::PathSegment { 113pub fn path_segment(name_ref: ast::NameRef) -> ast::PathSegment {
110 ast_from_text(&format!("use {};", name_ref)) 114 ast_from_text(&format!("use {};", name_ref))
111} 115}