Add support for exporting async functions

This commit is contained in:
Sebastian McKenzie 2014-11-13 13:16:49 +11:00
parent c5ca7ee32c
commit 2506be7b1a

View File

@ -2542,7 +2542,7 @@
function parseExport(node) {
next();
// export var|const|let|function|class ...;
if (tokType === _var || tokType === _const || tokType === _let || tokType === _function || tokType === _class) {
if (tokType === _var || tokType === _const || tokType === _let || tokType === _function || tokType === _class || tokType === _async) {
node.declaration = parseStatement();
node['default'] = false;
node.specifiers = null;