ruff/crates/red_knot_project
Shunsuke Shibayama da6b68cb58
[red-knot] infer attribute assignments bound in comprehensions (#17396)
## Summary

This PR is a follow-up to #16852.

Instance variables bound in comprehensions are recorded, allowing type
inference to work correctly.

This required adding support for unpacking in comprehension which
resolves https://github.com/astral-sh/ruff/issues/15369.

## Test Plan

One TODO in `mdtest/attributes.md` is now resolved, and some new test
cases are added.

---------

Co-authored-by: Dhruv Manilawala <dhruvmanila@gmail.com>
2025-04-19 06:42:48 +05:30
..
resources/test/corpus [red-knot] Add regression tests for narrowing constraints cycles (#17408) 2025-04-15 07:27:54 -07:00
src [red-knot] Detect version-related syntax errors (#16379) 2025-04-17 14:00:30 -04:00
tests [red-knot] infer attribute assignments bound in comprehensions (#17396) 2025-04-19 06:42:48 +05:30
Cargo.toml [red-knot] Add 'Format document' to playground (#17217) 2025-04-07 09:26:03 +02:00