ruff/crates/ruff_python_parser/resources/inline
Brent Westbrook 835e31b3ff
Fix syntax error false positive on alternative `match` patterns (#21362)
Summary
--

Fixes #21360 by using the union of names instead of overwriting them, as
Micha suggested originally on #21104.

This avoids overwriting the `n` name in the `Subscript` by the empty set
of names visited in the nested OR pattern before visiting the other arm
of the outer OR pattern.

Test Plan
--

A new inline test case taken from the issue
2025-11-10 10:51:51 -05:00
..
err Catch syntax errors in nested interpolations before Python 3.12 (#20949) 2025-10-20 09:03:13 -04:00
ok Fix syntax error false positive on alternative `match` patterns (#21362) 2025-11-10 10:51:51 -05:00