mirror of
https://github.com/astral-sh/ruff.git
synced 2025-09-30 13:51:37 +00:00
![]() ## Summary <!-- What's the purpose of the change? What does it do, and why? --> Similar to #10419, there was a case where there is a collision of C401 and C416 (as discussed in #10101). Fixed this by implementing short-circuit for the comprehension of the form `{x for x in foo}`. ## Test Plan <!-- How was it tested? --> Extended `C401.py` with the case where `set` is not builtin function, and divided the case where the short-circuit should occur. Removed the last testcase of `print(f"{ {set(a for a in 'abc')} }")` test as this is invalid as a python code, but should I keep this? |
||
---|---|---|
.. | ||
resources | ||
src | ||
__init__.py | ||
Cargo.toml |