Skip to content

Commit ae5e3c5

Browse files
committed
More formatting tweaking
1 parent bf7f3fb commit ae5e3c5

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

spec-draft.rst

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ as (we are omiting the ``Literal`` in places)::
6060

6161

6262
Rationale
63-
^^^^^^^^^
63+
'''''''''
6464
We need extended callable support, in order to inspect and produce callables via type-level computation. mypy supports `extended callables <https://mypy.readthedocs.io/en/stable/additional_features.html#extended-callable-types>`__ but they are deprecated in favor of callback protocols.
6565

6666

@@ -134,7 +134,7 @@ Type operators
134134

135135

136136
Object inspection and creation
137-
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
137+
''''''''''''''''''''''''''''''
138138

139139
* ``NewProtocol[*Ps: Member]``
140140

@@ -166,7 +166,7 @@ We also have helpers for extracting those names; they are all definable in terms
166166

167167

168168
Callable inspection and creation
169-
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
169+
''''''''''''''''''''''''''''''''
170170

171171
``Callable`` types always have their arguments exposed in the extended Callable format discussed above.
172172

@@ -180,7 +180,7 @@ TODO: Should we make ``GetInit`` be literal types of default parameter values to
180180
* ``Length[T: tuple]`` - get the length of a tuple as an int literal (or ``Literal[None]`` if it is unbounded)
181181

182182
Annotated
183-
^^^^^^^^^
183+
'''''''''
184184

185185
Libraries like FastAPI use annotations heavily, and we would like to be able to use annotations to drive type-level computation decision making.
186186

@@ -201,7 +201,7 @@ We understand that this may be controversial, as currently Annotated may be full
201201

202202

203203
InitField
204-
^^^^^^^^^
204+
'''''''''
205205

206206
We want to be able to support transforming types based on dataclasses/attrs/pydantic style field descriptors. In order to do that, we need to be able to consume things like calls to ``Field``.
207207

@@ -224,7 +224,7 @@ So if we write::
224224
then we would infer the type ``InitField[TypedDict('...', {'default': Literal[0]})]`` for the initializer, and that would be made available as the ``Init`` field of the ``Member``.
225225

226226
String manipulation
227-
^^^^^^^^^^^^^^^^^^^
227+
'''''''''''''''''''
228228

229229
String manipulation operations for string Literal types.
230230
We can put more in, but this is what typescript has.

0 commit comments

Comments
 (0)