Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PEP 747: TypeExpr: Type Hint for a Type Expression #3798

Merged
merged 47 commits into from
Jun 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
47 commits
Select commit Hold shift + click to select a range
564484a
PEP 755: TypeExpr: Type Hint for a Type Expression
davidfstr May 27, 2024
93aa917
Update .github/CODEOWNERS
davidfstr May 27, 2024
4ed4602
Update Created header
davidfstr May 27, 2024
0bbbd9c
Post-History: Recognize discuss.python.org post links without trailin…
davidfstr May 28, 2024
836a89a
Include only draft 1 and 2 links in Post-History. Remove Discussions-…
davidfstr May 28, 2024
6d5de2b
Change PEP number: 755 -> 747
davidfstr May 28, 2024
5737d06
Rewrite some PEP links using :pep:`...`
davidfstr May 28, 2024
9bbd9fc
Add code formatting in many places
davidfstr May 28, 2024
4352ac2
Formatting
davidfstr Jun 1, 2024
38ca3a1
Clarify statement about ForwardRefs
davidfstr Jun 1, 2024
3014728
Formatting
davidfstr Jun 1, 2024
2552bd0
Wordsmithing
davidfstr Jun 1, 2024
1c6a7af
PEP 12: Extract Intersphinx section. Add example of Intersphinx refer…
davidfstr May 31, 2024
433b557
Rewrite links to Typing specification to use Intersphinx references
davidfstr May 31, 2024
c997363
Change Optional[str] example in introductions to (str | None)
davidfstr May 31, 2024
c967db2
Revert "Post-History: Recognize discuss.python.org post links without…
davidfstr May 31, 2024
5e548ac
Alter draft 2 URL to non-canonical form to pass lint check
davidfstr May 31, 2024
f78c53b
Using TypeExprs: Clarify that TypeExpr is itself a type expression
davidfstr May 31, 2024
ad0d357
Remove some details about how TypeExpr is implemented at runtime
davidfstr May 31, 2024
a12fbb1
Affected signatures in the standard library: Elide the full signature…
davidfstr May 31, 2024
732ebf0
Clarify that class objects can usually, but not always, be instantiated
davidfstr May 31, 2024
3105326
Stringified TypeExprs: Clarify that behavior follows from TypeExpr be…
davidfstr Jun 1, 2024
fb83901
Clarify that (Any | None) is not the same as (Any)
davidfstr Jun 1, 2024
403a29d
Reformat Annotated link to be all on one line
davidfstr Jun 1, 2024
56ba5fe
Literal: Remove low-value example
davidfstr Jun 1, 2024
7c5911d
Non-Universal Type Expressions: Leave behaviors undefined
davidfstr Jun 1, 2024
e9cc932
"constrain" -> "parameterized by"
davidfstr Jun 1, 2024
cd51ef1
Shape -> MyTypedDict
davidfstr Jun 1, 2024
69ba1ee
"must" -> "already must"
davidfstr Jun 1, 2024
8a678fe
"constrain" -> "parameterized by" (Take 2)
davidfstr Jun 5, 2024
11a1e88
Add Rationale section, explaining what a type expression is and why i…
davidfstr Jun 5, 2024
f21077f
Non-Universal TypeExprs: Remove explanations of where Self, TypeGuard…
davidfstr Jun 5, 2024
9e58966
Static vs. Runtime Representations of TypeExprs: Streamline
davidfstr Jun 5, 2024
bf0ed38
Subtyping: Fix missing formatting for "object"
davidfstr Jun 5, 2024
098192b
Interactions with Annotated[]: Remove section
davidfstr Jun 5, 2024
2394391
How to Teach This: Rewrite section, integrating some prior 'Interacti…
davidfstr Jun 5, 2024
e035ecd
Revert "PEP 12: Extract Intersphinx section. Add example of Intersphi…
davidfstr Jun 6, 2024
dab1a63
Mention that dataclasses.make_dataclass() specially handles InitVar
davidfstr Jun 6, 2024
d3b7ec3
Explicit/Implicit TypeExpr Values: Add sections
davidfstr Jun 7, 2024
1c49cb6
Non-Universal TypeExprs: Inline section to initial 'TypeExpr Values' …
davidfstr Jun 7, 2024
64f510f
Wordsmith
davidfstr Jun 7, 2024
916e90a
Backwards Compatibility: Mention new rules for recognizing type expre…
davidfstr Jun 8, 2024
7e9b446
Motivation: Optionals -> unions
davidfstr Jun 8, 2024
f2b4818
Remove mentions to the is-consistent-with relationship, which is bein…
davidfstr Jun 8, 2024
4c2d5ab
Support pattern matching on type expressions: Clarify examples use a …
davidfstr Jun 8, 2024
ecafabc
Grammar
davidfstr Jun 8, 2024
bcc127e
Apply minor feedback
davidfstr Jun 16, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
Expand Up @@ -625,6 +625,8 @@ peps/pep-0743.rst @vstinner
peps/pep-0744.rst @brandtbucher
peps/pep-0745.rst @hugovk
# ...
peps/pep-0747.rst @JelleZijlstra
# ...
# peps/pep-0754.rst
# ...
peps/pep-0801.rst @warsaw
Expand Down
2 changes: 1 addition & 1 deletion peps/pep-0655.rst
Original file line number Diff line number Diff line change
Expand Up @@ -459,7 +459,7 @@ Such operators could be implemented on ``type`` via the ``__pos__``,
grammar.

It was decided that it would be prudent to introduce long-form notation
(i.e. ``Required[]`` and ``NotRequired[]``) before introducing
(i.e. ``Required[]`` and ``NotRequired[]``) before introducing
any short-form notation. Future PEPs may reconsider introducing this
or other short-form notation options.

Expand Down
Loading