[Python-ideas] Could the ast module's ASTs preserve source_length in addition to lineno and col_offset?

Haoyi Li haoyi.sg at gmail.com
Fri May 31 06:27:26 CEST 2013


Anyone else have any thoughts about this? This seems like it would be a
pretty straightforward thing to do, and I would be happy to go through the
code and submit a patch. The only question is whether we want to do it in
the first place; are there any reasons it can't/shouldn't be done that I'm
not aware of?


On Wed, May 29, 2013 at 8:09 PM, Steven D'Aprano <steve at pearwood.info>wrote:

> On 30/05/13 10:04, Haoyi Li wrote:
>
>> I don't need to keep the source code, I just need a single integer for
>> each
>> node. I would then be able to reconstruct the source snippet.
>>
>
> And so you did say. Sorry for the noise.
>
>
> --
> Steven
> ______________________________**_________________
> Python-ideas mailing list
> Python-ideas at python.org
> http://mail.python.org/**mailman/listinfo/python-ideas<http://mail.python.org/mailman/listinfo/python-ideas>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20130531/8228d68e/attachment.html>


More information about the Python-ideas mailing list