syntax::ast::make

Function hacky_block_expr

source
pub fn hacky_block_expr(
    elements: impl IntoIterator<Item = SyntaxElement>,
    tail_expr: Option<Expr>,
) -> BlockExpr
Expand description

Ideally this function wouldn’t exist since it involves manual indenting. It differs from make::block_expr by also supporting comments and whitespace.

FIXME: replace usages of this with the mutable syntax tree API