cb4162e4205bbb8fe70d1a40390272f9c832f7cb
The `discover_globals` function has been refactored to better handle pattern matching within definitions. It now uses a recursive helper function `register_pattern` to correctly process identifiers and tuple patterns. This ensures that all declared variables within a `Def` node are registered with their corresponding scope and virtual ID. Additionally, support for `Expansion` nodes has been added to ensure that any nested global definitions within them are also discovered.
Description
No description provided
Languages
Rust
100%