@@ -1166,30 +1166,38 @@ Program : StatementList Eof { AST.JSAstProgram $1 $2 {- 'Program1' -} }
1166
1166
-- [ ] export default ClassDeclaration[Default]
1167
1167
-- [ ] export default [lookahead ∉ { function, class }] AssignmentExpression[In] ;
1168
1168
ExportDeclaration :: { AST.JSStatement }
1169
- ExportDeclaration : Export ExportClause AutoSemi { AST.JSExport $1 $2 $3 {- ' ExportDeclaration1' -} }
1170
- | Export VariableStatement AutoSemi { AST.JSExport $1 (AST.JSExportStatement $2) $3 {- ' ExportDeclaration2' -} }
1169
+ ExportDeclaration : Export ExportClause AutoSemi
1170
+ { AST.JSExport $1 $2 $3 {- ' ExportDeclaration1' -} }
1171
+ | Export VariableStatement AutoSemi
1172
+ { AST.JSExport $1 (AST.JSExportStatement $2) $3 {- ' ExportDeclaration2' -} }
1171
1173
1172
1174
-- ExportClause :
1173
1175
-- { }
1174
1176
-- { ExportsList }
1175
1177
-- { ExportsList , }
1176
1178
ExportClause :: { AST.JSExportBody }
1177
- ExportClause : LBrace RBrace { AST.JSExportClause $1 Nothing $2 {- ' ExportClause1' -} }
1178
- | LBrace ExportsList RBrace { AST.JSExportClause $1 (Just $2) $3 {- ' ExportClause2' -} }
1179
+ ExportClause : LBrace RBrace
1180
+ { AST.JSExportClause $1 Nothing $2 {- ' ExportClause1' -} }
1181
+ | LBrace ExportsList RBrace
1182
+ { AST.JSExportClause $1 (Just $2) $3 {- ' ExportClause2' -} }
1179
1183
1180
1184
-- ExportsList :
1181
1185
-- ExportSpecifier
1182
1186
-- ExportsList , ExportSpecifier
1183
1187
ExportsList :: { AST.JSCommaList AST.JSExportSpecifier }
1184
- ExportsList : ExportSpecifier { AST.JSLOne $1 {- ' ExportsList1' -} }
1185
- | ExportsList Comma ExportSpecifier { AST.JSLCons $1 $2 $3 {- ' ExportsList2' -} }
1188
+ ExportsList : ExportSpecifier
1189
+ { AST.JSLOne $1 {- ' ExportsList1' -} }
1190
+ | ExportsList Comma ExportSpecifier
1191
+ { AST.JSLCons $1 $2 $3 {- ' ExportsList2' -} }
1186
1192
1187
1193
-- ExportSpecifier :
1188
1194
-- IdentifierName
1189
1195
-- IdentifierName as IdentifierName
1190
1196
ExportSpecifier :: { AST.JSExportSpecifier }
1191
- ExportSpecifier : IdentifierName { AST.JSExportSpecifier (identName $1) {- ' ExportSpecifier1' -} }
1192
- | IdentifierName As IdentifierName { AST.JSExportSpecifierAs (identName $1) $2 (identName $3) {- ' ExportSpecifier2' -} }
1197
+ ExportSpecifier : IdentifierName
1198
+ { AST.JSExportSpecifier (identName $1) {- ' ExportSpecifier1' -} }
1199
+ | IdentifierName As IdentifierName
1200
+ { AST.JSExportSpecifierAs (identName $1) $2 (identName $3) {- ' ExportSpecifier2' -} }
1193
1201
1194
1202
-- For debugging/other entry points
1195
1203
LiteralMain :: { AST.JSAST }
0 commit comments