mirror of
https://github.com/astral-sh/ruff.git
synced 2025-11-27 23:14:57 +00:00
## Summary This PR leverages the unified function definition node to add precise AST node types to `MemberKind`, which is used to power our docstring definition tracking (e.g., classes and functions, whether they're methods or functions or nested functions and so on, whether they have a docstring, etc.). It was painful to do this in the past because the function variants needed to support a union anyway, but storing precise nodes removes like a dozen panics. No behavior changes -- purely a refactor. ## Test Plan `cargo test` |
||
|---|---|---|
| .. | ||
| analyze | ||
| binding.rs | ||
| context.rs | ||
| definition.rs | ||
| expressions.rs | ||
| globals.rs | ||
| lib.rs | ||
| model.rs | ||
| reference.rs | ||
| scope.rs | ||
| star_import.rs | ||
| statements.rs | ||