Message381023
I'm very late to join this thread, but since the Constant() node has now a kind field, we can possibly add this (though I'm not saying we should, depending on whether still this would be a nice addition to clinic docstrings.)
2 options that I can think off:
- Introduce a couple of new tokens (BIN_NUMBER, OCT_NUMBER, HEX_NUMBER).
- Add a new field to the tok_state struct (like const char* number_type) and when constructing the Constant node in the _PyPegen_number_token, add that number_type as the kind field of the constant.
In case of anyone wondering, the latter would be a +20 lines addition (no changes on the grammar / tokens, just a couple of new lines into the tokenizer and the _PyPegen_number_token.) |
|
Date |
User |
Action |
Args |
2020-11-15 18:27:00 | BTaskaya | set | recipients:
+ BTaskaya, barry, georg.brandl, rhettinger, terry.reedy, mark.dickinson, larry, ezio.melotti, eric.araujo, Arfrever, r.david.murray, carsten.klein@axn-software.de, serhiy.storchaka |
2020-11-15 18:27:00 | BTaskaya | set | messageid: <1605464820.91.0.764120015841.issue16801@roundup.psfhosted.org> |
2020-11-15 18:27:00 | BTaskaya | link | issue16801 messages |
2020-11-15 18:27:00 | BTaskaya | create | |
|