mirror of https://github.com/astral-sh/ruff
## Summary Part of https://github.com/astral-sh/ty/issues/168. Infer more precise types for collection literals (currently, only `list` and `set`). For example, ```py x = [1, 2, 3] # revealed: list[Unknown | int] y: list[int] = [1, 2, 3] # revealed: list[int] ``` This could easily be extended to `dict` literals, but I am intentionally limiting scope for now. |
||
|---|---|---|
| .. | ||
| corpus | ||
| mdtest | ||
| primer | ||
| README.md | ||
README.md
Markdown files within the mdtest/ subdirectory are tests of type inference and type checking;
executed by the tests/mdtest.rs integration test.
See crates/ty_test/README.md for documentation of this test format.