aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_syntax/src
diff options
context:
space:
mode:
authorAleksey Kladov <[email protected]>2020-02-06 22:59:27 +0000
committerAleksey Kladov <[email protected]>2020-02-06 22:59:27 +0000
commit56e3fbe588597847b508969b7e3243725f5a792c (patch)
treeae968f2cef858c6b001e126dd7e3684d013566b9 /crates/ra_syntax/src
parenta4431e83025223d5aea0ae3d49a6356775cb5f75 (diff)
A tiny bit more consistent API
Diffstat (limited to 'crates/ra_syntax/src')
-rw-r--r--crates/ra_syntax/src/ast/make.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/ra_syntax/src/ast/make.rs b/crates/ra_syntax/src/ast/make.rs
index 629503dc5..02966a3ff 100644
--- a/crates/ra_syntax/src/ast/make.rs
+++ b/crates/ra_syntax/src/ast/make.rs
@@ -158,7 +158,7 @@ pub fn where_clause(preds: impl IntoIterator<Item = ast::WherePred>) -> ast::Whe
158 } 158 }
159} 159}
160 160
161pub fn if_expression(condition: &ast::Expr, statement: &str) -> ast::IfExpr { 161pub fn if_expression(condition: ast::Expr, statement: &str) -> ast::IfExpr {
162 ast_from_text(&format!( 162 ast_from_text(&format!(
163 "fn f() {{ if !{} {{\n {}\n}}\n}}", 163 "fn f() {{ if !{} {{\n {}\n}}\n}}",
164 condition.syntax().text(), 164 condition.syntax().text(),