Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix parsing of multiple methods on the same line
When a two class methods existed on the same line the second method would be omitted and the remainder of the file may experience other parsing mistakes. This occurred when the second method required altering the lex state in a way read_directive didn't reproduce. This would cause incorrect parsing of tokens as when tokens are ungotten the tokens are not re-lexed. Now when read_directive encounters a "def" token it assumes no directives are present (as only one directive is allowed per line). Fixes ruby#221
- Loading branch information
Showing
3 changed files
with
29 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters