JWE Project Ideas: Difference between revisions

Jump to navigation Jump to search
No edit summary
Line 8: Line 8:


* Gather and attach all comments to tokens in the lexer, never in the parser.  This change will allow us to simplify the grammar by eliminating the stash_comment nonterminal symbol in the parser. [<span style="color:DarkGreen">Done</span>]
* Gather and attach all comments to tokens in the lexer, never in the parser.  This change will allow us to simplify the grammar by eliminating the stash_comment nonterminal symbol in the parser. [<span style="color:DarkGreen">Done</span>]
* Store tokens (with location info and comments attached) in the parse tree instead of imprecise data like "leading_comment" or "trailing_comment".  This change will allow better location info for error reporting and easier and more accurate access to comments so that we can more easily find documentation strings or test and demo blocks (some of that work is already done). [<span style="color:DarkOrange">In Progress</span> - still need to handle some separator and operator tokens]
* Store tokens (with location info and comments attached) in the parse tree instead of imprecise data like "leading_comment" or "trailing_comment".  This change will allow better location info for error reporting and easier and more accurate access to comments so that we can more easily find documentation strings or test and demo blocks (some of that work is already done). [<span style="color:DarkOrange">In Progress</span> - still need to handle some separator tokens]
* Recognize and tag comments that look like test or demo blocks.  Skip those when looking for doc strings.
* Recognize and tag comments that look like test or demo blocks.  Skip those when looking for doc strings.
* Update the parse tree classes to provide access to the new information stored in them.
* Update the parse tree classes to provide access to the new information stored in them.

Navigation menu