[Cython] AST from Cython files

Fabio Zadrozny fabiofz at gmail.com
Mon Jan 6 07:20:09 EST 2020


Hi all,

I'm currently using:

from Cython.Compiler.TreeFragment import parse_from_strings
mod = parse_from_strings(name, source)

to obtain the AST and it seems to be working well for me (I later convert
that AST to my own AST), but I'm currently using this for an IDE, so, I'd
like to be able to obtain the AST even if there are errors in the source
code.

So, I was thinking about making a pull request which would allow Cython to
provide the AST and recover from errors (it'd return the AST and a list of
errors instead of raising the first error in this API).

So, I'd like to now from cython devs, before providing a pull request for
that if such a pull request would be Ok or if you see some issue in this
change.

Thanks,

Fabio
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/cython-devel/attachments/20200106/8c0a3228/attachment.html>


More information about the cython-devel mailing list