-
Notifications
You must be signed in to change notification settings - Fork 745
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
The JSX lexer handles interpolation by running an embedded version of itself. This is not the manner in which other lexers handle interpolation and so makes maintenance difficult. It also greatly complicates subclassing the lexer (a practical concern because the TSX lexer subclasses the JSX lexer). To fix this, this commit rewrites the JSX lexer to simplify its structure. In particular, by specifying `:interpol` and `:interpol_inner` states, the need for an embedded version of the lexer is obviated.
- Loading branch information
Showing
3 changed files
with
53 additions
and
72 deletions.
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