Message247038
An updated patch is attached. I had to implement a little bit more sophisticated tracking of one-line functions to fix parsing of things like
def foo():
async def f(): pass
async def f(): pass
async = 1
I hope that test_coroutine.py now covers all possible legal and illegal async/await syntax.
> Haven't reviewed the patch, but this approach sounds great (in fact I had
> assumed you were doing this already, and I was a bit surprised by some of
> the problems you encountered :-).
Yes, I'm a bit surprised myself ;) I guess one of the reasons why I tried to do more in tokenizer is that at the time of me hacking the tokenizer, compile.c wasn't quite ready (specifically, catching async for/async with/await outside of async functions).
> Good news :) I guess this means we can also remove the sentence I added at [..]
Right! |
|
Date |
User |
Action |
Args |
2015-07-21 14:30:25 | yselivanov | set | recipients:
+ yselivanov, gvanrossum, ncoghlan, vstinner, skrah, martin.panter |
2015-07-21 14:30:25 | yselivanov | set | messageid: <1437489025.36.0.562575701004.issue24619@psf.upfronthosting.co.za> |
2015-07-21 14:30:25 | yselivanov | link | issue24619 messages |
2015-07-21 14:30:25 | yselivanov | create | |
|