We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
visit_expr
expr_leaf_spans
1 parent 85d9abe commit 38efff4Copy full SHA for 38efff4
swayfmt/src/utils/language/expr/mod.rs
@@ -710,18 +710,18 @@ fn get_field_width(
710
// TODO: Find a better way of handling Boxed version
711
impl LeafSpans for Box<Expr> {
712
fn leaf_spans(&self) -> Vec<ByteSpan> {
713
- visit_expr(self)
+ expr_leaf_spans(self)
714
}
715
716
717
impl LeafSpans for Expr {
718
719
720
721
722
723
/// Collects various expr field's ByteSpans.
724
-fn visit_expr(expr: &Expr) -> Vec<ByteSpan> {
+fn expr_leaf_spans(expr: &Expr) -> Vec<ByteSpan> {
725
match expr {
726
Expr::Error(_) => vec![expr.span().into()],
727
Expr::Path(path) => path.leaf_spans(),
0 commit comments