|
1 | 1 | PEP: 827 |
2 | 2 | Title: Type Manipulation |
3 | | -Author: Michael J. Sullivan <sully@vercel.com>, Daniel W. Park <daniel.park@vercel.com>, Yury Selivanov <yury@vercel.com> |
| 3 | +Author: Michael J. Sullivan <sully@vercel.com>, |
| 4 | + Daniel W. Park <daniel.park@vercel.com>, |
| 5 | + Yury Selivanov <yury@vercel.com> |
4 | 6 | Discussions-To: Pending |
5 | 7 | Status: Draft |
6 | 8 | Type: Standards Track |
@@ -1017,7 +1019,7 @@ initializer). |
1017 | 1019 | dataclasses-style method generation |
1018 | 1020 | ----------------------------------- |
1019 | 1021 |
|
1020 | | -``InitFnType`` generates a ``Member`` for a new `__init__` function |
| 1022 | +``InitFnType`` generates a ``Member`` for a new ``__init__`` function |
1021 | 1023 | based on iterating over all attributes. |
1022 | 1024 |
|
1023 | 1025 | ``GetDefault`` here is borrowed from our FastAPI-like example above. |
@@ -1055,8 +1057,8 @@ based on iterating over all attributes. |
1055 | 1057 | *[x for x in typing.Iter[typing.Members[T]]], |
1056 | 1058 | ] |
1057 | 1059 |
|
1058 | | -``UpdateClass`` can then be used to create a class decorator (ala |
1059 | | -`@dataclass`) adds a new `__init__`` method to a class. |
| 1060 | +``UpdateClass`` can then be used to create a class decorator (a la |
| 1061 | +``@dataclass``) adds a new ``__init__`` method to a class. |
1060 | 1062 |
|
1061 | 1063 | :: |
1062 | 1064 |
|
@@ -1292,8 +1294,7 @@ tricks for building a string do not work for loops and |
1292 | 1294 | conditionals. |
1293 | 1295 |
|
1294 | 1296 | This could be mitigated by doing one of: |
1295 | | - 1. The `"Just store the |
1296 | | - strings" <https://peps.python.org/pep-0649/#just-store-the-strings>`_ |
| 1297 | + 1. The :pep:`"Just store the strings" <649#just-store-the-strings>`_ |
1297 | 1298 | option from :pep:`649`, which would allow always extracting |
1298 | 1299 | unevaluated strings. |
1299 | 1300 | 2. Adding a ``Format.AST`` mode for |
|
0 commit comments