Argument-Clinic / cpython

The Python programming language
https://www.python.org/
Other
1 stars 0 forks source link

PoC: Move docstring assert to the DSL state machine #12

Open erlend-aasland opened 1 year ago

erlend-aasland commented 1 year ago

An alternative to this could be to compute the correct line number from within format_docstring().

erlend-aasland commented 1 year ago

An alternative to this could be to compute the correct line number from within format_docstring().

OTOH, if we move the docstring formatting to the render step, it might not be that easy to get the correct line number anymore; perhaps the parsing state machine is the best place for it.