py: add async/await/async for/async with syntax
They are sugar for marking function as generator, "yield from" and pep492 python "semantically equivalents" respectively. @dpgeorge was the original author of this patch, but @pohmelie made changes to implement `async for` and `async with`.
This commit is contained in:
@@ -63,6 +63,10 @@ typedef enum _mp_token_kind_t {
|
||||
MP_TOKEN_KW_AND,
|
||||
MP_TOKEN_KW_AS,
|
||||
MP_TOKEN_KW_ASSERT,
|
||||
#if MICROPY_PY_ASYNC_AWAIT
|
||||
MP_TOKEN_KW_ASYNC,
|
||||
MP_TOKEN_KW_AWAIT,
|
||||
#endif
|
||||
MP_TOKEN_KW_BREAK,
|
||||
MP_TOKEN_KW_CLASS,
|
||||
MP_TOKEN_KW_CONTINUE,
|
||||
|
||||
Reference in New Issue
Block a user