fn find_syntax_expr(db: &dyn crate::Db, syntax_tree: syntax::Tree, offset: Offset) -> syntax::Expr {
    let spans = syntax_tree.spans(db);
    let data = syntax_tree.data(db);
    let traversal = TreeTraversal {
        spans,
        tables: &data.tables,
        offset,
    };
    traversal.find(data.root_expr).unwrap_or(data.root_expr)
}
/// Locates the syntax expression that the cursor is "on".
/// This is used to in the time-travelling debugger.
///
/// The idea is that executions stops at the "cusp" of the returned expression E:
/// that is, the moment when all of E's children have been
/// evaluated, but E has not yet taken effect itself.
///
/// Assumes: the offest is somewhere in this syntax tree.
///
/// Returns None if the cursor does not lie in the syntax tree at all.
Locates the syntax expression that the cursor is "on".
This is used to in the time-travelling debugger.

The idea is that executions stops at the "cusp" of the returned expression E:
that is, the moment when all of E's children have been
evaluated, but E has not yet taken effect itself.

the offest is somewhere in this syntax tree.

Returns None if the cursor does not lie in the syntax tree at all.
Locates the syntax expression that the cursor is " on " . This is used to in the time - travelling debugger . The idea is that executions stops at the " cusp " of the returned expression E : that is the moment when all of E ' s children have been evaluated but E has not yet taken effect itself . the offest is somewhere in this syntax tree . Returns None if the cursor does not lie in the syntax tree at all .
fn find_syntax_expr(db: &dyn crate::Db, syntax_tree: syntax::Tree, offset: Offset) -> syntax::Expr {
    let spans = syntax_tree.spans(db);
    let data = syntax_tree.data(db);
    let traversal = TreeTraversal {
        spans,
        tables: &data.tables,
        offset,
    };
    traversal.find(data.root_expr).unwrap_or(data.root_expr)
}
fn find_syntax_expr ( db : & dyn crate :: Db , syntax_tree : syntax :: Tree , offset : Offset ) -> syntax :: Expr { let spans = syntax_tree . spans ( db ) ; let data = syntax_tree . data ( db ) ; let traversal = TreeTraversal { spans , tables : & data . tables , offset , } ; traversal . find ( data . root_expr ) . unwrap_or ( data . root_expr ) }
Locates the syntax expression that the cursor is "on".
Locates the syntax expression that the cursor is " on " .
db
&dyn crate::Db
syntax_tree
syntax::Tree
offset
Offset
db
&dyn crate::Db
syntax_tree
syntax::Tree
offset
Offset