mirror of https://github.com/astral-sh/ruff
While looking into potential AST optimizations, I noticed the `AstNode` trait and `AnyNode` type aren't used anywhere in Ruff or Red Knot. It looks like they might be historical artifacts of previous ways of consuming AST nodes? - `AstNode::cast`, `AstNode::cast_ref`, and `AstNode::can_cast` are not used anywhere. - Since `cast_ref` isn't needed anymore, the `Ref` associated type isn't either. This is a pure refactoring, with no intended behavior changes. |
||
|---|---|---|
| .. | ||
| snapshots | ||
| debug.rs | ||
| format.rs | ||
| map.rs | ||
| mod.rs | ||
| node_key.rs | ||
| placement.rs | ||
| visitor.rs | ||