[fine] export, dump source map, lookup fix

This commit is contained in:
John Doty 2024-02-15 06:29:56 -08:00
parent a3ae4339cf
commit a21f18da6e
4 changed files with 65 additions and 16 deletions

View file

@ -42,6 +42,7 @@ pub enum TokenKind {
Await,
Class,
Else,
Export,
False,
For,
From,
@ -294,6 +295,9 @@ impl<'a> Tokens<'a> {
if ident == "else" {
return TokenKind::Else;
}
if ident == "export" {
return TokenKind::Export;
}
}
'f' => {
if ident == "false" {
@ -639,12 +643,13 @@ mod tests {
test_tokens!(
more_more_keywords,
"in is match _ as",
"in is match _ as export",
(0, In, "in"),
(3, Is, "is"),
(6, Match, "match"),
(12, Underscore, "_"),
(14, As, "as")
(14, As, "as"),
(17, Export, "export")
);
test_tokens!(