[ty] Use typing.Self for the first parameter of instance methods by sharkdp · Pull Request #20517 · astral-sh/ruff (original) (raw)
added the ty
Multi-file analysis & type inference
label
sharkdp deleted the david/implicit-self-signature branch
dcreager added a commit that referenced this pull request
- main: (21 commits)
[ty] Literal promotion refactor (#20646)
[ty] Add tests for nested generic functions (#20631)
[
cli] Add conflict between--add-noqaand--diffoptions (#20642) [ty] Ensure first-party search paths always appear in a sensible order (#20629) [ty] Usetyping.Selffor the first parameter of instance methods (#20517) [ty] Remove unnecessaryparsed_module()calls (#20630) RemoveTextEmitter(#20595) [ty] Use fully qualified names to distinguish ambiguous protocols in diagnostics (#20627) [ty] Ecosystem analyzer: relax timeout thresholds (#20626) [ty] Apply type mappings to functions eagerly (#20596) [ty] Improve disambiguation of class names in diagnostics (#20603) Add the The Basics title back to CONTRIBUTING.md (#20624) [playground] Fix quick fixes for empty ranges in playground (#20599) Update dependency ruff to v0.13.2 (#20622) [ruff] Fix minor typos in doc comments (#20623) Update dependency PyYAML to v6.0.3 (#20621) Update cargo-bins/cargo-binstall action to v1.15.6 (#20620) Fixed documentation for try_consider_else (#20587) [ty] UseTopmaterializations forTypeIsspecial form (#20591) [ty] SimplifyAny | (Any & T)toAny(#20593) ...
ibraheemdev added a commit that referenced this pull request
Summary
Extends #20517 to support the
implicit type of cls in @classmethod signatures. Part of
astral-sh/ty#159.
KotlinIsland pushed a commit to KotlinIsland/basedpython that referenced this pull request
Summary
This removes a hack in the protocol satisfiability check that was previously needed to work around missing assignability-modeling of inferable type variables. Assignability of type variables is not implemented fully, but some recent changes allow us to remove that hack with limited impact on the ecosystem (and the test suite). The change in the typing conformance test is favorable.
Test Plan
- Adapted Markdown tests
- Made sure that this change works in combination with astral-sh/ruff#20517
KotlinIsland pushed a commit to KotlinIsland/basedpython that referenced this pull request
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
[ Show hidden characters]({{ revealButtonHref }})