Tasks Accomplished This Week
Issues Raised
- [Tokenizer] Segfault during tokenization · Issue #612 · lcompilers/lpython (github.com) [CLOSED]
- [Tokenizer] Newline token not returned after comments · Issue #617 · lcompilers/lpython (github.com) [CLOSED]
Issues Closed/Partially Completed
- [New] Parse Ellipsis and None · Issue #510 · lcompilers/lpython (github.com) [CLOSED]
- [New] Parse IN and IS in the expression · Issue #511 · lcompilers/lpython (github.com) [OPEN]
- [New] Parse Comments after and inside Multiline statements · Issue #509 · lcompilers/lpython (github.com) [CLOSED]
- [Tokenizer] Segfault during tokenization · Issue #612 · lcompilers/lpython (github.com) [CLOSED]
- [Tokenizer] Newline token not returned after comments · Issue #617 · lcompilers/lpython (github.com) [CLOSED]
- [New] Parse raw, byte and formatted strings · Issue #512 · lcompilers/lpython (github.com) [OPEN]
PRs
- [Parser] Parsing rules for `...` and `None` by akshanshbhatt · Pull Request #538 · lcompilers/lpython (github.com) [CLOSED]
- [Parser] Rules for expressions containing `is` and `is not` by akshanshbhatt · Pull Request #557 · lcompilers/lpython (github.com) [CLOSED]
- [Parser] Rules for `not in` by akshanshbhatt · Pull Request #578 · lcompilers/lpython (github.com) [CLOSED]
- [Parser] Fix issues with comment and indentation by akshanshbhatt · Pull Request #619 · lcompilers/lpython (github.com) [CLOSED]
- [WIP][Parser] Add support for parsing prefixed strings by akshanshbhatt · Pull Request #624 · lcompilers/lpython (github.com) [OPEN]
Problems Faced This Week
- I tried to close #511 altogether but failed to do so because of multiple shift/reduce conflicts raised during parser generation. The syntax for logical keyword in was conflicting with the syntax of for loop.
- While working on parsing prefixed strings, I came across an error with byte strings. The current AST generation (the current slow parser) needs to be debugged.
- Formatted strings, as of now, works well for most of the cases. However in some cases, there is gibberish character generation for the formatted value's id field. I have still not found the actual cause of this issue. The same example generates perfectly fine AST on my mentor's computer (Linux, x86) but causes issue on mine (MacOS, ARM).
Plans For Upcoming Week
- I aim to complete PR #624 and close the issue related to it (#512). I aim to add basic parsing support for formatted, byte, raw and unicode string initially. We can iterate and make it better later.
- I also aim to work on issues #508 and #620.
- I will try to finally close #511 by refactoring the for loop parsing patterns.