diff options
author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2020-12-18 16:50:26 +0000 |
---|---|---|
committer | GitHub <[email protected]> | 2020-12-18 16:50:26 +0000 |
commit | 150ea3a61f07b19db3f55e8c675eba53f1a22961 (patch) | |
tree | 9fae5f7c47cabaa433b2aabeea5ab1dc0d3b0b8d /crates/syntax/src | |
parent | 8be3f25b0bf77b547ba83c3eb9689a40d212a55b (diff) | |
parent | cd4a7bf36e202ae7e97d9a655750f70176a0651e (diff) |
Merge #6931
6931: Minor, cleanup API r=matklad a=matklad
bors r+
🤖
Co-authored-by: Aleksey Kladov <[email protected]>
Diffstat (limited to 'crates/syntax/src')
-rw-r--r-- | crates/syntax/src/ast/make.rs | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/crates/syntax/src/ast/make.rs b/crates/syntax/src/ast/make.rs index 16b079c42..ba7e5d2fb 100644 --- a/crates/syntax/src/ast/make.rs +++ b/crates/syntax/src/ast/make.rs | |||
@@ -20,6 +20,9 @@ pub fn name_ref(text: &str) -> ast::NameRef { | |||
20 | pub fn ty(text: &str) -> ast::Type { | 20 | pub fn ty(text: &str) -> ast::Type { |
21 | ast_from_text(&format!("impl {} for D {{}};", text)) | 21 | ast_from_text(&format!("impl {} for D {{}};", text)) |
22 | } | 22 | } |
23 | pub fn ty_unit() -> ast::Type { | ||
24 | ty("()") | ||
25 | } | ||
23 | 26 | ||
24 | pub fn assoc_item_list() -> ast::AssocItemList { | 27 | pub fn assoc_item_list() -> ast::AssocItemList { |
25 | ast_from_text("impl C for D {};") | 28 | ast_from_text("impl C for D {};") |