Dynamic Templater

linkAmplenote Dynamic Templater Plugin Overview

The Amplenote Dynamic Templater Plugin allows users to build and insert dynamic templates seamlessly within Amplenote. With this plugin, you can expand date expressions, customize date formats, create note links, and automate template insertion based on your current context. This tool enhances productivity and streamlines your note-taking process.

Watch the Overview Video



☕ If the plugin is helpful to you, you can buy me a coffee!

linkFeatures

Dynamic Template Insertion: Build and insert templates dynamically at your current cursor position using the {= syntax, which mimics the native template support (@= or [[=).

Default Template Assignment: Assign default templates to specific tags or for new notes. These templates will be suggested when inserting a template with {=

Dynamic New Note Link/Button: Use a link/button to auto-create a new note with a dynamic template. This also supports expressions in the note name and specifying a template section to use.


Date and Math Expression Expansion: Automatically expand complex recognized date and math expressions within curly brackets, such as {tomorrow} or {1+8}

Supports Amplenote expressions listed here

Supports advanced expressions and compound expressions like:

{2 days before the Last Weekday of Four Months from Now at 5pm}

{2 Weeks after Friday}

{Thursday of Last Week}

Full list of supported expressions listed here: Evaluator Supported Date and Math Expressions

Task Start/Hide Dates: Apply dynamic start or hide dates to tasks using expressions like {start:expression} or {hide:expression}. Like {start:next Monday}.

Custom Date Formatting: Customize the format of dates using specifiers. For example, {"MM-dd-yyyy":tomorrow} expands to “09-27-2024”.

Dynamic Note Linking: Convert eligible text enclosed in double square brackets like [[daily-notes/{Next Monday}]] into links.

Auto-Creating Notes: Notes are created if they don't already exist. This can be suppressed with an optional prefix flag (?) or silent flag (_).

Display Name with Pipe Character (**|***): Use the pipe character to set an alias or display name for the link.

Nested Templates: You can link to and nest templates within each other with [[= ]] or {= }. You can also insert a subsection of a template.

Smart Indentation: Insert templates while maintaining the current indentation level within bullet, numbered, or task lists.

Note: This works as long as the template itself contains a list. Since headings and other content aren't indent-able those won't maintain current indentation.

Jot Suggestions: This functionality enhances the user experience in Jots mode.

linkKnown Issues

Jots seem to be more flaky in Amplenote than notes. The plugin suggestion does not appear consistently unless you type in the jot. And we have to use a workaround to insert the content until they fix the Plugin API, but it does work.

The plugin has more bloat than I want. It currently rebundles the date and js parsing libraries because Amplenote doesn't expose them. I'm working to see if we can change this and significantly reduce the plugin size.

linkUsage

linkImportant Usage Note

Certain convenience features of the plugin require dynamic templates to be tagged with a particular pre-set tag. By default, this tag is system/template, but it is a user-configurable setting under the plugin settings labeled Dynamic Template Tag. This is optional, most of the plugin functionality works without it.

linkInserting a Template

Type {= to insert default templates or {=Pick a template} to pull up a menu to select an available template

The plugin will automatically insert the template’s contents at the current cursor position.

linkCreating a Dynamic New Note Link

Two ways to create a dynamic new note link:

Use the {Templater: New Note Link} expression to bring up a form to generate the link.

Now when you have "new note" links as described in the Amplenote docs, there will be a "Dynamic Templater: Create" button that lets you create it while parsing the source note as a dynamic template.

linkTask Start/Hide Dates

To set a start date for a task, include {start:expression} in the task description.

To hide a task until a specific date, use {hide:expression}

linkCustom Date Formatting

Add a date format specifier to expressions for customized date formats. Here are all the date formats supported: date-fns Formats

Example: {"MM-dd-yyyy":tomorrow} expands to “09-27-2024”.

linkLinking Notes

Use double square brackets ([[ ]]) to create or link to notes. You can have date/math expressions in the link. You can also link to specific sections within a note by adding # followed by the section name.

By default, notes will be created if they do not exist, unless you add an optional flag (?) at the beginning of the note. The optional flag allows you to link to the note only if it exists, avoiding the creation of empty notes.

You can also use a silent flag (_) to surpress the link output completely if the note doesn't exist. It's a optional flag that doesn't output anything.

You can also use an alias to display a different name for the link by using the pipe character (|) at the end.

Examples:

[[daily-jots/{Next Sunday}]] links to (and creates, if necessary) a note tagged with "daily-jots" for next sunday.

[[?daily-jots/{Monday of last week}]] links to a note tagged with "daily-jots" for "Monday of last week" if it exists; otherwise, it will remain as plain text (e.g., [[daily-jots/September 9th, 2024]]). This allows you to create/link the note at a later time or remove it entirely using Amplenote's native interface.

[[Dynamic Note Name|Custom Display]] links to "Dynamic Note Name" but displays "Custom Display" as the clickable text.

[[{Tomorrow}#Section|Custom Display]] links to the "Section" of "Tomorrow" while showing "Custom Display" as the clickable text.

linkNested Templates

Use template links ([[= ]] or {= }, they are interchangeable) within your dynamic templates to nest other templates.

You can specify a subsection of a template to use for insertion with # or #>. The # includes the section header, and the #> only uses the section inner content.

Examples:

{=project/Projects} inserts the Projects note as a template

[[=project/Project Dashboard#Active Projects]] inserts the Active Projects section of the Projects note

[[=daily-templates/{"EEEE":Today}#>Tasks]] inserts the content under the tasks section of the template for the day of the week

linkAssigning Default Templates

For the default configuration:

Use the Tag Default Manager with the "Templater: Manage Defaults" menu under Cmd/Ctrl-O. Note: This opens a sidebar menu, which only works on desktop not mobile.

A global or tag default can also be set by going to the note and using the Templater: Set Default Template menu. (Menu won't appear if template isn't tagged with dynamic template tag)

At the tag level, you can make a template the default for a tag by tagging it with that tag and the Dynamic Template Tag. For example, a template could have both system/template and project tags to make it the default dynamic template for project notes.

Assign templates to tags to receive a Jot Suggestion when visiting that tag in Jots mode.

linkAuthor

Published by: lapluviosilla

Date: October 3rd, 2024

Last Updated: October 22nd, 2024

linkFeedback

If you have any questions, issues, or feedback, please feel free to reach out!

linkChangelog

October 22nd, 2024 -- Added nested templates and template section extraction features

October 19th, 2024 -- Fixed a couple bugs

October 14th, 2024 -- Added optional flag and display name feature for dynamic note linking

October 11th, 2024 -- Added note create link dynamic template support

October 10th, 2024 -- Added compound date expressions

linkDynamic Templater (1.1)

linkTable - Plugin Parameters:

name

Dynamic Templater

description

A plugin to make templates more powerful and dynamic

icon

auto_awesome_mosaic

instructions



Watch the Overview Video

View the README on Github
Features

- Dynamic Template Insertion: Build and insert templates dynamically at your current cursor position using the {= syntax, which mimics the native template support (@= or [[=).

- Default Template Assignment: Assign default templates to specific tags or for new notes. These templates will be suggested when inserting a template with {=

- Dynamic New Note Link/Button: Use a link/button to auto-create a new note with a dynamic template. This also supports expressions in the note name and specifying a template section to use.

- Date and Math Expression Expansion: Automatically expand complex recognized date and math expressions within curly brackets, such as {tomorrow} or {1+8}

- Supports Amplenote expressions listed here

- Supports advanced expressions and compound expressions like:

- {2 days before the Last Weekday of Four Months from Now at 5pm}

- {2 Weeks after Friday}

- {Thursday of Last Week}

- Full list of supported expressions listed here: Evaluator Supported Date and Math Expressions

- Task Start/Hide Dates: Apply dynamic start or hide dates to tasks using expressions like {start:expression} or {hide:expression}. Like {start:next Monday}.

- Custom Date Formatting: Customize the format of dates using specifiers. For example, {"MM-dd-yyyy":tomorrow} expands to “09-27-2024”.

- Dynamic Note Linking: Convert eligible text enclosed in double square brackets like [[daily-notes/{Next Monday}]] into links.

- Auto-Creating Notes: Notes are created if they don't already exist. This can be suppressed with an optional prefix flag (?) or silent flag (_).
- Display Name with Pipe Character (****|*****): Use the pipe character to set an alias or display name for the link.

- Nested Templates: You can link to and nest templates within each other with [[= ]] or {= }. You can also insert a subsection of a template.

- Smart Indentation: Insert templates while maintaining the current indentation level within bullet, numbered, or task lists.

- Note: This works as long as the template itself contains a list. Since headings and other content aren't indent-able those won't maintain current indentation.

- Jot Suggestions: This functionality enhances the user experience in Jots mode.

setting

Dynamic Template Tag (default: system/template)

setting

Global Default Template

setting

Tag Default Templates

linkCode Base:

Source Repo: https://github.com/lapluviosilla/amplenote-templater

(()=>{var Ze=Object.create,Ce=Object.defineProperty,et=Object.getOwnPropertyDescriptor,Se=Object.getOwnPropertyNames,tt=Object.getPrototypeOf,nt=Object.prototype.hasOwnProperty,it=(e,i)=>function(){return i||(0,e[Se(e)[0]])((i={exports:{}}).exports,i),i.exports},rt=(e,i,s,r)=>{if(i&&typeof i=="object"||typeof i=="function")for(let l of Se(i))!nt.call(e,l)&&l!==s&&Ce(e,l,{get:()=>i[l],enumerable:!(r=et(i,l))||r.enumerable});return e},st=(e,i,s)=>(s=e!=null?Ze(tt(e)):{},rt(i||!e||!e.__esModule?Ce(s,"default",{value:e,enumerable:!0}):s,e)),at=it({"node_modules/esprima/dist/esprima.js"(e,i){(function(r,l){typeof e=="object"&&typeof i=="object"?i.exports=l():typeof define=="function"&&define.amd?define([],l):typeof e=="object"?e.esprima=l():r.esprima=l()})(e,function(){return function(s){var r={};function l(u){if(r[u])return r[u].exports;var D=r[u]={exports:{},id:u,loaded:!1};return s[u].call(D.exports,D,D.exports,l),D.loaded=!0,D.exports}return l.m=s,l.c=r,l.p="",l(0)}([function(s,r,l){"use strict";Object.defineProperty(r,"__esModule",{value:!0});var u=l(1),D=l(3),f=l(8),h=l(15);function C(d,t,n){var a=null,o=function(B,N){n&&n(B,N),a&&a.visit(B,N)},p=typeof n=="function"?o:null,x=!1;if(t){x=typeof t.comment=="boolean"&&t.comment;var S=typeof t.attachComment=="boolean"&&t.attachComment;(x||S)&&(a=new u.CommentHandler,a.attach=S,t.comment=!0,p=o)}var w=!1;t&&typeof t.sourceType=="string"&&(w=t.sourceType==="module");var F;t&&typeof t.jsx=="boolean"&&t.jsx?F=new D.JSXParser(d,t,p):F=new f.Parser(d,t,p);var b=w?F.parseModule():F.parseScript(),k=b;return x&&a&&(k.comments=a.comments),F.config.tokens&&(k.tokens=F.tokens),F.config.tolerant&&(k.errors=F.errorHandler.errors),k}r.parse=C;function y(d,t,n){var a=t||{};return a.sourceType="module",C(d,a,n)}r.parseModule=y;function v(d,t,n){var a=t||{};return a.sourceType="script",C(d,a,n)}r.parseScript=v;function c(d,t,n){var a=new h.Tokenizer(d,t),o;o=[];try{for(;;){var p=a.getNextToken();if(!p)break;n&&(p=n(p)),o.push(p)}}catch(x){a.errorHandler.tolerate(x)}return a.errorHandler.tolerant&&(o.errors=a.errors()),o}r.tokenize=c;var m=l(2);r.Syntax=m.Syntax,r.version="4.0.1"},function(s,r,l){"use strict";Object.defineProperty(r,"__esModule",{value:!0});var u=l(2),D=function(){function f(){this.attach=!1,this.comments=[],this.stack=[],this.leading=[],this.trailing=[]}return f.prototype.insertInnerComments=function(h,C){if(h.type===u.Syntax.BlockStatement&&h.body.length===0){for(var y=[],v=this.leading.length-1;v>=0;--v){var c=this.leading[v];C.end.offset>=c.start&&(y.unshift(c.comment),this.leading.splice(v,1),this.trailing.splice(v,1))}y.length&&(h.innerComments=y)}},f.prototype.findTrailingComments=function(h){var C=[];if(this.trailing.length>0){for(var y=this.trailing.length-1;y>=0;--y){var v=this.trailing[y];v.start>=h.end.offset&&C.unshift(v.comment)}return this.trailing.length=0,C}var c=this.stack[this.stack.length-1];if(c&&c.node.trailingComments){var m=c.node.trailingComments[0];m&&m.range[0]>=h.end.offset&&(C=c.node.trailingComments,delete c.node.trailingComments)}return C},f.prototype.findLeadingComments=function(h){for(var C=[],y;this.stack.length>0;){var v=this.stack[this.stack.length-1];if(v&&v.start>=h.start.offset)y=v.node,this.stack.pop();else break}if(y){for(var c=y.leadingComments?y.leadingComments.length:0,m=c-1;m>=0;--m){var d=y.leadingComments[m];d.range[1]<=h.start.offset&&(C.unshift(d),y.leadingComments.splice(m,1))}return y.leadingComments&&y.leadingComments.length===0&&delete y.leadingComments,C}for(var m=this.leading.length-1;m>=0;--m){var v=this.leading[m];v.start<=h.start.offset&&(C.unshift(v.comment),this.leading.splice(m,1))}return C},f.prototype.visitNode=function(h,C){if(!(h.type===u.Syntax.Program&&h.body.length>0)){this.insertInnerComments(h,C);var y=this.findTrailingComments(C),v=this.findLeadingComments(C);v.length>0&&(h.leadingComments=v),y.length>0&&(h.trailingComments=y),this.stack.push({node:h,start:C.start.offset})}},f.prototype.visitComment=function(h,C){var y=h.type[0]==="L"?"Line":"Block",v={type:y,value:h.value};if(h.range&&(v.range=h.range),h.loc&&(v.loc=h.loc),this.comments.push(v),this.attach){var c={comment:{type:y,value:h.value,range:[C.start.offset,C.end.offset]},start:C.start.offset};h.loc&&(c.comment.loc=h.loc),h.type=y,this.leading.push(c),this.trailing.push(c)}},f.prototype.visit=function(h,C){h.type==="LineComment"?this.visitComment(h,C):h.type==="BlockComment"?this.visitComment(h,C):this.attach&&this.visitNode(h,C)},f}();r.CommentHandler=D},function(s,r){"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.Syntax={AssignmentExpression:"AssignmentExpression",AssignmentPattern:"AssignmentPattern",ArrayExpression:"ArrayExpression",ArrayPattern:"ArrayPattern",ArrowFunctionExpression:"ArrowFunctionExpression",AwaitExpression:"AwaitExpression",BlockStatement:"BlockStatement",BinaryExpression:"BinaryExpression",BreakStatement:"BreakStatement",CallExpression:"CallExpression",CatchClause:"CatchClause",ClassBody:"ClassBody",ClassDeclaration:"ClassDeclaration",ClassExpression:"ClassExpression",ConditionalExpression:"ConditionalExpression",ContinueStatement:"ContinueStatement",DoWhileStatement:"DoWhileStatement",DebuggerStatement:"DebuggerStatement",EmptyStatement:"EmptyStatement",ExportAllDeclaration:"ExportAllDeclaration",ExportDefaultDeclaration:"ExportDefaultDeclaration",ExportNamedDeclaration:"ExportNamedDeclaration",ExportSpecifier:"ExportSpecifier",ExpressionStatement:"ExpressionStatement",ForStatement:"ForStatement",ForOfStatement:"ForOfStatement",ForInStatement:"ForInStatement",FunctionDeclaration:"FunctionDeclaration",FunctionExpression:"FunctionExpression",Identifier:"Identifier",IfStatement:"IfStatement",ImportDeclaration:"ImportDeclaration",ImportDefaultSpecifier:"ImportDefaultSpecifier",ImportNamespaceSpecifier:"ImportNamespaceSpecifier",ImportSpecifier:"ImportSpecifier",Literal:"Literal",LabeledStatement:"LabeledStatement",LogicalExpression:"LogicalExpression",MemberExpression:"MemberExpression",MetaProperty:"MetaProperty",MethodDefinition:"MethodDefinition",NewExpression:"NewExpression",ObjectExpression:"ObjectExpression",ObjectPattern:"ObjectPattern",Program:"Program",Property:"Property",RestElement:"RestElement",ReturnStatement:"ReturnStatement",SequenceExpression:"SequenceExpression",SpreadElement:"SpreadElement",Super:"Super",SwitchCase:"SwitchCase",SwitchStatement:"SwitchStatement",TaggedTemplateExpression:"TaggedTemplateExpression",TemplateElement:"TemplateElement",TemplateLiteral:"TemplateLiteral",ThisExpression:"ThisExpression",ThrowStatement:"ThrowStatement",TryStatement:"TryStatement",UnaryExpression:"UnaryExpression",UpdateExpression:"UpdateExpression",VariableDeclaration:"VariableDeclaration",VariableDeclarator:"VariableDeclarator",WhileStatement:"WhileStatement",WithStatement:"WithStatement",YieldExpression:"YieldExpression"}},function(s,r,l){"use strict";var u=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,a){n.__proto__=a}||function(n,a){for(var o in a)a.hasOwnProperty(o)&&(n[o]=a[o])};return function(n,a){t(n,a);function o(){this.constructor=n}n.prototype=a===null?Object.create(a):(o.prototype=a.prototype,new o)}}();Object.defineProperty(r,"__esModule",{value:!0});var D=l(4),f=l(5),h=l(6),C=l(7),y=l(8),v=l(13),c=l(14);v.TokenName[100]="JSXIdentifier",v.TokenName[101]="JSXText";function m(t){var n;switch(t.type){case h.JSXSyntax.JSXIdentifier:var a=t;n=a.name;break;case h.JSXSyntax.JSXNamespacedName:var o=t;n=m(o.namespace)+":"+m(o.name);break;case h.JSXSyntax.JSXMemberExpression:var p=t;n=m(p.object)+"."+m(p.property);break;default:break}return n}var d=function(t){u(n,t);function n(a,o,p){return t.call(this,a,o,p)||this}return n.prototype.parsePrimaryExpression=function(){return this.match("<")?this.parseJSXRoot():t.prototype.parsePrimaryExpression.call(this)},n.prototype.startJSX=function(){this.scanner.index=this.startMarker.index,this.scanner.lineNumber=this.startMarker.line,this.scanner.lineStart=this.startMarker.index-this.startMarker.column},n.prototype.finishJSX=function(){this.nextToken()},n.prototype.reenterJSX=function(){this.startJSX(),this.expectJSX("}"),this.config.tokens&&this.tokens.pop()},n.prototype.createJSXNode=function(){return this.collectComments(),{index:this.scanner.index,line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart}},n.prototype.createJSXChildNode=function(){return{index:this.scanner.index,line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart}},n.prototype.scanXHTMLEntity=function(a){for(var o="&",p=!0,x=!1,S=!1,w=!1;!this.scanner.eof()&&p&&!x;){var F=this.scanner.source[this.scanner.index];if(F===a)break;if(x=F===";",o+=F,++this.scanner.index,!x)switch(o.length){case 2:S=F==="#";break;case 3:S&&(w=F==="x",p=w||D.Character.isDecimalDigit(F.charCodeAt(0)),S=S&&!w);break;default:p=p&&!(S&&!D.Character.isDecimalDigit(F.charCodeAt(0))),p=p&&!(w&&!D.Character.isHexDigit(F.charCodeAt(0)));break}}if(p&&x&&o.length>2){var b=o.substr(1,o.length-2);S&&b.length>1?o=String.fromCharCode(parseInt(b.substr(1),10)):w&&b.length>2?o=String.fromCharCode(parseInt("0"+b.substr(1),16)):!S&&!w&&c.XHTMLEntities[b]&&(o=c.XHTMLEntities[b])}return o},n.prototype.lexJSX=function(){var a=this.scanner.source.charCodeAt(this.scanner.index);if(a===60||a===62||a===47||a===58||a===61||a===123||a===125){var o=this.scanner.source[this.scanner.index++];return{type:7,value:o,lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:this.scanner.index-1,end:this.scanner.index}}if(a===34||a===39){for(var p=this.scanner.index,x=this.scanner.source[this.scanner.index++],S="";!this.scanner.eof();){var w=this.scanner.source[this.scanner.index++];if(w===x)break;w==="&"?S+=this.scanXHTMLEntity(x):S+=w}return{type:8,value:S,lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:p,end:this.scanner.index}}if(a===46){var F=this.scanner.source.charCodeAt(this.scanner.index+1),b=this.scanner.source.charCodeAt(this.scanner.index+2),o=F===46&&b===46?"...":".",p=this.scanner.index;return this.scanner.index+=o.length,{type:7,value:o,lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:p,end:this.scanner.index}}if(a===96)return{type:10,value:"",lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:this.scanner.index,end:this.scanner.index};if(D.Character.isIdentifierStart(a)&&a!==92){var p=this.scanner.index;for(++this.scanner.index;!this.scanner.eof();){var w=this.scanner.source.charCodeAt(this.scanner.index);if(D.Character.isIdentifierPart(w)&&w!==92)++this.scanner.index;else if(w===45)++this.scanner.index;else break}var k=this.scanner.source.slice(p,this.scanner.index);return{type:100,value:k,lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:p,end:this.scanner.index}}return this.scanner.lex()},n.prototype.nextJSXToken=function(){this.collectComments(),this.startMarker.index=this.scanner.index,this.startMarker.line=this.scanner.lineNumber,this.startMarker.column=this.scanner.index-this.scanner.lineStart;var a=this.lexJSX();return this.lastMarker.index=this.scanner.index,this.lastMarker.line=this.scanner.lineNumber,this.lastMarker.column=this.scanner.index-this.scanner.lineStart,this.config.tokens&&this.tokens.push(this.convertToken(a)),a},n.prototype.nextJSXText=function(){this.startMarker.index=this.scanner.index,this.startMarker.line=this.scanner.lineNumber,this.startMarker.column=this.scanner.index-this.scanner.lineStart;for(var a=this.scanner.index,o="";!this.scanner.eof();){var p=this.scanner.source[this.scanner.index];if(p==="{"||p==="<")break;++this.scanner.index,o+=p,D.Character.isLineTerminator(p.charCodeAt(0))&&(++this.scanner.lineNumber,p==="\r"&&this.scanner.source[this.scanner.index]===`
`&&++this.scanner.index,this.scanner.lineStart=this.scanner.index)}this.lastMarker.index=this.scanner.index,this.lastMarker.line=this.scanner.lineNumber,this.lastMarker.column=this.scanner.index-this.scanner.lineStart;var x={type:101,value:o,lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:a,end:this.scanner.index};return o.length>0&&this.config.tokens&&this.tokens.push(this.convertToken(x)),x},n.prototype.peekJSXToken=function(){var a=this.scanner.saveState();this.scanner.scanComments();var o=this.lexJSX();return this.scanner.restoreState(a),o},n.prototype.expectJSX=function(a){var o=this.nextJSXToken();(o.type!==7||o.value!==a)&&this.throwUnexpectedToken(o)},n.prototype.matchJSX=function(a){var o=this.peekJSXToken();return o.type===7&&o.value===a},n.prototype.parseJSXIdentifier=function(){var a=this.createJSXNode(),o=this.nextJSXToken();return o.type!==100&&this.throwUnexpectedToken(o),this.finalize(a,new f.JSXIdentifier(o.value))},n.prototype.parseJSXElementName=function(){var a=this.createJSXNode(),o=this.parseJSXIdentifier();if(this.matchJSX(":")){var p=o;this.expectJSX(":");var x=this.parseJSXIdentifier();o=this.finalize(a,new f.JSXNamespacedName(p,x))}else if(this.matchJSX("."))for(;this.matchJSX(".");){var S=o;this.expectJSX(".");var w=this.parseJSXIdentifier();o=this.finalize(a,new f.JSXMemberExpression(S,w))}return o},n.prototype.parseJSXAttributeName=function(){var a=this.createJSXNode(),o,p=this.parseJSXIdentifier();if(this.matchJSX(":")){var x=p;this.expectJSX(":");var S=this.parseJSXIdentifier();o=this.finalize(a,new f.JSXNamespacedName(x,S))}else o=p;return o},n.prototype.parseJSXStringLiteralAttribute=function(){var a=this.createJSXNode(),o=this.nextJSXToken();o.type!==8&&this.throwUnexpectedToken(o);var p=this.getTokenRaw(o);return this.finalize(a,new C.Literal(o.value,p))},n.prototype.parseJSXExpressionAttribute=function(){var a=this.createJSXNode();this.expectJSX("{"),this.finishJSX(),this.match("}")&&this.tolerateError("JSX attributes must only be assigned a non-empty expression");var o=this.parseAssignmentExpression();return this.reenterJSX(),this.finalize(a,new f.JSXExpressionContainer(o))},n.prototype.parseJSXAttributeValue=function(){return this.matchJSX("{")?this.parseJSXExpressionAttribute():this.matchJSX("<")?this.parseJSXElement():this.parseJSXStringLiteralAttribute()},n.prototype.parseJSXNameValueAttribute=function(){var a=this.createJSXNode(),o=this.parseJSXAttributeName(),p=null;return this.matchJSX("=")&&(this.expectJSX("="),p=this.parseJSXAttributeValue()),this.finalize(a,new f.JSXAttribute(o,p))},n.prototype.parseJSXSpreadAttribute=function(){var a=this.createJSXNode();this.expectJSX("{"),this.expectJSX("..."),this.finishJSX();var o=this.parseAssignmentExpression();return this.reenterJSX(),this.finalize(a,new f.JSXSpreadAttribute(o))},n.prototype.parseJSXAttributes=function(){for(var a=[];!this.matchJSX("/")&&!this.matchJSX(">");){var o=this.matchJSX("{")?this.parseJSXSpreadAttribute():this.parseJSXNameValueAttribute();a.push(o)}return a},n.prototype.parseJSXOpeningElement=function(){var a=this.createJSXNode();this.expectJSX("<");var o=this.parseJSXElementName(),p=this.parseJSXAttributes(),x=this.matchJSX("/");return x&&this.expectJSX("/"),this.expectJSX(">"),this.finalize(a,new f.JSXOpeningElement(o,x,p))},n.prototype.parseJSXBoundaryElement=function(){var a=this.createJSXNode();if(this.expectJSX("<"),this.matchJSX("/")){this.expectJSX("/");var o=this.parseJSXElementName();return this.expectJSX(">"),this.finalize(a,new f.JSXClosingElement(o))}var p=this.parseJSXElementName(),x=this.parseJSXAttributes(),S=this.matchJSX("/");return S&&this.expectJSX("/"),this.expectJSX(">"),this.finalize(a,new f.JSXOpeningElement(p,S,x))},n.prototype.parseJSXEmptyExpression=function(){var a=this.createJSXChildNode();return this.collectComments(),this.lastMarker.index=this.scanner.index,this.lastMarker.line=this.scanner.lineNumber,this.lastMarker.column=this.scanner.index-this.scanner.lineStart,this.finalize(a,new f.JSXEmptyExpression)},n.prototype.parseJSXExpressionContainer=function(){var a=this.createJSXNode();this.expectJSX("{");var o;return this.matchJSX("}")?(o=this.parseJSXEmptyExpression(),this.expectJSX("}")):(this.finishJSX(),o=this.parseAssignmentExpression(),this.reenterJSX()),this.finalize(a,new f.JSXExpressionContainer(o))},n.prototype.parseJSXChildren=function(){for(var a=[];!this.scanner.eof();){var o=this.createJSXChildNode(),p=this.nextJSXText();if(p.start<p.end){var x=this.getTokenRaw(p),S=this.finalize(o,new f.JSXText(p.value,x));a.push(S)}if(this.scanner.source[this.scanner.index]==="{"){var w=this.parseJSXExpressionContainer();a.push(w)}else break}return a},n.prototype.parseComplexJSXElement=function(a){for(var o=[];!this.scanner.eof();){a.children=a.children.concat(this.parseJSXChildren());var p=this.createJSXChildNode(),x=this.parseJSXBoundaryElement();if(x.type===h.JSXSyntax.JSXOpeningElement){var S=x;if(S.selfClosing){var w=this.finalize(p,new f.JSXElement(S,[],null));a.children.push(w)}else o.push(a),a={node:p,opening:S,closing:null,children:[]}}if(x.type===h.JSXSyntax.JSXClosingElement){a.closing=x;var F=m(a.opening.name),b=m(a.closing.name);if(F!==b&&this.tolerateError("Expected corresponding JSX closing tag for %0",F),o.length>0){var w=this.finalize(a.node,new f.JSXElement(a.opening,a.children,a.closing));a=o[o.length-1],a.children.push(w),o.pop()}else break}}return a},n.prototype.parseJSXElement=function(){var a=this.createJSXNode(),o=this.parseJSXOpeningElement(),p=[],x=null;if(!o.selfClosing){var S=this.parseComplexJSXElement({node:a,opening:o,closing:x,children:p});p=S.children,x=S.closing}return this.finalize(a,new f.JSXElement(o,p,x))},n.prototype.parseJSXRoot=function(){this.config.tokens&&this.tokens.pop(),this.startJSX();var a=this.parseJSXElement();return this.finishJSX(),a},n.prototype.isStartOfExpression=function(){return t.prototype.isStartOfExpression.call(this)||this.match("<")},n}(y.Parser);r.JSXParser=d},function(s,r){"use strict";Object.defineProperty(r,"__esModule",{value:!0});var l={NonAsciiIdentifierStart:/[\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0-\u08B4\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2118-\u211D\u2124\u2126\u2128\u212A-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309B-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FD5\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AD\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDE80-\uDE9C\uDEA0-\uDED0\uDF00-\uDF1F\uDF30-\uDF4A\uDF50-\uDF75\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00\uDE10-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE4\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC03-\uDC37\uDC83-\uDCAF\uDCD0-\uDCE8\uDD03-\uDD26\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE2B\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE80-\uDEAA\uDF00-\uDF19]|\uD806[\uDCA0-\uDCDF\uDCFF\uDEC0-\uDEF8]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50\uDF93-\uDF9F]|\uD82C[\uDC00\uDC01]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB]|\uD83A[\uDC00-\uDCC4]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1]|\uD87E[\uDC00-\uDE1D]/,NonAsciiIdentifierPart:/[\xAA\xB5\xB7\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0300-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u0483-\u0487\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u05D0-\u05EA\u05F0-\u05F2\u0610-\u061A\u0620-\u0669\u066E-\u06D3\u06D5-\u06DC\u06DF-\u06E8\u06EA-\u06FC\u06FF\u0710-\u074A\u074D-\u07B1\u07C0-\u07F5\u07FA\u0800-\u082D\u0840-\u085B\u08A0-\u08B4\u08E3-\u0963\u0966-\u096F\u0971-\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BC-\u09C4\u09C7\u09C8\u09CB-\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E3\u09E6-\u09F1\u0A01-\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A59-\u0A5C\u0A5E\u0A66-\u0A75\u0A81-\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABC-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AD0\u0AE0-\u0AE3\u0AE6-\u0AEF\u0AF9\u0B01-\u0B03\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3C-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B5C\u0B5D\u0B5F-\u0B63\u0B66-\u0B6F\u0B71\u0B82\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD0\u0BD7\u0BE6-\u0BEF\u0C00-\u0C03\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C58-\u0C5A\u0C60-\u0C63\u0C66-\u0C6F\u0C81-\u0C83\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBC-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CDE\u0CE0-\u0CE3\u0CE6-\u0CEF\u0CF1\u0CF2\u0D01-\u0D03\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D-\u0D44\u0D46-\u0D48\u0D4A-\u0D4E\u0D57\u0D5F-\u0D63\u0D66-\u0D6F\u0D7A-\u0D7F\u0D82\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E01-\u0E3A\u0E40-\u0E4E\u0E50-\u0E59\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB9\u0EBB-\u0EBD\u0EC0-\u0EC4\u0EC6\u0EC8-\u0ECD\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E-\u0F47\u0F49-\u0F6C\u0F71-\u0F84\u0F86-\u0F97\u0F99-\u0FBC\u0FC6\u1000-\u1049\u1050-\u109D\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u135D-\u135F\u1369-\u1371\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1714\u1720-\u1734\u1740-\u1753\u1760-\u176C\u176E-\u1770\u1772\u1773\u1780-\u17D3\u17D7\u17DC\u17DD\u17E0-\u17E9\u180B-\u180D\u1810-\u1819\u1820-\u1877\u1880-\u18AA\u18B0-\u18F5\u1900-\u191E\u1920-\u192B\u1930-\u193B\u1946-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19DA\u1A00-\u1A1B\u1A20-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AA7\u1AB0-\u1ABD\u1B00-\u1B4B\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1BF3\u1C00-\u1C37\u1C40-\u1C49\u1C4D-\u1C7D\u1CD0-\u1CD2\u1CD4-\u1CF6\u1CF8\u1CF9\u1D00-\u1DF5\u1DFC-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u200C\u200D\u203F\u2040\u2054\u2071\u207F\u2090-\u209C\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2102\u2107\u210A-\u2113\u2115\u2118-\u211D\u2124\u2126\u2128\u212A-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D7F-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2DE0-\u2DFF\u3005-\u3007\u3021-\u302F\u3031-\u3035\u3038-\u303C\u3041-\u3096\u3099-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FD5\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA62B\uA640-\uA66F\uA674-\uA67D\uA67F-\uA6F1\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AD\uA7B0-\uA7B7\uA7F7-\uA827\uA840-\uA873\uA880-\uA8C4\uA8D0-\uA8D9\uA8E0-\uA8F7\uA8FB\uA8FD\uA900-\uA92D\uA930-\uA953\uA960-\uA97C\uA980-\uA9C0\uA9CF-\uA9D9\uA9E0-\uA9FE\uAA00-\uAA36\uAA40-\uAA4D\uAA50-\uAA59\uAA60-\uAA76\uAA7A-\uAAC2\uAADB-\uAADD\uAAE0-\uAAEF\uAAF2-\uAAF6\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABEA\uABEC\uABED\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE00-\uFE0F\uFE20-\uFE2F\uFE33\uFE34\uFE4D-\uFE4F\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\uFF21-\uFF3A\uFF3F\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDDFD\uDE80-\uDE9C\uDEA0-\uDED0\uDEE0\uDF00-\uDF1F\uDF30-\uDF4A\uDF50-\uDF7A\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDCA0-\uDCA9\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00-\uDE03\uDE05\uDE06\uDE0C-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE38-\uDE3A\uDE3F\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE6\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC00-\uDC46\uDC66-\uDC6F\uDC7F-\uDCBA\uDCD0-\uDCE8\uDCF0-\uDCF9\uDD00-\uDD34\uDD36-\uDD3F\uDD50-\uDD73\uDD76\uDD80-\uDDC4\uDDCA-\uDDCC\uDDD0-\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE37\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEEA\uDEF0-\uDEF9\uDF00-\uDF03\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3C-\uDF44\uDF47\uDF48\uDF4B-\uDF4D\uDF50\uDF57\uDF5D-\uDF63\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC80-\uDCC5\uDCC7\uDCD0-\uDCD9\uDD80-\uDDB5\uDDB8-\uDDC0\uDDD8-\uDDDD\uDE00-\uDE40\uDE44\uDE50-\uDE59\uDE80-\uDEB7\uDEC0-\uDEC9\uDF00-\uDF19\uDF1D-\uDF2B\uDF30-\uDF39]|\uD806[\uDCA0-\uDCE9\uDCFF\uDEC0-\uDEF8]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDE60-\uDE69\uDED0-\uDEED\uDEF0-\uDEF4\uDF00-\uDF36\uDF40-\uDF43\uDF50-\uDF59\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50-\uDF7E\uDF8F-\uDF9F]|\uD82C[\uDC00\uDC01]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99\uDC9D\uDC9E]|\uD834[\uDD65-\uDD69\uDD6D-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB\uDFCE-\uDFFF]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD83A[\uDC00-\uDCC4\uDCD0-\uDCD6]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1]|\uD87E[\uDC00-\uDE1D]|\uDB40[\uDD00-\uDDEF]/};r.Character={fromCodePoint:function(u){return u<65536?String.fromCharCode(u):String.fromCharCode(55296+(u-65536>>10))+String.fromCharCode(56320+(u-65536&1023))},isWhiteSpace:function(u){return u===32||u===9||u===11||u===12||u===160||u>=5760&&[5760,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8239,8287,12288,65279].indexOf(u)>=0},isLineTerminator:function(u){return u===10||u===13||u===8232||u===8233},isIdentifierStart:function(u){return u===36||u===95||u>=65&&u<=90||u>=97&&u<=122||u===92||u>=128&&l.NonAsciiIdentifierStart.test(r.Character.fromCodePoint(u))},isIdentifierPart:function(u){return u===36||u===95||u>=65&&u<=90||u>=97&&u<=122||u>=48&&u<=57||u===92||u>=128&&l.NonAsciiIdentifierPart.test(r.Character.fromCodePoint(u))},isDecimalDigit:function(u){return u>=48&&u<=57},isHexDigit:function(u){return u>=48&&u<=57||u>=65&&u<=70||u>=97&&u<=102},isOctalDigit:function(u){return u>=48&&u<=55}}},function(s,r,l){"use strict";Object.defineProperty(r,"__esModule",{value:!0});var u=l(6),D=function(){function a(o){this.type=u.JSXSyntax.JSXClosingElement,this.name=o}return a}();r.JSXClosingElement=D;var f=function(){function a(o,p,x){this.type=u.JSXSyntax.JSXElement,this.openingElement=o,this.children=p,this.closingElement=x}return a}();r.JSXElement=f;var h=function(){function a(){this.type=u.JSXSyntax.JSXEmptyExpression}return a}();r.JSXEmptyExpression=h;var C=function(){function a(o){this.type=u.JSXSyntax.JSXExpressionContainer,this.expression=o}return a}();r.JSXExpressionContainer=C;var y=function(){function a(o){this.type=u.JSXSyntax.JSXIdentifier,this.name=o}return a}();r.JSXIdentifier=y;var v=function(){function a(o,p){this.type=u.JSXSyntax.JSXMemberExpression,this.object=o,this.property=p}return a}();r.JSXMemberExpression=v;var c=function(){function a(o,p){this.type=u.JSXSyntax.JSXAttribute,this.name=o,this.value=p}return a}();r.JSXAttribute=c;var m=function(){function a(o,p){this.type=u.JSXSyntax.JSXNamespacedName,this.namespace=o,this.name=p}return a}();r.JSXNamespacedName=m;var d=function(){function a(o,p,x){this.type=u.JSXSyntax.JSXOpeningElement,this.name=o,this.selfClosing=p,this.attributes=x}return a}();r.JSXOpeningElement=d;var t=function(){function a(o){this.type=u.JSXSyntax.JSXSpreadAttribute,this.argument=o}return a}();r.JSXSpreadAttribute=t;var n=function(){function a(o,p){this.type=u.JSXSyntax.JSXText,this.value=o,this.raw=p}return a}();r.JSXText=n},function(s,r){"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.JSXSyntax={JSXAttribute:"JSXAttribute",JSXClosingElement:"JSXClosingElement",JSXElement:"JSXElement",JSXEmptyExpression:"JSXEmptyExpression",JSXExpressionContainer:"JSXExpressionContainer",JSXIdentifier:"JSXIdentifier",JSXMemberExpression:"JSXMemberExpression",JSXNamespacedName:"JSXNamespacedName",JSXOpeningElement:"JSXOpeningElement",JSXSpreadAttribute:"JSXSpreadAttribute",JSXText:"JSXText"}},function(s,r,l){"use strict";Object.defineProperty(r,"__esModule",{value:!0});var u=l(2),D=function(){function g(E){this.type=u.Syntax.ArrayExpression,this.elements=E}return g}();r.ArrayExpression=D;var f=function(){function g(E){this.type=u.Syntax.ArrayPattern,this.elements=E}return g}();r.ArrayPattern=f;var h=function(){function g(E,A,T){this.type=u.Syntax.ArrowFunctionExpression,this.id=null,this.params=E,this.body=A,this.generator=!1,this.expression=T,this.async=!1}return g}();r.ArrowFunctionExpression=h;var C=function(){function g(E,A,T){this.type=u.Syntax.AssignmentExpression,this.operator=E,this.left=A,this.right=T}return g}();r.AssignmentExpression=C;var y=function(){function g(E,A){this.type=u.Syntax.AssignmentPattern,this.left=E,this.right=A}return g}();r.AssignmentPattern=y;var v=function(){function g(E,A,T){this.type=u.Syntax.ArrowFunctionExpression,this.id=null,this.params=E,this.body=A,this.generator=!1,this.expression=T,this.async=!0}return g}();r.AsyncArrowFunctionExpression=v;var c=function(){function g(E,A,T){this.type=u.Syntax.FunctionDeclaration,this.id=E,this.params=A,this.body=T,this.generator=!1,this.expression=!1,this.async=!0}return g}();r.AsyncFunctionDeclaration=c;var m=function(){function g(E,A,T){this.type=u.Syntax.FunctionExpression,this.id=E,this.params=A,this.body=T,this.generator=!1,this.expression=!1,this.async=!0}return g}();r.AsyncFunctionExpression=m;var d=function(){function g(E){this.type=u.Syntax.AwaitExpression,this.argument=E}return g}();r.AwaitExpression=d;var t=function(){function g(E,A,T){var R=E==="||"||E==="&&";this.type=R?u.Syntax.LogicalExpression:u.Syntax.BinaryExpression,this.operator=E,this.left=A,this.right=T}return g}();r.BinaryExpression=t;var n=function(){function g(E){this.type=u.Syntax.BlockStatement,this.body=E}return g}();r.BlockStatement=n;var a=function(){function g(E){this.type=u.Syntax.BreakStatement,this.label=E}return g}();r.BreakStatement=a;var o=function(){function g(E,A){this.type=u.Syntax.CallExpression,this.callee=E,this.arguments=A}return g}();r.CallExpression=o;var p=function(){function g(E,A){this.type=u.Syntax.CatchClause,this.param=E,this.body=A}return g}();r.CatchClause=p;var x=function(){function g(E){this.type=u.Syntax.ClassBody,this.body=E}return g}();r.ClassBody=x;var S=function(){function g(E,A,T){this.type=u.Syntax.ClassDeclaration,this.id=E,this.superClass=A,this.body=T}return g}();r.ClassDeclaration=S;var w=function(){function g(E,A,T){this.type=u.Syntax.ClassExpression,this.id=E,this.superClass=A,this.body=T}return g}();r.ClassExpression=w;var F=function(){function g(E,A){this.type=u.Syntax.MemberExpression,this.computed=!0,this.object=E,this.property=A}return g}();r.ComputedMemberExpression=F;var b=function(){function g(E,A,T){this.type=u.Syntax.ConditionalExpression,this.test=E,this.consequent=A,this.alternate=T}return g}();r.ConditionalExpression=b;var k=function(){function g(E){this.type=u.Syntax.ContinueStatement,this.label=E}return g}();r.ContinueStatement=k;var B=function(){function g(){this.type=u.Syntax.DebuggerStatement}return g}();r.DebuggerStatement=B;var N=function(){function g(E,A){this.type=u.Syntax.ExpressionStatement,this.expression=E,this.directive=A}return g}();r.Directive=N;var U=function(){function g(E,A){this.type=u.Syntax.DoWhileStatement,this.body=E,this.test=A}return g}();r.DoWhileStatement=U;var X=function(){function g(){this.type=u.Syntax.EmptyStatement}return g}();r.EmptyStatement=X;var K=function(){function g(E){this.type=u.Syntax.ExportAllDeclaration,this.source=E}return g}();r.ExportAllDeclaration=K;var ge=function(){function g(E){this.type=u.Syntax.ExportDefaultDeclaration,this.declaration=E}return g}();r.ExportDefaultDeclaration=ge;var di=function(){function g(E,A,T){this.type=u.Syntax.ExportNamedDeclaration,this.declaration=E,this.specifiers=A,this.source=T}return g}();r.ExportNamedDeclaration=di;var pi=function(){function g(E,A){this.type=u.Syntax.ExportSpecifier,this.exported=A,this.local=E}return g}();r.ExportSpecifier=pi;var fi=function(){function g(E){this.type=u.Syntax.ExpressionStatement,this.expression=E}return g}();r.ExpressionStatement=fi;var mi=function(){function g(E,A,T){this.type=u.Syntax.ForInStatement,this.left=E,this.right=A,this.body=T,this.each=!1}return g}();r.ForInStatement=mi;var Di=function(){function g(E,A,T){this.type=u.Syntax.ForOfStatement,this.left=E,this.right=A,this.body=T}return g}();r.ForOfStatement=Di;var xi=function(){function g(E,A,T,R){this.type=u.Syntax.ForStatement,this.init=E,this.test=A,this.update=T,this.body=R}return g}();r.ForStatement=xi;var yi=function(){function g(E,A,T,R){this.type=u.Syntax.FunctionDeclaration,this.id=E,this.params=A,this.body=T,this.generator=R,this.expression=!1,this.async=!1}return g}();r.FunctionDeclaration=yi;var vi=function(){function g(E,A,T,R){this.type=u.Syntax.FunctionExpression,this.id=E,this.params=A,this.body=T,this.generator=R,this.expression=!1,this.async=!1}return g}();r.FunctionExpression=vi;var gi=function(){function g(E){this.type=u.Syntax.Identifier,this.name=E}return g}();r.Identifier=gi;var Ei=function(){function g(E,A,T){this.type=u.Syntax.IfStatement,this.test=E,this.consequent=A,this.alternate=T}return g}();r.IfStatement=Ei;var Ci=function(){function g(E,A){this.type=u.Syntax.ImportDeclaration,this.specifiers=E,this.source=A}return g}();r.ImportDeclaration=Ci;var Si=function(){function g(E){this.type=u.Syntax.ImportDefaultSpecifier,this.local=E}return g}();r.ImportDefaultSpecifier=Si;var wi=function(){function g(E){this.type=u.Syntax.ImportNamespaceSpecifier,this.local=E}return g}();r.ImportNamespaceSpecifier=wi;var Ai=function(){function g(E,A){this.type=u.Syntax.ImportSpecifier,this.local=E,this.imported=A}return g}();r.ImportSpecifier=Ai;var Fi=function(){function g(E,A){this.type=u.Syntax.LabeledStatement,this.label=E,this.body=A}return g}();r.LabeledStatement=Fi;var bi=function(){function g(E,A){this.type=u.Syntax.Literal,this.value=E,this.raw=A}return g}();r.Literal=bi;var ki=function(){function g(E,A){this.type=u.Syntax.MetaProperty,this.meta=E,this.property=A}return g}();r.MetaProperty=ki;var Ti=function(){function g(E,A,T,R,Ee){this.type=u.Syntax.MethodDefinition,this.key=E,this.computed=A,this.value=T,this.kind=R,this.static=Ee}return g}();r.MethodDefinition=Ti;var Bi=function(){function g(E){this.type=u.Syntax.Program,this.body=E,this.sourceType="module"}return g}();r.Module=Bi;var Mi=function(){function g(E,A){this.type=u.Syntax.NewExpression,this.callee=E,this.arguments=A}return g}();r.NewExpression=Mi;var Ni=function(){function g(E){this.type=u.Syntax.ObjectExpression,this.properties=E}return g}();r.ObjectExpression=Ni;var Ii=function(){function g(E){this.type=u.Syntax.ObjectPattern,this.properties=E}return g}();r.ObjectPattern=Ii;var Pi=function(){function g(E,A,T,R,Ee,rr){this.type=u.Syntax.Property,this.key=A,this.computed=T,this.value=R,this.kind=E,this.method=Ee,this.shorthand=rr}return g}();r.Property=Pi;var Li=function(){function g(E,A,T,R){this.type=u.Syntax.Literal,this.value=E,this.raw=A,this.regex={pattern:T,flags:R}}return g}();r.RegexLiteral=Li;var Oi=function(){function g(E){this.type=u.Syntax.RestElement,this.argument=E}return g}();r.RestElement=Oi;var Ui=function(){function g(E){this.type=u.Syntax.ReturnStatement,this.argument=E}return g}();r.ReturnStatement=Ui;var Ji=function(){function g(E){this.type=u.Syntax.Program,this.body=E,this.sourceType="script"}return g}();r.Script=Ji;var Xi=function(){function g(E){this.type=u.Syntax.SequenceExpression,this.expressions=E}return g}();r.SequenceExpression=Xi;var Ri=function(){function g(E){this.type=u.Syntax.SpreadElement,this.argument=E}return g}();r.SpreadElement=Ri;var zi=function(){function g(E,A){this.type=u.Syntax.MemberExpression,this.computed=!1,this.object=E,this.property=A}return g}();r.StaticMemberExpression=zi;var Wi=function(){function g(){this.type=u.Syntax.Super}return g}();r.Super=Wi;var Yi=function(){function g(E,A){this.type=u.Syntax.SwitchCase,this.test=E,this.consequent=A}return g}();r.SwitchCase=Yi;var ji=function(){function g(E,A){this.type=u.Syntax.SwitchStatement,this.discriminant=E,this.cases=A}return g}();r.SwitchStatement=ji;var Hi=function(){function g(E,A){this.type=u.Syntax.TaggedTemplateExpression,this.tag=E,this.quasi=A}return g}();r.TaggedTemplateExpression=Hi;var Gi=function(){function g(E,A){this.type=u.Syntax.TemplateElement,this.value=E,this.tail=A}return g}();r.TemplateElement=Gi;var Ki=function(){function g(E,A){this.type=u.Syntax.TemplateLiteral,this.quasis=E,this.expressions=A}return g}();r.TemplateLiteral=Ki;var $i=function(){function g(){this.type=u.Syntax.ThisExpression}return g}();r.ThisExpression=$i;var Vi=function(){function g(E){this.type=u.Syntax.ThrowStatement,this.argument=E}return g}();r.ThrowStatement=Vi;var _i=function(){function g(E,A,T){this.type=u.Syntax.TryStatement,this.block=E,this.handler=A,this.finalizer=T}return g}();r.TryStatement=_i;var qi=function(){function g(E,A){this.type=u.Syntax.UnaryExpression,this.operator=E,this.argument=A,this.prefix=!0}return g}();r.UnaryExpression=qi;var Qi=function(){function g(E,A,T){this.type=u.Syntax.UpdateExpression,this.operator=E,this.argument=A,this.prefix=T}return g}();r.UpdateExpression=Qi;var Zi=function(){function g(E,A){this.type=u.Syntax.VariableDeclaration,this.declarations=E,this.kind=A}return g}();r.VariableDeclaration=Zi;var er=function(){function g(E,A){this.type=u.Syntax.VariableDeclarator,this.id=E,this.init=A}return g}();r.VariableDeclarator=er;var tr=function(){function g(E,A){this.type=u.Syntax.WhileStatement,this.test=E,this.body=A}return g}();r.WhileStatement=tr;var nr=function(){function g(E,A){this.type=u.Syntax.WithStatement,this.object=E,this.body=A}return g}();r.WithStatement=nr;var ir=function(){function g(E,A){this.type=u.Syntax.YieldExpression,this.argument=E,this.delegate=A}return g}();r.YieldExpression=ir},function(s,r,l){"use strict";Object.defineProperty(r,"__esModule",{value:!0});var u=l(9),D=l(10),f=l(11),h=l(7),C=l(12),y=l(2),v=l(13),c="ArrowParameterPlaceHolder",m=function(){function d(t,n,a){n===void 0&&(n={}),this.config={range:typeof n.range=="boolean"&&n.range,loc:typeof n.loc=="boolean"&&n.loc,source:null,tokens:typeof n.tokens=="boolean"&&n.tokens,comment:typeof n.comment=="boolean"&&n.comment,tolerant:typeof n.tolerant=="boolean"&&n.tolerant},this.config.loc&&n.source&&n.source!==null&&(this.config.source=String(n.source)),this.delegate=a,this.errorHandler=new D.ErrorHandler,this.errorHandler.tolerant=this.config.tolerant,this.scanner=new C.Scanner(t,this.errorHandler),this.scanner.trackComment=this.config.comment,this.operatorPrecedence={")":0,";":0,",":0,"=":0,"]":0,"||":1,"&&":2,"|":3,"^":4,"&":5,"==":6,"!=":6,"===":6,"!==":6,"<":7,">":7,"<=":7,">=":7,"<<":8,">>":8,">>>":8,"+":9,"-":9,"*":11,"/":11,"%":11},this.lookahead={type:2,value:"",lineNumber:this.scanner.lineNumber,lineStart:0,start:0,end:0},this.hasLineTerminator=!1,this.context={isModule:!1,await:!1,allowIn:!0,allowStrictDirective:!0,allowYield:!0,firstCoverInitializedNameError:null,isAssignmentTarget:!1,isBindingElement:!1,inFunctionBody:!1,inIteration:!1,inSwitch:!1,labelSet:{},strict:!1},this.tokens=[],this.startMarker={index:0,line:this.scanner.lineNumber,column:0},this.lastMarker={index:0,line:this.scanner.lineNumber,column:0},this.nextToken(),this.lastMarker={index:this.scanner.index,line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart}}return d.prototype.throwError=function(t){for(var n=[],a=1;a<arguments.length;a++)n[a-1]=arguments[a];var o=Array.prototype.slice.call(arguments,1),p=t.replace(/%(\d)/g,function(F,b){return u.assert(b<o.length,"Message reference must be in range"),o[b]}),x=this.lastMarker.index,S=this.lastMarker.line,w=this.lastMarker.column+1;throw this.errorHandler.createError(x,S,w,p)},d.prototype.tolerateError=function(t){for(var n=[],a=1;a<arguments.length;a++)n[a-1]=arguments[a];var o=Array.prototype.slice.call(arguments,1),p=t.replace(/%(\d)/g,function(F,b){return u.assert(b<o.length,"Message reference must be in range"),o[b]}),x=this.lastMarker.index,S=this.scanner.lineNumber,w=this.lastMarker.column+1;this.errorHandler.tolerateError(x,S,w,p)},d.prototype.unexpectedTokenError=function(t,n){var a=n||f.Messages.UnexpectedToken,o;if(t?(n||(a=t.type===2?f.Messages.UnexpectedEOS:t.type===3?f.Messages.UnexpectedIdentifier:t.type===6?f.Messages.UnexpectedNumber:t.type===8?f.Messages.UnexpectedString:t.type===10?f.Messages.UnexpectedTemplate:f.Messages.UnexpectedToken,t.type===4&&(this.scanner.isFutureReservedWord(t.value)?a=f.Messages.UnexpectedReserved:this.context.strict&&this.scanner.isStrictModeReservedWord(t.value)&&(a=f.Messages.StrictReservedWord))),o=t.value):o="ILLEGAL",a=a.replace("%0",o),t&&typeof t.lineNumber=="number"){var p=t.start,x=t.lineNumber,S=this.lastMarker.index-this.lastMarker.column,w=t.start-S+1;return this.errorHandler.createError(p,x,w,a)}else{var p=this.lastMarker.index,x=this.lastMarker.line,w=this.lastMarker.column+1;return this.errorHandler.createError(p,x,w,a)}},d.prototype.throwUnexpectedToken=function(t,n){throw this.unexpectedTokenError(t,n)},d.prototype.tolerateUnexpectedToken=function(t,n){this.errorHandler.tolerate(this.unexpectedTokenError(t,n))},d.prototype.collectComments=function(){if(!this.config.comment)this.scanner.scanComments();else{var t=this.scanner.scanComments();if(t.length>0&&this.delegate)for(var n=0;n<t.length;++n){var a=t[n],o=void 0;o={type:a.multiLine?"BlockComment":"LineComment",value:this.scanner.source.slice(a.slice[0],a.slice[1])},this.config.range&&(o.range=a.range),this.config.loc&&(o.loc=a.loc);var p={start:{line:a.loc.start.line,column:a.loc.start.column,offset:a.range[0]},end:{line:a.loc.end.line,column:a.loc.end.column,offset:a.range[1]}};this.delegate(o,p)}}},d.prototype.getTokenRaw=function(t){return this.scanner.source.slice(t.start,t.end)},d.prototype.convertToken=function(t){var n={type:v.TokenName[t.type],value:this.getTokenRaw(t)};if(this.config.range&&(n.range=[t.start,t.end]),this.config.loc&&(n.loc={start:{line:this.startMarker.line,column:this.startMarker.column},end:{line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart}}),t.type===9){var a=t.pattern,o=t.flags;n.regex={pattern:a,flags:o}}return n},d.prototype.nextToken=function(){var t=this.lookahead;this.lastMarker.index=this.scanner.index,this.lastMarker.line=this.scanner.lineNumber,this.lastMarker.column=this.scanner.index-this.scanner.lineStart,this.collectComments(),this.scanner.index!==this.startMarker.index&&(this.startMarker.index=this.scanner.index,this.startMarker.line=this.scanner.lineNumber,this.startMarker.column=this.scanner.index-this.scanner.lineStart);var n=this.scanner.lex();return this.hasLineTerminator=t.lineNumber!==n.lineNumber,n&&this.context.strict&&n.type===3&&this.scanner.isStrictModeReservedWord(n.value)&&(n.type=4),this.lookahead=n,this.config.tokens&&n.type!==2&&this.tokens.push(this.convertToken(n)),t},d.prototype.nextRegexToken=function(){this.collectComments();var t=this.scanner.scanRegExp();return this.config.tokens&&(this.tokens.pop(),this.tokens.push(this.convertToken(t))),this.lookahead=t,this.nextToken(),t},d.prototype.createNode=function(){return{index:this.startMarker.index,line:this.startMarker.line,column:this.startMarker.column}},d.prototype.startNode=function(t,n){n===void 0&&(n=0);var a=t.start-t.lineStart,o=t.lineNumber;return a<0&&(a+=n,o--),{index:t.start,line:o,column:a}},d.prototype.finalize=function(t,n){if(this.config.range&&(n.range=[t.index,this.lastMarker.index]),this.config.loc&&(n.loc={start:{line:t.line,column:t.column},end:{line:this.lastMarker.line,column:this.lastMarker.column}},this.config.source&&(n.loc.source=this.config.source)),this.delegate){var a={start:{line:t.line,column:t.column,offset:t.index},end:{line:this.lastMarker.line,column:this.lastMarker.column,offset:this.lastMarker.index}};this.delegate(n,a)}return n},d.prototype.expect=function(t){var n=this.nextToken();(n.type!==7||n.value!==t)&&this.throwUnexpectedToken(n)},d.prototype.expectCommaSeparator=function(){if(this.config.tolerant){var t=this.lookahead;t.type===7&&t.value===","?this.nextToken():t.type===7&&t.value===";"?(this.nextToken(),this.tolerateUnexpectedToken(t)):this.tolerateUnexpectedToken(t,f.Messages.UnexpectedToken)}else this.expect(",")},d.prototype.expectKeyword=function(t){var n=this.nextToken();(n.type!==4||n.value!==t)&&this.throwUnexpectedToken(n)},d.prototype.match=function(t){return this.lookahead.type===7&&this.lookahead.value===t},d.prototype.matchKeyword=function(t){return this.lookahead.type===4&&this.lookahead.value===t},d.prototype.matchContextualKeyword=function(t){return this.lookahead.type===3&&this.lookahead.value===t},d.prototype.matchAssign=function(){if(this.lookahead.type!==7)return!1;var t=this.lookahead.value;return t==="="||t==="*="||t==="**="||t==="/="||t==="%="||t==="+="||t==="-="||t==="<<="||t===">>="||t===">>>="||t==="&="||t==="^="||t==="|="},d.prototype.isolateCoverGrammar=function(t){var n=this.context.isBindingElement,a=this.context.isAssignmentTarget,o=this.context.firstCoverInitializedNameError;this.context.isBindingElement=!0,this.context.isAssignmentTarget=!0,this.context.firstCoverInitializedNameError=null;var p=t.call(this);return this.context.firstCoverInitializedNameError!==null&&this.throwUnexpectedToken(this.context.firstCoverInitializedNameError),this.context.isBindingElement=n,this.context.isAssignmentTarget=a,this.context.firstCoverInitializedNameError=o,p},d.prototype.inheritCoverGrammar=function(t){var n=this.context.isBindingElement,a=this.context.isAssignmentTarget,o=this.context.firstCoverInitializedNameError;this.context.isBindingElement=!0,this.context.isAssignmentTarget=!0,this.context.firstCoverInitializedNameError=null;var p=t.call(this);return this.context.isBindingElement=this.context.isBindingElement&&n,this.context.isAssignmentTarget=this.context.isAssignmentTarget&&a,this.context.firstCoverInitializedNameError=o||this.context.firstCoverInitializedNameError,p},d.prototype.consumeSemicolon=function(){this.match(";")?this.nextToken():this.hasLineTerminator||(this.lookahead.type!==2&&!this.match("}")&&this.throwUnexpectedToken(this.lookahead),this.lastMarker.index=this.startMarker.index,this.lastMarker.line=this.startMarker.line,this.lastMarker.column=this.startMarker.column)},d.prototype.parsePrimaryExpression=function(){var t=this.createNode(),n,a,o;switch(this.lookahead.type){case 3:(this.context.isModule||this.context.await)&&this.lookahead.value==="await"&&this.tolerateUnexpectedToken(this.lookahead),n=this.matchAsyncFunction()?this.parseFunctionExpression():this.finalize(t,new h.Identifier(this.nextToken().value));break;case 6:case 8:this.context.strict&&this.lookahead.octal&&this.tolerateUnexpectedToken(this.lookahead,f.Messages.StrictOctalLiteral),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,a=this.nextToken(),o=this.getTokenRaw(a),n=this.finalize(t,new h.Literal(a.value,o));break;case 1:this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,a=this.nextToken(),o=this.getTokenRaw(a),n=this.finalize(t,new h.Literal(a.value==="true",o));break;case 5:this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,a=this.nextToken(),o=this.getTokenRaw(a),n=this.finalize(t,new h.Literal(null,o));break;case 10:n=this.parseTemplateLiteral();break;case 7:switch(this.lookahead.value){case"(":this.context.isBindingElement=!1,n=this.inheritCoverGrammar(this.parseGroupExpression);break;case"[":n=this.inheritCoverGrammar(this.parseArrayInitializer);break;case"{":n=this.inheritCoverGrammar(this.parseObjectInitializer);break;case"/":case"/=":this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,this.scanner.index=this.startMarker.index,a=this.nextRegexToken(),o=this.getTokenRaw(a),n=this.finalize(t,new h.RegexLiteral(a.regex,o,a.pattern,a.flags));break;default:n=this.throwUnexpectedToken(this.nextToken())}break;case 4:!this.context.strict&&this.context.allowYield&&this.matchKeyword("yield")?n=this.parseIdentifierName():!this.context.strict&&this.matchKeyword("let")?n=this.finalize(t,new h.Identifier(this.nextToken().value)):(this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,this.matchKeyword("function")?n=this.parseFunctionExpression():this.matchKeyword("this")?(this.nextToken(),n=this.finalize(t,new h.ThisExpression)):this.matchKeyword("class")?n=this.parseClassExpression():n=this.throwUnexpectedToken(this.nextToken()));break;default:n=this.throwUnexpectedToken(this.nextToken())}return n},d.prototype.parseSpreadElement=function(){var t=this.createNode();this.expect("...");var n=this.inheritCoverGrammar(this.parseAssignmentExpression);return this.finalize(t,new h.SpreadElement(n))},d.prototype.parseArrayInitializer=function(){var t=this.createNode(),n=[];for(this.expect("[");!this.match("]");)if(this.match(","))this.nextToken(),n.push(null);else if(this.match("...")){var a=this.parseSpreadElement();this.match("]")||(this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,this.expect(",")),n.push(a)}else n.push(this.inheritCoverGrammar(this.parseAssignmentExpression)),this.match("]")||this.expect(",");return this.expect("]"),this.finalize(t,new h.ArrayExpression(n))},d.prototype.parsePropertyMethod=function(t){this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1;var n=this.context.strict,a=this.context.allowStrictDirective;this.context.allowStrictDirective=t.simple;var o=this.isolateCoverGrammar(this.parseFunctionSourceElements);return this.context.strict&&t.firstRestricted&&this.tolerateUnexpectedToken(t.firstRestricted,t.message),this.context.strict&&t.stricted&&this.tolerateUnexpectedToken(t.stricted,t.message),this.context.strict=n,this.context.allowStrictDirective=a,o},d.prototype.parsePropertyMethodFunction=function(){var t=!1,n=this.createNode(),a=this.context.allowYield;this.context.allowYield=!0;var o=this.parseFormalParameters(),p=this.parsePropertyMethod(o);return this.context.allowYield=a,this.finalize(n,new h.FunctionExpression(null,o.params,p,t))},d.prototype.parsePropertyMethodAsyncFunction=function(){var t=this.createNode(),n=this.context.allowYield,a=this.context.await;this.context.allowYield=!1,this.context.await=!0;var o=this.parseFormalParameters(),p=this.parsePropertyMethod(o);return this.context.allowYield=n,this.context.await=a,this.finalize(t,new h.AsyncFunctionExpression(null,o.params,p))},d.prototype.parseObjectPropertyKey=function(){var t=this.createNode(),n=this.nextToken(),a;switch(n.type){case 8:case 6:this.context.strict&&n.octal&&this.tolerateUnexpectedToken(n,f.Messages.StrictOctalLiteral);var o=this.getTokenRaw(n);a=this.finalize(t,new h.Literal(n.value,o));break;case 3:case 1:case 5:case 4:a=this.finalize(t,new h.Identifier(n.value));break;case 7:n.value==="["?(a=this.isolateCoverGrammar(this.parseAssignmentExpression),this.expect("]")):a=this.throwUnexpectedToken(n);break;default:a=this.throwUnexpectedToken(n)}return a},d.prototype.isPropertyKey=function(t,n){return t.type===y.Syntax.Identifier&&t.name===n||t.type===y.Syntax.Literal&&t.value===n},d.prototype.parseObjectProperty=function(t){var n=this.createNode(),a=this.lookahead,o,p=null,x=null,S=!1,w=!1,F=!1,b=!1;if(a.type===3){var k=a.value;this.nextToken(),S=this.match("["),b=!this.hasLineTerminator&&k==="async"&&!this.match(":")&&!this.match("(")&&!this.match("*")&&!this.match(","),p=b?this.parseObjectPropertyKey():this.finalize(n,new h.Identifier(k))}else this.match("*")?this.nextToken():(S=this.match("["),p=this.parseObjectPropertyKey());var B=this.qualifiedPropertyName(this.lookahead);if(a.type===3&&!b&&a.value==="get"&&B)o="get",S=this.match("["),p=this.parseObjectPropertyKey(),this.context.allowYield=!1,x=this.parseGetterMethod();else if(a.type===3&&!b&&a.value==="set"&&B)o="set",S=this.match("["),p=this.parseObjectPropertyKey(),x=this.parseSetterMethod();else if(a.type===7&&a.value==="*"&&B)o="init",S=this.match("["),p=this.parseObjectPropertyKey(),x=this.parseGeneratorMethod(),w=!0;else if(p||this.throwUnexpectedToken(this.lookahead),o="init",this.match(":")&&!b)!S&&this.isPropertyKey(p,"__proto__")&&(t.value&&this.tolerateError(f.Messages.DuplicateProtoProperty),t.value=!0),this.nextToken(),x=this.inheritCoverGrammar(this.parseAssignmentExpression);else if(this.match("("))x=b?this.parsePropertyMethodAsyncFunction():this.parsePropertyMethodFunction(),w=!0;else if(a.type===3){var k=this.finalize(n,new h.Identifier(a.value));if(this.match("=")){this.context.firstCoverInitializedNameError=this.lookahead,this.nextToken(),F=!0;var N=this.isolateCoverGrammar(this.parseAssignmentExpression);x=this.finalize(n,new h.AssignmentPattern(k,N))}else F=!0,x=k}else this.throwUnexpectedToken(this.nextToken());return this.finalize(n,new h.Property(o,p,S,x,w,F))},d.prototype.parseObjectInitializer=function(){var t=this.createNode();this.expect("{");for(var n=[],a={value:!1};!this.match("}");)n.push(this.parseObjectProperty(a)),this.match("}")||this.expectCommaSeparator();return this.expect("}"),this.finalize(t,new h.ObjectExpression(n))},d.prototype.parseTemplateHead=function(){u.assert(this.lookahead.head,"Template literal must start with a template head");var t=this.createNode(),n=this.nextToken(),a=n.value,o=n.cooked;return this.finalize(t,new h.TemplateElement({raw:a,cooked:o},n.tail))},d.prototype.parseTemplateElement=function(){this.lookahead.type!==10&&this.throwUnexpectedToken();var t=this.createNode(),n=this.nextToken(),a=n.value,o=n.cooked;return this.finalize(t,new h.TemplateElement({raw:a,cooked:o},n.tail))},d.prototype.parseTemplateLiteral=function(){var t=this.createNode(),n=[],a=[],o=this.parseTemplateHead();for(a.push(o);!o.tail;)n.push(this.parseExpression()),o=this.parseTemplateElement(),a.push(o);return this.finalize(t,new h.TemplateLiteral(a,n))},d.prototype.reinterpretExpressionAsPattern=function(t){switch(t.type){case y.Syntax.Identifier:case y.Syntax.MemberExpression:case y.Syntax.RestElement:case y.Syntax.AssignmentPattern:break;case y.Syntax.SpreadElement:t.type=y.Syntax.RestElement,this.reinterpretExpressionAsPattern(t.argument);break;case y.Syntax.ArrayExpression:t.type=y.Syntax.ArrayPattern;for(var n=0;n<t.elements.length;n++)t.elements[n]!==null&&this.reinterpretExpressionAsPattern(t.elements[n]);break;case y.Syntax.ObjectExpression:t.type=y.Syntax.ObjectPattern;for(var n=0;n<t.properties.length;n++)this.reinterpretExpressionAsPattern(t.properties[n].value);break;case y.Syntax.AssignmentExpression:t.type=y.Syntax.AssignmentPattern,delete t.operator,this.reinterpretExpressionAsPattern(t.left);break;default:break}},d.prototype.parseGroupExpression=function(){var t;if(this.expect("("),this.match(")"))this.nextToken(),this.match("=>")||this.expect("=>"),t={type:c,params:[],async:!1};else{var n=this.lookahead,a=[];if(this.match("..."))t=this.parseRestElement(a),this.expect(")"),this.match("=>")||this.expect("=>"),t={type:c,params:[t],async:!1};else{var o=!1;if(this.context.isBindingElement=!0,t=this.inheritCoverGrammar(this.parseAssignmentExpression),this.match(",")){var p=[];for(this.context.isAssignmentTarget=!1,p.push(t);this.lookahead.type!==2&&this.match(",");){if(this.nextToken(),this.match(")")){this.nextToken();for(var x=0;x<p.length;x++)this.reinterpretExpressionAsPattern(p[x]);o=!0,t={type:c,params:p,async:!1}}else if(this.match("...")){this.context.isBindingElement||this.throwUnexpectedToken(this.lookahead),p.push(this.parseRestElement(a)),this.expect(")"),this.match("=>")||this.expect("=>"),this.context.isBindingElement=!1;for(var x=0;x<p.length;x++)this.reinterpretExpressionAsPattern(p[x]);o=!0,t={type:c,params:p,async:!1}}else p.push(this.inheritCoverGrammar(this.parseAssignmentExpression));if(o)break}o||(t=this.finalize(this.startNode(n),new h.SequenceExpression(p)))}if(!o){if(this.expect(")"),this.match("=>")&&(t.type===y.Syntax.Identifier&&t.name==="yield"&&(o=!0,t={type:c,params:[t],async:!1}),!o)){if(this.context.isBindingElement||this.throwUnexpectedToken(this.lookahead),t.type===y.Syntax.SequenceExpression)for(var x=0;x<t.expressions.length;x++)this.reinterpretExpressionAsPattern(t.expressions[x]);else this.reinterpretExpressionAsPattern(t);var S=t.type===y.Syntax.SequenceExpression?t.expressions:[t];t={type:c,params:S,async:!1}}this.context.isBindingElement=!1}}}return t},d.prototype.parseArguments=function(){this.expect("(");var t=[];if(!this.match(")"))for(;;){var n=this.match("...")?this.parseSpreadElement():this.isolateCoverGrammar(this.parseAssignmentExpression);if(t.push(n),this.match(")")||(this.expectCommaSeparator(),this.match(")")))break}return this.expect(")"),t},d.prototype.isIdentifierName=function(t){return t.type===3||t.type===4||t.type===1||t.type===5},d.prototype.parseIdentifierName=function(){var t=this.createNode(),n=this.nextToken();return this.isIdentifierName(n)||this.throwUnexpectedToken(n),this.finalize(t,new h.Identifier(n.value))},d.prototype.parseNewExpression=function(){var t=this.createNode(),n=this.parseIdentifierName();u.assert(n.name==="new","New expression must start with `new`");var a;if(this.match("."))if(this.nextToken(),this.lookahead.type===3&&this.context.inFunctionBody&&this.lookahead.value==="target"){var o=this.parseIdentifierName();a=new h.MetaProperty(n,o)}else this.throwUnexpectedToken(this.lookahead);else{var p=this.isolateCoverGrammar(this.parseLeftHandSideExpression),x=this.match("(")?this.parseArguments():[];a=new h.NewExpression(p,x),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1}return this.finalize(t,a)},d.prototype.parseAsyncArgument=function(){var t=this.parseAssignmentExpression();return this.context.firstCoverInitializedNameError=null,t},d.prototype.parseAsyncArguments=function(){this.expect("(");var t=[];if(!this.match(")"))for(;;){var n=this.match("...")?this.parseSpreadElement():this.isolateCoverGrammar(this.parseAsyncArgument);if(t.push(n),this.match(")")||(this.expectCommaSeparator(),this.match(")")))break}return this.expect(")"),t},d.prototype.parseLeftHandSideExpressionAllowCall=function(){var t=this.lookahead,n=this.matchContextualKeyword("async"),a=this.context.allowIn;this.context.allowIn=!0;var o;for(this.matchKeyword("super")&&this.context.inFunctionBody?(o=this.createNode(),this.nextToken(),o=this.finalize(o,new h.Super),!this.match("(")&&!this.match(".")&&!this.match("[")&&this.throwUnexpectedToken(this.lookahead)):o=this.inheritCoverGrammar(this.matchKeyword("new")?this.parseNewExpression:this.parsePrimaryExpression);;)if(this.match(".")){this.context.isBindingElement=!1,this.context.isAssignmentTarget=!0,this.expect(".");var p=this.parseIdentifierName();o=this.finalize(this.startNode(t),new h.StaticMemberExpression(o,p))}else if(this.match("(")){var x=n&&t.lineNumber===this.lookahead.lineNumber;this.context.isBindingElement=!1,this.context.isAssignmentTarget=!1;var S=x?this.parseAsyncArguments():this.parseArguments();if(o=this.finalize(this.startNode(t),new h.CallExpression(o,S)),x&&this.match("=>")){for(var w=0;w<S.length;++w)this.reinterpretExpressionAsPattern(S[w]);o={type:c,params:S,async:!0}}}else if(this.match("[")){this.context.isBindingElement=!1,this.context.isAssignmentTarget=!0,this.expect("[");var p=this.isolateCoverGrammar(this.parseExpression);this.expect("]"),o=this.finalize(this.startNode(t),new h.ComputedMemberExpression(o,p))}else if(this.lookahead.type===10&&this.lookahead.head){var F=this.parseTemplateLiteral();o=this.finalize(this.startNode(t),new h.TaggedTemplateExpression(o,F))}else break;return this.context.allowIn=a,o},d.prototype.parseSuper=function(){var t=this.createNode();return this.expectKeyword("super"),!this.match("[")&&!this.match(".")&&this.throwUnexpectedToken(this.lookahead),this.finalize(t,new h.Super)},d.prototype.parseLeftHandSideExpression=function(){u.assert(this.context.allowIn,"callee of new expression always allow in keyword.");for(var t=this.startNode(this.lookahead),n=this.matchKeyword("super")&&this.context.inFunctionBody?this.parseSuper():this.inheritCoverGrammar(this.matchKeyword("new")?this.parseNewExpression:this.parsePrimaryExpression);;)if(this.match("[")){this.context.isBindingElement=!1,this.context.isAssignmentTarget=!0,this.expect("[");var a=this.isolateCoverGrammar(this.parseExpression);this.expect("]"),n=this.finalize(t,new h.ComputedMemberExpression(n,a))}else if(this.match(".")){this.context.isBindingElement=!1,this.context.isAssignmentTarget=!0,this.expect(".");var a=this.parseIdentifierName();n=this.finalize(t,new h.StaticMemberExpression(n,a))}else if(this.lookahead.type===10&&this.lookahead.head){var o=this.parseTemplateLiteral();n=this.finalize(t,new h.TaggedTemplateExpression(n,o))}else break;return n},d.prototype.parseUpdateExpression=function(){var t,n=this.lookahead;if(this.match("++")||this.match("--")){var a=this.startNode(n),o=this.nextToken();t=this.inheritCoverGrammar(this.parseUnaryExpression),this.context.strict&&t.type===y.Syntax.Identifier&&this.scanner.isRestrictedWord(t.name)&&this.tolerateError(f.Messages.StrictLHSPrefix),this.context.isAssignmentTarget||this.tolerateError(f.Messages.InvalidLHSInAssignment);var p=!0;t=this.finalize(a,new h.UpdateExpression(o.value,t,p)),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1}else if(t=this.inheritCoverGrammar(this.parseLeftHandSideExpressionAllowCall),!this.hasLineTerminator&&this.lookahead.type===7&&(this.match("++")||this.match("--"))){this.context.strict&&t.type===y.Syntax.Identifier&&this.scanner.isRestrictedWord(t.name)&&this.tolerateError(f.Messages.StrictLHSPostfix),this.context.isAssignmentTarget||this.tolerateError(f.Messages.InvalidLHSInAssignment),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1;var x=this.nextToken().value,p=!1;t=this.finalize(this.startNode(n),new h.UpdateExpression(x,t,p))}return t},d.prototype.parseAwaitExpression=function(){var t=this.createNode();this.nextToken();var n=this.parseUnaryExpression();return this.finalize(t,new h.AwaitExpression(n))},d.prototype.parseUnaryExpression=function(){var t;if(this.match("+")||this.match("-")||this.match("~")||this.match("!")||this.matchKeyword("delete")||this.matchKeyword("void")||this.matchKeyword("typeof")){var n=this.startNode(this.lookahead),a=this.nextToken();t=this.inheritCoverGrammar(this.parseUnaryExpression),t=this.finalize(n,new h.UnaryExpression(a.value,t)),this.context.strict&&t.operator==="delete"&&t.argument.type===y.Syntax.Identifier&&this.tolerateError(f.Messages.StrictDelete),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1}else this.context.await&&this.matchContextualKeyword("await")?t=this.parseAwaitExpression():t=this.parseUpdateExpression();return t},d.prototype.parseExponentiationExpression=function(){var t=this.lookahead,n=this.inheritCoverGrammar(this.parseUnaryExpression);if(n.type!==y.Syntax.UnaryExpression&&this.match("**")){this.nextToken(),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1;var a=n,o=this.isolateCoverGrammar(this.parseExponentiationExpression);n=this.finalize(this.startNode(t),new h.BinaryExpression("**",a,o))}return n},d.prototype.binaryPrecedence=function(t){var n=t.value,a;return t.type===7?a=this.operatorPrecedence[n]||0:t.type===4?a=n==="instanceof"||this.context.allowIn&&n==="in"?7:0:a=0,a},d.prototype.parseBinaryExpression=function(){var t=this.lookahead,n=this.inheritCoverGrammar(this.parseExponentiationExpression),a=this.lookahead,o=this.binaryPrecedence(a);if(o>0){this.nextToken(),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1;for(var p=[t,this.lookahead],x=n,S=this.isolateCoverGrammar(this.parseExponentiationExpression),w=[x,a.value,S],F=[o];o=this.binaryPrecedence(this.lookahead),!(o<=0);){for(;w.length>2&&o<=F[F.length-1];){S=w.pop();var b=w.pop();F.pop(),x=w.pop(),p.pop();var k=this.startNode(p[p.length-1]);w.push(this.finalize(k,new h.BinaryExpression(b,x,S)))}w.push(this.nextToken().value),F.push(o),p.push(this.lookahead),w.push(this.isolateCoverGrammar(this.parseExponentiationExpression))}var B=w.length-1;n=w[B];for(var N=p.pop();B>1;){var U=p.pop(),X=N&&N.lineStart,k=this.startNode(U,X),b=w[B-1];n=this.finalize(k,new h.BinaryExpression(b,w[B-2],n)),B-=2,N=U}}return n},d.prototype.parseConditionalExpression=function(){var t=this.lookahead,n=this.inheritCoverGrammar(this.parseBinaryExpression);if(this.match("?")){this.nextToken();var a=this.context.allowIn;this.context.allowIn=!0;var o=this.isolateCoverGrammar(this.parseAssignmentExpression);this.context.allowIn=a,this.expect(":");var p=this.isolateCoverGrammar(this.parseAssignmentExpression);n=this.finalize(this.startNode(t),new h.ConditionalExpression(n,o,p)),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1}return n},d.prototype.checkPatternParam=function(t,n){switch(n.type){case y.Syntax.Identifier:this.validateParam(t,n,n.name);break;case y.Syntax.RestElement:this.checkPatternParam(t,n.argument);break;case y.Syntax.AssignmentPattern:this.checkPatternParam(t,n.left);break;case y.Syntax.ArrayPattern:for(var a=0;a<n.elements.length;a++)n.elements[a]!==null&&this.checkPatternParam(t,n.elements[a]);break;case y.Syntax.ObjectPattern:for(var a=0;a<n.properties.length;a++)this.checkPatternParam(t,n.properties[a].value);break;default:break}t.simple=t.simple&&n instanceof h.Identifier},d.prototype.reinterpretAsCoverFormalsList=function(t){var n=[t],a,o=!1;switch(t.type){case y.Syntax.Identifier:break;case c:n=t.params,o=t.async;break;default:return null}a={simple:!0,paramSet:{}};for(var p=0;p<n.length;++p){var x=n[p];x.type===y.Syntax.AssignmentPattern?x.right.type===y.Syntax.YieldExpression&&(x.right.argument&&this.throwUnexpectedToken(this.lookahead),x.right.type=y.Syntax.Identifier,x.right.name="yield",delete x.right.argument,delete x.right.delegate):o&&x.type===y.Syntax.Identifier&&x.name==="await"&&this.throwUnexpectedToken(this.lookahead),this.checkPatternParam(a,x),n[p]=x}if(this.context.strict||!this.context.allowYield)for(var p=0;p<n.length;++p){var x=n[p];x.type===y.Syntax.YieldExpression&&this.throwUnexpectedToken(this.lookahead)}if(a.message===f.Messages.StrictParamDupe){var S=this.context.strict?a.stricted:a.firstRestricted;this.throwUnexpectedToken(S,a.message)}return{simple:a.simple,params:n,stricted:a.stricted,firstRestricted:a.firstRestricted,message:a.message}},d.prototype.parseAssignmentExpression=function(){var t;if(!this.context.allowYield&&this.matchKeyword("yield"))t=this.parseYieldExpression();else{var n=this.lookahead,a=n;if(t=this.parseConditionalExpression(),a.type===3&&a.lineNumber===this.lookahead.lineNumber&&a.value==="async"&&(this.lookahead.type===3||this.matchKeyword("yield"))){var o=this.parsePrimaryExpression();this.reinterpretExpressionAsPattern(o),t={type:c,params:[o],async:!0}}if(t.type===c||this.match("=>")){this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1;var p=t.async,x=this.reinterpretAsCoverFormalsList(t);if(x){this.hasLineTerminator&&this.tolerateUnexpectedToken(this.lookahead),this.context.firstCoverInitializedNameError=null;var S=this.context.strict,w=this.context.allowStrictDirective;this.context.allowStrictDirective=x.simple;var F=this.context.allowYield,b=this.context.await;this.context.allowYield=!0,this.context.await=p;var k=this.startNode(n);this.expect("=>");var B=void 0;if(this.match("{")){var N=this.context.allowIn;this.context.allowIn=!0,B=this.parseFunctionSourceElements(),this.context.allowIn=N}else B=this.isolateCoverGrammar(this.parseAssignmentExpression);var U=B.type!==y.Syntax.BlockStatement;this.context.strict&&x.firstRestricted&&this.throwUnexpectedToken(x.firstRestricted,x.message),this.context.strict&&x.stricted&&this.tolerateUnexpectedToken(x.stricted,x.message),t=p?this.finalize(k,new h.AsyncArrowFunctionExpression(x.params,B,U)):this.finalize(k,new h.ArrowFunctionExpression(x.params,B,U)),this.context.strict=S,this.context.allowStrictDirective=w,this.context.allowYield=F,this.context.await=b}}else if(this.matchAssign()){if(this.context.isAssignmentTarget||this.tolerateError(f.Messages.InvalidLHSInAssignment),this.context.strict&&t.type===y.Syntax.Identifier){var X=t;this.scanner.isRestrictedWord(X.name)&&this.tolerateUnexpectedToken(a,f.Messages.StrictLHSAssignment),this.scanner.isStrictModeReservedWord(X.name)&&this.tolerateUnexpectedToken(a,f.Messages.StrictReservedWord)}this.match("=")?this.reinterpretExpressionAsPattern(t):(this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1),a=this.nextToken();var K=a.value,ge=this.isolateCoverGrammar(this.parseAssignmentExpression);t=this.finalize(this.startNode(n),new h.AssignmentExpression(K,t,ge)),this.context.firstCoverInitializedNameError=null}}return t},d.prototype.parseExpression=function(){var t=this.lookahead,n=this.isolateCoverGrammar(this.parseAssignmentExpression);if(this.match(",")){var a=[];for(a.push(n);this.lookahead.type!==2&&this.match(",");)this.nextToken(),a.push(this.isolateCoverGrammar(this.parseAssignmentExpression));n=this.finalize(this.startNode(t),new h.SequenceExpression(a))}return n},d.prototype.parseStatementListItem=function(){var t;if(this.context.isAssignmentTarget=!0,this.context.isBindingElement=!0,this.lookahead.type===4)switch(this.lookahead.value){case"export":this.context.isModule||this.tolerateUnexpectedToken(this.lookahead,f.Messages.IllegalExportDeclaration),t=this.parseExportDeclaration();break;case"import":this.context.isModule||this.tolerateUnexpectedToken(this.lookahead,f.Messages.IllegalImportDeclaration),t=this.parseImportDeclaration();break;case"const":t=this.parseLexicalDeclaration({inFor:!1});break;case"function":t=this.parseFunctionDeclaration();break;case"class":t=this.parseClassDeclaration();break;case"let":t=this.isLexicalDeclaration()?this.parseLexicalDeclaration({inFor:!1}):this.parseStatement();break;default:t=this.parseStatement();break}else t=this.parseStatement();return t},d.prototype.parseBlock=function(){var t=this.createNode();this.expect("{");for(var n=[];!this.match("}");)n.push(this.parseStatementListItem());return this.expect("}"),this.finalize(t,new h.BlockStatement(n))},d.prototype.parseLexicalBinding=function(t,n){var a=this.createNode(),o=[],p=this.parsePattern(o,t);this.context.strict&&p.type===y.Syntax.Identifier&&this.scanner.isRestrictedWord(p.name)&&this.tolerateError(f.Messages.StrictVarName);var x=null;return t==="const"?!this.matchKeyword("in")&&!this.matchContextualKeyword("of")&&(this.match("=")?(this.nextToken(),x=this.isolateCoverGrammar(this.parseAssignmentExpression)):this.throwError(f.Messages.DeclarationMissingInitializer,"const")):(!n.inFor&&p.type!==y.Syntax.Identifier||this.match("="))&&(this.expect("="),x=this.isolateCoverGrammar(this.parseAssignmentExpression)),this.finalize(a,new h.VariableDeclarator(p,x))},d.prototype.parseBindingList=function(t,n){for(var a=[this.parseLexicalBinding(t,n)];this.match(",");)this.nextToken(),a.push(this.parseLexicalBinding(t,n));return a},d.prototype.isLexicalDeclaration=function(){var t=this.scanner.saveState();this.scanner.scanComments();var n=this.scanner.lex();return this.scanner.restoreState(t),n.type===3||n.type===7&&n.value==="["||n.type===7&&n.value==="{"||n.type===4&&n.value==="let"||n.type===4&&n.value==="yield"},d.prototype.parseLexicalDeclaration=function(t){var n=this.createNode(),a=this.nextToken().value;u.assert(a==="let"||a==="const","Lexical declaration must be either let or const");var o=this.parseBindingList(a,t);return this.consumeSemicolon(),this.finalize(n,new h.VariableDeclaration(o,a))},d.prototype.parseBindingRestElement=function(t,n){var a=this.createNode();this.expect("...");var o=this.parsePattern(t,n);return this.finalize(a,new h.RestElement(o))},d.prototype.parseArrayPattern=function(t,n){var a=this.createNode();this.expect("[");for(var o=[];!this.match("]");)if(this.match(","))this.nextToken(),o.push(null);else{if(this.match("...")){o.push(this.parseBindingRestElement(t,n));break}else o.push(this.parsePatternWithDefault(t,n));this.match("]")||this.expect(",")}return this.expect("]"),this.finalize(a,new h.ArrayPattern(o))},d.prototype.parsePropertyPattern=function(t,n){var a=this.createNode(),o=!1,p=!1,x=!1,S,w;if(this.lookahead.type===3){var F=this.lookahead;S=this.parseVariableIdentifier();var b=this.finalize(a,new h.Identifier(F.value));if(this.match("=")){t.push(F),p=!0,this.nextToken();var k=this.parseAssignmentExpression();w=this.finalize(this.startNode(F),new h.AssignmentPattern(b,k))}else this.match(":")?(this.expect(":"),w=this.parsePatternWithDefault(t,n)):(t.push(F),p=!0,w=b)}else o=this.match("["),S=this.parseObjectPropertyKey(),this.expect(":"),w=this.parsePatternWithDefault(t,n);return this.finalize(a,new h.Property("init",S,o,w,x,p))},d.prototype.parseObjectPattern=function(t,n){var a=this.createNode(),o=[];for(this.expect("{");!this.match("}");)o.push(this.parsePropertyPattern(t,n)),this.match("}")||this.expect(",");return this.expect("}"),this.finalize(a,new h.ObjectPattern(o))},d.prototype.parsePattern=function(t,n){var a;return this.match("[")?a=this.parseArrayPattern(t,n):this.match("{")?a=this.parseObjectPattern(t,n):(this.matchKeyword("let")&&(n==="const"||n==="let")&&this.tolerateUnexpectedToken(this.lookahead,f.Messages.LetInLexicalBinding),t.push(this.lookahead),a=this.parseVariableIdentifier(n)),a},d.prototype.parsePatternWithDefault=function(t,n){var a=this.lookahead,o=this.parsePattern(t,n);if(this.match("=")){this.nextToken();var p=this.context.allowYield;this.context.allowYield=!0;var x=this.isolateCoverGrammar(this.parseAssignmentExpression);this.context.allowYield=p,o=this.finalize(this.startNode(a),new h.AssignmentPattern(o,x))}return o},d.prototype.parseVariableIdentifier=function(t){var n=this.createNode(),a=this.nextToken();return a.type===4&&a.value==="yield"?this.context.strict?this.tolerateUnexpectedToken(a,f.Messages.StrictReservedWord):this.context.allowYield||this.throwUnexpectedToken(a):a.type!==3?this.context.strict&&a.type===4&&this.scanner.isStrictModeReservedWord(a.value)?this.tolerateUnexpectedToken(a,f.Messages.StrictReservedWord):(this.context.strict||a.value!=="let"||t!=="var")&&this.throwUnexpectedToken(a):(this.context.isModule||this.context.await)&&a.type===3&&a.value==="await"&&this.tolerateUnexpectedToken(a),this.finalize(n,new h.Identifier(a.value))},d.prototype.parseVariableDeclaration=function(t){var n=this.createNode(),a=[],o=this.parsePattern(a,"var");this.context.strict&&o.type===y.Syntax.Identifier&&this.scanner.isRestrictedWord(o.name)&&this.tolerateError(f.Messages.StrictVarName);var p=null;return this.match("=")?(this.nextToken(),p=this.isolateCoverGrammar(this.parseAssignmentExpression)):o.type!==y.Syntax.Identifier&&!t.inFor&&this.expect("="),this.finalize(n,new h.VariableDeclarator(o,p))},d.prototype.parseVariableDeclarationList=function(t){var n={inFor:t.inFor},a=[];for(a.push(this.parseVariableDeclaration(n));this.match(",");)this.nextToken(),a.push(this.parseVariableDeclaration(n));return a},d.prototype.parseVariableStatement=function(){var t=this.createNode();this.expectKeyword("var");var n=this.parseVariableDeclarationList({inFor:!1});return this.consumeSemicolon(),this.finalize(t,new h.VariableDeclaration(n,"var"))},d.prototype.parseEmptyStatement=function(){var t=this.createNode();return this.expect(";"),this.finalize(t,new h.EmptyStatement)},d.prototype.parseExpressionStatement=function(){var t=this.createNode(),n=this.parseExpression();return this.consumeSemicolon(),this.finalize(t,new h.ExpressionStatement(n))},d.prototype.parseIfClause=function(){return this.context.strict&&this.matchKeyword("function")&&this.tolerateError(f.Messages.StrictFunction),this.parseStatement()},d.prototype.parseIfStatement=function(){var t=this.createNode(),n,a=null;this.expectKeyword("if"),this.expect("(");var o=this.parseExpression();return!this.match(")")&&this.config.tolerant?(this.tolerateUnexpectedToken(this.nextToken()),n=this.finalize(this.createNode(),new h.EmptyStatement)):(this.expect(")"),n=this.parseIfClause(),this.matchKeyword("else")&&(this.nextToken(),a=this.parseIfClause())),this.finalize(t,new h.IfStatement(o,n,a))},d.prototype.parseDoWhileStatement=function(){var t=this.createNode();this.expectKeyword("do");var n=this.context.inIteration;this.context.inIteration=!0;var a=this.parseStatement();this.context.inIteration=n,this.expectKeyword("while"),this.expect("(");var o=this.parseExpression();return!this.match(")")&&this.config.tolerant?this.tolerateUnexpectedToken(this.nextToken()):(this.expect(")"),this.match(";")&&this.nextToken()),this.finalize(t,new h.DoWhileStatement(a,o))},d.prototype.parseWhileStatement=function(){var t=this.createNode(),n;this.expectKeyword("while"),this.expect("(");var a=this.parseExpression();if(!this.match(")")&&this.config.tolerant)this.tolerateUnexpectedToken(this.nextToken()),n=this.finalize(this.createNode(),new h.EmptyStatement);else{this.expect(")");var o=this.context.inIteration;this.context.inIteration=!0,n=this.parseStatement(),this.context.inIteration=o}return this.finalize(t,new h.WhileStatement(a,n))},d.prototype.parseForStatement=function(){var t=null,n=null,a=null,o=!0,p,x,S=this.createNode();if(this.expectKeyword("for"),this.expect("("),this.match(";"))this.nextToken();else if(this.matchKeyword("var")){t=this.createNode(),this.nextToken();var w=this.context.allowIn;this.context.allowIn=!1;var F=this.parseVariableDeclarationList({inFor:!0});if(this.context.allowIn=w,F.length===1&&this.matchKeyword("in")){var b=F[0];b.init&&(b.id.type===y.Syntax.ArrayPattern||b.id.type===y.Syntax.ObjectPattern||this.context.strict)&&this.tolerateError(f.Messages.ForInOfLoopInitializer,"for-in"),t=this.finalize(t,new h.VariableDeclaration(F,"var")),this.nextToken(),p=t,x=this.parseExpression(),t=null}else F.length===1&&F[0].init===null&&this.matchContextualKeyword("of")?(t=this.finalize(t,new h.VariableDeclaration(F,"var")),this.nextToken(),p=t,x=this.parseAssignmentExpression(),t=null,o=!1):(t=this.finalize(t,new h.VariableDeclaration(F,"var")),this.expect(";"))}else if(this.matchKeyword("const")||this.matchKeyword("let")){t=this.createNode();var k=this.nextToken().value;if(!this.context.strict&&this.lookahead.value==="in")t=this.finalize(t,new h.Identifier(k)),this.nextToken(),p=t,x=this.parseExpression(),t=null;else{var w=this.context.allowIn;this.context.allowIn=!1;var F=this.parseBindingList(k,{inFor:!0});this.context.allowIn=w,F.length===1&&F[0].init===null&&this.matchKeyword("in")?(t=this.finalize(t,new h.VariableDeclaration(F,k)),this.nextToken(),p=t,x=this.parseExpression(),t=null):F.length===1&&F[0].init===null&&this.matchContextualKeyword("of")?(t=this.finalize(t,new h.VariableDeclaration(F,k)),this.nextToken(),p=t,x=this.parseAssignmentExpression(),t=null,o=!1):(this.consumeSemicolon(),t=this.finalize(t,new h.VariableDeclaration(F,k)))}}else{var B=this.lookahead,w=this.context.allowIn;if(this.context.allowIn=!1,t=this.inheritCoverGrammar(this.parseAssignmentExpression),this.context.allowIn=w,this.matchKeyword("in"))(!this.context.isAssignmentTarget||t.type===y.Syntax.AssignmentExpression)&&this.tolerateError(f.Messages.InvalidLHSInForIn),this.nextToken(),this.reinterpretExpressionAsPattern(t),p=t,x=this.parseExpression(),t=null;else if(this.matchContextualKeyword("of"))(!this.context.isAssignmentTarget||t.type===y.Syntax.AssignmentExpression)&&this.tolerateError(f.Messages.InvalidLHSInForLoop),this.nextToken(),this.reinterpretExpressionAsPattern(t),p=t,x=this.parseAssignmentExpression(),t=null,o=!1;else{if(this.match(",")){for(var N=[t];this.match(",");)this.nextToken(),N.push(this.isolateCoverGrammar(this.parseAssignmentExpression));t=this.finalize(this.startNode(B),new h.SequenceExpression(N))}this.expect(";")}}typeof p>"u"&&(this.match(";")||(n=this.parseExpression()),this.expect(";"),this.match(")")||(a=this.parseExpression()));var U;if(!this.match(")")&&this.config.tolerant)this.tolerateUnexpectedToken(this.nextToken()),U=this.finalize(this.createNode(),new h.EmptyStatement);else{this.expect(")");var X=this.context.inIteration;this.context.inIteration=!0,U=this.isolateCoverGrammar(this.parseStatement),this.context.inIteration=X}return typeof p>"u"?this.finalize(S,new h.ForStatement(t,n,a,U)):o?this.finalize(S,new h.ForInStatement(p,x,U)):this.finalize(S,new h.ForOfStatement(p,x,U))},d.prototype.parseContinueStatement=function(){var t=this.createNode();this.expectKeyword("continue");var n=null;if(this.lookahead.type===3&&!this.hasLineTerminator){var a=this.parseVariableIdentifier();n=a;var o="$"+a.name;Object.prototype.hasOwnProperty.call(this.context.labelSet,o)||this.throwError(f.Messages.UnknownLabel,a.name)}return this.consumeSemicolon(),n===null&&!this.context.inIteration&&this.throwError(f.Messages.IllegalContinue),this.finalize(t,new h.ContinueStatement(n))},d.prototype.parseBreakStatement=function(){var t=this.createNode();this.expectKeyword("break");var n=null;if(this.lookahead.type===3&&!this.hasLineTerminator){var a=this.parseVariableIdentifier(),o="$"+a.name;Object.prototype.hasOwnProperty.call(this.context.labelSet,o)||this.throwError(f.Messages.UnknownLabel,a.name),n=a}return this.consumeSemicolon(),n===null&&!this.context.inIteration&&!this.context.inSwitch&&this.throwError(f.Messages.IllegalBreak),this.finalize(t,new h.BreakStatement(n))},d.prototype.parseReturnStatement=function(){this.context.inFunctionBody||this.tolerateError(f.Messages.IllegalReturn);var t=this.createNode();this.expectKeyword("return");var n=!this.match(";")&&!this.match("}")&&!this.hasLineTerminator&&this.lookahead.type!==2||this.lookahead.type===8||this.lookahead.type===10,a=n?this.parseExpression():null;return this.consumeSemicolon(),this.finalize(t,new h.ReturnStatement(a))},d.prototype.parseWithStatement=function(){this.context.strict&&this.tolerateError(f.Messages.StrictModeWith);var t=this.createNode(),n;this.expectKeyword("with"),this.expect("(");var a=this.parseExpression();return!this.match(")")&&this.config.tolerant?(this.tolerateUnexpectedToken(this.nextToken()),n=this.finalize(this.createNode(),new h.EmptyStatement)):(this.expect(")"),n=this.parseStatement()),this.finalize(t,new h.WithStatement(a,n))},d.prototype.parseSwitchCase=function(){var t=this.createNode(),n;this.matchKeyword("default")?(this.nextToken(),n=null):(this.expectKeyword("case"),n=this.parseExpression()),this.expect(":");for(var a=[];!(this.match("}")||this.matchKeyword("default")||this.matchKeyword("case"));)a.push(this.parseStatementListItem());return this.finalize(t,new h.SwitchCase(n,a))},d.prototype.parseSwitchStatement=function(){var t=this.createNode();this.expectKeyword("switch"),this.expect("(");var n=this.parseExpression();this.expect(")");var a=this.context.inSwitch;this.context.inSwitch=!0;var o=[],p=!1;for(this.expect("{");!this.match("}");){var x=this.parseSwitchCase();x.test===null&&(p&&this.throwError(f.Messages.MultipleDefaultsInSwitch),p=!0),o.push(x)}return this.expect("}"),this.context.inSwitch=a,this.finalize(t,new h.SwitchStatement(n,o))},d.prototype.parseLabelledStatement=function(){var t=this.createNode(),n=this.parseExpression(),a;if(n.type===y.Syntax.Identifier&&this.match(":")){this.nextToken();var o=n,p="$"+o.name;Object.prototype.hasOwnProperty.call(this.context.labelSet,p)&&this.throwError(f.Messages.Redeclaration,"Label",o.name),this.context.labelSet[p]=!0;var x=void 0;if(this.matchKeyword("class"))this.tolerateUnexpectedToken(this.lookahead),x=this.parseClassDeclaration();else if(this.matchKeyword("function")){var S=this.lookahead,w=this.parseFunctionDeclaration();this.context.strict?this.tolerateUnexpectedToken(S,f.Messages.StrictFunction):w.generator&&this.tolerateUnexpectedToken(S,f.Messages.GeneratorInLegacyContext),x=w}else x=this.parseStatement();delete this.context.labelSet[p],a=new h.LabeledStatement(o,x)}else this.consumeSemicolon(),a=new h.ExpressionStatement(n);return this.finalize(t,a)},d.prototype.parseThrowStatement=function(){var t=this.createNode();this.expectKeyword("throw"),this.hasLineTerminator&&this.throwError(f.Messages.NewlineAfterThrow);var n=this.parseExpression();return this.consumeSemicolon(),this.finalize(t,new h.ThrowStatement(n))},d.prototype.parseCatchClause=function(){var t=this.createNode();this.expectKeyword("catch"),this.expect("("),this.match(")")&&this.throwUnexpectedToken(this.lookahead);for(var n=[],a=this.parsePattern(n),o={},p=0;p<n.length;p++){var x="$"+n[p].value;Object.prototype.hasOwnProperty.call(o,x)&&this.tolerateError(f.Messages.DuplicateBinding,n[p].value),o[x]=!0}this.context.strict&&a.type===y.Syntax.Identifier&&this.scanner.isRestrictedWord(a.name)&&this.tolerateError(f.Messages.StrictCatchVariable),this.expect(")");var S=this.parseBlock();return this.finalize(t,new h.CatchClause(a,S))},d.prototype.parseFinallyClause=function(){return this.expectKeyword("finally"),this.parseBlock()},d.prototype.parseTryStatement=function(){var t=this.createNode();this.expectKeyword("try");var n=this.parseBlock(),a=this.matchKeyword("catch")?this.parseCatchClause():null,o=this.matchKeyword("finally")?this.parseFinallyClause():null;return!a&&!o&&this.throwError(f.Messages.NoCatchOrFinally),this.finalize(t,new h.TryStatement(n,a,o))},d.prototype.parseDebuggerStatement=function(){var t=this.createNode();return this.expectKeyword("debugger"),this.consumeSemicolon(),this.finalize(t,new h.DebuggerStatement)},d.prototype.parseStatement=function(){var t;switch(this.lookahead.type){case 1:case 5:case 6:case 8:case 10:case 9:t=this.parseExpressionStatement();break;case 7:var n=this.lookahead.value;n==="{"?t=this.parseBlock():n==="("?t=this.parseExpressionStatement():n===";"?t=this.parseEmptyStatement():t=this.parseExpressionStatement();break;case 3:t=this.matchAsyncFunction()?this.parseFunctionDeclaration():this.parseLabelledStatement();break;case 4:switch(this.lookahead.value){case"break":t=this.parseBreakStatement();break;case"continue":t=this.parseContinueStatement();break;case"debugger":t=this.parseDebuggerStatement();break;case"do":t=this.parseDoWhileStatement();break;case"for":t=this.parseForStatement();break;case"function":t=this.parseFunctionDeclaration();break;case"if":t=this.parseIfStatement();break;case"return":t=this.parseReturnStatement();break;case"switch":t=this.parseSwitchStatement();break;case"throw":t=this.parseThrowStatement();break;case"try":t=this.parseTryStatement();break;case"var":t=this.parseVariableStatement();break;case"while":t=this.parseWhileStatement();break;case"with":t=this.parseWithStatement();break;default:t=this.parseExpressionStatement();break}break;default:t=this.throwUnexpectedToken(this.lookahead)}return t},d.prototype.parseFunctionSourceElements=function(){var t=this.createNode();this.expect("{");var n=this.parseDirectivePrologues(),a=this.context.labelSet,o=this.context.inIteration,p=this.context.inSwitch,x=this.context.inFunctionBody;for(this.context.labelSet={},this.context.inIteration=!1,this.context.inSwitch=!1,this.context.inFunctionBody=!0;this.lookahead.type!==2&&!this.match("}");)n.push(this.parseStatementListItem());return this.expect("}"),this.context.labelSet=a,this.context.inIteration=o,this.context.inSwitch=p,this.context.inFunctionBody=x,this.finalize(t,new h.BlockStatement(n))},d.prototype.validateParam=function(t,n,a){var o="$"+a;this.context.strict?(this.scanner.isRestrictedWord(a)&&(t.stricted=n,t.message=f.Messages.StrictParamName),Object.prototype.hasOwnProperty.call(t.paramSet,o)&&(t.stricted=n,t.message=f.Messages.StrictParamDupe)):t.firstRestricted||(this.scanner.isRestrictedWord(a)?(t.firstRestricted=n,t.message=f.Messages.StrictParamName):this.scanner.isStrictModeReservedWord(a)?(t.firstRestricted=n,t.message=f.Messages.StrictReservedWord):Object.prototype.hasOwnProperty.call(t.paramSet,o)&&(t.stricted=n,t.message=f.Messages.StrictParamDupe)),typeof Object.defineProperty=="function"?Object.defineProperty(t.paramSet,o,{value:!0,enumerable:!0,writable:!0,configurable:!0}):t.paramSet[o]=!0},d.prototype.parseRestElement=function(t){var n=this.createNode();this.expect("...");var a=this.parsePattern(t);return this.match("=")&&this.throwError(f.Messages.DefaultRestParameter),this.match(")")||this.throwError(f.Messages.ParameterAfterRestParameter),this.finalize(n,new h.RestElement(a))},d.prototype.parseFormalParameter=function(t){for(var n=[],a=this.match("...")?this.parseRestElement(n):this.parsePatternWithDefault(n),o=0;o<n.length;o++)this.validateParam(t,n[o],n[o].value);t.simple=t.simple&&a instanceof h.Identifier,t.params.push(a)},d.prototype.parseFormalParameters=function(t){var n;if(n={simple:!0,params:[],firstRestricted:t},this.expect("("),!this.match(")"))for(n.paramSet={};this.lookahead.type!==2&&(this.parseFormalParameter(n),!(this.match(")")||(this.expect(","),this.match(")")))););return this.expect(")"),{simple:n.simple,params:n.params,stricted:n.stricted,firstRestricted:n.firstRestricted,message:n.message}},d.prototype.matchAsyncFunction=function(){var t=this.matchContextualKeyword("async");if(t){var n=this.scanner.saveState();this.scanner.scanComments();var a=this.scanner.lex();this.scanner.restoreState(n),t=n.lineNumber===a.lineNumber&&a.type===4&&a.value==="function"}return t},d.prototype.parseFunctionDeclaration=function(t){var n=this.createNode(),a=this.matchContextualKeyword("async");a&&this.nextToken(),this.expectKeyword("function");var o=a?!1:this.match("*");o&&this.nextToken();var p,x=null,S=null;if(!t||!this.match("(")){var w=this.lookahead;x=this.parseVariableIdentifier(),this.context.strict?this.scanner.isRestrictedWord(w.value)&&this.tolerateUnexpectedToken(w,f.Messages.StrictFunctionName):this.scanner.isRestrictedWord(w.value)?(S=w,p=f.Messages.StrictFunctionName)