Removing CharsetLiteral

It was no different from just Literal (and most likely won't be any
different)
This commit is contained in:
Jeff Avallone 2014-12-19 20:23:32 -05:00
parent 2d4694f447
commit 70789258ab
3 changed files with 1 additions and 9 deletions

View File

@ -9,7 +9,6 @@ import Match from './javascript/match.js';
import MatchFragment from './javascript/match_fragment.js';
import Subexp from './javascript/subexp.js';
import Charset from './javascript/charset.js';
import CharsetLiteral from './javascript/charset_literal.js';
import CharsetEscape from './javascript/charset_escape.js';
import CharsetRange from './javascript/charset_range.js';
import Literal from './javascript/literal.js';
@ -28,7 +27,6 @@ parser.Parser.Match = { module: Match };
parser.Parser.MatchFragment = { module: MatchFragment };
parser.Parser.Subexp = { module: Subexp };
parser.Parser.Charset = { module: Charset };
parser.Parser.CharsetLiteral = { module: CharsetLiteral };
parser.Parser.CharsetEscape = { module: CharsetEscape };
parser.Parser.CharsetRange = { module: CharsetRange };
parser.Parser.Literal = { module: Literal };

View File

@ -1,6 +0,0 @@
import _ from 'lodash';
import Literal from './literal.js';
export default _.extend({}, Literal, {
type: 'literal'
});

View File

@ -22,7 +22,7 @@ grammar JavascriptRegexp
charset <- "[" invert:"^"? parts:( charset_range / charset_terminal )* "]" <Charset>
charset_range <- first:charset_terminal "-" last:charset_terminal <CharsetRange>
charset_terminal <- charset_escape <CharsetEscape>
/ charset_literal <CharsetLiteral>
/ charset_literal <Literal>
charset_escape <- "\\" esc:(
code:[bdDfnrsStvwW] arg:""?
/ code:"0" arg:[0-7]+