(function (global, factory) { typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports) : typeof define === 'function' && define.amd ? define(['exports'], factory) : (global = global || self, factory(global.Babel = {})); }(this, (function (exports) { 'use strict'; var context = /*#__PURE__*/Object.freeze({ __proto__: null, get types () { return t; }, get DEFAULT_EXTENSIONS () { return DEFAULT_EXTENSIONS; }, get OptionManager () { return OptionManager; }, get Plugin () { return Plugin$1; }, get File () { return File$2; }, get buildExternalHelpers () { return babelBuildExternalHelpers; }, get resolvePlugin () { return resolvePlugin; }, get resolvePreset () { return resolvePreset; }, get version () { return version$1; }, get getEnv () { return getEnv; }, get tokTypes () { return types; }, get traverse () { return traverse$1; }, get template () { return template; }, get createConfigItem () { return createConfigItem; }, get loadPartialConfig () { return loadPartialConfig$1; }, get loadPartialConfigSync () { return loadPartialConfigSync; }, get loadPartialConfigAsync () { return loadPartialConfigAsync; }, get loadOptions () { return loadOptions; }, get loadOptionsSync () { return loadOptionsSync; }, get loadOptionsAsync () { return loadOptionsAsync; }, get transform () { return transform; }, get transformSync () { return transformSync; }, get transformAsync () { return transformAsync; }, get transformFile () { return transformFile$1; }, get transformFileSync () { return transformFileSync; }, get transformFileAsync () { return transformFileAsync; }, get transformFromAst () { return transformFromAst; }, get transformFromAstSync () { return transformFromAstSync; }, get transformFromAstAsync () { return transformFromAstAsync; }, get parse () { return parse$3; }, get parseSync () { return parseSync; }, get parseAsync () { return parseAsync; } }); function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; } function _inheritsLoose(subClass, superClass) { subClass.prototype = Object.create(superClass.prototype); subClass.prototype.constructor = subClass; subClass.__proto__ = superClass; } function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; } function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; } function _taggedTemplateLiteralLoose(strings, raw) { if (!raw) { raw = strings.slice(0); } strings.raw = raw; return strings; } function shallowEqual(actual, expected) { var keys = Object.keys(expected); for (var _i = 0, _arr = keys; _i < _arr.length; _i++) { var key = _arr[_i]; if (actual[key] !== expected[key]) { return false; } } return true; } function isArrayExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ArrayExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isAssignmentExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "AssignmentExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isBinaryExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "BinaryExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isInterpreterDirective(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "InterpreterDirective") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isDirective(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Directive") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isDirectiveLiteral(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "DirectiveLiteral") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isBlockStatement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "BlockStatement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isBreakStatement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "BreakStatement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isCallExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "CallExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isCatchClause(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "CatchClause") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isConditionalExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ConditionalExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isContinueStatement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ContinueStatement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isDebuggerStatement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "DebuggerStatement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isDoWhileStatement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "DoWhileStatement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isEmptyStatement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "EmptyStatement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isExpressionStatement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ExpressionStatement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isFile(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "File") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isForInStatement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ForInStatement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isForStatement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ForStatement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isFunctionDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "FunctionDeclaration") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isFunctionExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "FunctionExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isIdentifier(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Identifier") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isIfStatement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "IfStatement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isLabeledStatement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "LabeledStatement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isStringLiteral(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "StringLiteral") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isNumericLiteral(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "NumericLiteral") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isNullLiteral(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "NullLiteral") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isBooleanLiteral(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "BooleanLiteral") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isRegExpLiteral(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "RegExpLiteral") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isLogicalExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "LogicalExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isMemberExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "MemberExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isNewExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "NewExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isProgram(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Program") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isObjectExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ObjectExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isObjectMethod(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ObjectMethod") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isObjectProperty(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ObjectProperty") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isRestElement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "RestElement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isReturnStatement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ReturnStatement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isSequenceExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "SequenceExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isParenthesizedExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ParenthesizedExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isSwitchCase(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "SwitchCase") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isSwitchStatement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "SwitchStatement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isThisExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ThisExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isThrowStatement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ThrowStatement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTryStatement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TryStatement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isUnaryExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "UnaryExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isUpdateExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "UpdateExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isVariableDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "VariableDeclaration") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isVariableDeclarator(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "VariableDeclarator") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isWhileStatement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "WhileStatement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isWithStatement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "WithStatement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isAssignmentPattern(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "AssignmentPattern") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isArrayPattern(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ArrayPattern") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isArrowFunctionExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ArrowFunctionExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isClassBody(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ClassBody") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isClassExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ClassExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isClassDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ClassDeclaration") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isExportAllDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ExportAllDeclaration") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isExportDefaultDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ExportDefaultDeclaration") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isExportNamedDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ExportNamedDeclaration") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isExportSpecifier(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ExportSpecifier") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isForOfStatement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ForOfStatement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isImportDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ImportDeclaration") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isImportDefaultSpecifier(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ImportDefaultSpecifier") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isImportNamespaceSpecifier(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ImportNamespaceSpecifier") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isImportSpecifier(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ImportSpecifier") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isMetaProperty(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "MetaProperty") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isClassMethod(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ClassMethod") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isObjectPattern(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ObjectPattern") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isSpreadElement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "SpreadElement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isSuper(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Super") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTaggedTemplateExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TaggedTemplateExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTemplateElement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TemplateElement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTemplateLiteral(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TemplateLiteral") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isYieldExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "YieldExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isAnyTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "AnyTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isArrayTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ArrayTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isBooleanTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "BooleanTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isBooleanLiteralTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "BooleanLiteralTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isNullLiteralTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "NullLiteralTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isClassImplements(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ClassImplements") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isDeclareClass(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "DeclareClass") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isDeclareFunction(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "DeclareFunction") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isDeclareInterface(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "DeclareInterface") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isDeclareModule(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "DeclareModule") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isDeclareModuleExports(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "DeclareModuleExports") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isDeclareTypeAlias(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "DeclareTypeAlias") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isDeclareOpaqueType(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "DeclareOpaqueType") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isDeclareVariable(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "DeclareVariable") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isDeclareExportDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "DeclareExportDeclaration") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isDeclareExportAllDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "DeclareExportAllDeclaration") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isDeclaredPredicate(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "DeclaredPredicate") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isExistsTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ExistsTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isFunctionTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "FunctionTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isFunctionTypeParam(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "FunctionTypeParam") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isGenericTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "GenericTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isInferredPredicate(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "InferredPredicate") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isInterfaceExtends(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "InterfaceExtends") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isInterfaceDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "InterfaceDeclaration") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isInterfaceTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "InterfaceTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isIntersectionTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "IntersectionTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isMixedTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "MixedTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isEmptyTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "EmptyTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isNullableTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "NullableTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isNumberLiteralTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "NumberLiteralTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isNumberTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "NumberTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isObjectTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ObjectTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isObjectTypeInternalSlot(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ObjectTypeInternalSlot") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isObjectTypeCallProperty(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ObjectTypeCallProperty") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isObjectTypeIndexer(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ObjectTypeIndexer") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isObjectTypeProperty(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ObjectTypeProperty") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isObjectTypeSpreadProperty(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ObjectTypeSpreadProperty") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isOpaqueType(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "OpaqueType") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isQualifiedTypeIdentifier(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "QualifiedTypeIdentifier") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isStringLiteralTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "StringLiteralTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isStringTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "StringTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isThisTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ThisTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTupleTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TupleTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTypeofTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TypeofTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTypeAlias(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TypeAlias") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTypeCastExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TypeCastExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTypeParameter(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TypeParameter") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTypeParameterDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TypeParameterDeclaration") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTypeParameterInstantiation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TypeParameterInstantiation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isUnionTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "UnionTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isVariance(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Variance") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isVoidTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "VoidTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isEnumDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "EnumDeclaration") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isEnumBooleanBody(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "EnumBooleanBody") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isEnumNumberBody(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "EnumNumberBody") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isEnumStringBody(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "EnumStringBody") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isEnumSymbolBody(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "EnumSymbolBody") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isEnumBooleanMember(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "EnumBooleanMember") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isEnumNumberMember(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "EnumNumberMember") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isEnumStringMember(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "EnumStringMember") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isEnumDefaultedMember(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "EnumDefaultedMember") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isJSXAttribute(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "JSXAttribute") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isJSXClosingElement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "JSXClosingElement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isJSXElement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "JSXElement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isJSXEmptyExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "JSXEmptyExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isJSXExpressionContainer(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "JSXExpressionContainer") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isJSXSpreadChild(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "JSXSpreadChild") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isJSXIdentifier(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "JSXIdentifier") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isJSXMemberExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "JSXMemberExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isJSXNamespacedName(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "JSXNamespacedName") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isJSXOpeningElement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "JSXOpeningElement") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isJSXSpreadAttribute(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "JSXSpreadAttribute") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isJSXText(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "JSXText") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isJSXFragment(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "JSXFragment") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isJSXOpeningFragment(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "JSXOpeningFragment") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isJSXClosingFragment(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "JSXClosingFragment") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isNoop(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Noop") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isPlaceholder(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Placeholder") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isV8IntrinsicIdentifier(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "V8IntrinsicIdentifier") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isArgumentPlaceholder(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ArgumentPlaceholder") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isAwaitExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "AwaitExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isBindExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "BindExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isClassProperty(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ClassProperty") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isOptionalMemberExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "OptionalMemberExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isPipelineTopicExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "PipelineTopicExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isPipelineBareFunction(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "PipelineBareFunction") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isPipelinePrimaryTopicReference(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "PipelinePrimaryTopicReference") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isOptionalCallExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "OptionalCallExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isClassPrivateProperty(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ClassPrivateProperty") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isClassPrivateMethod(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ClassPrivateMethod") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isImport(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Import") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isDecorator(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Decorator") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isDoExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "DoExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isExportDefaultSpecifier(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ExportDefaultSpecifier") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isExportNamespaceSpecifier(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ExportNamespaceSpecifier") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isPrivateName(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "PrivateName") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isBigIntLiteral(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "BigIntLiteral") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSParameterProperty(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSParameterProperty") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSDeclareFunction(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSDeclareFunction") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSDeclareMethod(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSDeclareMethod") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSQualifiedName(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSQualifiedName") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSCallSignatureDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSCallSignatureDeclaration") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSConstructSignatureDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSConstructSignatureDeclaration") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSPropertySignature(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSPropertySignature") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSMethodSignature(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSMethodSignature") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSIndexSignature(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSIndexSignature") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSAnyKeyword(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSAnyKeyword") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSBooleanKeyword(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSBooleanKeyword") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSBigIntKeyword(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSBigIntKeyword") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSNeverKeyword(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSNeverKeyword") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSNullKeyword(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSNullKeyword") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSNumberKeyword(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSNumberKeyword") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSObjectKeyword(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSObjectKeyword") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSStringKeyword(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSStringKeyword") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSSymbolKeyword(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSSymbolKeyword") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSUndefinedKeyword(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSUndefinedKeyword") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSUnknownKeyword(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSUnknownKeyword") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSVoidKeyword(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSVoidKeyword") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSThisType(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSThisType") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSFunctionType(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSFunctionType") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSConstructorType(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSConstructorType") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSTypeReference(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSTypeReference") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSTypePredicate(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSTypePredicate") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSTypeQuery(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSTypeQuery") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSTypeLiteral(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSTypeLiteral") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSArrayType(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSArrayType") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSTupleType(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSTupleType") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSOptionalType(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSOptionalType") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSRestType(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSRestType") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSUnionType(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSUnionType") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSIntersectionType(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSIntersectionType") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSConditionalType(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSConditionalType") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSInferType(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSInferType") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSParenthesizedType(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSParenthesizedType") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSTypeOperator(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSTypeOperator") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSIndexedAccessType(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSIndexedAccessType") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSMappedType(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSMappedType") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSLiteralType(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSLiteralType") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSExpressionWithTypeArguments(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSExpressionWithTypeArguments") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSInterfaceDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSInterfaceDeclaration") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSInterfaceBody(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSInterfaceBody") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSTypeAliasDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSTypeAliasDeclaration") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSAsExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSAsExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSTypeAssertion(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSTypeAssertion") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSEnumDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSEnumDeclaration") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSEnumMember(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSEnumMember") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSModuleDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSModuleDeclaration") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSModuleBlock(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSModuleBlock") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSImportType(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSImportType") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSImportEqualsDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSImportEqualsDeclaration") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSExternalModuleReference(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSExternalModuleReference") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSNonNullExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSNonNullExpression") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSExportAssignment(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSExportAssignment") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSNamespaceExportDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSNamespaceExportDeclaration") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSTypeAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSTypeAnnotation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSTypeParameterInstantiation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSTypeParameterInstantiation") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSTypeParameterDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSTypeParameterDeclaration") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSTypeParameter(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSTypeParameter") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isExpression(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Expression" || "ArrayExpression" === nodeType || "AssignmentExpression" === nodeType || "BinaryExpression" === nodeType || "CallExpression" === nodeType || "ConditionalExpression" === nodeType || "FunctionExpression" === nodeType || "Identifier" === nodeType || "StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "RegExpLiteral" === nodeType || "LogicalExpression" === nodeType || "MemberExpression" === nodeType || "NewExpression" === nodeType || "ObjectExpression" === nodeType || "SequenceExpression" === nodeType || "ParenthesizedExpression" === nodeType || "ThisExpression" === nodeType || "UnaryExpression" === nodeType || "UpdateExpression" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassExpression" === nodeType || "MetaProperty" === nodeType || "Super" === nodeType || "TaggedTemplateExpression" === nodeType || "TemplateLiteral" === nodeType || "YieldExpression" === nodeType || "TypeCastExpression" === nodeType || "JSXElement" === nodeType || "JSXFragment" === nodeType || "AwaitExpression" === nodeType || "BindExpression" === nodeType || "OptionalMemberExpression" === nodeType || "PipelinePrimaryTopicReference" === nodeType || "OptionalCallExpression" === nodeType || "Import" === nodeType || "DoExpression" === nodeType || "BigIntLiteral" === nodeType || "TSAsExpression" === nodeType || "TSTypeAssertion" === nodeType || "TSNonNullExpression" === nodeType || nodeType === "Placeholder" && ("Expression" === node.expectedNode || "Identifier" === node.expectedNode || "StringLiteral" === node.expectedNode)) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isBinary(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Binary" || "BinaryExpression" === nodeType || "LogicalExpression" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isScopable(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Scopable" || "BlockStatement" === nodeType || "CatchClause" === nodeType || "DoWhileStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "Program" === nodeType || "ObjectMethod" === nodeType || "SwitchStatement" === nodeType || "WhileStatement" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassExpression" === nodeType || "ClassDeclaration" === nodeType || "ForOfStatement" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType || "TSModuleBlock" === nodeType || nodeType === "Placeholder" && "BlockStatement" === node.expectedNode) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isBlockParent(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "BlockParent" || "BlockStatement" === nodeType || "CatchClause" === nodeType || "DoWhileStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "Program" === nodeType || "ObjectMethod" === nodeType || "SwitchStatement" === nodeType || "WhileStatement" === nodeType || "ArrowFunctionExpression" === nodeType || "ForOfStatement" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType || "TSModuleBlock" === nodeType || nodeType === "Placeholder" && "BlockStatement" === node.expectedNode) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isBlock(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Block" || "BlockStatement" === nodeType || "Program" === nodeType || "TSModuleBlock" === nodeType || nodeType === "Placeholder" && "BlockStatement" === node.expectedNode) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isStatement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Statement" || "BlockStatement" === nodeType || "BreakStatement" === nodeType || "ContinueStatement" === nodeType || "DebuggerStatement" === nodeType || "DoWhileStatement" === nodeType || "EmptyStatement" === nodeType || "ExpressionStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "FunctionDeclaration" === nodeType || "IfStatement" === nodeType || "LabeledStatement" === nodeType || "ReturnStatement" === nodeType || "SwitchStatement" === nodeType || "ThrowStatement" === nodeType || "TryStatement" === nodeType || "VariableDeclaration" === nodeType || "WhileStatement" === nodeType || "WithStatement" === nodeType || "ClassDeclaration" === nodeType || "ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType || "ForOfStatement" === nodeType || "ImportDeclaration" === nodeType || "DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "InterfaceDeclaration" === nodeType || "OpaqueType" === nodeType || "TypeAlias" === nodeType || "TSDeclareFunction" === nodeType || "TSInterfaceDeclaration" === nodeType || "TSTypeAliasDeclaration" === nodeType || "TSEnumDeclaration" === nodeType || "TSModuleDeclaration" === nodeType || "TSImportEqualsDeclaration" === nodeType || "TSExportAssignment" === nodeType || "TSNamespaceExportDeclaration" === nodeType || nodeType === "Placeholder" && ("Statement" === node.expectedNode || "Declaration" === node.expectedNode || "BlockStatement" === node.expectedNode)) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTerminatorless(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Terminatorless" || "BreakStatement" === nodeType || "ContinueStatement" === nodeType || "ReturnStatement" === nodeType || "ThrowStatement" === nodeType || "YieldExpression" === nodeType || "AwaitExpression" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isCompletionStatement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "CompletionStatement" || "BreakStatement" === nodeType || "ContinueStatement" === nodeType || "ReturnStatement" === nodeType || "ThrowStatement" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isConditional(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Conditional" || "ConditionalExpression" === nodeType || "IfStatement" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isLoop(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Loop" || "DoWhileStatement" === nodeType || "ForInStatement" === nodeType || "ForStatement" === nodeType || "WhileStatement" === nodeType || "ForOfStatement" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isWhile(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "While" || "DoWhileStatement" === nodeType || "WhileStatement" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isExpressionWrapper(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ExpressionWrapper" || "ExpressionStatement" === nodeType || "ParenthesizedExpression" === nodeType || "TypeCastExpression" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isFor(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "For" || "ForInStatement" === nodeType || "ForStatement" === nodeType || "ForOfStatement" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isForXStatement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ForXStatement" || "ForInStatement" === nodeType || "ForOfStatement" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isFunction(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Function" || "FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "ObjectMethod" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isFunctionParent(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "FunctionParent" || "FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "ObjectMethod" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isPureish(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Pureish" || "FunctionDeclaration" === nodeType || "FunctionExpression" === nodeType || "StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "ArrowFunctionExpression" === nodeType || "ClassExpression" === nodeType || "ClassDeclaration" === nodeType || "BigIntLiteral" === nodeType || nodeType === "Placeholder" && "StringLiteral" === node.expectedNode) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Declaration" || "FunctionDeclaration" === nodeType || "VariableDeclaration" === nodeType || "ClassDeclaration" === nodeType || "ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType || "ImportDeclaration" === nodeType || "DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "InterfaceDeclaration" === nodeType || "OpaqueType" === nodeType || "TypeAlias" === nodeType || "EnumDeclaration" === nodeType || "TSDeclareFunction" === nodeType || "TSInterfaceDeclaration" === nodeType || "TSTypeAliasDeclaration" === nodeType || "TSEnumDeclaration" === nodeType || "TSModuleDeclaration" === nodeType || nodeType === "Placeholder" && "Declaration" === node.expectedNode) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isPatternLike(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "PatternLike" || "Identifier" === nodeType || "RestElement" === nodeType || "AssignmentPattern" === nodeType || "ArrayPattern" === nodeType || "ObjectPattern" === nodeType || nodeType === "Placeholder" && ("Pattern" === node.expectedNode || "Identifier" === node.expectedNode)) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isLVal(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "LVal" || "Identifier" === nodeType || "MemberExpression" === nodeType || "RestElement" === nodeType || "AssignmentPattern" === nodeType || "ArrayPattern" === nodeType || "ObjectPattern" === nodeType || "TSParameterProperty" === nodeType || nodeType === "Placeholder" && ("Pattern" === node.expectedNode || "Identifier" === node.expectedNode)) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSEntityName(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSEntityName" || "Identifier" === nodeType || "TSQualifiedName" === nodeType || nodeType === "Placeholder" && "Identifier" === node.expectedNode) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isLiteral(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Literal" || "StringLiteral" === nodeType || "NumericLiteral" === nodeType || "NullLiteral" === nodeType || "BooleanLiteral" === nodeType || "RegExpLiteral" === nodeType || "TemplateLiteral" === nodeType || "BigIntLiteral" === nodeType || nodeType === "Placeholder" && "StringLiteral" === node.expectedNode) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isUserWhitespacable(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "UserWhitespacable" || "ObjectMethod" === nodeType || "ObjectProperty" === nodeType || "ObjectTypeInternalSlot" === nodeType || "ObjectTypeCallProperty" === nodeType || "ObjectTypeIndexer" === nodeType || "ObjectTypeProperty" === nodeType || "ObjectTypeSpreadProperty" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isMethod(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Method" || "ObjectMethod" === nodeType || "ClassMethod" === nodeType || "ClassPrivateMethod" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isObjectMember(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ObjectMember" || "ObjectMethod" === nodeType || "ObjectProperty" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isProperty(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Property" || "ObjectProperty" === nodeType || "ClassProperty" === nodeType || "ClassPrivateProperty" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isUnaryLike(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "UnaryLike" || "UnaryExpression" === nodeType || "SpreadElement" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isPattern(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Pattern" || "AssignmentPattern" === nodeType || "ArrayPattern" === nodeType || "ObjectPattern" === nodeType || nodeType === "Placeholder" && "Pattern" === node.expectedNode) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isClass(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Class" || "ClassExpression" === nodeType || "ClassDeclaration" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isModuleDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ModuleDeclaration" || "ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType || "ImportDeclaration" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isExportDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ExportDeclaration" || "ExportAllDeclaration" === nodeType || "ExportDefaultDeclaration" === nodeType || "ExportNamedDeclaration" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isModuleSpecifier(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "ModuleSpecifier" || "ExportSpecifier" === nodeType || "ImportDefaultSpecifier" === nodeType || "ImportNamespaceSpecifier" === nodeType || "ImportSpecifier" === nodeType || "ExportDefaultSpecifier" === nodeType || "ExportNamespaceSpecifier" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isFlow(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Flow" || "AnyTypeAnnotation" === nodeType || "ArrayTypeAnnotation" === nodeType || "BooleanTypeAnnotation" === nodeType || "BooleanLiteralTypeAnnotation" === nodeType || "NullLiteralTypeAnnotation" === nodeType || "ClassImplements" === nodeType || "DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "DeclaredPredicate" === nodeType || "ExistsTypeAnnotation" === nodeType || "FunctionTypeAnnotation" === nodeType || "FunctionTypeParam" === nodeType || "GenericTypeAnnotation" === nodeType || "InferredPredicate" === nodeType || "InterfaceExtends" === nodeType || "InterfaceDeclaration" === nodeType || "InterfaceTypeAnnotation" === nodeType || "IntersectionTypeAnnotation" === nodeType || "MixedTypeAnnotation" === nodeType || "EmptyTypeAnnotation" === nodeType || "NullableTypeAnnotation" === nodeType || "NumberLiteralTypeAnnotation" === nodeType || "NumberTypeAnnotation" === nodeType || "ObjectTypeAnnotation" === nodeType || "ObjectTypeInternalSlot" === nodeType || "ObjectTypeCallProperty" === nodeType || "ObjectTypeIndexer" === nodeType || "ObjectTypeProperty" === nodeType || "ObjectTypeSpreadProperty" === nodeType || "OpaqueType" === nodeType || "QualifiedTypeIdentifier" === nodeType || "StringLiteralTypeAnnotation" === nodeType || "StringTypeAnnotation" === nodeType || "ThisTypeAnnotation" === nodeType || "TupleTypeAnnotation" === nodeType || "TypeofTypeAnnotation" === nodeType || "TypeAlias" === nodeType || "TypeAnnotation" === nodeType || "TypeCastExpression" === nodeType || "TypeParameter" === nodeType || "TypeParameterDeclaration" === nodeType || "TypeParameterInstantiation" === nodeType || "UnionTypeAnnotation" === nodeType || "Variance" === nodeType || "VoidTypeAnnotation" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isFlowType(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "FlowType" || "AnyTypeAnnotation" === nodeType || "ArrayTypeAnnotation" === nodeType || "BooleanTypeAnnotation" === nodeType || "BooleanLiteralTypeAnnotation" === nodeType || "NullLiteralTypeAnnotation" === nodeType || "ExistsTypeAnnotation" === nodeType || "FunctionTypeAnnotation" === nodeType || "GenericTypeAnnotation" === nodeType || "InterfaceTypeAnnotation" === nodeType || "IntersectionTypeAnnotation" === nodeType || "MixedTypeAnnotation" === nodeType || "EmptyTypeAnnotation" === nodeType || "NullableTypeAnnotation" === nodeType || "NumberLiteralTypeAnnotation" === nodeType || "NumberTypeAnnotation" === nodeType || "ObjectTypeAnnotation" === nodeType || "StringLiteralTypeAnnotation" === nodeType || "StringTypeAnnotation" === nodeType || "ThisTypeAnnotation" === nodeType || "TupleTypeAnnotation" === nodeType || "TypeofTypeAnnotation" === nodeType || "UnionTypeAnnotation" === nodeType || "VoidTypeAnnotation" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isFlowBaseAnnotation(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "FlowBaseAnnotation" || "AnyTypeAnnotation" === nodeType || "BooleanTypeAnnotation" === nodeType || "NullLiteralTypeAnnotation" === nodeType || "MixedTypeAnnotation" === nodeType || "EmptyTypeAnnotation" === nodeType || "NumberTypeAnnotation" === nodeType || "StringTypeAnnotation" === nodeType || "ThisTypeAnnotation" === nodeType || "VoidTypeAnnotation" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isFlowDeclaration(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "FlowDeclaration" || "DeclareClass" === nodeType || "DeclareFunction" === nodeType || "DeclareInterface" === nodeType || "DeclareModule" === nodeType || "DeclareModuleExports" === nodeType || "DeclareTypeAlias" === nodeType || "DeclareOpaqueType" === nodeType || "DeclareVariable" === nodeType || "DeclareExportDeclaration" === nodeType || "DeclareExportAllDeclaration" === nodeType || "InterfaceDeclaration" === nodeType || "OpaqueType" === nodeType || "TypeAlias" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isFlowPredicate(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "FlowPredicate" || "DeclaredPredicate" === nodeType || "InferredPredicate" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isEnumBody(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "EnumBody" || "EnumBooleanBody" === nodeType || "EnumNumberBody" === nodeType || "EnumStringBody" === nodeType || "EnumSymbolBody" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isEnumMember(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "EnumMember" || "EnumBooleanMember" === nodeType || "EnumNumberMember" === nodeType || "EnumStringMember" === nodeType || "EnumDefaultedMember" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isJSX(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "JSX" || "JSXAttribute" === nodeType || "JSXClosingElement" === nodeType || "JSXElement" === nodeType || "JSXEmptyExpression" === nodeType || "JSXExpressionContainer" === nodeType || "JSXSpreadChild" === nodeType || "JSXIdentifier" === nodeType || "JSXMemberExpression" === nodeType || "JSXNamespacedName" === nodeType || "JSXOpeningElement" === nodeType || "JSXSpreadAttribute" === nodeType || "JSXText" === nodeType || "JSXFragment" === nodeType || "JSXOpeningFragment" === nodeType || "JSXClosingFragment" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isPrivate(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "Private" || "ClassPrivateProperty" === nodeType || "ClassPrivateMethod" === nodeType || "PrivateName" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSTypeElement(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSTypeElement" || "TSCallSignatureDeclaration" === nodeType || "TSConstructSignatureDeclaration" === nodeType || "TSPropertySignature" === nodeType || "TSMethodSignature" === nodeType || "TSIndexSignature" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isTSType(node, opts) { if (!node) return false; var nodeType = node.type; if (nodeType === "TSType" || "TSAnyKeyword" === nodeType || "TSBooleanKeyword" === nodeType || "TSBigIntKeyword" === nodeType || "TSNeverKeyword" === nodeType || "TSNullKeyword" === nodeType || "TSNumberKeyword" === nodeType || "TSObjectKeyword" === nodeType || "TSStringKeyword" === nodeType || "TSSymbolKeyword" === nodeType || "TSUndefinedKeyword" === nodeType || "TSUnknownKeyword" === nodeType || "TSVoidKeyword" === nodeType || "TSThisType" === nodeType || "TSFunctionType" === nodeType || "TSConstructorType" === nodeType || "TSTypeReference" === nodeType || "TSTypePredicate" === nodeType || "TSTypeQuery" === nodeType || "TSTypeLiteral" === nodeType || "TSArrayType" === nodeType || "TSTupleType" === nodeType || "TSOptionalType" === nodeType || "TSRestType" === nodeType || "TSUnionType" === nodeType || "TSIntersectionType" === nodeType || "TSConditionalType" === nodeType || "TSInferType" === nodeType || "TSParenthesizedType" === nodeType || "TSTypeOperator" === nodeType || "TSIndexedAccessType" === nodeType || "TSMappedType" === nodeType || "TSLiteralType" === nodeType || "TSExpressionWithTypeArguments" === nodeType || "TSImportType" === nodeType) { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isNumberLiteral(node, opts) { console.trace("The node type NumberLiteral has been renamed to NumericLiteral"); if (!node) return false; var nodeType = node.type; if (nodeType === "NumberLiteral") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isRegexLiteral(node, opts) { console.trace("The node type RegexLiteral has been renamed to RegExpLiteral"); if (!node) return false; var nodeType = node.type; if (nodeType === "RegexLiteral") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isRestProperty(node, opts) { console.trace("The node type RestProperty has been renamed to RestElement"); if (!node) return false; var nodeType = node.type; if (nodeType === "RestProperty") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function isSpreadProperty(node, opts) { console.trace("The node type SpreadProperty has been renamed to SpreadElement"); if (!node) return false; var nodeType = node.type; if (nodeType === "SpreadProperty") { if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } return false; } function matchesPattern(member, match, allowPartial) { if (!isMemberExpression(member)) return false; var parts = Array.isArray(match) ? match : match.split("."); var nodes = []; var node; for (node = member; isMemberExpression(node); node = node.object) { nodes.push(node.property); } nodes.push(node); if (nodes.length < parts.length) return false; if (!allowPartial && nodes.length > parts.length) return false; for (var i = 0, j = nodes.length - 1; i < parts.length; i++, j--) { var _node = nodes[j]; var value = void 0; if (isIdentifier(_node)) { value = _node.name; } else if (isStringLiteral(_node)) { value = _node.value; } else { return false; } if (parts[i] !== value) return false; } return true; } function buildMatchMemberExpression(match, allowPartial) { var parts = match.split("."); return function (member) { return matchesPattern(member, parts, allowPartial); }; } var isReactComponent = buildMatchMemberExpression("React.Component"); function isCompatTag(tagName) { return !!tagName && /^[a-z]/.test(tagName); } function listCacheClear() { this.__data__ = []; this.size = 0; } var _listCacheClear = listCacheClear; function eq(value, other) { return value === other || value !== value && other !== other; } var eq_1 = eq; function assocIndexOf(array, key) { var length = array.length; while (length--) { if (eq_1(array[length][0], key)) { return length; } } return -1; } var _assocIndexOf = assocIndexOf; var arrayProto = Array.prototype; var splice = arrayProto.splice; function listCacheDelete(key) { var data = this.__data__, index = _assocIndexOf(data, key); if (index < 0) { return false; } var lastIndex = data.length - 1; if (index == lastIndex) { data.pop(); } else { splice.call(data, index, 1); } --this.size; return true; } var _listCacheDelete = listCacheDelete; function listCacheGet(key) { var data = this.__data__, index = _assocIndexOf(data, key); return index < 0 ? undefined : data[index][1]; } var _listCacheGet = listCacheGet; function listCacheHas(key) { return _assocIndexOf(this.__data__, key) > -1; } var _listCacheHas = listCacheHas; function listCacheSet(key, value) { var data = this.__data__, index = _assocIndexOf(data, key); if (index < 0) { ++this.size; data.push([key, value]); } else { data[index][1] = value; } return this; } var _listCacheSet = listCacheSet; function ListCache(entries) { var index = -1, length = entries == null ? 0 : entries.length; this.clear(); while (++index < length) { var entry = entries[index]; this.set(entry[0], entry[1]); } } ListCache.prototype.clear = _listCacheClear; ListCache.prototype['delete'] = _listCacheDelete; ListCache.prototype.get = _listCacheGet; ListCache.prototype.has = _listCacheHas; ListCache.prototype.set = _listCacheSet; var _ListCache = ListCache; function stackClear() { this.__data__ = new _ListCache(); this.size = 0; } var _stackClear = stackClear; function stackDelete(key) { var data = this.__data__, result = data['delete'](key); this.size = data.size; return result; } var _stackDelete = stackDelete; function stackGet(key) { return this.__data__.get(key); } var _stackGet = stackGet; function stackHas(key) { return this.__data__.has(key); } var _stackHas = stackHas; var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {}; function commonjsRequire () { throw new Error('Dynamic requires are not currently supported by rollup-plugin-commonjs'); } function unwrapExports (x) { return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x; } function createCommonjsModule(fn, module) { return module = { exports: {} }, fn(module, module.exports), module.exports; } function getCjsExportFromNamespace (n) { return n && n['default'] || n; } var freeGlobal = typeof commonjsGlobal == 'object' && commonjsGlobal && commonjsGlobal.Object === Object && commonjsGlobal; var _freeGlobal = freeGlobal; var freeSelf = typeof self == 'object' && self && self.Object === Object && self; var root = _freeGlobal || freeSelf || Function('return this')(); var _root = root; var Symbol$1 = _root.Symbol; var _Symbol = Symbol$1; var objectProto = Object.prototype; var hasOwnProperty = objectProto.hasOwnProperty; var nativeObjectToString = objectProto.toString; var symToStringTag = _Symbol ? _Symbol.toStringTag : undefined; function getRawTag(value) { var isOwn = hasOwnProperty.call(value, symToStringTag), tag = value[symToStringTag]; try { value[symToStringTag] = undefined; var unmasked = true; } catch (e) {} var result = nativeObjectToString.call(value); if (unmasked) { if (isOwn) { value[symToStringTag] = tag; } else { delete value[symToStringTag]; } } return result; } var _getRawTag = getRawTag; var objectProto$1 = Object.prototype; var nativeObjectToString$1 = objectProto$1.toString; function objectToString(value) { return nativeObjectToString$1.call(value); } var _objectToString = objectToString; var nullTag = '[object Null]', undefinedTag = '[object Undefined]'; var symToStringTag$1 = _Symbol ? _Symbol.toStringTag : undefined; function baseGetTag(value) { if (value == null) { return value === undefined ? undefinedTag : nullTag; } return symToStringTag$1 && symToStringTag$1 in Object(value) ? _getRawTag(value) : _objectToString(value); } var _baseGetTag = baseGetTag; function isObject(value) { var type = typeof value; return value != null && (type == 'object' || type == 'function'); } var isObject_1 = isObject; var asyncTag = '[object AsyncFunction]', funcTag = '[object Function]', genTag = '[object GeneratorFunction]', proxyTag = '[object Proxy]'; function isFunction$1(value) { if (!isObject_1(value)) { return false; } var tag = _baseGetTag(value); return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag; } var isFunction_1 = isFunction$1; var coreJsData = _root['__core-js_shared__']; var _coreJsData = coreJsData; var maskSrcKey = function () { var uid = /[^.]+$/.exec(_coreJsData && _coreJsData.keys && _coreJsData.keys.IE_PROTO || ''); return uid ? 'Symbol(src)_1.' + uid : ''; }(); function isMasked(func) { return !!maskSrcKey && maskSrcKey in func; } var _isMasked = isMasked; var funcProto = Function.prototype; var funcToString = funcProto.toString; function toSource(func) { if (func != null) { try { return funcToString.call(func); } catch (e) {} try { return func + ''; } catch (e) {} } return ''; } var _toSource = toSource; var reRegExpChar = /[\\^$.*+?()[\]{}|]/g; var reIsHostCtor = /^\[object .+?Constructor\]$/; var funcProto$1 = Function.prototype, objectProto$2 = Object.prototype; var funcToString$1 = funcProto$1.toString; var hasOwnProperty$1 = objectProto$2.hasOwnProperty; var reIsNative = RegExp('^' + funcToString$1.call(hasOwnProperty$1).replace(reRegExpChar, '\\$&').replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$'); function baseIsNative(value) { if (!isObject_1(value) || _isMasked(value)) { return false; } var pattern = isFunction_1(value) ? reIsNative : reIsHostCtor; return pattern.test(_toSource(value)); } var _baseIsNative = baseIsNative; function getValue(object, key) { return object == null ? undefined : object[key]; } var _getValue = getValue; function getNative(object, key) { var value = _getValue(object, key); return _baseIsNative(value) ? value : undefined; } var _getNative = getNative; var Map$1 = _getNative(_root, 'Map'); var _Map = Map$1; var nativeCreate = _getNative(Object, 'create'); var _nativeCreate = nativeCreate; function hashClear() { this.__data__ = _nativeCreate ? _nativeCreate(null) : {}; this.size = 0; } var _hashClear = hashClear; function hashDelete(key) { var result = this.has(key) && delete this.__data__[key]; this.size -= result ? 1 : 0; return result; } var _hashDelete = hashDelete; var HASH_UNDEFINED = '__lodash_hash_undefined__'; var objectProto$3 = Object.prototype; var hasOwnProperty$2 = objectProto$3.hasOwnProperty; function hashGet(key) { var data = this.__data__; if (_nativeCreate) { var result = data[key]; return result === HASH_UNDEFINED ? undefined : result; } return hasOwnProperty$2.call(data, key) ? data[key] : undefined; } var _hashGet = hashGet; var objectProto$4 = Object.prototype; var hasOwnProperty$3 = objectProto$4.hasOwnProperty; function hashHas(key) { var data = this.__data__; return _nativeCreate ? data[key] !== undefined : hasOwnProperty$3.call(data, key); } var _hashHas = hashHas; var HASH_UNDEFINED$1 = '__lodash_hash_undefined__'; function hashSet(key, value) { var data = this.__data__; this.size += this.has(key) ? 0 : 1; data[key] = _nativeCreate && value === undefined ? HASH_UNDEFINED$1 : value; return this; } var _hashSet = hashSet; function Hash(entries) { var index = -1, length = entries == null ? 0 : entries.length; this.clear(); while (++index < length) { var entry = entries[index]; this.set(entry[0], entry[1]); } } Hash.prototype.clear = _hashClear; Hash.prototype['delete'] = _hashDelete; Hash.prototype.get = _hashGet; Hash.prototype.has = _hashHas; Hash.prototype.set = _hashSet; var _Hash = Hash; function mapCacheClear() { this.size = 0; this.__data__ = { 'hash': new _Hash(), 'map': new (_Map || _ListCache)(), 'string': new _Hash() }; } var _mapCacheClear = mapCacheClear; function isKeyable(value) { var type = typeof value; return type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean' ? value !== '__proto__' : value === null; } var _isKeyable = isKeyable; function getMapData(map, key) { var data = map.__data__; return _isKeyable(key) ? data[typeof key == 'string' ? 'string' : 'hash'] : data.map; } var _getMapData = getMapData; function mapCacheDelete(key) { var result = _getMapData(this, key)['delete'](key); this.size -= result ? 1 : 0; return result; } var _mapCacheDelete = mapCacheDelete; function mapCacheGet(key) { return _getMapData(this, key).get(key); } var _mapCacheGet = mapCacheGet; function mapCacheHas(key) { return _getMapData(this, key).has(key); } var _mapCacheHas = mapCacheHas; function mapCacheSet(key, value) { var data = _getMapData(this, key), size = data.size; data.set(key, value); this.size += data.size == size ? 0 : 1; return this; } var _mapCacheSet = mapCacheSet; function MapCache(entries) { var index = -1, length = entries == null ? 0 : entries.length; this.clear(); while (++index < length) { var entry = entries[index]; this.set(entry[0], entry[1]); } } MapCache.prototype.clear = _mapCacheClear; MapCache.prototype['delete'] = _mapCacheDelete; MapCache.prototype.get = _mapCacheGet; MapCache.prototype.has = _mapCacheHas; MapCache.prototype.set = _mapCacheSet; var _MapCache = MapCache; var LARGE_ARRAY_SIZE = 200; function stackSet(key, value) { var data = this.__data__; if (data instanceof _ListCache) { var pairs = data.__data__; if (!_Map || pairs.length < LARGE_ARRAY_SIZE - 1) { pairs.push([key, value]); this.size = ++data.size; return this; } data = this.__data__ = new _MapCache(pairs); } data.set(key, value); this.size = data.size; return this; } var _stackSet = stackSet; function Stack(entries) { var data = this.__data__ = new _ListCache(entries); this.size = data.size; } Stack.prototype.clear = _stackClear; Stack.prototype['delete'] = _stackDelete; Stack.prototype.get = _stackGet; Stack.prototype.has = _stackHas; Stack.prototype.set = _stackSet; var _Stack = Stack; function arrayEach(array, iteratee) { var index = -1, length = array == null ? 0 : array.length; while (++index < length) { if (iteratee(array[index], index, array) === false) { break; } } return array; } var _arrayEach = arrayEach; var defineProperty = function () { try { var func = _getNative(Object, 'defineProperty'); func({}, '', {}); return func; } catch (e) {} }(); var _defineProperty = defineProperty; function baseAssignValue(object, key, value) { if (key == '__proto__' && _defineProperty) { _defineProperty(object, key, { 'configurable': true, 'enumerable': true, 'value': value, 'writable': true }); } else { object[key] = value; } } var _baseAssignValue = baseAssignValue; var objectProto$5 = Object.prototype; var hasOwnProperty$4 = objectProto$5.hasOwnProperty; function assignValue(object, key, value) { var objValue = object[key]; if (!(hasOwnProperty$4.call(object, key) && eq_1(objValue, value)) || value === undefined && !(key in object)) { _baseAssignValue(object, key, value); } } var _assignValue = assignValue; function copyObject(source, props, object, customizer) { var isNew = !object; object || (object = {}); var index = -1, length = props.length; while (++index < length) { var key = props[index]; var newValue = customizer ? customizer(object[key], source[key], key, object, source) : undefined; if (newValue === undefined) { newValue = source[key]; } if (isNew) { _baseAssignValue(object, key, newValue); } else { _assignValue(object, key, newValue); } } return object; } var _copyObject = copyObject; function baseTimes(n, iteratee) { var index = -1, result = Array(n); while (++index < n) { result[index] = iteratee(index); } return result; } var _baseTimes = baseTimes; function isObjectLike(value) { return value != null && typeof value == 'object'; } var isObjectLike_1 = isObjectLike; var argsTag = '[object Arguments]'; function baseIsArguments(value) { return isObjectLike_1(value) && _baseGetTag(value) == argsTag; } var _baseIsArguments = baseIsArguments; var objectProto$6 = Object.prototype; var hasOwnProperty$5 = objectProto$6.hasOwnProperty; var propertyIsEnumerable = objectProto$6.propertyIsEnumerable; var isArguments = _baseIsArguments(function () { return arguments; }()) ? _baseIsArguments : function (value) { return isObjectLike_1(value) && hasOwnProperty$5.call(value, 'callee') && !propertyIsEnumerable.call(value, 'callee'); }; var isArguments_1 = isArguments; var isArray = Array.isArray; var isArray_1 = isArray; function stubFalse() { return false; } var stubFalse_1 = stubFalse; var isBuffer_1 = createCommonjsModule(function (module, exports) { var freeExports = exports && !exports.nodeType && exports; var freeModule = freeExports && 'object' == 'object' && module && !module.nodeType && module; var moduleExports = freeModule && freeModule.exports === freeExports; var Buffer = moduleExports ? _root.Buffer : undefined; var nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined; var isBuffer = nativeIsBuffer || stubFalse_1; module.exports = isBuffer; }); var MAX_SAFE_INTEGER = 9007199254740991; var reIsUint = /^(?:0|[1-9]\d*)$/; function isIndex(value, length) { var type = typeof value; length = length == null ? MAX_SAFE_INTEGER : length; return !!length && (type == 'number' || type != 'symbol' && reIsUint.test(value)) && value > -1 && value % 1 == 0 && value < length; } var _isIndex = isIndex; var MAX_SAFE_INTEGER$1 = 9007199254740991; function isLength(value) { return typeof value == 'number' && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER$1; } var isLength_1 = isLength; var argsTag$1 = '[object Arguments]', arrayTag = '[object Array]', boolTag = '[object Boolean]', dateTag = '[object Date]', errorTag = '[object Error]', funcTag$1 = '[object Function]', mapTag = '[object Map]', numberTag = '[object Number]', objectTag = '[object Object]', regexpTag = '[object RegExp]', setTag = '[object Set]', stringTag = '[object String]', weakMapTag = '[object WeakMap]'; var arrayBufferTag = '[object ArrayBuffer]', dataViewTag = '[object DataView]', float32Tag = '[object Float32Array]', float64Tag = '[object Float64Array]', int8Tag = '[object Int8Array]', int16Tag = '[object Int16Array]', int32Tag = '[object Int32Array]', uint8Tag = '[object Uint8Array]', uint8ClampedTag = '[object Uint8ClampedArray]', uint16Tag = '[object Uint16Array]', uint32Tag = '[object Uint32Array]'; var typedArrayTags = {}; typedArrayTags[float32Tag] = typedArrayTags[float64Tag] = typedArrayTags[int8Tag] = typedArrayTags[int16Tag] = typedArrayTags[int32Tag] = typedArrayTags[uint8Tag] = typedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] = typedArrayTags[uint32Tag] = true; typedArrayTags[argsTag$1] = typedArrayTags[arrayTag] = typedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] = typedArrayTags[dataViewTag] = typedArrayTags[dateTag] = typedArrayTags[errorTag] = typedArrayTags[funcTag$1] = typedArrayTags[mapTag] = typedArrayTags[numberTag] = typedArrayTags[objectTag] = typedArrayTags[regexpTag] = typedArrayTags[setTag] = typedArrayTags[stringTag] = typedArrayTags[weakMapTag] = false; function baseIsTypedArray(value) { return isObjectLike_1(value) && isLength_1(value.length) && !!typedArrayTags[_baseGetTag(value)]; } var _baseIsTypedArray = baseIsTypedArray; function baseUnary(func) { return function (value) { return func(value); }; } var _baseUnary = baseUnary; var _nodeUtil = createCommonjsModule(function (module, exports) { var freeExports = exports && !exports.nodeType && exports; var freeModule = freeExports && 'object' == 'object' && module && !module.nodeType && module; var moduleExports = freeModule && freeModule.exports === freeExports; var freeProcess = moduleExports && _freeGlobal.process; var nodeUtil = function () { try { var types = freeModule && freeModule.require && freeModule.require('util').types; if (types) { return types; } return freeProcess && freeProcess.binding && freeProcess.binding('util'); } catch (e) {} }(); module.exports = nodeUtil; }); var nodeIsTypedArray = _nodeUtil && _nodeUtil.isTypedArray; var isTypedArray = nodeIsTypedArray ? _baseUnary(nodeIsTypedArray) : _baseIsTypedArray; var isTypedArray_1 = isTypedArray; var objectProto$7 = Object.prototype; var hasOwnProperty$6 = objectProto$7.hasOwnProperty; function arrayLikeKeys(value, inherited) { var isArr = isArray_1(value), isArg = !isArr && isArguments_1(value), isBuff = !isArr && !isArg && isBuffer_1(value), isType = !isArr && !isArg && !isBuff && isTypedArray_1(value), skipIndexes = isArr || isArg || isBuff || isType, result = skipIndexes ? _baseTimes(value.length, String) : [], length = result.length; for (var key in value) { if ((inherited || hasOwnProperty$6.call(value, key)) && !(skipIndexes && (key == 'length' || isBuff && (key == 'offset' || key == 'parent') || isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset') || _isIndex(key, length)))) { result.push(key); } } return result; } var _arrayLikeKeys = arrayLikeKeys; var objectProto$8 = Object.prototype; function isPrototype(value) { var Ctor = value && value.constructor, proto = typeof Ctor == 'function' && Ctor.prototype || objectProto$8; return value === proto; } var _isPrototype = isPrototype; function overArg(func, transform) { return function (arg) { return func(transform(arg)); }; } var _overArg = overArg; var nativeKeys = _overArg(Object.keys, Object); var _nativeKeys = nativeKeys; var objectProto$9 = Object.prototype; var hasOwnProperty$7 = objectProto$9.hasOwnProperty; function baseKeys(object) { if (!_isPrototype(object)) { return _nativeKeys(object); } var result = []; for (var key in Object(object)) { if (hasOwnProperty$7.call(object, key) && key != 'constructor') { result.push(key); } } return result; } var _baseKeys = baseKeys; function isArrayLike(value) { return value != null && isLength_1(value.length) && !isFunction_1(value); } var isArrayLike_1 = isArrayLike; function keys(object) { return isArrayLike_1(object) ? _arrayLikeKeys(object) : _baseKeys(object); } var keys_1 = keys; function baseAssign(object, source) { return object && _copyObject(source, keys_1(source), object); } var _baseAssign = baseAssign; function nativeKeysIn(object) { var result = []; if (object != null) { for (var key in Object(object)) { result.push(key); } } return result; } var _nativeKeysIn = nativeKeysIn; var objectProto$a = Object.prototype; var hasOwnProperty$8 = objectProto$a.hasOwnProperty; function baseKeysIn(object) { if (!isObject_1(object)) { return _nativeKeysIn(object); } var isProto = _isPrototype(object), result = []; for (var key in object) { if (!(key == 'constructor' && (isProto || !hasOwnProperty$8.call(object, key)))) { result.push(key); } } return result; } var _baseKeysIn = baseKeysIn; function keysIn$1(object) { return isArrayLike_1(object) ? _arrayLikeKeys(object, true) : _baseKeysIn(object); } var keysIn_1 = keysIn$1; function baseAssignIn(object, source) { return object && _copyObject(source, keysIn_1(source), object); } var _baseAssignIn = baseAssignIn; var _cloneBuffer = createCommonjsModule(function (module, exports) { var freeExports = exports && !exports.nodeType && exports; var freeModule = freeExports && 'object' == 'object' && module && !module.nodeType && module; var moduleExports = freeModule && freeModule.exports === freeExports; var Buffer = moduleExports ? _root.Buffer : undefined, allocUnsafe = Buffer ? Buffer.allocUnsafe : undefined; function cloneBuffer(buffer, isDeep) { if (isDeep) { return buffer.slice(); } var length = buffer.length, result = allocUnsafe ? allocUnsafe(length) : new buffer.constructor(length); buffer.copy(result); return result; } module.exports = cloneBuffer; }); function copyArray(source, array) { var index = -1, length = source.length; array || (array = Array(length)); while (++index < length) { array[index] = source[index]; } return array; } var _copyArray = copyArray; function arrayFilter(array, predicate) { var index = -1, length = array == null ? 0 : array.length, resIndex = 0, result = []; while (++index < length) { var value = array[index]; if (predicate(value, index, array)) { result[resIndex++] = value; } } return result; } var _arrayFilter = arrayFilter; function stubArray() { return []; } var stubArray_1 = stubArray; var objectProto$b = Object.prototype; var propertyIsEnumerable$1 = objectProto$b.propertyIsEnumerable; var nativeGetSymbols = Object.getOwnPropertySymbols; var getSymbols = !nativeGetSymbols ? stubArray_1 : function (object) { if (object == null) { return []; } object = Object(object); return _arrayFilter(nativeGetSymbols(object), function (symbol) { return propertyIsEnumerable$1.call(object, symbol); }); }; var _getSymbols = getSymbols; function copySymbols(source, object) { return _copyObject(source, _getSymbols(source), object); } var _copySymbols = copySymbols; function arrayPush(array, values) { var index = -1, length = values.length, offset = array.length; while (++index < length) { array[offset + index] = values[index]; } return array; } var _arrayPush = arrayPush; var getPrototype = _overArg(Object.getPrototypeOf, Object); var _getPrototype = getPrototype; var nativeGetSymbols$1 = Object.getOwnPropertySymbols; var getSymbolsIn = !nativeGetSymbols$1 ? stubArray_1 : function (object) { var result = []; while (object) { _arrayPush(result, _getSymbols(object)); object = _getPrototype(object); } return result; }; var _getSymbolsIn = getSymbolsIn; function copySymbolsIn(source, object) { return _copyObject(source, _getSymbolsIn(source), object); } var _copySymbolsIn = copySymbolsIn; function baseGetAllKeys(object, keysFunc, symbolsFunc) { var result = keysFunc(object); return isArray_1(object) ? result : _arrayPush(result, symbolsFunc(object)); } var _baseGetAllKeys = baseGetAllKeys; function getAllKeys(object) { return _baseGetAllKeys(object, keys_1, _getSymbols); } var _getAllKeys = getAllKeys; function getAllKeysIn(object) { return _baseGetAllKeys(object, keysIn_1, _getSymbolsIn); } var _getAllKeysIn = getAllKeysIn; var DataView$1 = _getNative(_root, 'DataView'); var _DataView = DataView$1; var Promise$1 = _getNative(_root, 'Promise'); var _Promise = Promise$1; var Set$1 = _getNative(_root, 'Set'); var _Set = Set$1; var WeakMap$1 = _getNative(_root, 'WeakMap'); var _WeakMap = WeakMap$1; var mapTag$1 = '[object Map]', objectTag$1 = '[object Object]', promiseTag = '[object Promise]', setTag$1 = '[object Set]', weakMapTag$1 = '[object WeakMap]'; var dataViewTag$1 = '[object DataView]'; var dataViewCtorString = _toSource(_DataView), mapCtorString = _toSource(_Map), promiseCtorString = _toSource(_Promise), setCtorString = _toSource(_Set), weakMapCtorString = _toSource(_WeakMap); var getTag = _baseGetTag; if (_DataView && getTag(new _DataView(new ArrayBuffer(1))) != dataViewTag$1 || _Map && getTag(new _Map()) != mapTag$1 || _Promise && getTag(_Promise.resolve()) != promiseTag || _Set && getTag(new _Set()) != setTag$1 || _WeakMap && getTag(new _WeakMap()) != weakMapTag$1) { getTag = function getTag(value) { var result = _baseGetTag(value), Ctor = result == objectTag$1 ? value.constructor : undefined, ctorString = Ctor ? _toSource(Ctor) : ''; if (ctorString) { switch (ctorString) { case dataViewCtorString: return dataViewTag$1; case mapCtorString: return mapTag$1; case promiseCtorString: return promiseTag; case setCtorString: return setTag$1; case weakMapCtorString: return weakMapTag$1; } } return result; }; } var _getTag = getTag; var objectProto$c = Object.prototype; var hasOwnProperty$9 = objectProto$c.hasOwnProperty; function initCloneArray(array) { var length = array.length, result = new array.constructor(length); if (length && typeof array[0] == 'string' && hasOwnProperty$9.call(array, 'index')) { result.index = array.index; result.input = array.input; } return result; } var _initCloneArray = initCloneArray; var Uint8Array$1 = _root.Uint8Array; var _Uint8Array = Uint8Array$1; function cloneArrayBuffer(arrayBuffer) { var result = new arrayBuffer.constructor(arrayBuffer.byteLength); new _Uint8Array(result).set(new _Uint8Array(arrayBuffer)); return result; } var _cloneArrayBuffer = cloneArrayBuffer; function cloneDataView(dataView, isDeep) { var buffer = isDeep ? _cloneArrayBuffer(dataView.buffer) : dataView.buffer; return new dataView.constructor(buffer, dataView.byteOffset, dataView.byteLength); } var _cloneDataView = cloneDataView; var reFlags = /\w*$/; function cloneRegExp(regexp) { var result = new regexp.constructor(regexp.source, reFlags.exec(regexp)); result.lastIndex = regexp.lastIndex; return result; } var _cloneRegExp = cloneRegExp; var symbolProto = _Symbol ? _Symbol.prototype : undefined, symbolValueOf = symbolProto ? symbolProto.valueOf : undefined; function cloneSymbol(symbol) { return symbolValueOf ? Object(symbolValueOf.call(symbol)) : {}; } var _cloneSymbol = cloneSymbol; function cloneTypedArray(typedArray, isDeep) { var buffer = isDeep ? _cloneArrayBuffer(typedArray.buffer) : typedArray.buffer; return new typedArray.constructor(buffer, typedArray.byteOffset, typedArray.length); } var _cloneTypedArray = cloneTypedArray; var boolTag$1 = '[object Boolean]', dateTag$1 = '[object Date]', mapTag$2 = '[object Map]', numberTag$1 = '[object Number]', regexpTag$1 = '[object RegExp]', setTag$2 = '[object Set]', stringTag$1 = '[object String]', symbolTag = '[object Symbol]'; var arrayBufferTag$1 = '[object ArrayBuffer]', dataViewTag$2 = '[object DataView]', float32Tag$1 = '[object Float32Array]', float64Tag$1 = '[object Float64Array]', int8Tag$1 = '[object Int8Array]', int16Tag$1 = '[object Int16Array]', int32Tag$1 = '[object Int32Array]', uint8Tag$1 = '[object Uint8Array]', uint8ClampedTag$1 = '[object Uint8ClampedArray]', uint16Tag$1 = '[object Uint16Array]', uint32Tag$1 = '[object Uint32Array]'; function initCloneByTag(object, tag, isDeep) { var Ctor = object.constructor; switch (tag) { case arrayBufferTag$1: return _cloneArrayBuffer(object); case boolTag$1: case dateTag$1: return new Ctor(+object); case dataViewTag$2: return _cloneDataView(object, isDeep); case float32Tag$1: case float64Tag$1: case int8Tag$1: case int16Tag$1: case int32Tag$1: case uint8Tag$1: case uint8ClampedTag$1: case uint16Tag$1: case uint32Tag$1: return _cloneTypedArray(object, isDeep); case mapTag$2: return new Ctor(); case numberTag$1: case stringTag$1: return new Ctor(object); case regexpTag$1: return _cloneRegExp(object); case setTag$2: return new Ctor(); case symbolTag: return _cloneSymbol(object); } } var _initCloneByTag = initCloneByTag; var objectCreate = Object.create; var baseCreate = function () { function object() {} return function (proto) { if (!isObject_1(proto)) { return {}; } if (objectCreate) { return objectCreate(proto); } object.prototype = proto; var result = new object(); object.prototype = undefined; return result; }; }(); var _baseCreate = baseCreate; function initCloneObject(object) { return typeof object.constructor == 'function' && !_isPrototype(object) ? _baseCreate(_getPrototype(object)) : {}; } var _initCloneObject = initCloneObject; var mapTag$3 = '[object Map]'; function baseIsMap(value) { return isObjectLike_1(value) && _getTag(value) == mapTag$3; } var _baseIsMap = baseIsMap; var nodeIsMap = _nodeUtil && _nodeUtil.isMap; var isMap = nodeIsMap ? _baseUnary(nodeIsMap) : _baseIsMap; var isMap_1 = isMap; var setTag$3 = '[object Set]'; function baseIsSet(value) { return isObjectLike_1(value) && _getTag(value) == setTag$3; } var _baseIsSet = baseIsSet; var nodeIsSet = _nodeUtil && _nodeUtil.isSet; var isSet = nodeIsSet ? _baseUnary(nodeIsSet) : _baseIsSet; var isSet_1 = isSet; var CLONE_DEEP_FLAG = 1, CLONE_FLAT_FLAG = 2, CLONE_SYMBOLS_FLAG = 4; var argsTag$2 = '[object Arguments]', arrayTag$1 = '[object Array]', boolTag$2 = '[object Boolean]', dateTag$2 = '[object Date]', errorTag$1 = '[object Error]', funcTag$2 = '[object Function]', genTag$1 = '[object GeneratorFunction]', mapTag$4 = '[object Map]', numberTag$2 = '[object Number]', objectTag$2 = '[object Object]', regexpTag$2 = '[object RegExp]', setTag$4 = '[object Set]', stringTag$2 = '[object String]', symbolTag$1 = '[object Symbol]', weakMapTag$2 = '[object WeakMap]'; var arrayBufferTag$2 = '[object ArrayBuffer]', dataViewTag$3 = '[object DataView]', float32Tag$2 = '[object Float32Array]', float64Tag$2 = '[object Float64Array]', int8Tag$2 = '[object Int8Array]', int16Tag$2 = '[object Int16Array]', int32Tag$2 = '[object Int32Array]', uint8Tag$2 = '[object Uint8Array]', uint8ClampedTag$2 = '[object Uint8ClampedArray]', uint16Tag$2 = '[object Uint16Array]', uint32Tag$2 = '[object Uint32Array]'; var cloneableTags = {}; cloneableTags[argsTag$2] = cloneableTags[arrayTag$1] = cloneableTags[arrayBufferTag$2] = cloneableTags[dataViewTag$3] = cloneableTags[boolTag$2] = cloneableTags[dateTag$2] = cloneableTags[float32Tag$2] = cloneableTags[float64Tag$2] = cloneableTags[int8Tag$2] = cloneableTags[int16Tag$2] = cloneableTags[int32Tag$2] = cloneableTags[mapTag$4] = cloneableTags[numberTag$2] = cloneableTags[objectTag$2] = cloneableTags[regexpTag$2] = cloneableTags[setTag$4] = cloneableTags[stringTag$2] = cloneableTags[symbolTag$1] = cloneableTags[uint8Tag$2] = cloneableTags[uint8ClampedTag$2] = cloneableTags[uint16Tag$2] = cloneableTags[uint32Tag$2] = true; cloneableTags[errorTag$1] = cloneableTags[funcTag$2] = cloneableTags[weakMapTag$2] = false; function baseClone(value, bitmask, customizer, key, object, stack) { var result, isDeep = bitmask & CLONE_DEEP_FLAG, isFlat = bitmask & CLONE_FLAT_FLAG, isFull = bitmask & CLONE_SYMBOLS_FLAG; if (customizer) { result = object ? customizer(value, key, object, stack) : customizer(value); } if (result !== undefined) { return result; } if (!isObject_1(value)) { return value; } var isArr = isArray_1(value); if (isArr) { result = _initCloneArray(value); if (!isDeep) { return _copyArray(value, result); } } else { var tag = _getTag(value), isFunc = tag == funcTag$2 || tag == genTag$1; if (isBuffer_1(value)) { return _cloneBuffer(value, isDeep); } if (tag == objectTag$2 || tag == argsTag$2 || isFunc && !object) { result = isFlat || isFunc ? {} : _initCloneObject(value); if (!isDeep) { return isFlat ? _copySymbolsIn(value, _baseAssignIn(result, value)) : _copySymbols(value, _baseAssign(result, value)); } } else { if (!cloneableTags[tag]) { return object ? value : {}; } result = _initCloneByTag(value, tag, isDeep); } } stack || (stack = new _Stack()); var stacked = stack.get(value); if (stacked) { return stacked; } stack.set(value, result); if (isSet_1(value)) { value.forEach(function (subValue) { result.add(baseClone(subValue, bitmask, customizer, subValue, value, stack)); }); } else if (isMap_1(value)) { value.forEach(function (subValue, key) { result.set(key, baseClone(subValue, bitmask, customizer, key, value, stack)); }); } var keysFunc = isFull ? isFlat ? _getAllKeysIn : _getAllKeys : isFlat ? keysIn : keys_1; var props = isArr ? undefined : keysFunc(value); _arrayEach(props || value, function (subValue, key) { if (props) { key = subValue; subValue = value[key]; } _assignValue(result, key, baseClone(subValue, bitmask, customizer, key, value, stack)); }); return result; } var _baseClone = baseClone; var CLONE_SYMBOLS_FLAG$1 = 4; function clone(value) { return _baseClone(value, CLONE_SYMBOLS_FLAG$1); } var clone_1 = clone; var fastProto = null; function FastObject(o) { if (fastProto !== null && typeof fastProto.property) { var result = fastProto; fastProto = FastObject.prototype = null; return result; } fastProto = FastObject.prototype = o == null ? Object.create(null) : o; return new FastObject(); } FastObject(); var toFastProperties = function toFastproperties(o) { return FastObject(o); }; var global$1 = typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {}; function defaultSetTimout() { throw new Error('setTimeout has not been defined'); } function defaultClearTimeout() { throw new Error('clearTimeout has not been defined'); } var cachedSetTimeout = defaultSetTimout; var cachedClearTimeout = defaultClearTimeout; if (typeof global$1.setTimeout === 'function') { cachedSetTimeout = setTimeout; } if (typeof global$1.clearTimeout === 'function') { cachedClearTimeout = clearTimeout; } function runTimeout(fun) { if (cachedSetTimeout === setTimeout) { return setTimeout(fun, 0); } if ((cachedSetTimeout === defaultSetTimout || !cachedSetTimeout) && setTimeout) { cachedSetTimeout = setTimeout; return setTimeout(fun, 0); } try { return cachedSetTimeout(fun, 0); } catch (e) { try { return cachedSetTimeout.call(null, fun, 0); } catch (e) { return cachedSetTimeout.call(this, fun, 0); } } } function runClearTimeout(marker) { if (cachedClearTimeout === clearTimeout) { return clearTimeout(marker); } if ((cachedClearTimeout === defaultClearTimeout || !cachedClearTimeout) && clearTimeout) { cachedClearTimeout = clearTimeout; return clearTimeout(marker); } try { return cachedClearTimeout(marker); } catch (e) { try { return cachedClearTimeout.call(null, marker); } catch (e) { return cachedClearTimeout.call(this, marker); } } } var queue = []; var draining = false; var currentQueue; var queueIndex = -1; function cleanUpNextTick() { if (!draining || !currentQueue) { return; } draining = false; if (currentQueue.length) { queue = currentQueue.concat(queue); } else { queueIndex = -1; } if (queue.length) { drainQueue(); } } function drainQueue() { if (draining) { return; } var timeout = runTimeout(cleanUpNextTick); draining = true; var len = queue.length; while (len) { currentQueue = queue; queue = []; while (++queueIndex < len) { if (currentQueue) { currentQueue[queueIndex].run(); } } queueIndex = -1; len = queue.length; } currentQueue = null; draining = false; runClearTimeout(timeout); } function nextTick(fun) { var args = new Array(arguments.length - 1); if (arguments.length > 1) { for (var i = 1; i < arguments.length; i++) { args[i - 1] = arguments[i]; } } queue.push(new Item(fun, args)); if (queue.length === 1 && !draining) { runTimeout(drainQueue); } } function Item(fun, array) { this.fun = fun; this.array = array; } Item.prototype.run = function () { this.fun.apply(null, this.array); }; var title = 'browser'; var platform = 'browser'; var browser = true; var env = {}; var argv = []; var version = ''; var versions = {}; var release = {}; var config = {}; function noop() {} var on = noop; var addListener = noop; var once = noop; var off = noop; var removeListener = noop; var removeAllListeners = noop; var emit = noop; function binding(name) { throw new Error('process.binding is not supported'); } function cwd() { return '/'; } function chdir(dir) { throw new Error('process.chdir is not supported'); } function umask() { return 0; } var performance = global$1.performance || {}; var performanceNow = performance.now || performance.mozNow || performance.msNow || performance.oNow || performance.webkitNow || function () { return new Date().getTime(); }; function hrtime(previousTimestamp) { var clocktime = performanceNow.call(performance) * 1e-3; var seconds = Math.floor(clocktime); var nanoseconds = Math.floor(clocktime % 1 * 1e9); if (previousTimestamp) { seconds = seconds - previousTimestamp[0]; nanoseconds = nanoseconds - previousTimestamp[1]; if (nanoseconds < 0) { seconds--; nanoseconds += 1e9; } } return [seconds, nanoseconds]; } var startTime = new Date(); function uptime() { var currentTime = new Date(); var dif = currentTime - startTime; return dif / 1000; } var process = { nextTick: nextTick, title: title, browser: browser, env: env, argv: argv, version: version, versions: versions, on: on, addListener: addListener, once: once, off: off, removeListener: removeListener, removeAllListeners: removeAllListeners, emit: emit, binding: binding, cwd: cwd, chdir: chdir, umask: umask, hrtime: hrtime, platform: platform, release: release, config: config, uptime: uptime }; var ast = createCommonjsModule(function (module) { (function () { function isExpression(node) { if (node == null) { return false; } switch (node.type) { case 'ArrayExpression': case 'AssignmentExpression': case 'BinaryExpression': case 'CallExpression': case 'ConditionalExpression': case 'FunctionExpression': case 'Identifier': case 'Literal': case 'LogicalExpression': case 'MemberExpression': case 'NewExpression': case 'ObjectExpression': case 'SequenceExpression': case 'ThisExpression': case 'UnaryExpression': case 'UpdateExpression': return true; } return false; } function isIterationStatement(node) { if (node == null) { return false; } switch (node.type) { case 'DoWhileStatement': case 'ForInStatement': case 'ForStatement': case 'WhileStatement': return true; } return false; } function isStatement(node) { if (node == null) { return false; } switch (node.type) { case 'BlockStatement': case 'BreakStatement': case 'ContinueStatement': case 'DebuggerStatement': case 'DoWhileStatement': case 'EmptyStatement': case 'ExpressionStatement': case 'ForInStatement': case 'ForStatement': case 'IfStatement': case 'LabeledStatement': case 'ReturnStatement': case 'SwitchStatement': case 'ThrowStatement': case 'TryStatement': case 'VariableDeclaration': case 'WhileStatement': case 'WithStatement': return true; } return false; } function isSourceElement(node) { return isStatement(node) || node != null && node.type === 'FunctionDeclaration'; } function trailingStatement(node) { switch (node.type) { case 'IfStatement': if (node.alternate != null) { return node.alternate; } return node.consequent; case 'LabeledStatement': case 'ForStatement': case 'ForInStatement': case 'WhileStatement': case 'WithStatement': return node.body; } return null; } function isProblematicIfStatement(node) { var current; if (node.type !== 'IfStatement') { return false; } if (node.alternate == null) { return false; } current = node.consequent; do { if (current.type === 'IfStatement') { if (current.alternate == null) { return true; } } current = trailingStatement(current); } while (current); return false; } module.exports = { isExpression: isExpression, isStatement: isStatement, isIterationStatement: isIterationStatement, isSourceElement: isSourceElement, isProblematicIfStatement: isProblematicIfStatement, trailingStatement: trailingStatement }; })(); }); var ast_1 = ast.isExpression; var ast_2 = ast.isStatement; var ast_3 = ast.isIterationStatement; var ast_4 = ast.isSourceElement; var ast_5 = ast.isProblematicIfStatement; var ast_6 = ast.trailingStatement; var code = createCommonjsModule(function (module) { (function () { var ES6Regex, ES5Regex, NON_ASCII_WHITESPACES, IDENTIFIER_START, IDENTIFIER_PART, ch; ES5Regex = { 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\u08B6-\u08BD\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\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\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-\u1884\u1887-\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\u1C80-\u1C88\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\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\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\u2E2F\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309D-\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-\uA7AE\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]/, NonAsciiIdentifierPart: /[\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0300-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\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\u08B6-\u08BD\u08D4-\u08E1\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\u0C80-\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\u0D54-\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\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-\u19D9\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\u1C80-\u1C88\u1CD0-\u1CD2\u1CD4-\u1CF6\u1CF8\u1CF9\u1D00-\u1DF5\u1DFB-\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\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\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\u2E2F\u3005-\u3007\u3021-\u302F\u3031-\u3035\u3038-\u303C\u3041-\u3096\u3099\u309A\u309D-\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-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA827\uA840-\uA873\uA880-\uA8C5\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]/ }; ES6Regex = { 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\u08B6-\u08BD\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\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\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\u1C80-\u1C88\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-\uA7AE\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\uDCB0-\uDCD3\uDCD8-\uDCFB\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[\uDC00-\uDC34\uDC47-\uDC4A\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE80-\uDEAA\uDF00-\uDF19]|\uD806[\uDCA0-\uDCDF\uDCFF\uDEC0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC2E\uDC40\uDC72-\uDC8F]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD81C-\uD820\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\uDFE0]|\uD821[\uDC00-\uDFEC]|\uD822[\uDC00-\uDEF2]|\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\uDD00-\uDD43]|\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\u08B6-\u08BD\u08D4-\u08E1\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\u0C80-\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\u0D54-\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\u1C80-\u1C88\u1CD0-\u1CD2\u1CD4-\u1CF6\u1CF8\u1CF9\u1D00-\u1DF5\u1DFB-\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-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA827\uA840-\uA873\uA880-\uA8C5\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\uDCB0-\uDCD3\uDCD8-\uDCFB\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\uDE3E\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[\uDC00-\uDC4A\uDC50-\uDC59\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]|\uD807[\uDC00-\uDC08\uDC0A-\uDC36\uDC38-\uDC40\uDC50-\uDC59\uDC72-\uDC8F\uDC92-\uDCA7\uDCA9-\uDCB6]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD81C-\uD820\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\uDFE0]|\uD821[\uDC00-\uDFEC]|\uD822[\uDC00-\uDEF2]|\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]|\uD838[\uDC00-\uDC06\uDC08-\uDC18\uDC1B-\uDC21\uDC23\uDC24\uDC26-\uDC2A]|\uD83A[\uDC00-\uDCC4\uDCD0-\uDCD6\uDD00-\uDD4A\uDD50-\uDD59]|\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]/ }; function isDecimalDigit(ch) { return 0x30 <= ch && ch <= 0x39; } function isHexDigit(ch) { return 0x30 <= ch && ch <= 0x39 || 0x61 <= ch && ch <= 0x66 || 0x41 <= ch && ch <= 0x46; } function isOctalDigit(ch) { return ch >= 0x30 && ch <= 0x37; } NON_ASCII_WHITESPACES = [0x1680, 0x2000, 0x2001, 0x2002, 0x2003, 0x2004, 0x2005, 0x2006, 0x2007, 0x2008, 0x2009, 0x200A, 0x202F, 0x205F, 0x3000, 0xFEFF]; function isWhiteSpace(ch) { return ch === 0x20 || ch === 0x09 || ch === 0x0B || ch === 0x0C || ch === 0xA0 || ch >= 0x1680 && NON_ASCII_WHITESPACES.indexOf(ch) >= 0; } function isLineTerminator(ch) { return ch === 0x0A || ch === 0x0D || ch === 0x2028 || ch === 0x2029; } function fromCodePoint(cp) { if (cp <= 0xFFFF) { return String.fromCharCode(cp); } var cu1 = String.fromCharCode(Math.floor((cp - 0x10000) / 0x400) + 0xD800); var cu2 = String.fromCharCode((cp - 0x10000) % 0x400 + 0xDC00); return cu1 + cu2; } IDENTIFIER_START = new Array(0x80); for (ch = 0; ch < 0x80; ++ch) { IDENTIFIER_START[ch] = ch >= 0x61 && ch <= 0x7A || ch >= 0x41 && ch <= 0x5A || ch === 0x24 || ch === 0x5F; } IDENTIFIER_PART = new Array(0x80); for (ch = 0; ch < 0x80; ++ch) { IDENTIFIER_PART[ch] = ch >= 0x61 && ch <= 0x7A || ch >= 0x41 && ch <= 0x5A || ch >= 0x30 && ch <= 0x39 || ch === 0x24 || ch === 0x5F; } function isIdentifierStartES5(ch) { return ch < 0x80 ? IDENTIFIER_START[ch] : ES5Regex.NonAsciiIdentifierStart.test(fromCodePoint(ch)); } function isIdentifierPartES5(ch) { return ch < 0x80 ? IDENTIFIER_PART[ch] : ES5Regex.NonAsciiIdentifierPart.test(fromCodePoint(ch)); } function isIdentifierStartES6(ch) { return ch < 0x80 ? IDENTIFIER_START[ch] : ES6Regex.NonAsciiIdentifierStart.test(fromCodePoint(ch)); } function isIdentifierPartES6(ch) { return ch < 0x80 ? IDENTIFIER_PART[ch] : ES6Regex.NonAsciiIdentifierPart.test(fromCodePoint(ch)); } module.exports = { isDecimalDigit: isDecimalDigit, isHexDigit: isHexDigit, isOctalDigit: isOctalDigit, isWhiteSpace: isWhiteSpace, isLineTerminator: isLineTerminator, isIdentifierStartES5: isIdentifierStartES5, isIdentifierPartES5: isIdentifierPartES5, isIdentifierStartES6: isIdentifierStartES6, isIdentifierPartES6: isIdentifierPartES6 }; })(); }); var code_1 = code.isDecimalDigit; var code_2 = code.isHexDigit; var code_3 = code.isOctalDigit; var code_4 = code.isWhiteSpace; var code_5 = code.isLineTerminator; var code_6 = code.isIdentifierStartES5; var code_7 = code.isIdentifierPartES5; var code_8 = code.isIdentifierStartES6; var code_9 = code.isIdentifierPartES6; var keyword = createCommonjsModule(function (module) { (function () { var code$1 = code; function isStrictModeReservedWordES6(id) { switch (id) { case 'implements': case 'interface': case 'package': case 'private': case 'protected': case 'public': case 'static': case 'let': return true; default: return false; } } function isKeywordES5(id, strict) { if (!strict && id === 'yield') { return false; } return isKeywordES6(id, strict); } function isKeywordES6(id, strict) { if (strict && isStrictModeReservedWordES6(id)) { return true; } switch (id.length) { case 2: return id === 'if' || id === 'in' || id === 'do'; case 3: return id === 'var' || id === 'for' || id === 'new' || id === 'try'; case 4: return id === 'this' || id === 'else' || id === 'case' || id === 'void' || id === 'with' || id === 'enum'; case 5: return id === 'while' || id === 'break' || id === 'catch' || id === 'throw' || id === 'const' || id === 'yield' || id === 'class' || id === 'super'; case 6: return id === 'return' || id === 'typeof' || id === 'delete' || id === 'switch' || id === 'export' || id === 'import'; case 7: return id === 'default' || id === 'finally' || id === 'extends'; case 8: return id === 'function' || id === 'continue' || id === 'debugger'; case 10: return id === 'instanceof'; default: return false; } } function isReservedWordES5(id, strict) { return id === 'null' || id === 'true' || id === 'false' || isKeywordES5(id, strict); } function isReservedWordES6(id, strict) { return id === 'null' || id === 'true' || id === 'false' || isKeywordES6(id, strict); } function isRestrictedWord(id) { return id === 'eval' || id === 'arguments'; } function isIdentifierNameES5(id) { var i, iz, ch; if (id.length === 0) { return false; } ch = id.charCodeAt(0); if (!code$1.isIdentifierStartES5(ch)) { return false; } for (i = 1, iz = id.length; i < iz; ++i) { ch = id.charCodeAt(i); if (!code$1.isIdentifierPartES5(ch)) { return false; } } return true; } function decodeUtf16(lead, trail) { return (lead - 0xD800) * 0x400 + (trail - 0xDC00) + 0x10000; } function isIdentifierNameES6(id) { var i, iz, ch, lowCh, check; if (id.length === 0) { return false; } check = code$1.isIdentifierStartES6; for (i = 0, iz = id.length; i < iz; ++i) { ch = id.charCodeAt(i); if (0xD800 <= ch && ch <= 0xDBFF) { ++i; if (i >= iz) { return false; } lowCh = id.charCodeAt(i); if (!(0xDC00 <= lowCh && lowCh <= 0xDFFF)) { return false; } ch = decodeUtf16(ch, lowCh); } if (!check(ch)) { return false; } check = code$1.isIdentifierPartES6; } return true; } function isIdentifierES5(id, strict) { return isIdentifierNameES5(id) && !isReservedWordES5(id, strict); } function isIdentifierES6(id, strict) { return isIdentifierNameES6(id) && !isReservedWordES6(id, strict); } module.exports = { isKeywordES5: isKeywordES5, isKeywordES6: isKeywordES6, isReservedWordES5: isReservedWordES5, isReservedWordES6: isReservedWordES6, isRestrictedWord: isRestrictedWord, isIdentifierNameES5: isIdentifierNameES5, isIdentifierNameES6: isIdentifierNameES6, isIdentifierES5: isIdentifierES5, isIdentifierES6: isIdentifierES6 }; })(); }); var keyword_1 = keyword.isKeywordES5; var keyword_2 = keyword.isKeywordES6; var keyword_3 = keyword.isReservedWordES5; var keyword_4 = keyword.isReservedWordES6; var keyword_5 = keyword.isRestrictedWord; var keyword_6 = keyword.isIdentifierNameES5; var keyword_7 = keyword.isIdentifierNameES6; var keyword_8 = keyword.isIdentifierES5; var keyword_9 = keyword.isIdentifierES6; var utils = createCommonjsModule(function (module, exports) { (function () { exports.ast = ast; exports.code = code; exports.keyword = keyword; })(); }); var utils_1 = utils.ast; var utils_2 = utils.code; var utils_3 = utils.keyword; function isType(nodeType, targetType) { if (nodeType === targetType) return true; if (ALIAS_KEYS[targetType]) return false; var aliases = FLIPPED_ALIAS_KEYS[targetType]; if (aliases) { if (aliases[0] === nodeType) return true; for (var _iterator = aliases, _isArray = Array.isArray(_iterator), _i = 0, _iterator = _isArray ? _iterator : _iterator[Symbol.iterator]();;) { var _ref; if (_isArray) { if (_i >= _iterator.length) break; _ref = _iterator[_i++]; } else { _i = _iterator.next(); if (_i.done) break; _ref = _i.value; } var alias = _ref; if (nodeType === alias) return true; } } return false; } function isPlaceholderType(placeholderType, targetType) { if (placeholderType === targetType) return true; var aliases = PLACEHOLDERS_ALIAS[placeholderType]; if (aliases) { for (var _iterator = aliases, _isArray = Array.isArray(_iterator), _i = 0, _iterator = _isArray ? _iterator : _iterator[Symbol.iterator]();;) { var _ref; if (_isArray) { if (_i >= _iterator.length) break; _ref = _iterator[_i++]; } else { _i = _iterator.next(); if (_i.done) break; _ref = _i.value; } var alias = _ref; if (targetType === alias) return true; } } return false; } function is(type, node, opts) { if (!node) return false; var matches = isType(node.type, type); if (!matches) { if (!opts && node.type === "Placeholder" && type in FLIPPED_ALIAS_KEYS) { return isPlaceholderType(node.expectedNode, type); } return false; } if (typeof opts === "undefined") { return true; } else { return shallowEqual(node, opts); } } var STATEMENT_OR_BLOCK_KEYS = ["consequent", "body", "alternate"]; var FLATTENABLE_KEYS = ["body", "expressions"]; var FOR_INIT_KEYS = ["left", "init"]; var COMMENT_KEYS = ["leadingComments", "trailingComments", "innerComments"]; var LOGICAL_OPERATORS = ["||", "&&", "??"]; var UPDATE_OPERATORS = ["++", "--"]; var BOOLEAN_NUMBER_BINARY_OPERATORS = [">", "<", ">=", "<="]; var EQUALITY_BINARY_OPERATORS = ["==", "===", "!=", "!=="]; var COMPARISON_BINARY_OPERATORS = [].concat(EQUALITY_BINARY_OPERATORS, ["in", "instanceof"]); var BOOLEAN_BINARY_OPERATORS = [].concat(COMPARISON_BINARY_OPERATORS, BOOLEAN_NUMBER_BINARY_OPERATORS); var NUMBER_BINARY_OPERATORS = ["-", "/", "%", "*", "**", "&", "|", ">>", ">>>", "<<", "^"]; var BINARY_OPERATORS = ["+"].concat(NUMBER_BINARY_OPERATORS, BOOLEAN_BINARY_OPERATORS); var ASSIGNMENT_OPERATORS = ["=", "+="].concat(NUMBER_BINARY_OPERATORS.map(function (op) { return op + "="; })); var BOOLEAN_UNARY_OPERATORS = ["delete", "!"]; var NUMBER_UNARY_OPERATORS = ["+", "-", "~"]; var STRING_UNARY_OPERATORS = ["typeof"]; var UNARY_OPERATORS = ["void", "throw"].concat(BOOLEAN_UNARY_OPERATORS, NUMBER_UNARY_OPERATORS, STRING_UNARY_OPERATORS); var INHERIT_KEYS = { optional: ["typeAnnotation", "typeParameters", "returnType"], force: ["start", "loc", "end"] }; var BLOCK_SCOPED_SYMBOL = Symbol["for"]("var used to be block scoped"); var NOT_LOCAL_BINDING = Symbol["for"]("should not be considered a local binding"); function validate(node, key, val) { if (!node) return; var fields = NODE_FIELDS[node.type]; if (!fields) return; var field = fields[key]; validateField(node, key, val, field); validateChild(node, key, val); } function validateField(node, key, val, field) { if (!field || !field.validate) return; if (field.optional && val == null) return; field.validate(node, key, val); } function validateChild(node, key, val) { if (val == null) return; var validate = NODE_PARENT_VALIDATIONS[val.type]; if (!validate) return; validate(node, key, val); } var VISITOR_KEYS = {}; var ALIAS_KEYS = {}; var FLIPPED_ALIAS_KEYS = {}; var NODE_FIELDS = {}; var BUILDER_KEYS = {}; var DEPRECATED_KEYS = {}; var NODE_PARENT_VALIDATIONS = {}; function getType(val) { if (Array.isArray(val)) { return "array"; } else if (val === null) { return "null"; } else { return typeof val; } } function validate$1(validate) { return { validate: validate }; } function typeIs(typeName) { return typeof typeName === "string" ? assertNodeType(typeName) : assertNodeType.apply(void 0, typeName); } function validateType(typeName) { return validate$1(typeIs(typeName)); } function validateOptional(validate) { return { validate: validate, optional: true }; } function validateOptionalType(typeName) { return { validate: typeIs(typeName), optional: true }; } function arrayOf(elementType) { return chain(assertValueType("array"), assertEach(elementType)); } function arrayOfType(typeName) { return arrayOf(typeIs(typeName)); } function validateArrayOfType(typeName) { return validate$1(arrayOfType(typeName)); } function assertEach(callback) { function validator(node, key, val) { if (!Array.isArray(val)) return; for (var i = 0; i < val.length; i++) { var subkey = key + "[" + i + "]"; var v = val[i]; callback(node, subkey, v); if (process.env.BABEL_TYPES_8_BREAKING) validateChild(node, subkey, v); } } validator.each = callback; return validator; } function assertOneOf() { for (var _len = arguments.length, values = new Array(_len), _key = 0; _key < _len; _key++) { values[_key] = arguments[_key]; } function validate(node, key, val) { if (values.indexOf(val) < 0) { throw new TypeError("Property " + key + " expected value to be one of " + JSON.stringify(values) + " but got " + JSON.stringify(val)); } } validate.oneOf = values; return validate; } function assertNodeType() { for (var _len2 = arguments.length, types = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) { types[_key2] = arguments[_key2]; } function validate(node, key, val) { for (var _iterator = types, _isArray = Array.isArray(_iterator), _i = 0, _iterator = _isArray ? _iterator : _iterator[Symbol.iterator]();;) { var _ref; if (_isArray) { if (_i >= _iterator.length) break; _ref = _iterator[_i++]; } else { _i = _iterator.next(); if (_i.done) break; _ref = _i.value; } var type = _ref; if (is(type, val)) { validateChild(node, key, val); return; } } throw new TypeError("Property " + key + " of " + node.type + " expected node to be of a type " + JSON.stringify(types) + " but instead got " + JSON.stringify(val && val.type)); } validate.oneOfNodeTypes = types; return validate; } function assertNodeOrValueType() { for (var _len3 = arguments.length, types = new Array(_len3), _key3 = 0; _key3 < _len3; _key3++) { types[_key3] = arguments[_key3]; } function validate(node, key, val) { for (var _iterator2 = types, _isArray2 = Array.isArray(_iterator2), _i2 = 0, _iterator2 = _isArray2 ? _iterator2 : _iterator2[Symbol.iterator]();;) { var _ref2; if (_isArray2) { if (_i2 >= _iterator2.length) break; _ref2 = _iterator2[_i2++]; } else { _i2 = _iterator2.next(); if (_i2.done) break; _ref2 = _i2.value; } var type = _ref2; if (getType(val) === type || is(type, val)) { validateChild(node, key, val); return; } } throw new TypeError("Property " + key + " of " + node.type + " expected node to be of a type " + JSON.stringify(types) + " but instead got " + JSON.stringify(val && val.type)); } validate.oneOfNodeOrValueTypes = types; return validate; } function assertValueType(type) { function validate(node, key, val) { var valid = getType(val) === type; if (!valid) { throw new TypeError("Property " + key + " expected type of " + type + " but got " + getType(val)); } } validate.type = type; return validate; } function assertShape(shape) { function validate(node, key, val) { var errors = []; for (var _i3 = 0, _Object$keys = Object.keys(shape); _i3 < _Object$keys.length; _i3++) { var property = _Object$keys[_i3]; try { validateField(node, property, val[property], shape[property]); } catch (error) { if (error instanceof TypeError) { errors.push(error.message); continue; } throw error; } } if (errors.length) { throw new TypeError("Property " + key + " of " + node.type + " expected to have the following:\n" + errors.join("\n")); } } validate.shapeOf = shape; return validate; } function chain() { for (var _len4 = arguments.length, fns = new Array(_len4), _key4 = 0; _key4 < _len4; _key4++) { fns[_key4] = arguments[_key4]; } function validate() { for (var _iterator3 = fns, _isArray3 = Array.isArray(_iterator3), _i4 = 0, _iterator3 = _isArray3 ? _iterator3 : _iterator3[Symbol.iterator]();;) { var _ref3; if (_isArray3) { if (_i4 >= _iterator3.length) break; _ref3 = _iterator3[_i4++]; } else { _i4 = _iterator3.next(); if (_i4.done) break; _ref3 = _i4.value; } var fn = _ref3; fn.apply(void 0, arguments); } } validate.chainOf = fns; return validate; } var validTypeOpts = ["aliases", "builder", "deprecatedAlias", "fields", "inherits", "visitor", "validate"]; var validFieldKeys = ["default", "optional", "validate"]; function defineType(type, opts) { if (opts === void 0) { opts = {}; } var inherits = opts.inherits && store[opts.inherits] || {}; var fields = opts.fields; if (!fields) { fields = {}; if (inherits.fields) { var keys = Object.getOwnPropertyNames(inherits.fields); for (var _i5 = 0, _arr = keys; _i5 < _arr.length; _i5++) { var key = _arr[_i5]; var field = inherits.fields[key]; fields[key] = { "default": field["default"], optional: field.optional, validate: field.validate }; } } } var visitor = opts.visitor || inherits.visitor || []; var aliases = opts.aliases || inherits.aliases || []; var builder = opts.builder || inherits.builder || opts.visitor || []; for (var _i6 = 0, _arr2 = Object.keys(opts); _i6 < _arr2.length; _i6++) { var k = _arr2[_i6]; if (validTypeOpts.indexOf(k) === -1) { throw new Error("Unknown type option \"" + k + "\" on " + type); } } if (opts.deprecatedAlias) { DEPRECATED_KEYS[opts.deprecatedAlias] = type; } for (var _i7 = 0, _arr3 = visitor.concat(builder); _i7 < _arr3.length; _i7++) { var _key5 = _arr3[_i7]; fields[_key5] = fields[_key5] || {}; } for (var _i8 = 0, _Object$keys2 = Object.keys(fields); _i8 < _Object$keys2.length; _i8++) { var _key6 = _Object$keys2[_i8]; var _field = fields[_key6]; if (_field["default"] !== undefined && builder.indexOf(_key6) === -1) { _field.optional = true; } if (_field["default"] === undefined) { _field["default"] = null; } else if (!_field.validate && _field["default"] != null) { _field.validate = assertValueType(getType(_field["default"])); } for (var _i9 = 0, _arr4 = Object.keys(_field); _i9 < _arr4.length; _i9++) { var _k = _arr4[_i9]; if (validFieldKeys.indexOf(_k) === -1) { throw new Error("Unknown field key \"" + _k + "\" on " + type + "." + _key6); } } } VISITOR_KEYS[type] = opts.visitor = visitor; BUILDER_KEYS[type] = opts.builder = builder; NODE_FIELDS[type] = opts.fields = fields; ALIAS_KEYS[type] = opts.aliases = aliases; aliases.forEach(function (alias) { FLIPPED_ALIAS_KEYS[alias] = FLIPPED_ALIAS_KEYS[alias] || []; FLIPPED_ALIAS_KEYS[alias].push(type); }); if (opts.validate) { NODE_PARENT_VALIDATIONS[type] = opts.validate; } store[type] = opts; } var store = {}; defineType("ArrayExpression", { fields: { elements: { validate: chain(assertValueType("array"), assertEach(assertNodeOrValueType("null", "Expression", "SpreadElement"))), "default": !process.env.BABEL_TYPES_8_BREAKING ? [] : undefined } }, visitor: ["elements"], aliases: ["Expression"] }); defineType("AssignmentExpression", { fields: { operator: { validate: function () { if (!process.env.BABEL_TYPES_8_BREAKING) { return assertValueType("string"); } var identifier = assertOneOf.apply(void 0, ASSIGNMENT_OPERATORS); var pattern = assertOneOf("="); return function (node, key, val) { var validator = is("Pattern", node.left) ? pattern : identifier; validator(node, key, val); }; }() }, left: { validate: !process.env.BABEL_TYPES_8_BREAKING ? assertNodeType("LVal") : assertNodeType("Identifier", "MemberExpression", "ArrayPattern", "ObjectPattern") }, right: { validate: assertNodeType("Expression") } }, builder: ["operator", "left", "right"], visitor: ["left", "right"], aliases: ["Expression"] }); defineType("BinaryExpression", { builder: ["operator", "left", "right"], fields: { operator: { validate: assertOneOf.apply(void 0, BINARY_OPERATORS) }, left: { validate: assertNodeType("Expression") }, right: { validate: assertNodeType("Expression") } }, visitor: ["left", "right"], aliases: ["Binary", "Expression"] }); defineType("InterpreterDirective", { builder: ["value"], fields: { value: { validate: assertValueType("string") } } }); defineType("Directive", { visitor: ["value"], fields: { value: { validate: assertNodeType("DirectiveLiteral") } } }); defineType("DirectiveLiteral", { builder: ["value"], fields: { value: { validate: assertValueType("string") } } }); defineType("BlockStatement", { builder: ["body", "directives"], visitor: ["directives", "body"], fields: { directives: { validate: chain(assertValueType("array"), assertEach(assertNodeType("Directive"))), "default": [] }, body: { validate: chain(assertValueType("array"), assertEach(assertNodeType("Statement"))) } }, aliases: ["Scopable", "BlockParent", "Block", "Statement"] }); defineType("BreakStatement", { visitor: ["label"], fields: { label: { validate: assertNodeType("Identifier"), optional: true } }, aliases: ["Statement", "Terminatorless", "CompletionStatement"] }); defineType("CallExpression", { visitor: ["callee", "arguments", "typeParameters", "typeArguments"], builder: ["callee", "arguments"], aliases: ["Expression"], fields: Object.assign({ callee: { validate: assertNodeType("Expression", "V8IntrinsicIdentifier") }, arguments: { validate: chain(assertValueType("array"), assertEach(assertNodeType("Expression", "SpreadElement", "JSXNamespacedName", "ArgumentPlaceholder"))) } }, !process.env.BABEL_TYPES_8_BREAKING ? { optional: { validate: assertOneOf(true, false), optional: true } } : {}, { typeArguments: { validate: assertNodeType("TypeParameterInstantiation"), optional: true }, typeParameters: { validate: assertNodeType("TSTypeParameterInstantiation"), optional: true } }) }); defineType("CatchClause", { visitor: ["param", "body"], fields: { param: { validate: assertNodeType("Identifier", "ArrayPattern", "ObjectPattern"), optional: true }, body: { validate: assertNodeType("BlockStatement") } }, aliases: ["Scopable", "BlockParent"] }); defineType("ConditionalExpression", { visitor: ["test", "consequent", "alternate"], fields: { test: { validate: assertNodeType("Expression") }, consequent: { validate: assertNodeType("Expression") }, alternate: { validate: assertNodeType("Expression") } }, aliases: ["Expression", "Conditional"] }); defineType("ContinueStatement", { visitor: ["label"], fields: { label: { validate: assertNodeType("Identifier"), optional: true } }, aliases: ["Statement", "Terminatorless", "CompletionStatement"] }); defineType("DebuggerStatement", { aliases: ["Statement"] }); defineType("DoWhileStatement", { visitor: ["test", "body"], fields: { test: { validate: assertNodeType("Expression") }, body: { validate: assertNodeType("Statement") } }, aliases: ["Statement", "BlockParent", "Loop", "While", "Scopable"] }); defineType("EmptyStatement", { aliases: ["Statement"] }); defineType("ExpressionStatement", { visitor: ["expression"], fields: { expression: { validate: assertNodeType("Expression") } }, aliases: ["Statement", "ExpressionWrapper"] }); defineType("File", { builder: ["program", "comments", "tokens"], visitor: ["program"], fields: { program: { validate: assertNodeType("Program") } } }); defineType("ForInStatement", { visitor: ["left", "right", "body"], aliases: ["Scopable", "Statement", "For", "BlockParent", "Loop", "ForXStatement"], fields: { left: { validate: !process.env.BABEL_TYPES_8_BREAKING ? assertNodeType("VariableDeclaration", "LVal") : assertNodeType("VariableDeclaration", "Identifier", "MemberExpression", "ArrayPattern", "ObjectPattern") }, right: { validate: assertNodeType("Expression") }, body: { validate: assertNodeType("Statement") } } }); defineType("ForStatement", { visitor: ["init", "test", "update", "body"], aliases: ["Scopable", "Statement", "For", "BlockParent", "Loop"], fields: { init: { validate: assertNodeType("VariableDeclaration", "Expression"), optional: true }, test: { validate: assertNodeType("Expression"), optional: true }, update: { validate: assertNodeType("Expression"), optional: true }, body: { validate: assertNodeType("Statement") } } }); var functionCommon = { params: { validate: chain(assertValueType("array"), assertEach(assertNodeType("Identifier", "Pattern", "RestElement", "TSParameterProperty"))) }, generator: { "default": false }, async: { "default": false } }; var functionTypeAnnotationCommon = { returnType: { validate: assertNodeType("TypeAnnotation", "TSTypeAnnotation", "Noop"), optional: true }, typeParameters: { validate: assertNodeType("TypeParameterDeclaration", "TSTypeParameterDeclaration", "Noop"), optional: true } }; var functionDeclarationCommon = Object.assign({}, functionCommon, { declare: { validate: assertValueType("boolean"), optional: true }, id: { validate: assertNodeType("Identifier"), optional: true } }); defineType("FunctionDeclaration", { builder: ["id", "params", "body", "generator", "async"], visitor: ["id", "params", "body", "returnType", "typeParameters"], fields: Object.assign({}, functionDeclarationCommon, {}, functionTypeAnnotationCommon, { body: { validate: assertNodeType("BlockStatement") } }), aliases: ["Scopable", "Function", "BlockParent", "FunctionParent", "Statement", "Pureish", "Declaration"], validate: function () { if (!process.env.BABEL_TYPES_8_BREAKING) return function () {}; var identifier = assertNodeType("Identifier"); return function (parent, key, node) { if (!is("ExportDefaultDeclaration", parent)) { identifier(node, "id", node.id); } }; }() }); defineType("FunctionExpression", { inherits: "FunctionDeclaration", aliases: ["Scopable", "Function", "BlockParent", "FunctionParent", "Expression", "Pureish"], fields: Object.assign({}, functionCommon, {}, functionTypeAnnotationCommon, { id: { validate: assertNodeType("Identifier"), optional: true }, body: { validate: assertNodeType("BlockStatement") } }) }); var patternLikeCommon = { typeAnnotation: { validate: assertNodeType("TypeAnnotation", "TSTypeAnnotation", "Noop"), optional: true }, decorators: { validate: chain(assertValueType("array"), assertEach(assertNodeType("Decorator"))) } }; defineType("Identifier", { builder: ["name"], visitor: ["typeAnnotation", "decorators"], aliases: ["Expression", "PatternLike", "LVal", "TSEntityName"], fields: Object.assign({}, patternLikeCommon, { name: { validate: chain(assertValueType("string"), function (node, key, val) { if (!process.env.BABEL_TYPES_8_BREAKING) return; if (!utils.keyword.isIdentifierNameES6(val)) { throw new TypeError("\"" + val + "\" is not a valid identifier name"); } }) }, optional: { validate: assertValueType("boolean"), optional: true } }), validate: function validate(parent, key, node) { if (!process.env.BABEL_TYPES_8_BREAKING) return; var match = /\.(\w+)$/.exec(key); if (!match) return; var parentKey = match[1]; var nonComp = { computed: false }; if (parentKey === "property") { if (is("MemberExpression", parent, nonComp)) return; if (is("OptionalMemberExpression", parent, nonComp)) return; } else if (parentKey === "key") { if (is("Property", parent, nonComp)) return; if (is("Method", parent, nonComp)) return; } else if (parentKey === "exported") { if (is("ExportSpecifier", parent)) return; } else if (parentKey === "imported") { if (is("ImportSpecifier", parent, { imported: node })) return; } else if (parentKey === "meta") { if (is("MetaProperty", parent, { meta: node })) return; } if (utils.keyword.isReservedWordES6(node.name, false) && node.name !== "this") { throw new TypeError("\"" + node.name + "\" is not a valid identifer"); } } }); defineType("IfStatement", { visitor: ["test", "consequent", "alternate"], aliases: ["Statement", "Conditional"], fields: { test: { validate: assertNodeType("Expression") }, consequent: { validate: assertNodeType("Statement") }, alternate: { optional: true, validate: assertNodeType("Statement") } } }); defineType("LabeledStatement", { visitor: ["label", "body"], aliases: ["Statement"], fields: { label: { validate: assertNodeType("Identifier") }, body: { validate: assertNodeType("Statement") } } }); defineType("StringLiteral", { builder: ["value"], fields: { value: { validate: assertValueType("string") } }, aliases: ["Expression", "Pureish", "Literal", "Immutable"] }); defineType("NumericLiteral", { builder: ["value"], deprecatedAlias: "NumberLiteral", fields: { value: { validate: assertValueType("number") } }, aliases: ["Expression", "Pureish", "Literal", "Immutable"] }); defineType("NullLiteral", { aliases: ["Expression", "Pureish", "Literal", "Immutable"] }); defineType("BooleanLiteral", { builder: ["value"], fields: { value: { validate: assertValueType("boolean") } }, aliases: ["Expression", "Pureish", "Literal", "Immutable"] }); defineType("RegExpLiteral", { builder: ["pattern", "flags"], deprecatedAlias: "RegexLiteral", aliases: ["Expression", "Literal"], fields: { pattern: { validate: assertValueType("string") }, flags: { validate: chain(assertValueType("string"), function (node, key, val) { if (!process.env.BABEL_TYPES_8_BREAKING) return; var invalid = /[^gimsuy]/.exec(val); if (invalid) { throw new TypeError("\"" + invalid[0] + "\" is not a valid RegExp flag"); } }), "default": "" } } }); defineType("LogicalExpression", { builder: ["operator", "left", "right"], visitor: ["left", "right"], aliases: ["Binary", "Expression"], fields: { operator: { validate: assertOneOf.apply(void 0, LOGICAL_OPERATORS) }, left: { validate: assertNodeType("Expression") }, right: { validate: assertNodeType("Expression") } } }); defineType("MemberExpression", { builder: ["object", "property", "computed", "optional"], visitor: ["object", "property"], aliases: ["Expression", "LVal"], fields: Object.assign({ object: { validate: assertNodeType("Expression") }, property: { validate: function () { var normal = assertNodeType("Identifier", "PrivateName"); var computed = assertNodeType("Expression"); return function (node, key, val) { var validator = node.computed ? computed : normal; validator(node, key, val); }; }() }, computed: { "default": false } }, !process.env.BABEL_TYPES_8_BREAKING ? { optional: { validate: assertOneOf(true, false), optional: true } } : {}) }); defineType("NewExpression", { inherits: "CallExpression" }); defineType("Program", { visitor: ["directives", "body"], builder: ["body", "directives", "sourceType", "interpreter"], fields: { sourceFile: { validate: assertValueType("string") }, sourceType: { validate: assertOneOf("script", "module"), "default": "script" }, interpreter: { validate: assertNodeType("InterpreterDirective"), "default": null, optional: true }, directives: { validate: chain(assertValueType("array"), assertEach(assertNodeType("Directive"))), "default": [] }, body: { validate: chain(assertValueType("array"), assertEach(assertNodeType("Statement"))) } }, aliases: ["Scopable", "BlockParent", "Block"] }); defineType("ObjectExpression", { visitor: ["properties"], aliases: ["Expression"], fields: { properties: { validate: chain(assertValueType("array"), assertEach(assertNodeType("ObjectMethod", "ObjectProperty", "SpreadElement"))) } } }); defineType("ObjectMethod", { builder: ["kind", "key", "params", "body", "computed", "generator", "async"], fields: Object.assign({}, functionCommon, {}, functionTypeAnnotationCommon, { kind: Object.assign({ validate: assertOneOf("method", "get", "set") }, !process.env.BABEL_TYPES_8_BREAKING ? { "default": "method" } : {}), computed: { "default": false }, key: { validate: function () { var normal = assertNodeType("Identifier", "StringLiteral", "NumericLiteral"); var computed = assertNodeType("Expression"); return function (node, key, val) { var validator = node.computed ? computed : normal; validator(node, key, val); }; }() }, decorators: { validate: chain(assertValueType("array"), assertEach(assertNodeType("Decorator"))), optional: true }, body: { validate: assertNodeType("BlockStatement") } }), visitor: ["key", "params", "body", "decorators", "returnType", "typeParameters"], aliases: ["UserWhitespacable", "Function", "Scopable", "BlockParent", "FunctionParent", "Method", "ObjectMember"] }); defineType("ObjectProperty", { builder: ["key", "value", "computed", "shorthand"].concat(!process.env.BABEL_TYPES_8_BREAKING ? ["decorators"] : []), fields: { computed: { "default": false }, key: { validate: function () { var normal = assertNodeType("Identifier", "StringLiteral", "NumericLiteral"); var computed = assertNodeType("Expression"); return function (node, key, val) { var validator = node.computed ? computed : normal; validator(node, key, val); }; }() }, value: { validate: assertNodeType("Expression", "PatternLike") }, shorthand: { validate: chain(assertValueType("boolean"), function (node, key, val) { if (!process.env.BABEL_TYPES_8_BREAKING) return; if (val && node.computed) { throw new TypeError("Property shorthand of ObjectProperty cannot be true if computed is true"); } }, function (node, key, val) { if (!process.env.BABEL_TYPES_8_BREAKING) return; if (val && !is("Identifier", node.key)) { throw new TypeError("Property shorthand of ObjectProperty cannot be true if key is not an Identifier"); } }), "default": false }, decorators: { validate: chain(assertValueType("array"), assertEach(assertNodeType("Decorator"))), optional: true } }, visitor: ["key", "value", "decorators"], aliases: ["UserWhitespacable", "Property", "ObjectMember"], validate: function () { var pattern = assertNodeType("Identifier", "Pattern"); var expression = assertNodeType("Expression"); return function (parent, key, node) { if (!process.env.BABEL_TYPES_8_BREAKING) return; var validator = is("ObjectPattern", parent) ? pattern : expression; validator(node, "value", node.value); }; }() }); defineType("RestElement", { visitor: ["argument", "typeAnnotation"], builder: ["argument"], aliases: ["LVal", "PatternLike"], deprecatedAlias: "RestProperty", fields: Object.assign({}, patternLikeCommon, { argument: { validate: !process.env.BABEL_TYPES_8_BREAKING ? assertNodeType("LVal") : assertNodeType("Identifier", "Pattern", "MemberExpression") } }), validate: function validate(parent, key) { if (!process.env.BABEL_TYPES_8_BREAKING) return; var match = /(\w+)\[(\d+)\]/.exec(key); if (!match) throw new Error("Internal Babel error: malformed key."); var listKey = match[1], index = match[2]; if (parent[listKey].length > index + 1) { throw new TypeError("RestElement must be last element of " + listKey); } } }); defineType("ReturnStatement", { visitor: ["argument"], aliases: ["Statement", "Terminatorless", "CompletionStatement"], fields: { argument: { validate: assertNodeType("Expression"), optional: true } } }); defineType("SequenceExpression", { visitor: ["expressions"], fields: { expressions: { validate: chain(assertValueType("array"), assertEach(assertNodeType("Expression"))) } }, aliases: ["Expression"] }); defineType("ParenthesizedExpression", { visitor: ["expression"], aliases: ["Expression", "ExpressionWrapper"], fields: { expression: { validate: assertNodeType("Expression") } } }); defineType("SwitchCase", { visitor: ["test", "consequent"], fields: { test: { validate: assertNodeType("Expression"), optional: true }, consequent: { validate: chain(assertValueType("array"), assertEach(assertNodeType("Statement"))) } } }); defineType("SwitchStatement", { visitor: ["discriminant", "cases"], aliases: ["Statement", "BlockParent", "Scopable"], fields: { discriminant: { validate: assertNodeType("Expression") }, cases: { validate: chain(assertValueType("array"), assertEach(assertNodeType("SwitchCase"))) } } }); defineType("ThisExpression", { aliases: ["Expression"] }); defineType("ThrowStatement", { visitor: ["argument"], aliases: ["Statement", "Terminatorless", "CompletionStatement"], fields: { argument: { validate: assertNodeType("Expression") } } }); defineType("TryStatement", { visitor: ["block", "handler", "finalizer"], aliases: ["Statement"], fields: { block: { validate: chain(assertNodeType("BlockStatement"), function (node) { if (!process.env.BABEL_TYPES_8_BREAKING) return; if (!node.handler && !node.finalizer) { throw new TypeError("TryStatement expects either a handler or finalizer, or both"); } }) }, handler: { optional: true, validate: assertNodeType("CatchClause") }, finalizer: { optional: true, validate: assertNodeType("BlockStatement") } } }); defineType("UnaryExpression", { builder: ["operator", "argument", "prefix"], fields: { prefix: { "default": true }, argument: { validate: assertNodeType("Expression") }, operator: { validate: assertOneOf.apply(void 0, UNARY_OPERATORS) } }, visitor: ["argument"], aliases: ["UnaryLike", "Expression"] }); defineType("UpdateExpression", { builder: ["operator", "argument", "prefix"], fields: { prefix: { "default": false }, argument: { validate: !process.env.BABEL_TYPES_8_BREAKING ? assertNodeType("Expression") : assertNodeType("Identifier", "MemberExpression") }, operator: { validate: assertOneOf.apply(void 0, UPDATE_OPERATORS) } }, visitor: ["argument"], aliases: ["Expression"] }); defineType("VariableDeclaration", { builder: ["kind", "declarations"], visitor: ["declarations"], aliases: ["Statement", "Declaration"], fields: { declare: { validate: assertValueType("boolean"), optional: true }, kind: { validate: assertOneOf("var", "let", "const") }, declarations: { validate: chain(assertValueType("array"), assertEach(assertNodeType("VariableDeclarator"))) } }, validate: function validate(parent, key, node) { if (!process.env.BABEL_TYPES_8_BREAKING) return; if (!is("ForXStatement", parent, { left: node })) return; if (node.declarations.length !== 1) { throw new TypeError("Exactly one VariableDeclarator is required in the VariableDeclaration of a " + parent.type); } } }); defineType("VariableDeclarator", { visitor: ["id", "init"], fields: { id: { validate: function () { if (!process.env.BABEL_TYPES_8_BREAKING) { return assertNodeType("LVal"); } var normal = assertNodeType("Identifier", "ArrayPattern", "ObjectPattern"); var without = assertNodeType("Identifier"); return function (node, key, val) { var validator = node.init ? normal : without; validator(node, key, val); }; }() }, definite: { optional: true, validate: assertValueType("boolean") }, init: { optional: true, validate: assertNodeType("Expression") } } }); defineType("WhileStatement", { visitor: ["test", "body"], aliases: ["Statement", "BlockParent", "Loop", "While", "Scopable"], fields: { test: { validate: assertNodeType("Expression") }, body: { validate: assertNodeType("Statement") } } }); defineType("WithStatement", { visitor: ["object", "body"], aliases: ["Statement"], fields: { object: { validate: assertNodeType("Expression") }, body: { validate: assertNodeType("Statement") } } }); defineType("AssignmentPattern", { visitor: ["left", "right", "decorators"], builder: ["left", "right"], aliases: ["Pattern", "PatternLike", "LVal"], fields: Object.assign({}, patternLikeCommon, { left: { validate: assertNodeType("Identifier", "ObjectPattern", "ArrayPattern", "MemberExpression") }, right: { validate: assertNodeType("Expression") }, decorators: { validate: chain(assertValueType("array"), assertEach(assertNodeType("Decorator"))), optional: true } }) }); defineType("ArrayPattern", { visitor: ["elements", "typeAnnotation"], builder: ["elements"], aliases: ["Pattern", "PatternLike", "LVal"], fields: Object.assign({}, patternLikeCommon, { elements: { validate: chain(assertValueType("array"), assertEach(assertNodeOrValueType("null", "PatternLike"))) }, decorators: { validate: chain(assertValueType("array"), assertEach(assertNodeType("Decorator"))), optional: true } }) }); defineType("ArrowFunctionExpression", { builder: ["params", "body", "async"], visitor: ["params", "body", "returnType", "typeParameters"], aliases: ["Scopable", "Function", "BlockParent", "FunctionParent", "Expression", "Pureish"], fields: Object.assign({}, functionCommon, {}, functionTypeAnnotationCommon, { expression: { validate: assertValueType("boolean") }, body: { validate: assertNodeType("BlockStatement", "Expression") } }) }); defineType("ClassBody", { visitor: ["body"], fields: { body: { validate: chain(assertValueType("array"), assertEach(assertNodeType("ClassMethod", "ClassPrivateMethod", "ClassProperty", "ClassPrivateProperty", "TSDeclareMethod", "TSIndexSignature"))) } } }); defineType("ClassExpression", { builder: ["id", "superClass", "body", "decorators"], visitor: ["id", "body", "superClass", "mixins", "typeParameters", "superTypeParameters", "implements", "decorators"], aliases: ["Scopable", "Class", "Expression", "Pureish"], fields: { id: { validate: assertNodeType("Identifier"), optional: true }, typeParameters: { validate: assertNodeType("TypeParameterDeclaration", "TSTypeParameterDeclaration", "Noop"), optional: true }, body: { validate: assertNodeType("ClassBody") }, superClass: { optional: true, validate: assertNodeType("Expression") }, superTypeParameters: { validate: assertNodeType("TypeParameterInstantiation", "TSTypeParameterInstantiation"), optional: true }, "implements": { validate: chain(assertValueType("array"), assertEach(assertNodeType("TSExpressionWithTypeArguments", "ClassImplements"))), optional: true }, decorators: { validate: chain(assertValueType("array"), assertEach(assertNodeType("Decorator"))), optional: true } } }); defineType("ClassDeclaration", { inherits: "ClassExpression", aliases: ["Scopable", "Class", "Statement", "Declaration", "Pureish"], fields: { declare: { validate: assertValueType("boolean"), optional: true }, "abstract": { validate: assertValueType("boolean"), optional: true } }, validate: function () { var identifier = assertNodeType("Identifier"); return function (parent, key, node) { if (!process.env.BABEL_TYPES_8_BREAKING) return; if (!is("ExportDefaultDeclaration", parent)) { identifier(node, "id", node.id); } }; }() }); defineType("ExportAllDeclaration", { visitor: ["source"], aliases: ["Statement", "Declaration", "ModuleDeclaration", "ExportDeclaration"], fields: { source: { validate: assertNodeType("StringLiteral") } } }); defineType("ExportDefaultDeclaration", { visitor: ["declaration"], aliases: ["Statement", "Declaration", "ModuleDeclaration", "ExportDeclaration"], fields: { declaration: { validate: assertNodeType("FunctionDeclaration", "TSDeclareFunction", "ClassDeclaration", "Expression") } } }); defineType("ExportNamedDeclaration", { visitor: ["declaration", "specifiers", "source"], aliases: ["Statement", "Declaration", "ModuleDeclaration", "ExportDeclaration"], fields: { declaration: { optional: true, validate: chain(assertNodeType("Declaration"), function (node, key, val) { if (!process.env.BABEL_TYPES_8_BREAKING) return; if (val && node.specifiers.length) { throw new TypeError("Only declaration or specifiers is allowed on ExportNamedDeclaration"); } }, function (node, key, val) { if (!process.env.BABEL_TYPES_8_BREAKING) return; if (val && node.source) { throw new TypeError("Cannot export a declaration from a source"); } }) }, specifiers: { "default": [], validate: chain(assertValueType("array"), assertEach(function () { var sourced = assertNodeType("ExportSpecifier", "ExportDefaultSpecifier", "ExportNamespaceSpecifier"); var sourceless = assertNodeType("ExportSpecifier"); if (!process.env.BABEL_TYPES_8_BREAKING) return sourced; return function (node, key, val) { var validator = node.source ? sourced : sourceless; validator(node, key, val); }; }())) }, source: { validate: assertNodeType("StringLiteral"), optional: true }, exportKind: validateOptional(assertOneOf("type", "value")) } }); defineType("ExportSpecifier", { visitor: ["local", "exported"], aliases: ["ModuleSpecifier"], fields: { local: { validate: assertNodeType("Identifier") }, exported: { validate: assertNodeType("Identifier") } } }); defineType("ForOfStatement", { visitor: ["left", "right", "body"], builder: ["left", "right", "body", "await"], aliases: ["Scopable", "Statement", "For", "BlockParent", "Loop", "ForXStatement"], fields: { left: { validate: function () { if (!process.env.BABEL_TYPES_8_BREAKING) { return assertNodeType("VariableDeclaration", "LVal"); } var declaration = assertNodeType("VariableDeclaration"); var lval = assertNodeType("Identifier", "MemberExpression", "ArrayPattern", "ObjectPattern"); return function (node, key, val) { if (is("VariableDeclaration", val)) { declaration(node, key, val); } else { lval(node, key, val); } }; }() }, right: { validate: assertNodeType("Expression") }, body: { validate: assertNodeType("Statement") }, "await": { "default": false } } }); defineType("ImportDeclaration", { visitor: ["specifiers", "source"], aliases: ["Statement", "Declaration", "ModuleDeclaration"], fields: { specifiers: { validate: chain(assertValueType("array"), assertEach(assertNodeType("ImportSpecifier", "ImportDefaultSpecifier", "ImportNamespaceSpecifier"))) }, source: { validate: assertNodeType("StringLiteral") }, importKind: { validate: assertOneOf("type", "typeof", "value"), optional: true } } }); defineType("ImportDefaultSpecifier", { visitor: ["local"], aliases: ["ModuleSpecifier"], fields: { local: { validate: assertNodeType("Identifier") } } }); defineType("ImportNamespaceSpecifier", { visitor: ["local"], aliases: ["ModuleSpecifier"], fields: { local: { validate: assertNodeType("Identifier") } } }); defineType("ImportSpecifier", { visitor: ["local", "imported"], aliases: ["ModuleSpecifier"], fields: { local: { validate: assertNodeType("Identifier") }, imported: { validate: assertNodeType("Identifier") }, importKind: { validate: assertOneOf("type", "typeof"), optional: true } } }); defineType("MetaProperty", { visitor: ["meta", "property"], aliases: ["Expression"], fields: { meta: { validate: chain(assertNodeType("Identifier"), function (node, key, val) { if (!process.env.BABEL_TYPES_8_BREAKING) return; var property; switch (val.name) { case "function": property = "sent"; break; case "new": property = "target"; break; case "import": property = "meta"; break; } if (!is("Identifier", node.property, { name: property })) { throw new TypeError("Unrecognised MetaProperty"); } }) }, property: { validate: assertNodeType("Identifier") } } }); var classMethodOrPropertyCommon = { "abstract": { validate: assertValueType("boolean"), optional: true }, accessibility: { validate: assertOneOf("public", "private", "protected"), optional: true }, "static": { "default": false }, computed: { "default": false }, optional: { validate: assertValueType("boolean"), optional: true }, key: { validate: chain(function () { var normal = assertNodeType("Identifier", "StringLiteral", "NumericLiteral"); var computed = assertNodeType("Expression"); return function (node, key, val) { var validator = node.computed ? computed : normal; validator(node, key, val); }; }(), assertNodeType("Identifier", "StringLiteral", "NumericLiteral", "Expression")) } }; var classMethodOrDeclareMethodCommon = Object.assign({}, functionCommon, {}, classMethodOrPropertyCommon, { kind: { validate: assertOneOf("get", "set", "method", "constructor"), "default": "method" }, access: { validate: chain(assertValueType("string"), assertOneOf("public", "private", "protected")), optional: true }, decorators: { validate: chain(assertValueType("array"), assertEach(assertNodeType("Decorator"))), optional: true } }); defineType("ClassMethod", { aliases: ["Function", "Scopable", "BlockParent", "FunctionParent", "Method"], builder: ["kind", "key", "params", "body", "computed", "static", "generator", "async"], visitor: ["key", "params", "body", "decorators", "returnType", "typeParameters"], fields: Object.assign({}, classMethodOrDeclareMethodCommon, {}, functionTypeAnnotationCommon, { body: { validate: assertNodeType("BlockStatement") } }) }); defineType("ObjectPattern", { visitor: ["properties", "typeAnnotation", "decorators"], builder: ["properties"], aliases: ["Pattern", "PatternLike", "LVal"], fields: Object.assign({}, patternLikeCommon, { properties: { validate: chain(assertValueType("array"), assertEach(assertNodeType("RestElement", "ObjectProperty"))) } }) }); defineType("SpreadElement", { visitor: ["argument"], aliases: ["UnaryLike"], deprecatedAlias: "SpreadProperty", fields: { argument: { validate: assertNodeType("Expression") } } }); defineType("Super", { aliases: ["Expression"] }); defineType("TaggedTemplateExpression", { visitor: ["tag", "quasi"], aliases: ["Expression"], fields: { tag: { validate: assertNodeType("Expression") }, quasi: { validate: assertNodeType("TemplateLiteral") }, typeParameters: { validate: assertNodeType("TypeParameterInstantiation", "TSTypeParameterInstantiation"), optional: true } } }); defineType("TemplateElement", { builder: ["value", "tail"], fields: { value: { validate: assertShape({ raw: { validate: assertValueType("string") }, cooked: { validate: assertValueType("string"), optional: true } }) }, tail: { "default": false } } }); defineType("TemplateLiteral", { visitor: ["quasis", "expressions"], aliases: ["Expression", "Literal"], fields: { quasis: { validate: chain(assertValueType("array"), assertEach(assertNodeType("TemplateElement"))) }, expressions: { validate: chain(assertValueType("array"), assertEach(assertNodeType("Expression")), function (node, key, val) { if (node.quasis.length !== val.length + 1) { throw new TypeError("Number of " + node.type + " quasis should be exactly one more than the number of expressions.\nExpected " + (val.length + 1) + " quasis but got " + node.quasis.length); } }) } } }); defineType("YieldExpression", { builder: ["argument", "delegate"], visitor: ["argument"], aliases: ["Expression", "Terminatorless"], fields: { delegate: { validate: chain(assertValueType("boolean"), function (node, key, val) { if (!process.env.BABEL_TYPES_8_BREAKING) return; if (val && !node.argument) { throw new TypeError("Property delegate of YieldExpression cannot be true if there is no argument"); } }), "default": false }, argument: { optional: true, validate: assertNodeType("Expression") } } }); var defineInterfaceishType = function defineInterfaceishType(name, typeParameterType) { if (typeParameterType === void 0) { typeParameterType = "TypeParameterDeclaration"; } defineType(name, { builder: ["id", "typeParameters", "extends", "body"], visitor: ["id", "typeParameters", "extends", "mixins", "implements", "body"], aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], fields: { id: validateType("Identifier"), typeParameters: validateOptionalType(typeParameterType), "extends": validateOptional(arrayOfType("InterfaceExtends")), mixins: validateOptional(arrayOfType("InterfaceExtends")), "implements": validateOptional(arrayOfType("ClassImplements")), body: validateType("ObjectTypeAnnotation") } }); }; defineType("AnyTypeAnnotation", { aliases: ["Flow", "FlowType", "FlowBaseAnnotation"] }); defineType("ArrayTypeAnnotation", { visitor: ["elementType"], aliases: ["Flow", "FlowType"], fields: { elementType: validateType("FlowType") } }); defineType("BooleanTypeAnnotation", { aliases: ["Flow", "FlowType", "FlowBaseAnnotation"] }); defineType("BooleanLiteralTypeAnnotation", { builder: ["value"], aliases: ["Flow", "FlowType"], fields: { value: validate$1(assertValueType("boolean")) } }); defineType("NullLiteralTypeAnnotation", { aliases: ["Flow", "FlowType", "FlowBaseAnnotation"] }); defineType("ClassImplements", { visitor: ["id", "typeParameters"], aliases: ["Flow"], fields: { id: validateType("Identifier"), typeParameters: validateOptionalType("TypeParameterInstantiation") } }); defineInterfaceishType("DeclareClass"); defineType("DeclareFunction", { visitor: ["id"], aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], fields: { id: validateType("Identifier"), predicate: validateOptionalType("DeclaredPredicate") } }); defineInterfaceishType("DeclareInterface"); defineType("DeclareModule", { builder: ["id", "body", "kind"], visitor: ["id", "body"], aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], fields: { id: validateType(["Identifier", "StringLiteral"]), body: validateType("BlockStatement"), kind: validateOptional(assertOneOf("CommonJS", "ES")) } }); defineType("DeclareModuleExports", { visitor: ["typeAnnotation"], aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], fields: { typeAnnotation: validateType("TypeAnnotation") } }); defineType("DeclareTypeAlias", { visitor: ["id", "typeParameters", "right"], aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], fields: { id: validateType("Identifier"), typeParameters: validateOptionalType("TypeParameterDeclaration"), right: validateType("FlowType") } }); defineType("DeclareOpaqueType", { visitor: ["id", "typeParameters", "supertype"], aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], fields: { id: validateType("Identifier"), typeParameters: validateOptionalType("TypeParameterDeclaration"), supertype: validateOptionalType("FlowType") } }); defineType("DeclareVariable", { visitor: ["id"], aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], fields: { id: validateType("Identifier") } }); defineType("DeclareExportDeclaration", { visitor: ["declaration", "specifiers", "source"], aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], fields: { declaration: validateOptionalType("Flow"), specifiers: validateOptional(arrayOfType(["ExportSpecifier", "ExportNamespaceSpecifier"])), source: validateOptionalType("StringLiteral"), "default": validateOptional(assertValueType("boolean")) } }); defineType("DeclareExportAllDeclaration", { visitor: ["source"], aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], fields: { source: validateType("StringLiteral"), exportKind: validateOptional(assertOneOf("type", "value")) } }); defineType("DeclaredPredicate", { visitor: ["value"], aliases: ["Flow", "FlowPredicate"], fields: { value: validateType("Flow") } }); defineType("ExistsTypeAnnotation", { aliases: ["Flow", "FlowType"] }); defineType("FunctionTypeAnnotation", { visitor: ["typeParameters", "params", "rest", "returnType"], aliases: ["Flow", "FlowType"], fields: { typeParameters: validateOptionalType("TypeParameterDeclaration"), params: validate$1(arrayOfType("FunctionTypeParam")), rest: validateOptionalType("FunctionTypeParam"), returnType: validateType("FlowType") } }); defineType("FunctionTypeParam", { visitor: ["name", "typeAnnotation"], aliases: ["Flow"], fields: { name: validateOptionalType("Identifier"), typeAnnotation: validateType("FlowType"), optional: validateOptional(assertValueType("boolean")) } }); defineType("GenericTypeAnnotation", { visitor: ["id", "typeParameters"], aliases: ["Flow", "FlowType"], fields: { id: validateType(["Identifier", "QualifiedTypeIdentifier"]), typeParameters: validateOptionalType("TypeParameterInstantiation") } }); defineType("InferredPredicate", { aliases: ["Flow", "FlowPredicate"] }); defineType("InterfaceExtends", { visitor: ["id", "typeParameters"], aliases: ["Flow"], fields: { id: validateType(["Identifier", "QualifiedTypeIdentifier"]), typeParameters: validateOptionalType("TypeParameterInstantiation") } }); defineInterfaceishType("InterfaceDeclaration"); defineType("InterfaceTypeAnnotation", { visitor: ["extends", "body"], aliases: ["Flow", "FlowType"], fields: { "extends": validateOptional(arrayOfType("InterfaceExtends")), body: validateType("ObjectTypeAnnotation") } }); defineType("IntersectionTypeAnnotation", { visitor: ["types"], aliases: ["Flow", "FlowType"], fields: { types: validate$1(arrayOfType("FlowType")) } }); defineType("MixedTypeAnnotation", { aliases: ["Flow", "FlowType", "FlowBaseAnnotation"] }); defineType("EmptyTypeAnnotation", { aliases: ["Flow", "FlowType", "FlowBaseAnnotation"] }); defineType("NullableTypeAnnotation", { visitor: ["typeAnnotation"], aliases: ["Flow", "FlowType"], fields: { typeAnnotation: validateType("FlowType") } }); defineType("NumberLiteralTypeAnnotation", { builder: ["value"], aliases: ["Flow", "FlowType"], fields: { value: validate$1(assertValueType("number")) } }); defineType("NumberTypeAnnotation", { aliases: ["Flow", "FlowType", "FlowBaseAnnotation"] }); defineType("ObjectTypeAnnotation", { visitor: ["properties", "indexers", "callProperties", "internalSlots"], aliases: ["Flow", "FlowType"], builder: ["properties", "indexers", "callProperties", "internalSlots", "exact"], fields: { properties: validate$1(arrayOfType(["ObjectTypeProperty", "ObjectTypeSpreadProperty"])), indexers: validateOptional(arrayOfType("ObjectTypeIndexer")), callProperties: validateOptional(arrayOfType("ObjectTypeCallProperty")), internalSlots: validateOptional(arrayOfType("ObjectTypeInternalSlot")), exact: { validate: assertValueType("boolean"), "default": false }, inexact: validateOptional(assertValueType("boolean")) } }); defineType("ObjectTypeInternalSlot", { visitor: ["id", "value", "optional", "static", "method"], aliases: ["Flow", "UserWhitespacable"], fields: { id: validateType("Identifier"), value: validateType("FlowType"), optional: validate$1(assertValueType("boolean")), "static": validate$1(assertValueType("boolean")), method: validate$1(assertValueType("boolean")) } }); defineType("ObjectTypeCallProperty", { visitor: ["value"], aliases: ["Flow", "UserWhitespacable"], fields: { value: validateType("FlowType"), "static": validate$1(assertValueType("boolean")) } }); defineType("ObjectTypeIndexer", { visitor: ["id", "key", "value", "variance"], aliases: ["Flow", "UserWhitespacable"], fields: { id: validateOptionalType("Identifier"), key: validateType("FlowType"), value: validateType("FlowType"), "static": validate$1(assertValueType("boolean")), variance: validateOptionalType("Variance") } }); defineType("ObjectTypeProperty", { visitor: ["key", "value", "variance"], aliases: ["Flow", "UserWhitespacable"], fields: { key: validateType(["Identifier", "StringLiteral"]), value: validateType("FlowType"), kind: validate$1(assertOneOf("init", "get", "set")), "static": validate$1(assertValueType("boolean")), proto: validate$1(assertValueType("boolean")), optional: validate$1(assertValueType("boolean")), variance: validateOptionalType("Variance") } }); defineType("ObjectTypeSpreadProperty", { visitor: ["argument"], aliases: ["Flow", "UserWhitespacable"], fields: { argument: validateType("FlowType") } }); defineType("OpaqueType", { visitor: ["id", "typeParameters", "supertype", "impltype"], aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], fields: { id: validateType("Identifier"), typeParameters: validateOptionalType("TypeParameterDeclaration"), supertype: validateOptionalType("FlowType"), impltype: validateType("FlowType") } }); defineType("QualifiedTypeIdentifier", { visitor: ["id", "qualification"], aliases: ["Flow"], fields: { id: validateType("Identifier"), qualification: validateType(["Identifier", "QualifiedTypeIdentifier"]) } }); defineType("StringLiteralTypeAnnotation", { builder: ["value"], aliases: ["Flow", "FlowType"], fields: { value: validate$1(assertValueType("string")) } }); defineType("StringTypeAnnotation", { aliases: ["Flow", "FlowType", "FlowBaseAnnotation"] }); defineType("ThisTypeAnnotation", { aliases: ["Flow", "FlowType", "FlowBaseAnnotation"] }); defineType("TupleTypeAnnotation", { visitor: ["types"], aliases: ["Flow", "FlowType"], fields: { types: validate$1(arrayOfType("FlowType")) } }); defineType("TypeofTypeAnnotation", { visitor: ["argument"], aliases: ["Flow", "FlowType"], fields: { argument: validateType("FlowType") } }); defineType("TypeAlias", { visitor: ["id", "typeParameters", "right"], aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], fields: { id: validateType("Identifier"), typeParameters: validateOptionalType("TypeParameterDeclaration"), right: validateType("FlowType") } }); defineType("TypeAnnotation", { aliases: ["Flow"], visitor: ["typeAnnotation"], fields: { typeAnnotation: validateType("FlowType") } }); defineType("TypeCastExpression", { visitor: ["expression", "typeAnnotation"], aliases: ["Flow", "ExpressionWrapper", "Expression"], fields: { expression: validateType("Expression"), typeAnnotation: validateType("TypeAnnotation") } }); defineType("TypeParameter", { aliases: ["Flow"], visitor: ["bound", "default", "variance"], fields: { name: validate$1(assertValueType("string")), bound: validateOptionalType("TypeAnnotation"), "default": validateOptionalType("FlowType"), variance: validateOptionalType("Variance") } }); defineType("TypeParameterDeclaration", { aliases: ["Flow"], visitor: ["params"], fields: { params: validate$1(arrayOfType("TypeParameter")) } }); defineType("TypeParameterInstantiation", { aliases: ["Flow"], visitor: ["params"], fields: { params: validate$1(arrayOfType("FlowType")) } }); defineType("UnionTypeAnnotation", { visitor: ["types"], aliases: ["Flow", "FlowType"], fields: { types: validate$1(arrayOfType("FlowType")) } }); defineType("Variance", { aliases: ["Flow"], builder: ["kind"], fields: { kind: validate$1(assertOneOf("minus", "plus")) } }); defineType("VoidTypeAnnotation", { aliases: ["Flow", "FlowType", "FlowBaseAnnotation"] }); defineType("EnumDeclaration", { aliases: ["Declaration"], visitor: ["id", "body"], fields: { id: validateType("Identifier"), body: validateType(["EnumBooleanBody", "EnumNumberBody", "EnumStringBody", "EnumSymbolBody"]) } }); defineType("EnumBooleanBody", { aliases: ["EnumBody"], visitor: ["members"], fields: { explicit: validate$1(assertValueType("boolean")), members: validateArrayOfType("EnumBooleanMember") } }); defineType("EnumNumberBody", { aliases: ["EnumBody"], visitor: ["members"], fields: { explicit: validate$1(assertValueType("boolean")), members: validateArrayOfType("EnumNumberMember") } }); defineType("EnumStringBody", { aliases: ["EnumBody"], visitor: ["members"], fields: { explicit: validate$1(assertValueType("boolean")), members: validateArrayOfType(["EnumStringMember", "EnumDefaultedMember"]) } }); defineType("EnumSymbolBody", { aliases: ["EnumBody"], visitor: ["members"], fields: { members: validateArrayOfType("EnumDefaultedMember") } }); defineType("EnumBooleanMember", { aliases: ["EnumMember"], visitor: ["id"], fields: { id: validateType("Identifier"), init: validateType("BooleanLiteral") } }); defineType("EnumNumberMember", { aliases: ["EnumMember"], visitor: ["id", "init"], fields: { id: validateType("Identifier"), init: validateType("NumericLiteral") } }); defineType("EnumStringMember", { aliases: ["EnumMember"], visitor: ["id", "init"], fields: { id: validateType("Identifier"), init: validateType("StringLiteral") } }); defineType("EnumDefaultedMember", { aliases: ["EnumMember"], visitor: ["id"], fields: { id: validateType("Identifier") } }); defineType("JSXAttribute", { visitor: ["name", "value"], aliases: ["JSX", "Immutable"], fields: { name: { validate: assertNodeType("JSXIdentifier", "JSXNamespacedName") }, value: { optional: true, validate: assertNodeType("JSXElement", "JSXFragment", "StringLiteral", "JSXExpressionContainer") } } }); defineType("JSXClosingElement", { visitor: ["name"], aliases: ["JSX", "Immutable"], fields: { name: { validate: assertNodeType("JSXIdentifier", "JSXMemberExpression", "JSXNamespacedName") } } }); defineType("JSXElement", { builder: ["openingElement", "closingElement", "children", "selfClosing"], visitor: ["openingElement", "children", "closingElement"], aliases: ["JSX", "Immutable", "Expression"], fields: { openingElement: { validate: assertNodeType("JSXOpeningElement") }, closingElement: { optional: true, validate: assertNodeType("JSXClosingElement") }, children: { validate: chain(assertValueType("array"), assertEach(assertNodeType("JSXText", "JSXExpressionContainer", "JSXSpreadChild", "JSXElement", "JSXFragment"))) } } }); defineType("JSXEmptyExpression", { aliases: ["JSX"] }); defineType("JSXExpressionContainer", { visitor: ["expression"], aliases: ["JSX", "Immutable"], fields: { expression: { validate: assertNodeType("Expression", "JSXEmptyExpression") } } }); defineType("JSXSpreadChild", { visitor: ["expression"], aliases: ["JSX", "Immutable"], fields: { expression: { validate: assertNodeType("Expression") } } }); defineType("JSXIdentifier", { builder: ["name"], aliases: ["JSX"], fields: { name: { validate: assertValueType("string") } } }); defineType("JSXMemberExpression", { visitor: ["object", "property"], aliases: ["JSX"], fields: { object: { validate: assertNodeType("JSXMemberExpression", "JSXIdentifier") }, property: { validate: assertNodeType("JSXIdentifier") } } }); defineType("JSXNamespacedName", { visitor: ["namespace", "name"], aliases: ["JSX"], fields: { namespace: { validate: assertNodeType("JSXIdentifier") }, name: { validate: assertNodeType("JSXIdentifier") } } }); defineType("JSXOpeningElement", { builder: ["name", "attributes", "selfClosing"], visitor: ["name", "attributes"], aliases: ["JSX", "Immutable"], fields: { name: { validate: assertNodeType("JSXIdentifier", "JSXMemberExpression", "JSXNamespacedName") }, selfClosing: { "default": false }, attributes: { validate: chain(assertValueType("array"), assertEach(assertNodeType("JSXAttribute", "JSXSpreadAttribute"))) }, typeParameters: { validate: assertNodeType("TypeParameterInstantiation", "TSTypeParameterInstantiation"), optional: true } } }); defineType("JSXSpreadAttribute", { visitor: ["argument"], aliases: ["JSX"], fields: { argument: { validate: assertNodeType("Expression") } } }); defineType("JSXText", { aliases: ["JSX", "Immutable"], builder: ["value"], fields: { value: { validate: assertValueType("string") } } }); defineType("JSXFragment", { builder: ["openingFragment", "closingFragment", "children"], visitor: ["openingFragment", "children", "closingFragment"], aliases: ["JSX", "Immutable", "Expression"], fields: { openingFragment: { validate: assertNodeType("JSXOpeningFragment") }, closingFragment: { validate: assertNodeType("JSXClosingFragment") }, children: { validate: chain(assertValueType("array"), assertEach(assertNodeType("JSXText", "JSXExpressionContainer", "JSXSpreadChild", "JSXElement", "JSXFragment"))) } } }); defineType("JSXOpeningFragment", { aliases: ["JSX", "Immutable"] }); defineType("JSXClosingFragment", { aliases: ["JSX", "Immutable"] }); var PLACEHOLDERS = ["Identifier", "StringLiteral", "Expression", "Statement", "Declaration", "BlockStatement", "ClassBody", "Pattern"]; var PLACEHOLDERS_ALIAS = { Declaration: ["Statement"], Pattern: ["PatternLike", "LVal"] }; for (var _i = 0, _PLACEHOLDERS = PLACEHOLDERS; _i < _PLACEHOLDERS.length; _i++) { var type = _PLACEHOLDERS[_i]; var alias = ALIAS_KEYS[type]; if (alias && alias.length) PLACEHOLDERS_ALIAS[type] = alias; } var PLACEHOLDERS_FLIPPED_ALIAS = {}; Object.keys(PLACEHOLDERS_ALIAS).forEach(function (type) { PLACEHOLDERS_ALIAS[type].forEach(function (alias) { if (!Object.hasOwnProperty.call(PLACEHOLDERS_FLIPPED_ALIAS, alias)) { PLACEHOLDERS_FLIPPED_ALIAS[alias] = []; } PLACEHOLDERS_FLIPPED_ALIAS[alias].push(type); }); }); defineType("Noop", { visitor: [] }); defineType("Placeholder", { visitor: [], builder: ["expectedNode", "name"], fields: { name: { validate: assertNodeType("Identifier") }, expectedNode: { validate: assertOneOf.apply(void 0, PLACEHOLDERS) } } }); defineType("V8IntrinsicIdentifier", { builder: ["name"], fields: { name: { validate: assertValueType("string") } } }); defineType("ArgumentPlaceholder", {}); defineType("AwaitExpression", { builder: ["argument"], visitor: ["argument"], aliases: ["Expression", "Terminatorless"], fields: { argument: { validate: assertNodeType("Expression") } } }); defineType("BindExpression", { visitor: ["object", "callee"], aliases: ["Expression"], fields: !process.env.BABEL_TYPES_8_BREAKING ? {} : { object: { validate: assertNodeType("Expression") }, callee: { validate: assertNodeType("Expression") } } }); defineType("ClassProperty", { visitor: ["key", "value", "typeAnnotation", "decorators"], builder: ["key", "value", "typeAnnotation", "decorators", "computed", "static"], aliases: ["Property"], fields: Object.assign({}, classMethodOrPropertyCommon, { value: { validate: assertNodeType("Expression"), optional: true }, definite: { validate: assertValueType("boolean"), optional: true }, typeAnnotation: { validate: assertNodeType("TypeAnnotation", "TSTypeAnnotation", "Noop"), optional: true }, decorators: { validate: chain(assertValueType("array"), assertEach(assertNodeType("Decorator"))), optional: true }, readonly: { validate: assertValueType("boolean"), optional: true }, declare: { validate: assertValueType("boolean"), optional: true } }) }); defineType("OptionalMemberExpression", { builder: ["object", "property", "computed", "optional"], visitor: ["object", "property"], aliases: ["Expression"], fields: { object: { validate: assertNodeType("Expression") }, property: { validate: function () { var normal = assertNodeType("Identifier"); var computed = assertNodeType("Expression"); return function (node, key, val) { var validator = node.computed ? computed : normal; validator(node, key, val); }; }() }, computed: { "default": false }, optional: { validate: assertValueType("boolean") } } }); defineType("PipelineTopicExpression", { builder: ["expression"], visitor: ["expression"], fields: { expression: { validate: assertNodeType("Expression") } } }); defineType("PipelineBareFunction", { builder: ["callee"], visitor: ["callee"], fields: { callee: { validate: assertNodeType("Expression") } } }); defineType("PipelinePrimaryTopicReference", { aliases: ["Expression"] }); defineType("OptionalCallExpression", { visitor: ["callee", "arguments", "typeParameters", "typeArguments"], builder: ["callee", "arguments", "optional"], aliases: ["Expression"], fields: { callee: { validate: assertNodeType("Expression") }, arguments: { validate: chain(assertValueType("array"), assertEach(assertNodeType("Expression", "SpreadElement", "JSXNamespacedName"))) }, optional: { validate: assertValueType("boolean") }, typeArguments: { validate: assertNodeType("TypeParameterInstantiation"), optional: true }, typeParameters: { validate: assertNodeType("TSTypeParameterInstantiation"), optional: true } } }); defineType("ClassPrivateProperty", { visitor: ["key", "value", "decorators"], builder: ["key", "value", "decorators"], aliases: ["Property", "Private"], fields: { key: { validate: assertNodeType("PrivateName") }, value: { validate: assertNodeType("Expression"), optional: true }, decorators: { validate: chain(assertValueType("array"), assertEach(assertNodeType("Decorator"))), optional: true } } }); defineType("ClassPrivateMethod", { builder: ["kind", "key", "params", "body", "static"], visitor: ["key", "params", "body", "decorators", "returnType", "typeParameters"], aliases: ["Function", "Scopable", "BlockParent", "FunctionParent", "Method", "Private"], fields: Object.assign({}, classMethodOrDeclareMethodCommon, { key: { validate: assertNodeType("PrivateName") }, body: { validate: assertNodeType("BlockStatement") } }) }); defineType("Import", { aliases: ["Expression"] }); defineType("Decorator", { visitor: ["expression"], fields: { expression: { validate: assertNodeType("Expression") } } }); defineType("DoExpression", { visitor: ["body"], aliases: ["Expression"], fields: { body: { validate: assertNodeType("BlockStatement") } } }); defineType("ExportDefaultSpecifier", { visitor: ["exported"], aliases: ["ModuleSpecifier"], fields: { exported: { validate: assertNodeType("Identifier") } } }); defineType("ExportNamespaceSpecifier", { visitor: ["exported"], aliases: ["ModuleSpecifier"], fields: { exported: { validate: assertNodeType("Identifier") } } }); defineType("PrivateName", { visitor: ["id"], aliases: ["Private"], fields: { id: { validate: assertNodeType("Identifier") } } }); defineType("BigIntLiteral", { builder: ["value"], fields: { value: { validate: assertValueType("string") } }, aliases: ["Expression", "Pureish", "Literal", "Immutable"] }); var bool = assertValueType("boolean"); var tSFunctionTypeAnnotationCommon = { returnType: { validate: assertNodeType("TSTypeAnnotation", "Noop"), optional: true }, typeParameters: { validate: assertNodeType("TSTypeParameterDeclaration", "Noop"), optional: true } }; defineType("TSParameterProperty", { aliases: ["LVal"], visitor: ["parameter"], fields: { accessibility: { validate: assertOneOf("public", "private", "protected"), optional: true }, readonly: { validate: assertValueType("boolean"), optional: true }, parameter: { validate: assertNodeType("Identifier", "AssignmentPattern") } } }); defineType("TSDeclareFunction", { aliases: ["Statement", "Declaration"], visitor: ["id", "typeParameters", "params", "returnType"], fields: Object.assign({}, functionDeclarationCommon, {}, tSFunctionTypeAnnotationCommon) }); defineType("TSDeclareMethod", { visitor: ["decorators", "key", "typeParameters", "params", "returnType"], fields: Object.assign({}, classMethodOrDeclareMethodCommon, {}, tSFunctionTypeAnnotationCommon) }); defineType("TSQualifiedName", { aliases: ["TSEntityName"], visitor: ["left", "right"], fields: { left: validateType("TSEntityName"), right: validateType("Identifier") } }); var signatureDeclarationCommon = { typeParameters: validateOptionalType("TSTypeParameterDeclaration"), parameters: validateArrayOfType(["Identifier", "RestElement"]), typeAnnotation: validateOptionalType("TSTypeAnnotation") }; var callConstructSignatureDeclaration = { aliases: ["TSTypeElement"], visitor: ["typeParameters", "parameters", "typeAnnotation"], fields: signatureDeclarationCommon }; defineType("TSCallSignatureDeclaration", callConstructSignatureDeclaration); defineType("TSConstructSignatureDeclaration", callConstructSignatureDeclaration); var namedTypeElementCommon = { key: validateType("Expression"), computed: validate$1(bool), optional: validateOptional(bool) }; defineType("TSPropertySignature", { aliases: ["TSTypeElement"], visitor: ["key", "typeAnnotation", "initializer"], fields: Object.assign({}, namedTypeElementCommon, { readonly: validateOptional(bool), typeAnnotation: validateOptionalType("TSTypeAnnotation"), initializer: validateOptionalType("Expression") }) }); defineType("TSMethodSignature", { aliases: ["TSTypeElement"], visitor: ["key", "typeParameters", "parameters", "typeAnnotation"], fields: Object.assign({}, signatureDeclarationCommon, {}, namedTypeElementCommon) }); defineType("TSIndexSignature", { aliases: ["TSTypeElement"], visitor: ["parameters", "typeAnnotation"], fields: { readonly: validateOptional(bool), parameters: validateArrayOfType("Identifier"), typeAnnotation: validateOptionalType("TSTypeAnnotation") } }); var tsKeywordTypes = ["TSAnyKeyword", "TSBooleanKeyword", "TSBigIntKeyword", "TSNeverKeyword", "TSNullKeyword", "TSNumberKeyword", "TSObjectKeyword", "TSStringKeyword", "TSSymbolKeyword", "TSUndefinedKeyword", "TSUnknownKeyword", "TSVoidKeyword"]; for (var _i$1 = 0, _tsKeywordTypes = tsKeywordTypes; _i$1 < _tsKeywordTypes.length; _i$1++) { var type$1 = _tsKeywordTypes[_i$1]; defineType(type$1, { aliases: ["TSType"], visitor: [], fields: {} }); } defineType("TSThisType", { aliases: ["TSType"], visitor: [], fields: {} }); var fnOrCtr = { aliases: ["TSType"], visitor: ["typeParameters", "parameters", "typeAnnotation"], fields: signatureDeclarationCommon }; defineType("TSFunctionType", fnOrCtr); defineType("TSConstructorType", fnOrCtr); defineType("TSTypeReference", { aliases: ["TSType"], visitor: ["typeName", "typeParameters"], fields: { typeName: validateType("TSEntityName"), typeParameters: validateOptionalType("TSTypeParameterInstantiation") } }); defineType("TSTypePredicate", { aliases: ["TSType"], visitor: ["parameterName", "typeAnnotation"], builder: ["parameterName", "typeAnnotation", "asserts"], fields: { parameterName: validateType(["Identifier", "TSThisType"]), typeAnnotation: validateOptionalType("TSTypeAnnotation"), asserts: validateOptional(bool) } }); defineType("TSTypeQuery", { aliases: ["TSType"], visitor: ["exprName"], fields: { exprName: validateType(["TSEntityName", "TSImportType"]) } }); defineType("TSTypeLiteral", { aliases: ["TSType"], visitor: ["members"], fields: { members: validateArrayOfType("TSTypeElement") } }); defineType("TSArrayType", { aliases: ["TSType"], visitor: ["elementType"], fields: { elementType: validateType("TSType") } }); defineType("TSTupleType", { aliases: ["TSType"], visitor: ["elementTypes"], fields: { elementTypes: validateArrayOfType("TSType") } }); defineType("TSOptionalType", { aliases: ["TSType"], visitor: ["typeAnnotation"], fields: { typeAnnotation: validateType("TSType") } }); defineType("TSRestType", { aliases: ["TSType"], visitor: ["typeAnnotation"], fields: { typeAnnotation: validateType("TSType") } }); var unionOrIntersection = { aliases: ["TSType"], visitor: ["types"], fields: { types: validateArrayOfType("TSType") } }; defineType("TSUnionType", unionOrIntersection); defineType("TSIntersectionType", unionOrIntersection); defineType("TSConditionalType", { aliases: ["TSType"], visitor: ["checkType", "extendsType", "trueType", "falseType"], fields: { checkType: validateType("TSType"), extendsType: validateType("TSType"), trueType: validateType("TSType"), falseType: validateType("TSType") } }); defineType("TSInferType", { aliases: ["TSType"], visitor: ["typeParameter"], fields: { typeParameter: validateType("TSTypeParameter") } }); defineType("TSParenthesizedType", { aliases: ["TSType"], visitor: ["typeAnnotation"], fields: { typeAnnotation: validateType("TSType") } }); defineType("TSTypeOperator", { aliases: ["TSType"], visitor: ["typeAnnotation"], fields: { operator: validate$1(assertValueType("string")), typeAnnotation: validateType("TSType") } }); defineType("TSIndexedAccessType", { aliases: ["TSType"], visitor: ["objectType", "indexType"], fields: { objectType: validateType("TSType"), indexType: validateType("TSType") } }); defineType("TSMappedType", { aliases: ["TSType"], visitor: ["typeParameter", "typeAnnotation"], fields: { readonly: validateOptional(bool), typeParameter: validateType("TSTypeParameter"), optional: validateOptional(bool), typeAnnotation: validateOptionalType("TSType") } }); defineType("TSLiteralType", { aliases: ["TSType"], visitor: ["literal"], fields: { literal: validateType(["NumericLiteral", "StringLiteral", "BooleanLiteral"]) } }); defineType("TSExpressionWithTypeArguments", { aliases: ["TSType"], visitor: ["expression", "typeParameters"], fields: { expression: validateType("TSEntityName"), typeParameters: validateOptionalType("TSTypeParameterInstantiation") } }); defineType("TSInterfaceDeclaration", { aliases: ["Statement", "Declaration"], visitor: ["id", "typeParameters", "extends", "body"], fields: { declare: validateOptional(bool), id: validateType("Identifier"), typeParameters: validateOptionalType("TSTypeParameterDeclaration"), "extends": validateOptional(arrayOfType("TSExpressionWithTypeArguments")), body: validateType("TSInterfaceBody") } }); defineType("TSInterfaceBody", { visitor: ["body"], fields: { body: validateArrayOfType("TSTypeElement") } }); defineType("TSTypeAliasDeclaration", { aliases: ["Statement", "Declaration"], visitor: ["id", "typeParameters", "typeAnnotation"], fields: { declare: validateOptional(bool), id: validateType("Identifier"), typeParameters: validateOptionalType("TSTypeParameterDeclaration"), typeAnnotation: validateType("TSType") } }); defineType("TSAsExpression", { aliases: ["Expression"], visitor: ["expression", "typeAnnotation"], fields: { expression: validateType("Expression"), typeAnnotation: validateType("TSType") } }); defineType("TSTypeAssertion", { aliases: ["Expression"], visitor: ["typeAnnotation", "expression"], fields: { typeAnnotation: validateType("TSType"), expression: validateType("Expression") } }); defineType("TSEnumDeclaration", { aliases: ["Statement", "Declaration"], visitor: ["id", "members"], fields: { declare: validateOptional(bool), "const": validateOptional(bool), id: validateType("Identifier"), members: validateArrayOfType("TSEnumMember"), initializer: validateOptionalType("Expression") } }); defineType("TSEnumMember", { visitor: ["id", "initializer"], fields: { id: validateType(["Identifier", "StringLiteral"]), initializer: validateOptionalType("Expression") } }); defineType("TSModuleDeclaration", { aliases: ["Statement", "Declaration"], visitor: ["id", "body"], fields: { declare: validateOptional(bool), global: validateOptional(bool), id: validateType(["Identifier", "StringLiteral"]), body: validateType(["TSModuleBlock", "TSModuleDeclaration"]) } }); defineType("TSModuleBlock", { aliases: ["Scopable", "Block", "BlockParent"], visitor: ["body"], fields: { body: validateArrayOfType("Statement") } }); defineType("TSImportType", { aliases: ["TSType"], visitor: ["argument", "qualifier", "typeParameters"], fields: { argument: validateType("StringLiteral"), qualifier: validateOptionalType("TSEntityName"), typeParameters: validateOptionalType("TSTypeParameterInstantiation") } }); defineType("TSImportEqualsDeclaration", { aliases: ["Statement"], visitor: ["id", "moduleReference"], fields: { isExport: validate$1(bool), id: validateType("Identifier"), moduleReference: validateType(["TSEntityName", "TSExternalModuleReference"]) } }); defineType("TSExternalModuleReference", { visitor: ["expression"], fields: { expression: validateType("StringLiteral") } }); defineType("TSNonNullExpression", { aliases: ["Expression"], visitor: ["expression"], fields: { expression: validateType("Expression") } }); defineType("TSExportAssignment", { aliases: ["Statement"], visitor: ["expression"], fields: { expression: validateType("Expression") } }); defineType("TSNamespaceExportDeclaration", { aliases: ["Statement"], visitor: ["id"], fields: { id: validateType("Identifier") } }); defineType("TSTypeAnnotation", { visitor: ["typeAnnotation"], fields: { typeAnnotation: { validate: assertNodeType("TSType") } } }); defineType("TSTypeParameterInstantiation", { visitor: ["params"], fields: { params: { validate: chain(assertValueType("array"), assertEach(assertNodeType("TSType"))) } } }); defineType("TSTypeParameterDeclaration", { visitor: ["params"], fields: { params: { validate: chain(assertValueType("array"), assertEach(assertNodeType("TSTypeParameter"))) } } }); defineType("TSTypeParameter", { builder: ["constraint", "default", "name"], visitor: ["constraint", "default"], fields: { name: { validate: assertValueType("string") }, constraint: { validate: assertNodeType("TSType"), optional: true }, "default": { validate: assertNodeType("TSType"), optional: true } } }); toFastProperties(VISITOR_KEYS); toFastProperties(ALIAS_KEYS); toFastProperties(FLIPPED_ALIAS_KEYS); toFastProperties(NODE_FIELDS); toFastProperties(BUILDER_KEYS); toFastProperties(DEPRECATED_KEYS); toFastProperties(PLACEHOLDERS_ALIAS); toFastProperties(PLACEHOLDERS_FLIPPED_ALIAS); var TYPES = Object.keys(VISITOR_KEYS).concat(Object.keys(FLIPPED_ALIAS_KEYS)).concat(Object.keys(DEPRECATED_KEYS)); function builder(type) { for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { args[_key - 1] = arguments[_key]; } var keys = BUILDER_KEYS[type]; var countArgs = args.length; if (countArgs > keys.length) { throw new Error(type + ": Too many arguments passed. Received " + countArgs + " but can receive no more than " + keys.length); } var node = { type: type }; var i = 0; keys.forEach(function (key) { var field = NODE_FIELDS[type][key]; var arg; if (i < countArgs) arg = args[i]; if (arg === undefined) arg = clone_1(field["default"]); node[key] = arg; i++; }); for (var _i = 0, _Object$keys = Object.keys(node); _i < _Object$keys.length; _i++) { var key = _Object$keys[_i]; validate(node, key, node[key]); } return node; } function ArrayExpression() { for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) { args[_key] = arguments[_key]; } return builder.apply(void 0, ["ArrayExpression"].concat(args)); } function AssignmentExpression() { for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) { args[_key2] = arguments[_key2]; } return builder.apply(void 0, ["AssignmentExpression"].concat(args)); } function BinaryExpression() { for (var _len3 = arguments.length, args = new Array(_len3), _key3 = 0; _key3 < _len3; _key3++) { args[_key3] = arguments[_key3]; } return builder.apply(void 0, ["BinaryExpression"].concat(args)); } function InterpreterDirective() { for (var _len4 = arguments.length, args = new Array(_len4), _key4 = 0; _key4 < _len4; _key4++) { args[_key4] = arguments[_key4]; } return builder.apply(void 0, ["InterpreterDirective"].concat(args)); } function Directive() { for (var _len5 = arguments.length, args = new Array(_len5), _key5 = 0; _key5 < _len5; _key5++) { args[_key5] = arguments[_key5]; } return builder.apply(void 0, ["Directive"].concat(args)); } function DirectiveLiteral() { for (var _len6 = arguments.length, args = new Array(_len6), _key6 = 0; _key6 < _len6; _key6++) { args[_key6] = arguments[_key6]; } return builder.apply(void 0, ["DirectiveLiteral"].concat(args)); } function BlockStatement() { for (var _len7 = arguments.length, args = new Array(_len7), _key7 = 0; _key7 < _len7; _key7++) { args[_key7] = arguments[_key7]; } return builder.apply(void 0, ["BlockStatement"].concat(args)); } function BreakStatement() { for (var _len8 = arguments.length, args = new Array(_len8), _key8 = 0; _key8 < _len8; _key8++) { args[_key8] = arguments[_key8]; } return builder.apply(void 0, ["BreakStatement"].concat(args)); } function CallExpression() { for (var _len9 = arguments.length, args = new Array(_len9), _key9 = 0; _key9 < _len9; _key9++) { args[_key9] = arguments[_key9]; } return builder.apply(void 0, ["CallExpression"].concat(args)); } function CatchClause() { for (var _len10 = arguments.length, args = new Array(_len10), _key10 = 0; _key10 < _len10; _key10++) { args[_key10] = arguments[_key10]; } return builder.apply(void 0, ["CatchClause"].concat(args)); } function ConditionalExpression() { for (var _len11 = arguments.length, args = new Array(_len11), _key11 = 0; _key11 < _len11; _key11++) { args[_key11] = arguments[_key11]; } return builder.apply(void 0, ["ConditionalExpression"].concat(args)); } function ContinueStatement() { for (var _len12 = arguments.length, args = new Array(_len12), _key12 = 0; _key12 < _len12; _key12++) { args[_key12] = arguments[_key12]; } return builder.apply(void 0, ["ContinueStatement"].concat(args)); } function DebuggerStatement() { for (var _len13 = arguments.length, args = new Array(_len13), _key13 = 0; _key13 < _len13; _key13++) { args[_key13] = arguments[_key13]; } return builder.apply(void 0, ["DebuggerStatement"].concat(args)); } function DoWhileStatement() { for (var _len14 = arguments.length, args = new Array(_len14), _key14 = 0; _key14 < _len14; _key14++) { args[_key14] = arguments[_key14]; } return builder.apply(void 0, ["DoWhileStatement"].concat(args)); } function EmptyStatement() { for (var _len15 = arguments.length, args = new Array(_len15), _key15 = 0; _key15 < _len15; _key15++) { args[_key15] = arguments[_key15]; } return builder.apply(void 0, ["EmptyStatement"].concat(args)); } function ExpressionStatement() { for (var _len16 = arguments.length, args = new Array(_len16), _key16 = 0; _key16 < _len16; _key16++) { args[_key16] = arguments[_key16]; } return builder.apply(void 0, ["ExpressionStatement"].concat(args)); } function File() { for (var _len17 = arguments.length, args = new Array(_len17), _key17 = 0; _key17 < _len17; _key17++) { args[_key17] = arguments[_key17]; } return builder.apply(void 0, ["File"].concat(args)); } function ForInStatement() { for (var _len18 = arguments.length, args = new Array(_len18), _key18 = 0; _key18 < _len18; _key18++) { args[_key18] = arguments[_key18]; } return builder.apply(void 0, ["ForInStatement"].concat(args)); } function ForStatement() { for (var _len19 = arguments.length, args = new Array(_len19), _key19 = 0; _key19 < _len19; _key19++) { args[_key19] = arguments[_key19]; } return builder.apply(void 0, ["ForStatement"].concat(args)); } function FunctionDeclaration() { for (var _len20 = arguments.length, args = new Array(_len20), _key20 = 0; _key20 < _len20; _key20++) { args[_key20] = arguments[_key20]; } return builder.apply(void 0, ["FunctionDeclaration"].concat(args)); } function FunctionExpression() { for (var _len21 = arguments.length, args = new Array(_len21), _key21 = 0; _key21 < _len21; _key21++) { args[_key21] = arguments[_key21]; } return builder.apply(void 0, ["FunctionExpression"].concat(args)); } function Identifier() { for (var _len22 = arguments.length, args = new Array(_len22), _key22 = 0; _key22 < _len22; _key22++) { args[_key22] = arguments[_key22]; } return builder.apply(void 0, ["Identifier"].concat(args)); } function IfStatement() { for (var _len23 = arguments.length, args = new Array(_len23), _key23 = 0; _key23 < _len23; _key23++) { args[_key23] = arguments[_key23]; } return builder.apply(void 0, ["IfStatement"].concat(args)); } function LabeledStatement() { for (var _len24 = arguments.length, args = new Array(_len24), _key24 = 0; _key24 < _len24; _key24++) { args[_key24] = arguments[_key24]; } return builder.apply(void 0, ["LabeledStatement"].concat(args)); } function StringLiteral() { for (var _len25 = arguments.length, args = new Array(_len25), _key25 = 0; _key25 < _len25; _key25++) { args[_key25] = arguments[_key25]; } return builder.apply(void 0, ["StringLiteral"].concat(args)); } function NumericLiteral() { for (var _len26 = arguments.length, args = new Array(_len26), _key26 = 0; _key26 < _len26; _key26++) { args[_key26] = arguments[_key26]; } return builder.apply(void 0, ["NumericLiteral"].concat(args)); } function NullLiteral() { for (var _len27 = arguments.length, args = new Array(_len27), _key27 = 0; _key27 < _len27; _key27++) { args[_key27] = arguments[_key27]; } return builder.apply(void 0, ["NullLiteral"].concat(args)); } function BooleanLiteral() { for (var _len28 = arguments.length, args = new Array(_len28), _key28 = 0; _key28 < _len28; _key28++) { args[_key28] = arguments[_key28]; } return builder.apply(void 0, ["BooleanLiteral"].concat(args)); } function RegExpLiteral() { for (var _len29 = arguments.length, args = new Array(_len29), _key29 = 0; _key29 < _len29; _key29++) { args[_key29] = arguments[_key29]; } return builder.apply(void 0, ["RegExpLiteral"].concat(args)); } function LogicalExpression() { for (var _len30 = arguments.length, args = new Array(_len30), _key30 = 0; _key30 < _len30; _key30++) { args[_key30] = arguments[_key30]; } return builder.apply(void 0, ["LogicalExpression"].concat(args)); } function MemberExpression() { for (var _len31 = arguments.length, args = new Array(_len31), _key31 = 0; _key31 < _len31; _key31++) { args[_key31] = arguments[_key31]; } return builder.apply(void 0, ["MemberExpression"].concat(args)); } function NewExpression() { for (var _len32 = arguments.length, args = new Array(_len32), _key32 = 0; _key32 < _len32; _key32++) { args[_key32] = arguments[_key32]; } return builder.apply(void 0, ["NewExpression"].concat(args)); } function Program() { for (var _len33 = arguments.length, args = new Array(_len33), _key33 = 0; _key33 < _len33; _key33++) { args[_key33] = arguments[_key33]; } return builder.apply(void 0, ["Program"].concat(args)); } function ObjectExpression() { for (var _len34 = arguments.length, args = new Array(_len34), _key34 = 0; _key34 < _len34; _key34++) { args[_key34] = arguments[_key34]; } return builder.apply(void 0, ["ObjectExpression"].concat(args)); } function ObjectMethod() { for (var _len35 = arguments.length, args = new Array(_len35), _key35 = 0; _key35 < _len35; _key35++) { args[_key35] = arguments[_key35]; } return builder.apply(void 0, ["ObjectMethod"].concat(args)); } function ObjectProperty() { for (var _len36 = arguments.length, args = new Array(_len36), _key36 = 0; _key36 < _len36; _key36++) { args[_key36] = arguments[_key36]; } return builder.apply(void 0, ["ObjectProperty"].concat(args)); } function RestElement() { for (var _len37 = arguments.length, args = new Array(_len37), _key37 = 0; _key37 < _len37; _key37++) { args[_key37] = arguments[_key37]; } return builder.apply(void 0, ["RestElement"].concat(args)); } function ReturnStatement() { for (var _len38 = arguments.length, args = new Array(_len38), _key38 = 0; _key38 < _len38; _key38++) { args[_key38] = arguments[_key38]; } return builder.apply(void 0, ["ReturnStatement"].concat(args)); } function SequenceExpression() { for (var _len39 = arguments.length, args = new Array(_len39), _key39 = 0; _key39 < _len39; _key39++) { args[_key39] = arguments[_key39]; } return builder.apply(void 0, ["SequenceExpression"].concat(args)); } function ParenthesizedExpression() { for (var _len40 = arguments.length, args = new Array(_len40), _key40 = 0; _key40 < _len40; _key40++) { args[_key40] = arguments[_key40]; } return builder.apply(void 0, ["ParenthesizedExpression"].concat(args)); } function SwitchCase() { for (var _len41 = arguments.length, args = new Array(_len41), _key41 = 0; _key41 < _len41; _key41++) { args[_key41] = arguments[_key41]; } return builder.apply(void 0, ["SwitchCase"].concat(args)); } function SwitchStatement() { for (var _len42 = arguments.length, args = new Array(_len42), _key42 = 0; _key42 < _len42; _key42++) { args[_key42] = arguments[_key42]; } return builder.apply(void 0, ["SwitchStatement"].concat(args)); } function ThisExpression() { for (var _len43 = arguments.length, args = new Array(_len43), _key43 = 0; _key43 < _len43; _key43++) { args[_key43] = arguments[_key43]; } return builder.apply(void 0, ["ThisExpression"].concat(args)); } function ThrowStatement() { for (var _len44 = arguments.length, args = new Array(_len44), _key44 = 0; _key44 < _len44; _key44++) { args[_key44] = arguments[_key44]; } return builder.apply(void 0, ["ThrowStatement"].concat(args)); } function TryStatement() { for (var _len45 = arguments.length, args = new Array(_len45), _key45 = 0; _key45 < _len45; _key45++) { args[_key45] = arguments[_key45]; } return builder.apply(void 0, ["TryStatement"].concat(args)); } function UnaryExpression() { for (var _len46 = arguments.length, args = new Array(_len46), _key46 = 0; _key46 < _len46; _key46++) { args[_key46] = arguments[_key46]; } return builder.apply(void 0, ["UnaryExpression"].concat(args)); } function UpdateExpression() { for (var _len47 = arguments.length, args = new Array(_len47), _key47 = 0; _key47 < _len47; _key47++) { args[_key47] = arguments[_key47]; } return builder.apply(void 0, ["UpdateExpression"].concat(args)); } function VariableDeclaration() { for (var _len48 = arguments.length, args = new Array(_len48), _key48 = 0; _key48 < _len48; _key48++) { args[_key48] = arguments[_key48]; } return builder.apply(void 0, ["VariableDeclaration"].concat(args)); } function VariableDeclarator() { for (var _len49 = arguments.length, args = new Array(_len49), _key49 = 0; _key49 < _len49; _key49++) { args[_key49] = arguments[_key49]; } return builder.apply(void 0, ["VariableDeclarator"].concat(args)); } function WhileStatement() { for (var _len50 = arguments.length, args = new Array(_len50), _key50 = 0; _key50 < _len50; _key50++) { args[_key50] = arguments[_key50]; } return builder.apply(void 0, ["WhileStatement"].concat(args)); } function WithStatement() { for (var _len51 = arguments.length, args = new Array(_len51), _key51 = 0; _key51 < _len51; _key51++) { args[_key51] = arguments[_key51]; } return builder.apply(void 0, ["WithStatement"].concat(args)); } function AssignmentPattern() { for (var _len52 = arguments.length, args = new Array(_len52), _key52 = 0; _key52 < _len52; _key52++) { args[_key52] = arguments[_key52]; } return builder.apply(void 0, ["AssignmentPattern"].concat(args)); } function ArrayPattern() { for (var _len53 = arguments.length, args = new Array(_len53), _key53 = 0; _key53 < _len53; _key53++) { args[_key53] = arguments[_key53]; } return builder.apply(void 0, ["ArrayPattern"].concat(args)); } function ArrowFunctionExpression() { for (var _len54 = arguments.length, args = new Array(_len54), _key54 = 0; _key54 < _len54; _key54++) { args[_key54] = arguments[_key54]; } return builder.apply(void 0, ["ArrowFunctionExpression"].concat(args)); } function ClassBody() { for (var _len55 = arguments.length, args = new Array(_len55), _key55 = 0; _key55 < _len55; _key55++) { args[_key55] = arguments[_key55]; } return builder.apply(void 0, ["ClassBody"].concat(args)); } function ClassExpression() { for (var _len56 = arguments.length, args = new Array(_len56), _key56 = 0; _key56 < _len56; _key56++) { args[_key56] = arguments[_key56]; } return builder.apply(void 0, ["ClassExpression"].concat(args)); } function ClassDeclaration() { for (var _len57 = arguments.length, args = new Array(_len57), _key57 = 0; _key57 < _len57; _key57++) { args[_key57] = arguments[_key57]; } return builder.apply(void 0, ["ClassDeclaration"].concat(args)); } function ExportAllDeclaration() { for (var _len58 = arguments.length, args = new Array(_len58), _key58 = 0; _key58 < _len58; _key58++) { args[_key58] = arguments[_key58]; } return builder.apply(void 0, ["ExportAllDeclaration"].concat(args)); } function ExportDefaultDeclaration() { for (var _len59 = arguments.length, args = new Array(_len59), _key59 = 0; _key59 < _len59; _key59++) { args[_key59] = arguments[_key59]; } return builder.apply(void 0, ["ExportDefaultDeclaration"].concat(args)); } function ExportNamedDeclaration() { for (var _len60 = arguments.length, args = new Array(_len60), _key60 = 0; _key60 < _len60; _key60++) { args[_key60] = arguments[_key60]; } return builder.apply(void 0, ["ExportNamedDeclaration"].concat(args)); } function ExportSpecifier() { for (var _len61 = arguments.length, args = new Array(_len61), _key61 = 0; _key61 < _len61; _key61++) { args[_key61] = arguments[_key61]; } return builder.apply(void 0, ["ExportSpecifier"].concat(args)); } function ForOfStatement() { for (var _len62 = arguments.length, args = new Array(_len62), _key62 = 0; _key62 < _len62; _key62++) { args[_key62] = arguments[_key62]; } return builder.apply(void 0, ["ForOfStatement"].concat(args)); } function ImportDeclaration() { for (var _len63 = arguments.length, args = new Array(_len63), _key63 = 0; _key63 < _len63; _key63++) { args[_key63] = arguments[_key63]; } return builder.apply(void 0, ["ImportDeclaration"].concat(args)); } function ImportDefaultSpecifier() { for (var _len64 = arguments.length, args = new Array(_len64), _key64 = 0; _key64 < _len64; _key64++) { args[_key64] = arguments[_key64]; } return builder.apply(void 0, ["ImportDefaultSpecifier"].concat(args)); } function ImportNamespaceSpecifier() { for (var _len65 = arguments.length, args = new Array(_len65), _key65 = 0; _key65 < _len65; _key65++) { args[_key65] = arguments[_key65]; } return builder.apply(void 0, ["ImportNamespaceSpecifier"].concat(args)); } function ImportSpecifier() { for (var _len66 = arguments.length, args = new Array(_len66), _key66 = 0; _key66 < _len66; _key66++) { args[_key66] = arguments[_key66]; } return builder.apply(void 0, ["ImportSpecifier"].concat(args)); } function MetaProperty() { for (var _len67 = arguments.length, args = new Array(_len67), _key67 = 0; _key67 < _len67; _key67++) { args[_key67] = arguments[_key67]; } return builder.apply(void 0, ["MetaProperty"].concat(args)); } function ClassMethod() { for (var _len68 = arguments.length, args = new Array(_len68), _key68 = 0; _key68 < _len68; _key68++) { args[_key68] = arguments[_key68]; } return builder.apply(void 0, ["ClassMethod"].concat(args)); } function ObjectPattern() { for (var _len69 = arguments.length, args = new Array(_len69), _key69 = 0; _key69 < _len69; _key69++) { args[_key69] = arguments[_key69]; } return builder.apply(void 0, ["ObjectPattern"].concat(args)); } function SpreadElement() { for (var _len70 = arguments.length, args = new Array(_len70), _key70 = 0; _key70 < _len70; _key70++) { args[_key70] = arguments[_key70]; } return builder.apply(void 0, ["SpreadElement"].concat(args)); } function Super() { for (var _len71 = arguments.length, args = new Array(_len71), _key71 = 0; _key71 < _len71; _key71++) { args[_key71] = arguments[_key71]; } return builder.apply(void 0, ["Super"].concat(args)); } function TaggedTemplateExpression() { for (var _len72 = arguments.length, args = new Array(_len72), _key72 = 0; _key72 < _len72; _key72++) { args[_key72] = arguments[_key72]; } return builder.apply(void 0, ["TaggedTemplateExpression"].concat(args)); } function TemplateElement() { for (var _len73 = arguments.length, args = new Array(_len73), _key73 = 0; _key73 < _len73; _key73++) { args[_key73] = arguments[_key73]; } return builder.apply(void 0, ["TemplateElement"].concat(args)); } function TemplateLiteral() { for (var _len74 = arguments.length, args = new Array(_len74), _key74 = 0; _key74 < _len74; _key74++) { args[_key74] = arguments[_key74]; } return builder.apply(void 0, ["TemplateLiteral"].concat(args)); } function YieldExpression() { for (var _len75 = arguments.length, args = new Array(_len75), _key75 = 0; _key75 < _len75; _key75++) { args[_key75] = arguments[_key75]; } return builder.apply(void 0, ["YieldExpression"].concat(args)); } function AnyTypeAnnotation() { for (var _len76 = arguments.length, args = new Array(_len76), _key76 = 0; _key76 < _len76; _key76++) { args[_key76] = arguments[_key76]; } return builder.apply(void 0, ["AnyTypeAnnotation"].concat(args)); } function ArrayTypeAnnotation() { for (var _len77 = arguments.length, args = new Array(_len77), _key77 = 0; _key77 < _len77; _key77++) { args[_key77] = arguments[_key77]; } return builder.apply(void 0, ["ArrayTypeAnnotation"].concat(args)); } function BooleanTypeAnnotation() { for (var _len78 = arguments.length, args = new Array(_len78), _key78 = 0; _key78 < _len78; _key78++) { args[_key78] = arguments[_key78]; } return builder.apply(void 0, ["BooleanTypeAnnotation"].concat(args)); } function BooleanLiteralTypeAnnotation() { for (var _len79 = arguments.length, args = new Array(_len79), _key79 = 0; _key79 < _len79; _key79++) { args[_key79] = arguments[_key79]; } return builder.apply(void 0, ["BooleanLiteralTypeAnnotation"].concat(args)); } function NullLiteralTypeAnnotation() { for (var _len80 = arguments.length, args = new Array(_len80), _key80 = 0; _key80 < _len80; _key80++) { args[_key80] = arguments[_key80]; } return builder.apply(void 0, ["NullLiteralTypeAnnotation"].concat(args)); } function ClassImplements() { for (var _len81 = arguments.length, args = new Array(_len81), _key81 = 0; _key81 < _len81; _key81++) { args[_key81] = arguments[_key81]; } return builder.apply(void 0, ["ClassImplements"].concat(args)); } function DeclareClass() { for (var _len82 = arguments.length, args = new Array(_len82), _key82 = 0; _key82 < _len82; _key82++) { args[_key82] = arguments[_key82]; } return builder.apply(void 0, ["DeclareClass"].concat(args)); } function DeclareFunction() { for (var _len83 = arguments.length, args = new Array(_len83), _key83 = 0; _key83 < _len83; _key83++) { args[_key83] = arguments[_key83]; } return builder.apply(void 0, ["DeclareFunction"].concat(args)); } function DeclareInterface() { for (var _len84 = arguments.length, args = new Array(_len84), _key84 = 0; _key84 < _len84; _key84++) { args[_key84] = arguments[_key84]; } return builder.apply(void 0, ["DeclareInterface"].concat(args)); } function DeclareModule() { for (var _len85 = arguments.length, args = new Array(_len85), _key85 = 0; _key85 < _len85; _key85++) { args[_key85] = arguments[_key85]; } return builder.apply(void 0, ["DeclareModule"].concat(args)); } function DeclareModuleExports() { for (var _len86 = arguments.length, args = new Array(_len86), _key86 = 0; _key86 < _len86; _key86++) { args[_key86] = arguments[_key86]; } return builder.apply(void 0, ["DeclareModuleExports"].concat(args)); } function DeclareTypeAlias() { for (var _len87 = arguments.length, args = new Array(_len87), _key87 = 0; _key87 < _len87; _key87++) { args[_key87] = arguments[_key87]; } return builder.apply(void 0, ["DeclareTypeAlias"].concat(args)); } function DeclareOpaqueType() { for (var _len88 = arguments.length, args = new Array(_len88), _key88 = 0; _key88 < _len88; _key88++) { args[_key88] = arguments[_key88]; } return builder.apply(void 0, ["DeclareOpaqueType"].concat(args)); } function DeclareVariable() { for (var _len89 = arguments.length, args = new Array(_len89), _key89 = 0; _key89 < _len89; _key89++) { args[_key89] = arguments[_key89]; } return builder.apply(void 0, ["DeclareVariable"].concat(args)); } function DeclareExportDeclaration() { for (var _len90 = arguments.length, args = new Array(_len90), _key90 = 0; _key90 < _len90; _key90++) { args[_key90] = arguments[_key90]; } return builder.apply(void 0, ["DeclareExportDeclaration"].concat(args)); } function DeclareExportAllDeclaration() { for (var _len91 = arguments.length, args = new Array(_len91), _key91 = 0; _key91 < _len91; _key91++) { args[_key91] = arguments[_key91]; } return builder.apply(void 0, ["DeclareExportAllDeclaration"].concat(args)); } function DeclaredPredicate() { for (var _len92 = arguments.length, args = new Array(_len92), _key92 = 0; _key92 < _len92; _key92++) { args[_key92] = arguments[_key92]; } return builder.apply(void 0, ["DeclaredPredicate"].concat(args)); } function ExistsTypeAnnotation() { for (var _len93 = arguments.length, args = new Array(_len93), _key93 = 0; _key93 < _len93; _key93++) { args[_key93] = arguments[_key93]; } return builder.apply(void 0, ["ExistsTypeAnnotation"].concat(args)); } function FunctionTypeAnnotation() { for (var _len94 = arguments.length, args = new Array(_len94), _key94 = 0; _key94 < _len94; _key94++) { args[_key94] = arguments[_key94]; } return builder.apply(void 0, ["FunctionTypeAnnotation"].concat(args)); } function FunctionTypeParam() { for (var _len95 = arguments.length, args = new Array(_len95), _key95 = 0; _key95 < _len95; _key95++) { args[_key95] = arguments[_key95]; } return builder.apply(void 0, ["FunctionTypeParam"].concat(args)); } function GenericTypeAnnotation() { for (var _len96 = arguments.length, args = new Array(_len96), _key96 = 0; _key96 < _len96; _key96++) { args[_key96] = arguments[_key96]; } return builder.apply(void 0, ["GenericTypeAnnotation"].concat(args)); } function InferredPredicate() { for (var _len97 = arguments.length, args = new Array(_len97), _key97 = 0; _key97 < _len97; _key97++) { args[_key97] = arguments[_key97]; } return builder.apply(void 0, ["InferredPredicate"].concat(args)); } function InterfaceExtends() { for (var _len98 = arguments.length, args = new Array(_len98), _key98 = 0; _key98 < _len98; _key98++) { args[_key98] = arguments[_key98]; } return builder.apply(void 0, ["InterfaceExtends"].concat(args)); } function InterfaceDeclaration() { for (var _len99 = arguments.length, args = new Array(_len99), _key99 = 0; _key99 < _len99; _key99++) { args[_key99] = arguments[_key99]; } return builder.apply(void 0, ["InterfaceDeclaration"].concat(args)); } function InterfaceTypeAnnotation() { for (var _len100 = arguments.length, args = new Array(_len100), _key100 = 0; _key100 < _len100; _key100++) { args[_key100] = arguments[_key100]; } return builder.apply(void 0, ["InterfaceTypeAnnotation"].concat(args)); } function IntersectionTypeAnnotation() { for (var _len101 = arguments.length, args = new Array(_len101), _key101 = 0; _key101 < _len101; _key101++) { args[_key101] = arguments[_key101]; } return builder.apply(void 0, ["IntersectionTypeAnnotation"].concat(args)); } function MixedTypeAnnotation() { for (var _len102 = arguments.length, args = new Array(_len102), _key102 = 0; _key102 < _len102; _key102++) { args[_key102] = arguments[_key102]; } return builder.apply(void 0, ["MixedTypeAnnotation"].concat(args)); } function EmptyTypeAnnotation() { for (var _len103 = arguments.length, args = new Array(_len103), _key103 = 0; _key103 < _len103; _key103++) { args[_key103] = arguments[_key103]; } return builder.apply(void 0, ["EmptyTypeAnnotation"].concat(args)); } function NullableTypeAnnotation() { for (var _len104 = arguments.length, args = new Array(_len104), _key104 = 0; _key104 < _len104; _key104++) { args[_key104] = arguments[_key104]; } return builder.apply(void 0, ["NullableTypeAnnotation"].concat(args)); } function NumberLiteralTypeAnnotation() { for (var _len105 = arguments.length, args = new Array(_len105), _key105 = 0; _key105 < _len105; _key105++) { args[_key105] = arguments[_key105]; } return builder.apply(void 0, ["NumberLiteralTypeAnnotation"].concat(args)); } function NumberTypeAnnotation() { for (var _len106 = arguments.length, args = new Array(_len106), _key106 = 0; _key106 < _len106; _key106++) { args[_key106] = arguments[_key106]; } return builder.apply(void 0, ["NumberTypeAnnotation"].concat(args)); } function ObjectTypeAnnotation() { for (var _len107 = arguments.length, args = new Array(_len107), _key107 = 0; _key107 < _len107; _key107++) { args[_key107] = arguments[_key107]; } return builder.apply(void 0, ["ObjectTypeAnnotation"].concat(args)); } function ObjectTypeInternalSlot() { for (var _len108 = arguments.length, args = new Array(_len108), _key108 = 0; _key108 < _len108; _key108++) { args[_key108] = arguments[_key108]; } return builder.apply(void 0, ["ObjectTypeInternalSlot"].concat(args)); } function ObjectTypeCallProperty() { for (var _len109 = arguments.length, args = new Array(_len109), _key109 = 0; _key109 < _len109; _key109++) { args[_key109] = arguments[_key109]; } return builder.apply(void 0, ["ObjectTypeCallProperty"].concat(args)); } function ObjectTypeIndexer() { for (var _len110 = arguments.length, args = new Array(_len110), _key110 = 0; _key110 < _len110; _key110++) { args[_key110] = arguments[_key110]; } return builder.apply(void 0, ["ObjectTypeIndexer"].concat(args)); } function ObjectTypeProperty() { for (var _len111 = arguments.length, args = new Array(_len111), _key111 = 0; _key111 < _len111; _key111++) { args[_key111] = arguments[_key111]; } return builder.apply(void 0, ["ObjectTypeProperty"].concat(args)); } function ObjectTypeSpreadProperty() { for (var _len112 = arguments.length, args = new Array(_len112), _key112 = 0; _key112 < _len112; _key112++) { args[_key112] = arguments[_key112]; } return builder.apply(void 0, ["ObjectTypeSpreadProperty"].concat(args)); } function OpaqueType() { for (var _len113 = arguments.length, args = new Array(_len113), _key113 = 0; _key113 < _len113; _key113++) { args[_key113] = arguments[_key113]; } return builder.apply(void 0, ["OpaqueType"].concat(args)); } function QualifiedTypeIdentifier() { for (var _len114 = arguments.length, args = new Array(_len114), _key114 = 0; _key114 < _len114; _key114++) { args[_key114] = arguments[_key114]; } return builder.apply(void 0, ["QualifiedTypeIdentifier"].concat(args)); } function StringLiteralTypeAnnotation() { for (var _len115 = arguments.length, args = new Array(_len115), _key115 = 0; _key115 < _len115; _key115++) { args[_key115] = arguments[_key115]; } return builder.apply(void 0, ["StringLiteralTypeAnnotation"].concat(args)); } function StringTypeAnnotation() { for (var _len116 = arguments.length, args = new Array(_len116), _key116 = 0; _key116 < _len116; _key116++) { args[_key116] = arguments[_key116]; } return builder.apply(void 0, ["StringTypeAnnotation"].concat(args)); } function ThisTypeAnnotation() { for (var _len117 = arguments.length, args = new Array(_len117), _key117 = 0; _key117 < _len117; _key117++) { args[_key117] = arguments[_key117]; } return builder.apply(void 0, ["ThisTypeAnnotation"].concat(args)); } function TupleTypeAnnotation() { for (var _len118 = arguments.length, args = new Array(_len118), _key118 = 0; _key118 < _len118; _key118++) { args[_key118] = arguments[_key118]; } return builder.apply(void 0, ["TupleTypeAnnotation"].concat(args)); } function TypeofTypeAnnotation() { for (var _len119 = arguments.length, args = new Array(_len119), _key119 = 0; _key119 < _len119; _key119++) { args[_key119] = arguments[_key119]; } return builder.apply(void 0, ["TypeofTypeAnnotation"].concat(args)); } function TypeAlias() { for (var _len120 = arguments.length, args = new Array(_len120), _key120 = 0; _key120 < _len120; _key120++) { args[_key120] = arguments[_key120]; } return builder.apply(void 0, ["TypeAlias"].concat(args)); } function TypeAnnotation() { for (var _len121 = arguments.length, args = new Array(_len121), _key121 = 0; _key121 < _len121; _key121++) { args[_key121] = arguments[_key121]; } return builder.apply(void 0, ["TypeAnnotation"].concat(args)); } function TypeCastExpression() { for (var _len122 = arguments.length, args = new Array(_len122), _key122 = 0; _key122 < _len122; _key122++) { args[_key122] = arguments[_key122]; } return builder.apply(void 0, ["TypeCastExpression"].concat(args)); } function TypeParameter() { for (var _len123 = arguments.length, args = new Array(_len123), _key123 = 0; _key123 < _len123; _key123++) { args[_key123] = arguments[_key123]; } return builder.apply(void 0, ["TypeParameter"].concat(args)); } function TypeParameterDeclaration() { for (var _len124 = arguments.length, args = new Array(_len124), _key124 = 0; _key124 < _len124; _key124++) { args[_key124] = arguments[_key124]; } return builder.apply(void 0, ["TypeParameterDeclaration"].concat(args)); } function TypeParameterInstantiation() { for (var _len125 = arguments.length, args = new Array(_len125), _key125 = 0; _key125 < _len125; _key125++) { args[_key125] = arguments[_key125]; } return builder.apply(void 0, ["TypeParameterInstantiation"].concat(args)); } function UnionTypeAnnotation() { for (var _len126 = arguments.length, args = new Array(_len126), _key126 = 0; _key126 < _len126; _key126++) { args[_key126] = arguments[_key126]; } return builder.apply(void 0, ["UnionTypeAnnotation"].concat(args)); } function Variance() { for (var _len127 = arguments.length, args = new Array(_len127), _key127 = 0; _key127 < _len127; _key127++) { args[_key127] = arguments[_key127]; } return builder.apply(void 0, ["Variance"].concat(args)); } function VoidTypeAnnotation() { for (var _len128 = arguments.length, args = new Array(_len128), _key128 = 0; _key128 < _len128; _key128++) { args[_key128] = arguments[_key128]; } return builder.apply(void 0, ["VoidTypeAnnotation"].concat(args)); } function EnumDeclaration() { for (var _len129 = arguments.length, args = new Array(_len129), _key129 = 0; _key129 < _len129; _key129++) { args[_key129] = arguments[_key129]; } return builder.apply(void 0, ["EnumDeclaration"].concat(args)); } function EnumBooleanBody() { for (var _len130 = arguments.length, args = new Array(_len130), _key130 = 0; _key130 < _len130; _key130++) { args[_key130] = arguments[_key130]; } return builder.apply(void 0, ["EnumBooleanBody"].concat(args)); } function EnumNumberBody() { for (var _len131 = arguments.length, args = new Array(_len131), _key131 = 0; _key131 < _len131; _key131++) { args[_key131] = arguments[_key131]; } return builder.apply(void 0, ["EnumNumberBody"].concat(args)); } function EnumStringBody() { for (var _len132 = arguments.length, args = new Array(_len132), _key132 = 0; _key132 < _len132; _key132++) { args[_key132] = arguments[_key132]; } return builder.apply(void 0, ["EnumStringBody"].concat(args)); } function EnumSymbolBody() { for (var _len133 = arguments.length, args = new Array(_len133), _key133 = 0; _key133 < _len133; _key133++) { args[_key133] = arguments[_key133]; } return builder.apply(void 0, ["EnumSymbolBody"].concat(args)); } function EnumBooleanMember() { for (var _len134 = arguments.length, args = new Array(_len134), _key134 = 0; _key134 < _len134; _key134++) { args[_key134] = arguments[_key134]; } return builder.apply(void 0, ["EnumBooleanMember"].concat(args)); } function EnumNumberMember() { for (var _len135 = arguments.length, args = new Array(_len135), _key135 = 0; _key135 < _len135; _key135++) { args[_key135] = arguments[_key135]; } return builder.apply(void 0, ["EnumNumberMember"].concat(args)); } function EnumStringMember() { for (var _len136 = arguments.length, args = new Array(_len136), _key136 = 0; _key136 < _len136; _key136++) { args[_key136] = arguments[_key136]; } return builder.apply(void 0, ["EnumStringMember"].concat(args)); } function EnumDefaultedMember() { for (var _len137 = arguments.length, args = new Array(_len137), _key137 = 0; _key137 < _len137; _key137++) { args[_key137] = arguments[_key137]; } return builder.apply(void 0, ["EnumDefaultedMember"].concat(args)); } function JSXAttribute() { for (var _len138 = arguments.length, args = new Array(_len138), _key138 = 0; _key138 < _len138; _key138++) { args[_key138] = arguments[_key138]; } return builder.apply(void 0, ["JSXAttribute"].concat(args)); } function JSXClosingElement() { for (var _len139 = arguments.length, args = new Array(_len139), _key139 = 0; _key139 < _len139; _key139++) { args[_key139] = arguments[_key139]; } return builder.apply(void 0, ["JSXClosingElement"].concat(args)); } function JSXElement() { for (var _len140 = arguments.length, args = new Array(_len140), _key140 = 0; _key140 < _len140; _key140++) { args[_key140] = arguments[_key140]; } return builder.apply(void 0, ["JSXElement"].concat(args)); } function JSXEmptyExpression() { for (var _len141 = arguments.length, args = new Array(_len141), _key141 = 0; _key141 < _len141; _key141++) { args[_key141] = arguments[_key141]; } return builder.apply(void 0, ["JSXEmptyExpression"].concat(args)); } function JSXExpressionContainer() { for (var _len142 = arguments.length, args = new Array(_len142), _key142 = 0; _key142 < _len142; _key142++) { args[_key142] = arguments[_key142]; } return builder.apply(void 0, ["JSXExpressionContainer"].concat(args)); } function JSXSpreadChild() { for (var _len143 = arguments.length, args = new Array(_len143), _key143 = 0; _key143 < _len143; _key143++) { args[_key143] = arguments[_key143]; } return builder.apply(void 0, ["JSXSpreadChild"].concat(args)); } function JSXIdentifier() { for (var _len144 = arguments.length, args = new Array(_len144), _key144 = 0; _key144 < _len144; _key144++) { args[_key144] = arguments[_key144]; } return builder.apply(void 0, ["JSXIdentifier"].concat(args)); } function JSXMemberExpression() { for (var _len145 = arguments.length, args = new Array(_len145), _key145 = 0; _key145 < _len145; _key145++) { args[_key145] = arguments[_key145]; } return builder.apply(void 0, ["JSXMemberExpression"].concat(args)); } function JSXNamespacedName() { for (var _len146 = arguments.length, args = new Array(_len146), _key146 = 0; _key146 < _len146; _key146++) { args[_key146] = arguments[_key146]; } return builder.apply(void 0, ["JSXNamespacedName"].concat(args)); } function JSXOpeningElement() { for (var _len147 = arguments.length, args = new Array(_len147), _key147 = 0; _key147 < _len147; _key147++) { args[_key147] = arguments[_key147]; } return builder.apply(void 0, ["JSXOpeningElement"].concat(args)); } function JSXSpreadAttribute() { for (var _len148 = arguments.length, args = new Array(_len148), _key148 = 0; _key148 < _len148; _key148++) { args[_key148] = arguments[_key148]; } return builder.apply(void 0, ["JSXSpreadAttribute"].concat(args)); } function JSXText() { for (var _len149 = arguments.length, args = new Array(_len149), _key149 = 0; _key149 < _len149; _key149++) { args[_key149] = arguments[_key149]; } return builder.apply(void 0, ["JSXText"].concat(args)); } function JSXFragment() { for (var _len150 = arguments.length, args = new Array(_len150), _key150 = 0; _key150 < _len150; _key150++) { args[_key150] = arguments[_key150]; } return builder.apply(void 0, ["JSXFragment"].concat(args)); } function JSXOpeningFragment() { for (var _len151 = arguments.length, args = new Array(_len151), _key151 = 0; _key151 < _len151; _key151++) { args[_key151] = arguments[_key151]; } return builder.apply(void 0, ["JSXOpeningFragment"].concat(args)); } function JSXClosingFragment() { for (var _len152 = arguments.length, args = new Array(_len152), _key152 = 0; _key152 < _len152; _key152++) { args[_key152] = arguments[_key152]; } return builder.apply(void 0, ["JSXClosingFragment"].concat(args)); } function Noop() { for (var _len153 = arguments.length, args = new Array(_len153), _key153 = 0; _key153 < _len153; _key153++) { args[_key153] = arguments[_key153]; } return builder.apply(void 0, ["Noop"].concat(args)); } function Placeholder() { for (var _len154 = arguments.length, args = new Array(_len154), _key154 = 0; _key154 < _len154; _key154++) { args[_key154] = arguments[_key154]; } return builder.apply(void 0, ["Placeholder"].concat(args)); } function V8IntrinsicIdentifier() { for (var _len155 = arguments.length, args = new Array(_len155), _key155 = 0; _key155 < _len155; _key155++) { args[_key155] = arguments[_key155]; } return builder.apply(void 0, ["V8IntrinsicIdentifier"].concat(args)); } function ArgumentPlaceholder() { for (var _len156 = arguments.length, args = new Array(_len156), _key156 = 0; _key156 < _len156; _key156++) { args[_key156] = arguments[_key156]; } return builder.apply(void 0, ["ArgumentPlaceholder"].concat(args)); } function AwaitExpression() { for (var _len157 = arguments.length, args = new Array(_len157), _key157 = 0; _key157 < _len157; _key157++) { args[_key157] = arguments[_key157]; } return builder.apply(void 0, ["AwaitExpression"].concat(args)); } function BindExpression() { for (var _len158 = arguments.length, args = new Array(_len158), _key158 = 0; _key158 < _len158; _key158++) { args[_key158] = arguments[_key158]; } return builder.apply(void 0, ["BindExpression"].concat(args)); } function ClassProperty() { for (var _len159 = arguments.length, args = new Array(_len159), _key159 = 0; _key159 < _len159; _key159++) { args[_key159] = arguments[_key159]; } return builder.apply(void 0, ["ClassProperty"].concat(args)); } function OptionalMemberExpression() { for (var _len160 = arguments.length, args = new Array(_len160), _key160 = 0; _key160 < _len160; _key160++) { args[_key160] = arguments[_key160]; } return builder.apply(void 0, ["OptionalMemberExpression"].concat(args)); } function PipelineTopicExpression() { for (var _len161 = arguments.length, args = new Array(_len161), _key161 = 0; _key161 < _len161; _key161++) { args[_key161] = arguments[_key161]; } return builder.apply(void 0, ["PipelineTopicExpression"].concat(args)); } function PipelineBareFunction() { for (var _len162 = arguments.length, args = new Array(_len162), _key162 = 0; _key162 < _len162; _key162++) { args[_key162] = arguments[_key162]; } return builder.apply(void 0, ["PipelineBareFunction"].concat(args)); } function PipelinePrimaryTopicReference() { for (var _len163 = arguments.length, args = new Array(_len163), _key163 = 0; _key163 < _len163; _key163++) { args[_key163] = arguments[_key163]; } return builder.apply(void 0, ["PipelinePrimaryTopicReference"].concat(args)); } function OptionalCallExpression() { for (var _len164 = arguments.length, args = new Array(_len164), _key164 = 0; _key164 < _len164; _key164++) { args[_key164] = arguments[_key164]; } return builder.apply(void 0, ["OptionalCallExpression"].concat(args)); } function ClassPrivateProperty() { for (var _len165 = arguments.length, args = new Array(_len165), _key165 = 0; _key165 < _len165; _key165++) { args[_key165] = arguments[_key165]; } return builder.apply(void 0, ["ClassPrivateProperty"].concat(args)); } function ClassPrivateMethod() { for (var _len166 = arguments.length, args = new Array(_len166), _key166 = 0; _key166 < _len166; _key166++) { args[_key166] = arguments[_key166]; } return builder.apply(void 0, ["ClassPrivateMethod"].concat(args)); } function Import() { for (var _len167 = arguments.length, args = new Array(_len167), _key167 = 0; _key167 < _len167; _key167++) { args[_key167] = arguments[_key167]; } return builder.apply(void 0, ["Import"].concat(args)); } function Decorator() { for (var _len168 = arguments.length, args = new Array(_len168), _key168 = 0; _key168 < _len168; _key168++) { args[_key168] = arguments[_key168]; } return builder.apply(void 0, ["Decorator"].concat(args)); } function DoExpression() { for (var _len169 = arguments.length, args = new Array(_len169), _key169 = 0; _key169 < _len169; _key169++) { args[_key169] = arguments[_key169]; } return builder.apply(void 0, ["DoExpression"].concat(args)); } function ExportDefaultSpecifier() { for (var _len170 = arguments.length, args = new Array(_len170), _key170 = 0; _key170 < _len170; _key170++) { args[_key170] = arguments[_key170]; } return builder.apply(void 0, ["ExportDefaultSpecifier"].concat(args)); } function ExportNamespaceSpecifier() { for (var _len171 = arguments.length, args = new Array(_len171), _key171 = 0; _key171 < _len171; _key171++) { args[_key171] = arguments[_key171]; } return builder.apply(void 0, ["ExportNamespaceSpecifier"].concat(args)); } function PrivateName() { for (var _len172 = arguments.length, args = new Array(_len172), _key172 = 0; _key172 < _len172; _key172++) { args[_key172] = arguments[_key172]; } return builder.apply(void 0, ["PrivateName"].concat(args)); } function BigIntLiteral() { for (var _len173 = arguments.length, args = new Array(_len173), _key173 = 0; _key173 < _len173; _key173++) { args[_key173] = arguments[_key173]; } return builder.apply(void 0, ["BigIntLiteral"].concat(args)); } function TSParameterProperty() { for (var _len174 = arguments.length, args = new Array(_len174), _key174 = 0; _key174 < _len174; _key174++) { args[_key174] = arguments[_key174]; } return builder.apply(void 0, ["TSParameterProperty"].concat(args)); } function TSDeclareFunction() { for (var _len175 = arguments.length, args = new Array(_len175), _key175 = 0; _key175 < _len175; _key175++) { args[_key175] = arguments[_key175]; } return builder.apply(void 0, ["TSDeclareFunction"].concat(args)); } function TSDeclareMethod() { for (var _len176 = arguments.length, args = new Array(_len176), _key176 = 0; _key176 < _len176; _key176++) { args[_key176] = arguments[_key176]; } return builder.apply(void 0, ["TSDeclareMethod"].concat(args)); } function TSQualifiedName() { for (var _len177 = arguments.length, args = new Array(_len177), _key177 = 0; _key177 < _len177; _key177++) { args[_key177] = arguments[_key177]; } return builder.apply(void 0, ["TSQualifiedName"].concat(args)); } function TSCallSignatureDeclaration() { for (var _len178 = arguments.length, args = new Array(_len178), _key178 = 0; _key178 < _len178; _key178++) { args[_key178] = arguments[_key178]; } return builder.apply(void 0, ["TSCallSignatureDeclaration"].concat(args)); } function TSConstructSignatureDeclaration() { for (var _len179 = arguments.length, args = new Array(_len179), _key179 = 0; _key179 < _len179; _key179++) { args[_key179] = arguments[_key179]; } return builder.apply(void 0, ["TSConstructSignatureDeclaration"].concat(args)); } function TSPropertySignature() { for (var _len180 = arguments.length, args = new Array(_len180), _key180 = 0; _key180 < _len180; _key180++) { args[_key180] = arguments[_key180]; } return builder.apply(void 0, ["TSPropertySignature"].concat(args)); } function TSMethodSignature() { for (var _len181 = arguments.length, args = new Array(_len181), _key181 = 0; _key181 < _len181; _key181++) { args[_key181] = arguments[_key181]; } return builder.apply(void 0, ["TSMethodSignature"].concat(args)); } function TSIndexSignature() { for (var _len182 = arguments.length, args = new Array(_len182), _key182 = 0; _key182 < _len182; _key182++) { args[_key182] = arguments[_key182]; } return builder.apply(void 0, ["TSIndexSignature"].concat(args)); } function TSAnyKeyword() { for (var _len183 = arguments.length, args = new Array(_len183), _key183 = 0; _key183 < _len183; _key183++) { args[_key183] = arguments[_key183]; } return builder.apply(void 0, ["TSAnyKeyword"].concat(args)); } function TSBooleanKeyword() { for (var _len184 = arguments.length, args = new Array(_len184), _key184 = 0; _key184 < _len184; _key184++) { args[_key184] = arguments[_key184]; } return builder.apply(void 0, ["TSBooleanKeyword"].concat(args)); } function TSBigIntKeyword() { for (var _len185 = arguments.length, args = new Array(_len185), _key185 = 0; _key185 < _len185; _key185++) { args[_key185] = arguments[_key185]; } return builder.apply(void 0, ["TSBigIntKeyword"].concat(args)); } function TSNeverKeyword() { for (var _len186 = arguments.length, args = new Array(_len186), _key186 = 0; _key186 < _len186; _key186++) { args[_key186] = arguments[_key186]; } return builder.apply(void 0, ["TSNeverKeyword"].concat(args)); } function TSNullKeyword() { for (var _len187 = arguments.length, args = new Array(_len187), _key187 = 0; _key187 < _len187; _key187++) { args[_key187] = arguments[_key187]; } return builder.apply(void 0, ["TSNullKeyword"].concat(args)); } function TSNumberKeyword() { for (var _len188 = arguments.length, args = new Array(_len188), _key188 = 0; _key188 < _len188; _key188++) { args[_key188] = arguments[_key188]; } return builder.apply(void 0, ["TSNumberKeyword"].concat(args)); } function TSObjectKeyword() { for (var _len189 = arguments.length, args = new Array(_len189), _key189 = 0; _key189 < _len189; _key189++) { args[_key189] = arguments[_key189]; } return builder.apply(void 0, ["TSObjectKeyword"].concat(args)); } function TSStringKeyword() { for (var _len190 = arguments.length, args = new Array(_len190), _key190 = 0; _key190 < _len190; _key190++) { args[_key190] = arguments[_key190]; } return builder.apply(void 0, ["TSStringKeyword"].concat(args)); } function TSSymbolKeyword() { for (var _len191 = arguments.length, args = new Array(_len191), _key191 = 0; _key191 < _len191; _key191++) { args[_key191] = arguments[_key191]; } return builder.apply(void 0, ["TSSymbolKeyword"].concat(args)); } function TSUndefinedKeyword() { for (var _len192 = arguments.length, args = new Array(_len192), _key192 = 0; _key192 < _len192; _key192++) { args[_key192] = arguments[_key192]; } return builder.apply(void 0, ["TSUndefinedKeyword"].concat(args)); } function TSUnknownKeyword() { for (var _len193 = arguments.length, args = new Array(_len193), _key193 = 0; _key193 < _len193; _key193++) { args[_key193] = arguments[_key193]; } return builder.apply(void 0, ["TSUnknownKeyword"].concat(args)); } function TSVoidKeyword() { for (var _len194 = arguments.length, args = new Array(_len194), _key194 = 0; _key194 < _len194; _key194++) { args[_key194] = arguments[_key194]; } return builder.apply(void 0, ["TSVoidKeyword"].concat(args)); } function TSThisType() { for (var _len195 = arguments.length, args = new Array(_len195), _key195 = 0; _key195 < _len195; _key195++) { args[_key195] = arguments[_key195]; } return builder.apply(void 0, ["TSThisType"].concat(args)); } function TSFunctionType() { for (var _len196 = arguments.length, args = new Array(_len196), _key196 = 0; _key196 < _len196; _key196++) { args[_key196] = arguments[_key196]; } return builder.apply(void 0, ["TSFunctionType"].concat(args)); } function TSConstructorType() { for (var _len197 = arguments.length, args = new Array(_len197), _key197 = 0; _key197 < _len197; _key197++) { args[_key197] = arguments[_key197]; } return builder.apply(void 0, ["TSConstructorType"].concat(args)); } function TSTypeReference() { for (var _len198 = arguments.length, args = new Array(_len198), _key198 = 0; _key198 < _len198; _key198++) { args[_key198] = arguments[_key198]; } return builder.apply(void 0, ["TSTypeReference"].concat(args)); } function TSTypePredicate() { for (var _len199 = arguments.length, args = new Array(_len199), _key199 = 0; _key199 < _len199; _key199++) { args[_key199] = arguments[_key199]; } return builder.apply(void 0, ["TSTypePredicate"].concat(args)); } function TSTypeQuery() { for (var _len200 = arguments.length, args = new Array(_len200), _key200 = 0; _key200 < _len200; _key200++) { args[_key200] = arguments[_key200]; } return builder.apply(void 0, ["TSTypeQuery"].concat(args)); } function TSTypeLiteral() { for (var _len201 = arguments.length, args = new Array(_len201), _key201 = 0; _key201 < _len201; _key201++) { args[_key201] = arguments[_key201]; } return builder.apply(void 0, ["TSTypeLiteral"].concat(args)); } function TSArrayType() { for (var _len202 = arguments.length, args = new Array(_len202), _key202 = 0; _key202 < _len202; _key202++) { args[_key202] = arguments[_key202]; } return builder.apply(void 0, ["TSArrayType"].concat(args)); } function TSTupleType() { for (var _len203 = arguments.length, args = new Array(_len203), _key203 = 0; _key203 < _len203; _key203++) { args[_key203] = arguments[_key203]; } return builder.apply(void 0, ["TSTupleType"].concat(args)); } function TSOptionalType() { for (var _len204 = arguments.length, args = new Array(_len204), _key204 = 0; _key204 < _len204; _key204++) { args[_key204] = arguments[_key204]; } return builder.apply(void 0, ["TSOptionalType"].concat(args)); } function TSRestType() { for (var _len205 = arguments.length, args = new Array(_len205), _key205 = 0; _key205 < _len205; _key205++) { args[_key205] = arguments[_key205]; } return builder.apply(void 0, ["TSRestType"].concat(args)); } function TSUnionType() { for (var _len206 = arguments.length, args = new Array(_len206), _key206 = 0; _key206 < _len206; _key206++) { args[_key206] = arguments[_key206]; } return builder.apply(void 0, ["TSUnionType"].concat(args)); } function TSIntersectionType() { for (var _len207 = arguments.length, args = new Array(_len207), _key207 = 0; _key207 < _len207; _key207++) { args[_key207] = arguments[_key207]; } return builder.apply(void 0, ["TSIntersectionType"].concat(args)); } function TSConditionalType() { for (var _len208 = arguments.length, args = new Array(_len208), _key208 = 0; _key208 < _len208; _key208++) { args[_key208] = arguments[_key208]; } return builder.apply(void 0, ["TSConditionalType"].concat(args)); } function TSInferType() { for (var _len209 = arguments.length, args = new Array(_len209), _key209 = 0; _key209 < _len209; _key209++) { args[_key209] = arguments[_key209]; } return builder.apply(void 0, ["TSInferType"].concat(args)); } function TSParenthesizedType() { for (var _len210 = arguments.length, args = new Array(_len210), _key210 = 0; _key210 < _len210; _key210++) { args[_key210] = arguments[_key210]; } return builder.apply(void 0, ["TSParenthesizedType"].concat(args)); } function TSTypeOperator() { for (var _len211 = arguments.length, args = new Array(_len211), _key211 = 0; _key211 < _len211; _key211++) { args[_key211] = arguments[_key211]; } return builder.apply(void 0, ["TSTypeOperator"].concat(args)); } function TSIndexedAccessType() { for (var _len212 = arguments.length, args = new Array(_len212), _key212 = 0; _key212 < _len212; _key212++) { args[_key212] = arguments[_key212]; } return builder.apply(void 0, ["TSIndexedAccessType"].concat(args)); } function TSMappedType() { for (var _len213 = arguments.length, args = new Array(_len213), _key213 = 0; _key213 < _len213; _key213++) { args[_key213] = arguments[_key213]; } return builder.apply(void 0, ["TSMappedType"].concat(args)); } function TSLiteralType() { for (var _len214 = arguments.length, args = new Array(_len214), _key214 = 0; _key214 < _len214; _key214++) { args[_key214] = arguments[_key214]; } return builder.apply(void 0, ["TSLiteralType"].concat(args)); } function TSExpressionWithTypeArguments() { for (var _len215 = arguments.length, args = new Array(_len215), _key215 = 0; _key215 < _len215; _key215++) { args[_key215] = arguments[_key215]; } return builder.apply(void 0, ["TSExpressionWithTypeArguments"].concat(args)); } function TSInterfaceDeclaration() { for (var _len216 = arguments.length, args = new Array(_len216), _key216 = 0; _key216 < _len216; _key216++) { args[_key216] = arguments[_key216]; } return builder.apply(void 0, ["TSInterfaceDeclaration"].concat(args)); } function TSInterfaceBody() { for (var _len217 = arguments.length, args = new Array(_len217), _key217 = 0; _key217 < _len217; _key217++) { args[_key217] = arguments[_key217]; } return builder.apply(void 0, ["TSInterfaceBody"].concat(args)); } function TSTypeAliasDeclaration() { for (var _len218 = arguments.length, args = new Array(_len218), _key218 = 0; _key218 < _len218; _key218++) { args[_key218] = arguments[_key218]; } return builder.apply(void 0, ["TSTypeAliasDeclaration"].concat(args)); } function TSAsExpression() { for (var _len219 = arguments.length, args = new Array(_len219), _key219 = 0; _key219 < _len219; _key219++) { args[_key219] = arguments[_key219]; } return builder.apply(void 0, ["TSAsExpression"].concat(args)); } function TSTypeAssertion() { for (var _len220 = arguments.length, args = new Array(_len220), _key220 = 0; _key220 < _len220; _key220++) { args[_key220] = arguments[_key220]; } return builder.apply(void 0, ["TSTypeAssertion"].concat(args)); } function TSEnumDeclaration() { for (var _len221 = arguments.length, args = new Array(_len221), _key221 = 0; _key221 < _len221; _key221++) { args[_key221] = arguments[_key221]; } return builder.apply(void 0, ["TSEnumDeclaration"].concat(args)); } function TSEnumMember() { for (var _len222 = arguments.length, args = new Array(_len222), _key222 = 0; _key222 < _len222; _key222++) { args[_key222] = arguments[_key222]; } return builder.apply(void 0, ["TSEnumMember"].concat(args)); } function TSModuleDeclaration() { for (var _len223 = arguments.length, args = new Array(_len223), _key223 = 0; _key223 < _len223; _key223++) { args[_key223] = arguments[_key223]; } return builder.apply(void 0, ["TSModuleDeclaration"].concat(args)); } function TSModuleBlock() { for (var _len224 = arguments.length, args = new Array(_len224), _key224 = 0; _key224 < _len224; _key224++) { args[_key224] = arguments[_key224]; } return builder.apply(void 0, ["TSModuleBlock"].concat(args)); } function TSImportType() { for (var _len225 = arguments.length, args = new Array(_len225), _key225 = 0; _key225 < _len225; _key225++) { args[_key225] = arguments[_key225]; } return builder.apply(void 0, ["TSImportType"].concat(args)); } function TSImportEqualsDeclaration() { for (var _len226 = arguments.length, args = new Array(_len226), _key226 = 0; _key226 < _len226; _key226++) { args[_key226] = arguments[_key226]; } return builder.apply(void 0, ["TSImportEqualsDeclaration"].concat(args)); } function TSExternalModuleReference() { for (var _len227 = arguments.length, args = new Array(_len227), _key227 = 0; _key227 < _len227; _key227++) { args[_key227] = arguments[_key227]; } return builder.apply(void 0, ["TSExternalModuleReference"].concat(args)); } function TSNonNullExpression() { for (var _len228 = arguments.length, args = new Array(_len228), _key228 = 0; _key228 < _len228; _key228++) { args[_key228] = arguments[_key228]; } return builder.apply(void 0, ["TSNonNullExpression"].concat(args)); } function TSExportAssignment() { for (var _len229 = arguments.length, args = new Array(_len229), _key229 = 0; _key229 < _len229; _key229++) { args[_key229] = arguments[_key229]; } return builder.apply(void 0, ["TSExportAssignment"].concat(args)); } function TSNamespaceExportDeclaration() { for (var _len230 = arguments.length, args = new Array(_len230), _key230 = 0; _key230 < _len230; _key230++) { args[_key230] = arguments[_key230]; } return builder.apply(void 0, ["TSNamespaceExportDeclaration"].concat(args)); } function TSTypeAnnotation() { for (var _len231 = arguments.length, args = new Array(_len231), _key231 = 0; _key231 < _len231; _key231++) { args[_key231] = arguments[_key231]; } return builder.apply(void 0, ["TSTypeAnnotation"].concat(args)); } function TSTypeParameterInstantiation() { for (var _len232 = arguments.length, args = new Array(_len232), _key232 = 0; _key232 < _len232; _key232++) { args[_key232] = arguments[_key232]; } return builder.apply(void 0, ["TSTypeParameterInstantiation"].concat(args)); } function TSTypeParameterDeclaration() { for (var _len233 = arguments.length, args = new Array(_len233), _key233 = 0; _key233 < _len233; _key233++) { args[_key233] = arguments[_key233]; } return builder.apply(void 0, ["TSTypeParameterDeclaration"].concat(args)); } function TSTypeParameter() { for (var _len234 = arguments.length, args = new Array(_len234), _key234 = 0; _key234 < _len234; _key234++) { args[_key234] = arguments[_key234]; } return builder.apply(void 0, ["TSTypeParameter"].concat(args)); } function NumberLiteral() { console.trace("The node type NumberLiteral has been renamed to NumericLiteral"); for (var _len235 = arguments.length, args = new Array(_len235), _key235 = 0; _key235 < _len235; _key235++) { args[_key235] = arguments[_key235]; } return NumberLiteral.apply(void 0, ["NumberLiteral"].concat(args)); } function RegexLiteral() { console.trace("The node type RegexLiteral has been renamed to RegExpLiteral"); for (var _len236 = arguments.length, args = new Array(_len236), _key236 = 0; _key236 < _len236; _key236++) { args[_key236] = arguments[_key236]; } return RegexLiteral.apply(void 0, ["RegexLiteral"].concat(args)); } function RestProperty() { console.trace("The node type RestProperty has been renamed to RestElement"); for (var _len237 = arguments.length, args = new Array(_len237), _key237 = 0; _key237 < _len237; _key237++) { args[_key237] = arguments[_key237]; } return RestProperty.apply(void 0, ["RestProperty"].concat(args)); } function SpreadProperty() { console.trace("The node type SpreadProperty has been renamed to SpreadElement"); for (var _len238 = arguments.length, args = new Array(_len238), _key238 = 0; _key238 < _len238; _key238++) { args[_key238] = arguments[_key238]; } return SpreadProperty.apply(void 0, ["SpreadProperty"].concat(args)); } function cleanJSXElementLiteralChild(child, args) { var lines = child.value.split(/\r\n|\n|\r/); var lastNonEmptyLine = 0; for (var i = 0; i < lines.length; i++) { if (lines[i].match(/[^ \t]/)) { lastNonEmptyLine = i; } } var str = ""; for (var _i = 0; _i < lines.length; _i++) { var line = lines[_i]; var isFirstLine = _i === 0; var isLastLine = _i === lines.length - 1; var isLastNonEmptyLine = _i === lastNonEmptyLine; var trimmedLine = line.replace(/\t/g, " "); if (!isFirstLine) { trimmedLine = trimmedLine.replace(/^[ ]+/, ""); } if (!isLastLine) { trimmedLine = trimmedLine.replace(/[ ]+$/, ""); } if (trimmedLine) { if (!isLastNonEmptyLine) { trimmedLine += " "; } str += trimmedLine; } } if (str) args.push(StringLiteral(str)); } function buildChildren(node) { var elements = []; for (var i = 0; i < node.children.length; i++) { var child = node.children[i]; if (isJSXText(child)) { cleanJSXElementLiteralChild(child, elements); continue; } if (isJSXExpressionContainer(child)) child = child.expression; if (isJSXEmptyExpression(child)) continue; elements.push(child); } return elements; } function isNode(node) { return !!(node && VISITOR_KEYS[node.type]); } function assertNode(node) { if (!isNode(node)) { var type = node && node.type || JSON.stringify(node); throw new TypeError("Not a valid node of type \"" + type + "\""); } } function assert(type, node, opts) { if (!is(type, node, opts)) { throw new Error("Expected type \"" + type + "\" with option " + JSON.stringify(opts) + ", " + ("but instead got \"" + node.type + "\".")); } } function assertArrayExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("ArrayExpression", node, opts); } function assertAssignmentExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("AssignmentExpression", node, opts); } function assertBinaryExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("BinaryExpression", node, opts); } function assertInterpreterDirective(node, opts) { if (opts === void 0) { opts = {}; } assert("InterpreterDirective", node, opts); } function assertDirective(node, opts) { if (opts === void 0) { opts = {}; } assert("Directive", node, opts); } function assertDirectiveLiteral(node, opts) { if (opts === void 0) { opts = {}; } assert("DirectiveLiteral", node, opts); } function assertBlockStatement(node, opts) { if (opts === void 0) { opts = {}; } assert("BlockStatement", node, opts); } function assertBreakStatement(node, opts) { if (opts === void 0) { opts = {}; } assert("BreakStatement", node, opts); } function assertCallExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("CallExpression", node, opts); } function assertCatchClause(node, opts) { if (opts === void 0) { opts = {}; } assert("CatchClause", node, opts); } function assertConditionalExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("ConditionalExpression", node, opts); } function assertContinueStatement(node, opts) { if (opts === void 0) { opts = {}; } assert("ContinueStatement", node, opts); } function assertDebuggerStatement(node, opts) { if (opts === void 0) { opts = {}; } assert("DebuggerStatement", node, opts); } function assertDoWhileStatement(node, opts) { if (opts === void 0) { opts = {}; } assert("DoWhileStatement", node, opts); } function assertEmptyStatement(node, opts) { if (opts === void 0) { opts = {}; } assert("EmptyStatement", node, opts); } function assertExpressionStatement(node, opts) { if (opts === void 0) { opts = {}; } assert("ExpressionStatement", node, opts); } function assertFile(node, opts) { if (opts === void 0) { opts = {}; } assert("File", node, opts); } function assertForInStatement(node, opts) { if (opts === void 0) { opts = {}; } assert("ForInStatement", node, opts); } function assertForStatement(node, opts) { if (opts === void 0) { opts = {}; } assert("ForStatement", node, opts); } function assertFunctionDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("FunctionDeclaration", node, opts); } function assertFunctionExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("FunctionExpression", node, opts); } function assertIdentifier(node, opts) { if (opts === void 0) { opts = {}; } assert("Identifier", node, opts); } function assertIfStatement(node, opts) { if (opts === void 0) { opts = {}; } assert("IfStatement", node, opts); } function assertLabeledStatement(node, opts) { if (opts === void 0) { opts = {}; } assert("LabeledStatement", node, opts); } function assertStringLiteral(node, opts) { if (opts === void 0) { opts = {}; } assert("StringLiteral", node, opts); } function assertNumericLiteral(node, opts) { if (opts === void 0) { opts = {}; } assert("NumericLiteral", node, opts); } function assertNullLiteral(node, opts) { if (opts === void 0) { opts = {}; } assert("NullLiteral", node, opts); } function assertBooleanLiteral(node, opts) { if (opts === void 0) { opts = {}; } assert("BooleanLiteral", node, opts); } function assertRegExpLiteral(node, opts) { if (opts === void 0) { opts = {}; } assert("RegExpLiteral", node, opts); } function assertLogicalExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("LogicalExpression", node, opts); } function assertMemberExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("MemberExpression", node, opts); } function assertNewExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("NewExpression", node, opts); } function assertProgram(node, opts) { if (opts === void 0) { opts = {}; } assert("Program", node, opts); } function assertObjectExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("ObjectExpression", node, opts); } function assertObjectMethod(node, opts) { if (opts === void 0) { opts = {}; } assert("ObjectMethod", node, opts); } function assertObjectProperty(node, opts) { if (opts === void 0) { opts = {}; } assert("ObjectProperty", node, opts); } function assertRestElement(node, opts) { if (opts === void 0) { opts = {}; } assert("RestElement", node, opts); } function assertReturnStatement(node, opts) { if (opts === void 0) { opts = {}; } assert("ReturnStatement", node, opts); } function assertSequenceExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("SequenceExpression", node, opts); } function assertParenthesizedExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("ParenthesizedExpression", node, opts); } function assertSwitchCase(node, opts) { if (opts === void 0) { opts = {}; } assert("SwitchCase", node, opts); } function assertSwitchStatement(node, opts) { if (opts === void 0) { opts = {}; } assert("SwitchStatement", node, opts); } function assertThisExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("ThisExpression", node, opts); } function assertThrowStatement(node, opts) { if (opts === void 0) { opts = {}; } assert("ThrowStatement", node, opts); } function assertTryStatement(node, opts) { if (opts === void 0) { opts = {}; } assert("TryStatement", node, opts); } function assertUnaryExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("UnaryExpression", node, opts); } function assertUpdateExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("UpdateExpression", node, opts); } function assertVariableDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("VariableDeclaration", node, opts); } function assertVariableDeclarator(node, opts) { if (opts === void 0) { opts = {}; } assert("VariableDeclarator", node, opts); } function assertWhileStatement(node, opts) { if (opts === void 0) { opts = {}; } assert("WhileStatement", node, opts); } function assertWithStatement(node, opts) { if (opts === void 0) { opts = {}; } assert("WithStatement", node, opts); } function assertAssignmentPattern(node, opts) { if (opts === void 0) { opts = {}; } assert("AssignmentPattern", node, opts); } function assertArrayPattern(node, opts) { if (opts === void 0) { opts = {}; } assert("ArrayPattern", node, opts); } function assertArrowFunctionExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("ArrowFunctionExpression", node, opts); } function assertClassBody(node, opts) { if (opts === void 0) { opts = {}; } assert("ClassBody", node, opts); } function assertClassExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("ClassExpression", node, opts); } function assertClassDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("ClassDeclaration", node, opts); } function assertExportAllDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("ExportAllDeclaration", node, opts); } function assertExportDefaultDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("ExportDefaultDeclaration", node, opts); } function assertExportNamedDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("ExportNamedDeclaration", node, opts); } function assertExportSpecifier(node, opts) { if (opts === void 0) { opts = {}; } assert("ExportSpecifier", node, opts); } function assertForOfStatement(node, opts) { if (opts === void 0) { opts = {}; } assert("ForOfStatement", node, opts); } function assertImportDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("ImportDeclaration", node, opts); } function assertImportDefaultSpecifier(node, opts) { if (opts === void 0) { opts = {}; } assert("ImportDefaultSpecifier", node, opts); } function assertImportNamespaceSpecifier(node, opts) { if (opts === void 0) { opts = {}; } assert("ImportNamespaceSpecifier", node, opts); } function assertImportSpecifier(node, opts) { if (opts === void 0) { opts = {}; } assert("ImportSpecifier", node, opts); } function assertMetaProperty(node, opts) { if (opts === void 0) { opts = {}; } assert("MetaProperty", node, opts); } function assertClassMethod(node, opts) { if (opts === void 0) { opts = {}; } assert("ClassMethod", node, opts); } function assertObjectPattern(node, opts) { if (opts === void 0) { opts = {}; } assert("ObjectPattern", node, opts); } function assertSpreadElement(node, opts) { if (opts === void 0) { opts = {}; } assert("SpreadElement", node, opts); } function assertSuper(node, opts) { if (opts === void 0) { opts = {}; } assert("Super", node, opts); } function assertTaggedTemplateExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("TaggedTemplateExpression", node, opts); } function assertTemplateElement(node, opts) { if (opts === void 0) { opts = {}; } assert("TemplateElement", node, opts); } function assertTemplateLiteral(node, opts) { if (opts === void 0) { opts = {}; } assert("TemplateLiteral", node, opts); } function assertYieldExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("YieldExpression", node, opts); } function assertAnyTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("AnyTypeAnnotation", node, opts); } function assertArrayTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("ArrayTypeAnnotation", node, opts); } function assertBooleanTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("BooleanTypeAnnotation", node, opts); } function assertBooleanLiteralTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("BooleanLiteralTypeAnnotation", node, opts); } function assertNullLiteralTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("NullLiteralTypeAnnotation", node, opts); } function assertClassImplements(node, opts) { if (opts === void 0) { opts = {}; } assert("ClassImplements", node, opts); } function assertDeclareClass(node, opts) { if (opts === void 0) { opts = {}; } assert("DeclareClass", node, opts); } function assertDeclareFunction(node, opts) { if (opts === void 0) { opts = {}; } assert("DeclareFunction", node, opts); } function assertDeclareInterface(node, opts) { if (opts === void 0) { opts = {}; } assert("DeclareInterface", node, opts); } function assertDeclareModule(node, opts) { if (opts === void 0) { opts = {}; } assert("DeclareModule", node, opts); } function assertDeclareModuleExports(node, opts) { if (opts === void 0) { opts = {}; } assert("DeclareModuleExports", node, opts); } function assertDeclareTypeAlias(node, opts) { if (opts === void 0) { opts = {}; } assert("DeclareTypeAlias", node, opts); } function assertDeclareOpaqueType(node, opts) { if (opts === void 0) { opts = {}; } assert("DeclareOpaqueType", node, opts); } function assertDeclareVariable(node, opts) { if (opts === void 0) { opts = {}; } assert("DeclareVariable", node, opts); } function assertDeclareExportDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("DeclareExportDeclaration", node, opts); } function assertDeclareExportAllDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("DeclareExportAllDeclaration", node, opts); } function assertDeclaredPredicate(node, opts) { if (opts === void 0) { opts = {}; } assert("DeclaredPredicate", node, opts); } function assertExistsTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("ExistsTypeAnnotation", node, opts); } function assertFunctionTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("FunctionTypeAnnotation", node, opts); } function assertFunctionTypeParam(node, opts) { if (opts === void 0) { opts = {}; } assert("FunctionTypeParam", node, opts); } function assertGenericTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("GenericTypeAnnotation", node, opts); } function assertInferredPredicate(node, opts) { if (opts === void 0) { opts = {}; } assert("InferredPredicate", node, opts); } function assertInterfaceExtends(node, opts) { if (opts === void 0) { opts = {}; } assert("InterfaceExtends", node, opts); } function assertInterfaceDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("InterfaceDeclaration", node, opts); } function assertInterfaceTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("InterfaceTypeAnnotation", node, opts); } function assertIntersectionTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("IntersectionTypeAnnotation", node, opts); } function assertMixedTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("MixedTypeAnnotation", node, opts); } function assertEmptyTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("EmptyTypeAnnotation", node, opts); } function assertNullableTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("NullableTypeAnnotation", node, opts); } function assertNumberLiteralTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("NumberLiteralTypeAnnotation", node, opts); } function assertNumberTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("NumberTypeAnnotation", node, opts); } function assertObjectTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("ObjectTypeAnnotation", node, opts); } function assertObjectTypeInternalSlot(node, opts) { if (opts === void 0) { opts = {}; } assert("ObjectTypeInternalSlot", node, opts); } function assertObjectTypeCallProperty(node, opts) { if (opts === void 0) { opts = {}; } assert("ObjectTypeCallProperty", node, opts); } function assertObjectTypeIndexer(node, opts) { if (opts === void 0) { opts = {}; } assert("ObjectTypeIndexer", node, opts); } function assertObjectTypeProperty(node, opts) { if (opts === void 0) { opts = {}; } assert("ObjectTypeProperty", node, opts); } function assertObjectTypeSpreadProperty(node, opts) { if (opts === void 0) { opts = {}; } assert("ObjectTypeSpreadProperty", node, opts); } function assertOpaqueType(node, opts) { if (opts === void 0) { opts = {}; } assert("OpaqueType", node, opts); } function assertQualifiedTypeIdentifier(node, opts) { if (opts === void 0) { opts = {}; } assert("QualifiedTypeIdentifier", node, opts); } function assertStringLiteralTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("StringLiteralTypeAnnotation", node, opts); } function assertStringTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("StringTypeAnnotation", node, opts); } function assertThisTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("ThisTypeAnnotation", node, opts); } function assertTupleTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("TupleTypeAnnotation", node, opts); } function assertTypeofTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("TypeofTypeAnnotation", node, opts); } function assertTypeAlias(node, opts) { if (opts === void 0) { opts = {}; } assert("TypeAlias", node, opts); } function assertTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("TypeAnnotation", node, opts); } function assertTypeCastExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("TypeCastExpression", node, opts); } function assertTypeParameter(node, opts) { if (opts === void 0) { opts = {}; } assert("TypeParameter", node, opts); } function assertTypeParameterDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("TypeParameterDeclaration", node, opts); } function assertTypeParameterInstantiation(node, opts) { if (opts === void 0) { opts = {}; } assert("TypeParameterInstantiation", node, opts); } function assertUnionTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("UnionTypeAnnotation", node, opts); } function assertVariance(node, opts) { if (opts === void 0) { opts = {}; } assert("Variance", node, opts); } function assertVoidTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("VoidTypeAnnotation", node, opts); } function assertEnumDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("EnumDeclaration", node, opts); } function assertEnumBooleanBody(node, opts) { if (opts === void 0) { opts = {}; } assert("EnumBooleanBody", node, opts); } function assertEnumNumberBody(node, opts) { if (opts === void 0) { opts = {}; } assert("EnumNumberBody", node, opts); } function assertEnumStringBody(node, opts) { if (opts === void 0) { opts = {}; } assert("EnumStringBody", node, opts); } function assertEnumSymbolBody(node, opts) { if (opts === void 0) { opts = {}; } assert("EnumSymbolBody", node, opts); } function assertEnumBooleanMember(node, opts) { if (opts === void 0) { opts = {}; } assert("EnumBooleanMember", node, opts); } function assertEnumNumberMember(node, opts) { if (opts === void 0) { opts = {}; } assert("EnumNumberMember", node, opts); } function assertEnumStringMember(node, opts) { if (opts === void 0) { opts = {}; } assert("EnumStringMember", node, opts); } function assertEnumDefaultedMember(node, opts) { if (opts === void 0) { opts = {}; } assert("EnumDefaultedMember", node, opts); } function assertJSXAttribute(node, opts) { if (opts === void 0) { opts = {}; } assert("JSXAttribute", node, opts); } function assertJSXClosingElement(node, opts) { if (opts === void 0) { opts = {}; } assert("JSXClosingElement", node, opts); } function assertJSXElement(node, opts) { if (opts === void 0) { opts = {}; } assert("JSXElement", node, opts); } function assertJSXEmptyExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("JSXEmptyExpression", node, opts); } function assertJSXExpressionContainer(node, opts) { if (opts === void 0) { opts = {}; } assert("JSXExpressionContainer", node, opts); } function assertJSXSpreadChild(node, opts) { if (opts === void 0) { opts = {}; } assert("JSXSpreadChild", node, opts); } function assertJSXIdentifier(node, opts) { if (opts === void 0) { opts = {}; } assert("JSXIdentifier", node, opts); } function assertJSXMemberExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("JSXMemberExpression", node, opts); } function assertJSXNamespacedName(node, opts) { if (opts === void 0) { opts = {}; } assert("JSXNamespacedName", node, opts); } function assertJSXOpeningElement(node, opts) { if (opts === void 0) { opts = {}; } assert("JSXOpeningElement", node, opts); } function assertJSXSpreadAttribute(node, opts) { if (opts === void 0) { opts = {}; } assert("JSXSpreadAttribute", node, opts); } function assertJSXText(node, opts) { if (opts === void 0) { opts = {}; } assert("JSXText", node, opts); } function assertJSXFragment(node, opts) { if (opts === void 0) { opts = {}; } assert("JSXFragment", node, opts); } function assertJSXOpeningFragment(node, opts) { if (opts === void 0) { opts = {}; } assert("JSXOpeningFragment", node, opts); } function assertJSXClosingFragment(node, opts) { if (opts === void 0) { opts = {}; } assert("JSXClosingFragment", node, opts); } function assertNoop(node, opts) { if (opts === void 0) { opts = {}; } assert("Noop", node, opts); } function assertPlaceholder(node, opts) { if (opts === void 0) { opts = {}; } assert("Placeholder", node, opts); } function assertV8IntrinsicIdentifier(node, opts) { if (opts === void 0) { opts = {}; } assert("V8IntrinsicIdentifier", node, opts); } function assertArgumentPlaceholder(node, opts) { if (opts === void 0) { opts = {}; } assert("ArgumentPlaceholder", node, opts); } function assertAwaitExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("AwaitExpression", node, opts); } function assertBindExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("BindExpression", node, opts); } function assertClassProperty(node, opts) { if (opts === void 0) { opts = {}; } assert("ClassProperty", node, opts); } function assertOptionalMemberExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("OptionalMemberExpression", node, opts); } function assertPipelineTopicExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("PipelineTopicExpression", node, opts); } function assertPipelineBareFunction(node, opts) { if (opts === void 0) { opts = {}; } assert("PipelineBareFunction", node, opts); } function assertPipelinePrimaryTopicReference(node, opts) { if (opts === void 0) { opts = {}; } assert("PipelinePrimaryTopicReference", node, opts); } function assertOptionalCallExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("OptionalCallExpression", node, opts); } function assertClassPrivateProperty(node, opts) { if (opts === void 0) { opts = {}; } assert("ClassPrivateProperty", node, opts); } function assertClassPrivateMethod(node, opts) { if (opts === void 0) { opts = {}; } assert("ClassPrivateMethod", node, opts); } function assertImport(node, opts) { if (opts === void 0) { opts = {}; } assert("Import", node, opts); } function assertDecorator(node, opts) { if (opts === void 0) { opts = {}; } assert("Decorator", node, opts); } function assertDoExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("DoExpression", node, opts); } function assertExportDefaultSpecifier(node, opts) { if (opts === void 0) { opts = {}; } assert("ExportDefaultSpecifier", node, opts); } function assertExportNamespaceSpecifier(node, opts) { if (opts === void 0) { opts = {}; } assert("ExportNamespaceSpecifier", node, opts); } function assertPrivateName(node, opts) { if (opts === void 0) { opts = {}; } assert("PrivateName", node, opts); } function assertBigIntLiteral(node, opts) { if (opts === void 0) { opts = {}; } assert("BigIntLiteral", node, opts); } function assertTSParameterProperty(node, opts) { if (opts === void 0) { opts = {}; } assert("TSParameterProperty", node, opts); } function assertTSDeclareFunction(node, opts) { if (opts === void 0) { opts = {}; } assert("TSDeclareFunction", node, opts); } function assertTSDeclareMethod(node, opts) { if (opts === void 0) { opts = {}; } assert("TSDeclareMethod", node, opts); } function assertTSQualifiedName(node, opts) { if (opts === void 0) { opts = {}; } assert("TSQualifiedName", node, opts); } function assertTSCallSignatureDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("TSCallSignatureDeclaration", node, opts); } function assertTSConstructSignatureDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("TSConstructSignatureDeclaration", node, opts); } function assertTSPropertySignature(node, opts) { if (opts === void 0) { opts = {}; } assert("TSPropertySignature", node, opts); } function assertTSMethodSignature(node, opts) { if (opts === void 0) { opts = {}; } assert("TSMethodSignature", node, opts); } function assertTSIndexSignature(node, opts) { if (opts === void 0) { opts = {}; } assert("TSIndexSignature", node, opts); } function assertTSAnyKeyword(node, opts) { if (opts === void 0) { opts = {}; } assert("TSAnyKeyword", node, opts); } function assertTSBooleanKeyword(node, opts) { if (opts === void 0) { opts = {}; } assert("TSBooleanKeyword", node, opts); } function assertTSBigIntKeyword(node, opts) { if (opts === void 0) { opts = {}; } assert("TSBigIntKeyword", node, opts); } function assertTSNeverKeyword(node, opts) { if (opts === void 0) { opts = {}; } assert("TSNeverKeyword", node, opts); } function assertTSNullKeyword(node, opts) { if (opts === void 0) { opts = {}; } assert("TSNullKeyword", node, opts); } function assertTSNumberKeyword(node, opts) { if (opts === void 0) { opts = {}; } assert("TSNumberKeyword", node, opts); } function assertTSObjectKeyword(node, opts) { if (opts === void 0) { opts = {}; } assert("TSObjectKeyword", node, opts); } function assertTSStringKeyword(node, opts) { if (opts === void 0) { opts = {}; } assert("TSStringKeyword", node, opts); } function assertTSSymbolKeyword(node, opts) { if (opts === void 0) { opts = {}; } assert("TSSymbolKeyword", node, opts); } function assertTSUndefinedKeyword(node, opts) { if (opts === void 0) { opts = {}; } assert("TSUndefinedKeyword", node, opts); } function assertTSUnknownKeyword(node, opts) { if (opts === void 0) { opts = {}; } assert("TSUnknownKeyword", node, opts); } function assertTSVoidKeyword(node, opts) { if (opts === void 0) { opts = {}; } assert("TSVoidKeyword", node, opts); } function assertTSThisType(node, opts) { if (opts === void 0) { opts = {}; } assert("TSThisType", node, opts); } function assertTSFunctionType(node, opts) { if (opts === void 0) { opts = {}; } assert("TSFunctionType", node, opts); } function assertTSConstructorType(node, opts) { if (opts === void 0) { opts = {}; } assert("TSConstructorType", node, opts); } function assertTSTypeReference(node, opts) { if (opts === void 0) { opts = {}; } assert("TSTypeReference", node, opts); } function assertTSTypePredicate(node, opts) { if (opts === void 0) { opts = {}; } assert("TSTypePredicate", node, opts); } function assertTSTypeQuery(node, opts) { if (opts === void 0) { opts = {}; } assert("TSTypeQuery", node, opts); } function assertTSTypeLiteral(node, opts) { if (opts === void 0) { opts = {}; } assert("TSTypeLiteral", node, opts); } function assertTSArrayType(node, opts) { if (opts === void 0) { opts = {}; } assert("TSArrayType", node, opts); } function assertTSTupleType(node, opts) { if (opts === void 0) { opts = {}; } assert("TSTupleType", node, opts); } function assertTSOptionalType(node, opts) { if (opts === void 0) { opts = {}; } assert("TSOptionalType", node, opts); } function assertTSRestType(node, opts) { if (opts === void 0) { opts = {}; } assert("TSRestType", node, opts); } function assertTSUnionType(node, opts) { if (opts === void 0) { opts = {}; } assert("TSUnionType", node, opts); } function assertTSIntersectionType(node, opts) { if (opts === void 0) { opts = {}; } assert("TSIntersectionType", node, opts); } function assertTSConditionalType(node, opts) { if (opts === void 0) { opts = {}; } assert("TSConditionalType", node, opts); } function assertTSInferType(node, opts) { if (opts === void 0) { opts = {}; } assert("TSInferType", node, opts); } function assertTSParenthesizedType(node, opts) { if (opts === void 0) { opts = {}; } assert("TSParenthesizedType", node, opts); } function assertTSTypeOperator(node, opts) { if (opts === void 0) { opts = {}; } assert("TSTypeOperator", node, opts); } function assertTSIndexedAccessType(node, opts) { if (opts === void 0) { opts = {}; } assert("TSIndexedAccessType", node, opts); } function assertTSMappedType(node, opts) { if (opts === void 0) { opts = {}; } assert("TSMappedType", node, opts); } function assertTSLiteralType(node, opts) { if (opts === void 0) { opts = {}; } assert("TSLiteralType", node, opts); } function assertTSExpressionWithTypeArguments(node, opts) { if (opts === void 0) { opts = {}; } assert("TSExpressionWithTypeArguments", node, opts); } function assertTSInterfaceDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("TSInterfaceDeclaration", node, opts); } function assertTSInterfaceBody(node, opts) { if (opts === void 0) { opts = {}; } assert("TSInterfaceBody", node, opts); } function assertTSTypeAliasDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("TSTypeAliasDeclaration", node, opts); } function assertTSAsExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("TSAsExpression", node, opts); } function assertTSTypeAssertion(node, opts) { if (opts === void 0) { opts = {}; } assert("TSTypeAssertion", node, opts); } function assertTSEnumDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("TSEnumDeclaration", node, opts); } function assertTSEnumMember(node, opts) { if (opts === void 0) { opts = {}; } assert("TSEnumMember", node, opts); } function assertTSModuleDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("TSModuleDeclaration", node, opts); } function assertTSModuleBlock(node, opts) { if (opts === void 0) { opts = {}; } assert("TSModuleBlock", node, opts); } function assertTSImportType(node, opts) { if (opts === void 0) { opts = {}; } assert("TSImportType", node, opts); } function assertTSImportEqualsDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("TSImportEqualsDeclaration", node, opts); } function assertTSExternalModuleReference(node, opts) { if (opts === void 0) { opts = {}; } assert("TSExternalModuleReference", node, opts); } function assertTSNonNullExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("TSNonNullExpression", node, opts); } function assertTSExportAssignment(node, opts) { if (opts === void 0) { opts = {}; } assert("TSExportAssignment", node, opts); } function assertTSNamespaceExportDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("TSNamespaceExportDeclaration", node, opts); } function assertTSTypeAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("TSTypeAnnotation", node, opts); } function assertTSTypeParameterInstantiation(node, opts) { if (opts === void 0) { opts = {}; } assert("TSTypeParameterInstantiation", node, opts); } function assertTSTypeParameterDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("TSTypeParameterDeclaration", node, opts); } function assertTSTypeParameter(node, opts) { if (opts === void 0) { opts = {}; } assert("TSTypeParameter", node, opts); } function assertExpression(node, opts) { if (opts === void 0) { opts = {}; } assert("Expression", node, opts); } function assertBinary(node, opts) { if (opts === void 0) { opts = {}; } assert("Binary", node, opts); } function assertScopable(node, opts) { if (opts === void 0) { opts = {}; } assert("Scopable", node, opts); } function assertBlockParent(node, opts) { if (opts === void 0) { opts = {}; } assert("BlockParent", node, opts); } function assertBlock(node, opts) { if (opts === void 0) { opts = {}; } assert("Block", node, opts); } function assertStatement(node, opts) { if (opts === void 0) { opts = {}; } assert("Statement", node, opts); } function assertTerminatorless(node, opts) { if (opts === void 0) { opts = {}; } assert("Terminatorless", node, opts); } function assertCompletionStatement(node, opts) { if (opts === void 0) { opts = {}; } assert("CompletionStatement", node, opts); } function assertConditional(node, opts) { if (opts === void 0) { opts = {}; } assert("Conditional", node, opts); } function assertLoop(node, opts) { if (opts === void 0) { opts = {}; } assert("Loop", node, opts); } function assertWhile(node, opts) { if (opts === void 0) { opts = {}; } assert("While", node, opts); } function assertExpressionWrapper(node, opts) { if (opts === void 0) { opts = {}; } assert("ExpressionWrapper", node, opts); } function assertFor(node, opts) { if (opts === void 0) { opts = {}; } assert("For", node, opts); } function assertForXStatement(node, opts) { if (opts === void 0) { opts = {}; } assert("ForXStatement", node, opts); } function assertFunction(node, opts) { if (opts === void 0) { opts = {}; } assert("Function", node, opts); } function assertFunctionParent(node, opts) { if (opts === void 0) { opts = {}; } assert("FunctionParent", node, opts); } function assertPureish(node, opts) { if (opts === void 0) { opts = {}; } assert("Pureish", node, opts); } function assertDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("Declaration", node, opts); } function assertPatternLike(node, opts) { if (opts === void 0) { opts = {}; } assert("PatternLike", node, opts); } function assertLVal(node, opts) { if (opts === void 0) { opts = {}; } assert("LVal", node, opts); } function assertTSEntityName(node, opts) { if (opts === void 0) { opts = {}; } assert("TSEntityName", node, opts); } function assertLiteral(node, opts) { if (opts === void 0) { opts = {}; } assert("Literal", node, opts); } function assertImmutable(node, opts) { if (opts === void 0) { opts = {}; } assert("Immutable", node, opts); } function assertUserWhitespacable(node, opts) { if (opts === void 0) { opts = {}; } assert("UserWhitespacable", node, opts); } function assertMethod(node, opts) { if (opts === void 0) { opts = {}; } assert("Method", node, opts); } function assertObjectMember(node, opts) { if (opts === void 0) { opts = {}; } assert("ObjectMember", node, opts); } function assertProperty(node, opts) { if (opts === void 0) { opts = {}; } assert("Property", node, opts); } function assertUnaryLike(node, opts) { if (opts === void 0) { opts = {}; } assert("UnaryLike", node, opts); } function assertPattern(node, opts) { if (opts === void 0) { opts = {}; } assert("Pattern", node, opts); } function assertClass(node, opts) { if (opts === void 0) { opts = {}; } assert("Class", node, opts); } function assertModuleDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("ModuleDeclaration", node, opts); } function assertExportDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("ExportDeclaration", node, opts); } function assertModuleSpecifier(node, opts) { if (opts === void 0) { opts = {}; } assert("ModuleSpecifier", node, opts); } function assertFlow(node, opts) { if (opts === void 0) { opts = {}; } assert("Flow", node, opts); } function assertFlowType(node, opts) { if (opts === void 0) { opts = {}; } assert("FlowType", node, opts); } function assertFlowBaseAnnotation(node, opts) { if (opts === void 0) { opts = {}; } assert("FlowBaseAnnotation", node, opts); } function assertFlowDeclaration(node, opts) { if (opts === void 0) { opts = {}; } assert("FlowDeclaration", node, opts); } function assertFlowPredicate(node, opts) { if (opts === void 0) { opts = {}; } assert("FlowPredicate", node, opts); } function assertEnumBody(node, opts) { if (opts === void 0) { opts = {}; } assert("EnumBody", node, opts); } function assertEnumMember(node, opts) { if (opts === void 0) { opts = {}; } assert("EnumMember", node, opts); } function assertJSX(node, opts) { if (opts === void 0) { opts = {}; } assert("JSX", node, opts); } function assertPrivate(node, opts) { if (opts === void 0) { opts = {}; } assert("Private", node, opts); } function assertTSTypeElement(node, opts) { if (opts === void 0) { opts = {}; } assert("TSTypeElement", node, opts); } function assertTSType(node, opts) { if (opts === void 0) { opts = {}; } assert("TSType", node, opts); } function assertNumberLiteral(node, opts) { console.trace("The node type NumberLiteral has been renamed to NumericLiteral"); assert("NumberLiteral", node, opts); } function assertRegexLiteral(node, opts) { console.trace("The node type RegexLiteral has been renamed to RegExpLiteral"); assert("RegexLiteral", node, opts); } function assertRestProperty(node, opts) { console.trace("The node type RestProperty has been renamed to RestElement"); assert("RestProperty", node, opts); } function assertSpreadProperty(node, opts) { console.trace("The node type SpreadProperty has been renamed to SpreadElement"); assert("SpreadProperty", node, opts); } function createTypeAnnotationBasedOnTypeof(type) { if (type === "string") { return StringTypeAnnotation(); } else if (type === "number") { return NumberTypeAnnotation(); } else if (type === "undefined") { return VoidTypeAnnotation(); } else if (type === "boolean") { return BooleanTypeAnnotation(); } else if (type === "function") { return GenericTypeAnnotation(Identifier("Function")); } else if (type === "object") { return GenericTypeAnnotation(Identifier("Object")); } else if (type === "symbol") { return GenericTypeAnnotation(Identifier("Symbol")); } else { throw new Error("Invalid typeof value"); } } function removeTypeDuplicates(nodes) { var generics = {}; var bases = {}; var typeGroups = []; var types = []; for (var i = 0; i < nodes.length; i++) { var node = nodes[i]; if (!node) continue; if (types.indexOf(node) >= 0) { continue; } if (isAnyTypeAnnotation(node)) { return [node]; } if (isFlowBaseAnnotation(node)) { bases[node.type] = node; continue; } if (isUnionTypeAnnotation(node)) { if (typeGroups.indexOf(node.types) < 0) { nodes = nodes.concat(node.types); typeGroups.push(node.types); } continue; } if (isGenericTypeAnnotation(node)) { var name = node.id.name; if (generics[name]) { var existing = generics[name]; if (existing.typeParameters) { if (node.typeParameters) { existing.typeParameters.params = removeTypeDuplicates(existing.typeParameters.params.concat(node.typeParameters.params)); } } else { existing = node.typeParameters; } } else { generics[name] = node; } continue; } types.push(node); } for (var _i = 0, _Object$keys = Object.keys(bases); _i < _Object$keys.length; _i++) { var type = _Object$keys[_i]; types.push(bases[type]); } for (var _i2 = 0, _Object$keys2 = Object.keys(generics); _i2 < _Object$keys2.length; _i2++) { var _name = _Object$keys2[_i2]; types.push(generics[_name]); } return types; } function createUnionTypeAnnotation(types) { var flattened = removeTypeDuplicates(types); if (flattened.length === 1) { return flattened[0]; } else { return UnionTypeAnnotation(flattened); } } var has = Function.call.bind(Object.prototype.hasOwnProperty); function cloneIfNode(obj, deep) { if (obj && typeof obj.type === "string" && obj.type !== "CommentLine" && obj.type !== "CommentBlock") { return cloneNode(obj, deep); } return obj; } function cloneIfNodeOrArray(obj, deep) { if (Array.isArray(obj)) { return obj.map(function (node) { return cloneIfNode(node, deep); }); } return cloneIfNode(obj, deep); } function cloneNode(node, deep) { if (deep === void 0) { deep = true; } if (!node) return node; var type = node.type; var newNode = { type: type }; if (type === "Identifier") { newNode.name = node.name; if (has(node, "optional") && typeof node.optional === "boolean") { newNode.optional = node.optional; } if (has(node, "typeAnnotation")) { newNode.typeAnnotation = deep ? cloneIfNodeOrArray(node.typeAnnotation, true) : node.typeAnnotation; } } else if (!has(NODE_FIELDS, type)) { throw new Error("Unknown node type: \"" + type + "\""); } else { for (var _i = 0, _Object$keys = Object.keys(NODE_FIELDS[type]); _i < _Object$keys.length; _i++) { var field = _Object$keys[_i]; if (has(node, field)) { newNode[field] = deep ? cloneIfNodeOrArray(node[field], true) : node[field]; } } } if (has(node, "loc")) { newNode.loc = node.loc; } if (has(node, "leadingComments")) { newNode.leadingComments = node.leadingComments; } if (has(node, "innerComments")) { newNode.innerComments = node.innerComments; } if (has(node, "trailingComments")) { newNode.trailingComments = node.trailingComments; } if (has(node, "extra")) { newNode.extra = Object.assign({}, node.extra); } return newNode; } function clone$1(node) { return cloneNode(node, false); } function cloneDeep(node) { return cloneNode(node); } function cloneWithoutLoc(node) { var newNode = clone$1(node); newNode.loc = null; return newNode; } function addComments(node, type, comments) { if (!comments || !node) return node; var key = type + "Comments"; if (node[key]) { if (type === "leading") { node[key] = comments.concat(node[key]); } else { node[key] = node[key].concat(comments); } } else { node[key] = comments; } return node; } function addComment(node, type, content, line) { return addComments(node, type, [{ type: line ? "CommentLine" : "CommentBlock", value: content }]); } var HASH_UNDEFINED$2 = '__lodash_hash_undefined__'; function setCacheAdd(value) { this.__data__.set(value, HASH_UNDEFINED$2); return this; } var _setCacheAdd = setCacheAdd; function setCacheHas(value) { return this.__data__.has(value); } var _setCacheHas = setCacheHas; function SetCache(values) { var index = -1, length = values == null ? 0 : values.length; this.__data__ = new _MapCache(); while (++index < length) { this.add(values[index]); } } SetCache.prototype.add = SetCache.prototype.push = _setCacheAdd; SetCache.prototype.has = _setCacheHas; var _SetCache = SetCache; function baseFindIndex(array, predicate, fromIndex, fromRight) { var length = array.length, index = fromIndex + (fromRight ? 1 : -1); while (fromRight ? index-- : ++index < length) { if (predicate(array[index], index, array)) { return index; } } return -1; } var _baseFindIndex = baseFindIndex; function baseIsNaN(value) { return value !== value; } var _baseIsNaN = baseIsNaN; function strictIndexOf(array, value, fromIndex) { var index = fromIndex - 1, length = array.length; while (++index < length) { if (array[index] === value) { return index; } } return -1; } var _strictIndexOf = strictIndexOf; function baseIndexOf(array, value, fromIndex) { return value === value ? _strictIndexOf(array, value, fromIndex) : _baseFindIndex(array, _baseIsNaN, fromIndex); } var _baseIndexOf = baseIndexOf; function arrayIncludes(array, value) { var length = array == null ? 0 : array.length; return !!length && _baseIndexOf(array, value, 0) > -1; } var _arrayIncludes = arrayIncludes; function arrayIncludesWith(array, value, comparator) { var index = -1, length = array == null ? 0 : array.length; while (++index < length) { if (comparator(value, array[index])) { return true; } } return false; } var _arrayIncludesWith = arrayIncludesWith; function cacheHas(cache, key) { return cache.has(key); } var _cacheHas = cacheHas; function noop$1() {} var noop_1 = noop$1; function setToArray(set) { var index = -1, result = Array(set.size); set.forEach(function (value) { result[++index] = value; }); return result; } var _setToArray = setToArray; var INFINITY = 1 / 0; var createSet = !(_Set && 1 / _setToArray(new _Set([, -0]))[1] == INFINITY) ? noop_1 : function (values) { return new _Set(values); }; var _createSet = createSet; var LARGE_ARRAY_SIZE$1 = 200; function baseUniq(array, iteratee, comparator) { var index = -1, includes = _arrayIncludes, length = array.length, isCommon = true, result = [], seen = result; if (comparator) { isCommon = false; includes = _arrayIncludesWith; } else if (length >= LARGE_ARRAY_SIZE$1) { var set = iteratee ? null : _createSet(array); if (set) { return _setToArray(set); } isCommon = false; includes = _cacheHas; seen = new _SetCache(); } else { seen = iteratee ? [] : result; } outer: while (++index < length) { var value = array[index], computed = iteratee ? iteratee(value) : value; value = comparator || value !== 0 ? value : 0; if (isCommon && computed === computed) { var seenIndex = seen.length; while (seenIndex--) { if (seen[seenIndex] === computed) { continue outer; } } if (iteratee) { seen.push(computed); } result.push(value); } else if (!includes(seen, computed, comparator)) { if (seen !== result) { seen.push(computed); } result.push(value); } } return result; } var _baseUniq = baseUniq; function uniq(array) { return array && array.length ? _baseUniq(array) : []; } var uniq_1 = uniq; function inherit(key, child, parent) { if (child && parent) { child[key] = uniq_1([].concat(child[key], parent[key]).filter(Boolean)); } } function inheritInnerComments(child, parent) { inherit("innerComments", child, parent); } function inheritLeadingComments(child, parent) { inherit("leadingComments", child, parent); } function inheritTrailingComments(child, parent) { inherit("trailingComments", child, parent); } function inheritsComments(child, parent) { inheritTrailingComments(child, parent); inheritLeadingComments(child, parent); inheritInnerComments(child, parent); return child; } function removeComments(node) { COMMENT_KEYS.forEach(function (key) { node[key] = null; }); return node; } var EXPRESSION_TYPES = FLIPPED_ALIAS_KEYS["Expression"]; var BINARY_TYPES = FLIPPED_ALIAS_KEYS["Binary"]; var SCOPABLE_TYPES = FLIPPED_ALIAS_KEYS["Scopable"]; var BLOCKPARENT_TYPES = FLIPPED_ALIAS_KEYS["BlockParent"]; var BLOCK_TYPES = FLIPPED_ALIAS_KEYS["Block"]; var STATEMENT_TYPES = FLIPPED_ALIAS_KEYS["Statement"]; var TERMINATORLESS_TYPES = FLIPPED_ALIAS_KEYS["Terminatorless"]; var COMPLETIONSTATEMENT_TYPES = FLIPPED_ALIAS_KEYS["CompletionStatement"]; var CONDITIONAL_TYPES = FLIPPED_ALIAS_KEYS["Conditional"]; var LOOP_TYPES = FLIPPED_ALIAS_KEYS["Loop"]; var WHILE_TYPES = FLIPPED_ALIAS_KEYS["While"]; var EXPRESSIONWRAPPER_TYPES = FLIPPED_ALIAS_KEYS["ExpressionWrapper"]; var FOR_TYPES = FLIPPED_ALIAS_KEYS["For"]; var FORXSTATEMENT_TYPES = FLIPPED_ALIAS_KEYS["ForXStatement"]; var FUNCTION_TYPES = FLIPPED_ALIAS_KEYS["Function"]; var FUNCTIONPARENT_TYPES = FLIPPED_ALIAS_KEYS["FunctionParent"]; var PUREISH_TYPES = FLIPPED_ALIAS_KEYS["Pureish"]; var DECLARATION_TYPES = FLIPPED_ALIAS_KEYS["Declaration"]; var PATTERNLIKE_TYPES = FLIPPED_ALIAS_KEYS["PatternLike"]; var LVAL_TYPES = FLIPPED_ALIAS_KEYS["LVal"]; var TSENTITYNAME_TYPES = FLIPPED_ALIAS_KEYS["TSEntityName"]; var LITERAL_TYPES = FLIPPED_ALIAS_KEYS["Literal"]; var IMMUTABLE_TYPES = FLIPPED_ALIAS_KEYS["Immutable"]; var USERWHITESPACABLE_TYPES = FLIPPED_ALIAS_KEYS["UserWhitespacable"]; var METHOD_TYPES = FLIPPED_ALIAS_KEYS["Method"]; var OBJECTMEMBER_TYPES = FLIPPED_ALIAS_KEYS["ObjectMember"]; var PROPERTY_TYPES = FLIPPED_ALIAS_KEYS["Property"]; var UNARYLIKE_TYPES = FLIPPED_ALIAS_KEYS["UnaryLike"]; var PATTERN_TYPES = FLIPPED_ALIAS_KEYS["Pattern"]; var CLASS_TYPES = FLIPPED_ALIAS_KEYS["Class"]; var MODULEDECLARATION_TYPES = FLIPPED_ALIAS_KEYS["ModuleDeclaration"]; var EXPORTDECLARATION_TYPES = FLIPPED_ALIAS_KEYS["ExportDeclaration"]; var MODULESPECIFIER_TYPES = FLIPPED_ALIAS_KEYS["ModuleSpecifier"]; var FLOW_TYPES = FLIPPED_ALIAS_KEYS["Flow"]; var FLOWTYPE_TYPES = FLIPPED_ALIAS_KEYS["FlowType"]; var FLOWBASEANNOTATION_TYPES = FLIPPED_ALIAS_KEYS["FlowBaseAnnotation"]; var FLOWDECLARATION_TYPES = FLIPPED_ALIAS_KEYS["FlowDeclaration"]; var FLOWPREDICATE_TYPES = FLIPPED_ALIAS_KEYS["FlowPredicate"]; var ENUMBODY_TYPES = FLIPPED_ALIAS_KEYS["EnumBody"]; var ENUMMEMBER_TYPES = FLIPPED_ALIAS_KEYS["EnumMember"]; var JSX_TYPES = FLIPPED_ALIAS_KEYS["JSX"]; var PRIVATE_TYPES = FLIPPED_ALIAS_KEYS["Private"]; var TSTYPEELEMENT_TYPES = FLIPPED_ALIAS_KEYS["TSTypeElement"]; var TSTYPE_TYPES = FLIPPED_ALIAS_KEYS["TSType"]; function toBlock(node, parent) { if (isBlockStatement(node)) { return node; } var blockNodes = []; if (isEmptyStatement(node)) { blockNodes = []; } else { if (!isStatement(node)) { if (isFunction(parent)) { node = ReturnStatement(node); } else { node = ExpressionStatement(node); } } blockNodes = [node]; } return BlockStatement(blockNodes); } function ensureBlock(node, key) { if (key === void 0) { key = "body"; } return node[key] = toBlock(node[key], node); } function isValidIdentifier(name, reserved) { if (reserved === void 0) { reserved = true; } if (typeof name !== "string") return false; if (reserved) { if (utils.keyword.isReservedWordES6(name, true)) { return false; } else if (name === "await") { return false; } } return utils.keyword.isIdentifierNameES6(name); } function toIdentifier(name) { name = name + ""; name = name.replace(/[^a-zA-Z0-9$_]/g, "-"); name = name.replace(/^[-0-9]+/, ""); name = name.replace(/[-\s]+(.)?/g, function (match, c) { return c ? c.toUpperCase() : ""; }); if (!isValidIdentifier(name)) { name = "_" + name; } return name || "_"; } function toBindingIdentifierName(name) { name = toIdentifier(name); if (name === "eval" || name === "arguments") name = "_" + name; return name; } function toComputedKey(node, key) { if (key === void 0) { key = node.key || node.property; } if (!node.computed && isIdentifier(key)) key = StringLiteral(key.name); return key; } function toExpression(node) { if (isExpressionStatement(node)) { node = node.expression; } if (isExpression(node)) { return node; } if (isClass(node)) { node.type = "ClassExpression"; } else if (isFunction(node)) { node.type = "FunctionExpression"; } if (!isExpression(node)) { throw new Error("cannot turn " + node.type + " to an expression"); } return node; } function traverseFast(node, enter, opts) { if (!node) return; var keys = VISITOR_KEYS[node.type]; if (!keys) return; opts = opts || {}; enter(node, opts); for (var _iterator = keys, _isArray = Array.isArray(_iterator), _i = 0, _iterator = _isArray ? _iterator : _iterator[Symbol.iterator]();;) { var _ref; if (_isArray) { if (_i >= _iterator.length) break; _ref = _iterator[_i++]; } else { _i = _iterator.next(); if (_i.done) break; _ref = _i.value; } var key = _ref; var subNode = node[key]; if (Array.isArray(subNode)) { for (var _iterator2 = subNode, _isArray2 = Array.isArray(_iterator2), _i2 = 0, _iterator2 = _isArray2 ? _iterator2 : _iterator2[Symbol.iterator]();;) { var _ref2; if (_isArray2) { if (_i2 >= _iterator2.length) break; _ref2 = _iterator2[_i2++]; } else { _i2 = _iterator2.next(); if (_i2.done) break; _ref2 = _i2.value; } var _node = _ref2; traverseFast(_node, enter, opts); } } else { traverseFast(subNode, enter, opts); } } } var CLEAR_KEYS = ["tokens", "start", "end", "loc", "raw", "rawValue"]; var CLEAR_KEYS_PLUS_COMMENTS = COMMENT_KEYS.concat(["comments"]).concat(CLEAR_KEYS); function removeProperties(node, opts) { if (opts === void 0) { opts = {}; } var map = opts.preserveComments ? CLEAR_KEYS : CLEAR_KEYS_PLUS_COMMENTS; for (var _iterator = map, _isArray = Array.isArray(_iterator), _i = 0, _iterator = _isArray ? _iterator : _iterator[Symbol.iterator]();;) { var _ref; if (_isArray) { if (_i >= _iterator.length) break; _ref = _iterator[_i++]; } else { _i = _iterator.next(); if (_i.done) break; _ref = _i.value; } var key = _ref; if (node[key] != null) node[key] = undefined; } for (var _i2 = 0, _Object$keys = Object.keys(node); _i2 < _Object$keys.length; _i2++) { var _key = _Object$keys[_i2]; if (_key[0] === "_" && node[_key] != null) node[_key] = undefined; } var symbols = Object.getOwnPropertySymbols(node); for (var _iterator2 = symbols, _isArray2 = Array.isArray(_iterator2), _i3 = 0, _iterator2 = _isArray2 ? _iterator2 : _iterator2[Symbol.iterator]();;) { var _ref2; if (_isArray2) { if (_i3 >= _iterator2.length) break; _ref2 = _iterator2[_i3++]; } else { _i3 = _iterator2.next(); if (_i3.done) break; _ref2 = _i3.value; } var sym = _ref2; node[sym] = null; } } function removePropertiesDeep(tree, opts) { traverseFast(tree, removeProperties, opts); return tree; } function toKeyAlias(node, key) { if (key === void 0) { key = node.key; } var alias; if (node.kind === "method") { return toKeyAlias.increment() + ""; } else if (isIdentifier(key)) { alias = key.name; } else if (isStringLiteral(key)) { alias = JSON.stringify(key.value); } else { alias = JSON.stringify(removePropertiesDeep(cloneNode(key))); } if (node.computed) { alias = "[" + alias + "]"; } if (node["static"]) { alias = "static:" + alias; } return alias; } toKeyAlias.uid = 0; toKeyAlias.increment = function () { if (toKeyAlias.uid >= Number.MAX_SAFE_INTEGER) { return toKeyAlias.uid = 0; } else { return toKeyAlias.uid++; } }; function getBindingIdentifiers(node, duplicates, outerOnly) { var search = [].concat(node); var ids = Object.create(null); while (search.length) { var id = search.shift(); if (!id) continue; var keys = getBindingIdentifiers.keys[id.type]; if (isIdentifier(id)) { if (duplicates) { var _ids = ids[id.name] = ids[id.name] || []; _ids.push(id); } else { ids[id.name] = id; } continue; } if (isExportDeclaration(id)) { if (isDeclaration(id.declaration)) { search.push(id.declaration); } continue; } if (outerOnly) { if (isFunctionDeclaration(id)) { search.push(id.id); continue; } if (isFunctionExpression(id)) { continue; } } if (keys) { for (var i = 0; i < keys.length; i++) { var key = keys[i]; if (id[key]) { search = search.concat(id[key]); } } } } return ids; } getBindingIdentifiers.keys = { DeclareClass: ["id"], DeclareFunction: ["id"], DeclareModule: ["id"], DeclareVariable: ["id"], DeclareInterface: ["id"], DeclareTypeAlias: ["id"], DeclareOpaqueType: ["id"], InterfaceDeclaration: ["id"], TypeAlias: ["id"], OpaqueType: ["id"], CatchClause: ["param"], LabeledStatement: ["label"], UnaryExpression: ["argument"], AssignmentExpression: ["left"], ImportSpecifier: ["local"], ImportNamespaceSpecifier: ["local"], ImportDefaultSpecifier: ["local"], ImportDeclaration: ["specifiers"], ExportSpecifier: ["exported"], ExportNamespaceSpecifier: ["exported"], ExportDefaultSpecifier: ["exported"], FunctionDeclaration: ["id", "params"], FunctionExpression: ["id", "params"], ArrowFunctionExpression: ["params"], ObjectMethod: ["params"], ClassMethod: ["params"], ForInStatement: ["left"], ForOfStatement: ["left"], ClassDeclaration: ["id"], ClassExpression: ["id"], RestElement: ["argument"], UpdateExpression: ["argument"], ObjectProperty: ["value"], AssignmentPattern: ["left"], ArrayPattern: ["elements"], ObjectPattern: ["properties"], VariableDeclaration: ["declarations"], VariableDeclarator: ["id"] }; function gatherSequenceExpressions(nodes, scope, declars) { var exprs = []; var ensureLastUndefined = true; for (var _iterator = nodes, _isArray = Array.isArray(_iterator), _i = 0, _iterator = _isArray ? _iterator : _iterator[Symbol.iterator]();;) { var _ref; if (_isArray) { if (_i >= _iterator.length) break; _ref = _iterator[_i++]; } else { _i = _iterator.next(); if (_i.done) break; _ref = _i.value; } var node = _ref; ensureLastUndefined = false; if (isExpression(node)) { exprs.push(node); } else if (isExpressionStatement(node)) { exprs.push(node.expression); } else if (isVariableDeclaration(node)) { if (node.kind !== "var") return; for (var _i2 = 0, _arr = node.declarations; _i2 < _arr.length; _i2++) { var declar = _arr[_i2]; var bindings = getBindingIdentifiers(declar); for (var _i3 = 0, _Object$keys = Object.keys(bindings); _i3 < _Object$keys.length; _i3++) { var key = _Object$keys[_i3]; declars.push({ kind: node.kind, id: cloneNode(bindings[key]) }); } if (declar.init) { exprs.push(AssignmentExpression("=", declar.id, declar.init)); } } ensureLastUndefined = true; } else if (isIfStatement(node)) { var consequent = node.consequent ? gatherSequenceExpressions([node.consequent], scope, declars) : scope.buildUndefinedNode(); var alternate = node.alternate ? gatherSequenceExpressions([node.alternate], scope, declars) : scope.buildUndefinedNode(); if (!consequent || !alternate) return; exprs.push(ConditionalExpression(node.test, consequent, alternate)); } else if (isBlockStatement(node)) { var body = gatherSequenceExpressions(node.body, scope, declars); if (!body) return; exprs.push(body); } else if (isEmptyStatement(node)) { ensureLastUndefined = true; } else { return; } } if (ensureLastUndefined) { exprs.push(scope.buildUndefinedNode()); } if (exprs.length === 1) { return exprs[0]; } else { return SequenceExpression(exprs); } } function toSequenceExpression(nodes, scope) { if (!nodes || !nodes.length) return; var declars = []; var result = gatherSequenceExpressions(nodes, scope, declars); if (!result) return; for (var _i = 0, _declars = declars; _i < _declars.length; _i++) { var declar = _declars[_i]; scope.push(declar); } return result; } function toStatement(node, ignore) { if (isStatement(node)) { return node; } var mustHaveId = false; var newType; if (isClass(node)) { mustHaveId = true; newType = "ClassDeclaration"; } else if (isFunction(node)) { mustHaveId = true; newType = "FunctionDeclaration"; } else if (isAssignmentExpression(node)) { return ExpressionStatement(node); } if (mustHaveId && !node.id) { newType = false; } if (!newType) { if (ignore) { return false; } else { throw new Error("cannot turn " + node.type + " to a statement"); } } node.type = newType; return node; } var objectTag$3 = '[object Object]'; var funcProto$2 = Function.prototype, objectProto$d = Object.prototype; var funcToString$2 = funcProto$2.toString; var hasOwnProperty$a = objectProto$d.hasOwnProperty; var objectCtorString = funcToString$2.call(Object); function isPlainObject(value) { if (!isObjectLike_1(value) || _baseGetTag(value) != objectTag$3) { return false; } var proto = _getPrototype(value); if (proto === null) { return true; } var Ctor = hasOwnProperty$a.call(proto, 'constructor') && proto.constructor; return typeof Ctor == 'function' && Ctor instanceof Ctor && funcToString$2.call(Ctor) == objectCtorString; } var isPlainObject_1 = isPlainObject; var regexpTag$3 = '[object RegExp]'; function baseIsRegExp(value) { return isObjectLike_1(value) && _baseGetTag(value) == regexpTag$3; } var _baseIsRegExp = baseIsRegExp; var nodeIsRegExp = _nodeUtil && _nodeUtil.isRegExp; var isRegExp = nodeIsRegExp ? _baseUnary(nodeIsRegExp) : _baseIsRegExp; var isRegExp_1 = isRegExp; function valueToNode(value) { if (value === undefined) { return Identifier("undefined"); } if (value === true || value === false) { return BooleanLiteral(value); } if (value === null) { return NullLiteral(); } if (typeof value === "string") { return StringLiteral(value); } if (typeof value === "number") { var result; if (Number.isFinite(value)) { result = NumericLiteral(Math.abs(value)); } else { var numerator; if (Number.isNaN(value)) { numerator = NumericLiteral(0); } else { numerator = NumericLiteral(1); } result = BinaryExpression("/", numerator, NumericLiteral(0)); } if (value < 0 || Object.is(value, -0)) { result = UnaryExpression("-", result); } return result; } if (isRegExp_1(value)) { var pattern = value.source; var flags = value.toString().match(/\/([a-z]+|)$/)[1]; return RegExpLiteral(pattern, flags); } if (Array.isArray(value)) { return ArrayExpression(value.map(valueToNode)); } if (isPlainObject_1(value)) { var props = []; for (var _i = 0, _Object$keys = Object.keys(value); _i < _Object$keys.length; _i++) { var key = _Object$keys[_i]; var nodeKey = void 0; if (isValidIdentifier(key)) { nodeKey = Identifier(key); } else { nodeKey = StringLiteral(key); } props.push(ObjectProperty(nodeKey, valueToNode(value[key]))); } return ObjectExpression(props); } throw new Error("don't know how to turn this value into a node"); } function appendToMemberExpression(member, append, computed) { if (computed === void 0) { computed = false; } member.object = MemberExpression(member.object, member.property, member.computed); member.property = append; member.computed = !!computed; return member; } function inherits(child, parent) { if (!child || !parent) return child; for (var _i = 0, _arr = INHERIT_KEYS.optional; _i < _arr.length; _i++) { var key = _arr[_i]; if (child[key] == null) { child[key] = parent[key]; } } for (var _i2 = 0, _Object$keys = Object.keys(parent); _i2 < _Object$keys.length; _i2++) { var _key = _Object$keys[_i2]; if (_key[0] === "_" && _key !== "__clone") child[_key] = parent[_key]; } for (var _i3 = 0, _arr2 = INHERIT_KEYS.force; _i3 < _arr2.length; _i3++) { var _key2 = _arr2[_i3]; child[_key2] = parent[_key2]; } inheritsComments(child, parent); return child; } function prependToMemberExpression(member, prepend) { member.object = MemberExpression(prepend, member.object); return member; } function getOuterBindingIdentifiers(node, duplicates) { return getBindingIdentifiers(node, duplicates, true); } function traverse(node, handlers, state) { if (typeof handlers === "function") { handlers = { enter: handlers }; } var _ref = handlers, enter = _ref.enter, exit = _ref.exit; traverseSimpleImpl(node, enter, exit, state, []); } function traverseSimpleImpl(node, enter, exit, state, ancestors) { var keys = VISITOR_KEYS[node.type]; if (!keys) return; if (enter) enter(node, ancestors, state); for (var _iterator = keys, _isArray = Array.isArray(_iterator), _i = 0, _iterator = _isArray ? _iterator : _iterator[Symbol.iterator]();;) { var _ref2; if (_isArray) { if (_i >= _iterator.length) break; _ref2 = _iterator[_i++]; } else { _i = _iterator.next(); if (_i.done) break; _ref2 = _i.value; } var key = _ref2; var subNode = node[key]; if (Array.isArray(subNode)) { for (var i = 0; i < subNode.length; i++) { var child = subNode[i]; if (!child) continue; ancestors.push({ node: node, key: key, index: i }); traverseSimpleImpl(child, enter, exit, state, ancestors); ancestors.pop(); } } else if (subNode) { ancestors.push({ node: node, key: key }); traverseSimpleImpl(subNode, enter, exit, state, ancestors); ancestors.pop(); } } if (exit) exit(node, ancestors, state); } function isBinding(node, parent, grandparent) { if (grandparent && node.type === "Identifier" && parent.type === "ObjectProperty" && grandparent.type === "ObjectExpression") { return false; } var keys = getBindingIdentifiers.keys[parent.type]; if (keys) { for (var i = 0; i < keys.length; i++) { var key = keys[i]; var val = parent[key]; if (Array.isArray(val)) { if (val.indexOf(node) >= 0) return true; } else { if (val === node) return true; } } } return false; } function isLet(node) { return isVariableDeclaration(node) && (node.kind !== "var" || node[BLOCK_SCOPED_SYMBOL]); } function isBlockScoped(node) { return isFunctionDeclaration(node) || isClassDeclaration(node) || isLet(node); } function isImmutable(node) { if (isType(node.type, "Immutable")) return true; if (isIdentifier(node)) { if (node.name === "undefined") { return true; } else { return false; } } return false; } function isNodesEquivalent(a, b) { if (typeof a !== "object" || typeof b !== "object" || a == null || b == null) { return a === b; } if (a.type !== b.type) { return false; } var fields = Object.keys(NODE_FIELDS[a.type] || a.type); var visitorKeys = VISITOR_KEYS[a.type]; for (var _i = 0, _fields = fields; _i < _fields.length; _i++) { var field = _fields[_i]; if (typeof a[field] !== typeof b[field]) { return false; } if (a[field] == null && b[field] == null) { continue; } else if (a[field] == null || b[field] == null) { return false; } if (Array.isArray(a[field])) { if (!Array.isArray(b[field])) { return false; } if (a[field].length !== b[field].length) { return false; } for (var i = 0; i < a[field].length; i++) { if (!isNodesEquivalent(a[field][i], b[field][i])) { return false; } } continue; } if (typeof a[field] === "object" && (!visitorKeys || !visitorKeys.includes(field))) { for (var _i2 = 0, _Object$keys = Object.keys(a[field]); _i2 < _Object$keys.length; _i2++) { var key = _Object$keys[_i2]; if (a[field][key] !== b[field][key]) { return false; } } continue; } if (!isNodesEquivalent(a[field], b[field])) { return false; } } return true; } function isReferenced(node, parent, grandparent) { switch (parent.type) { case "MemberExpression": case "JSXMemberExpression": case "OptionalMemberExpression": if (parent.property === node) { return !!parent.computed; } return parent.object === node; case "VariableDeclarator": return parent.init === node; case "ArrowFunctionExpression": return parent.body === node; case "ExportSpecifier": if (parent.source) { return false; } return parent.local === node; case "PrivateName": return false; case "ObjectProperty": case "ClassProperty": case "ClassPrivateProperty": case "ClassMethod": case "ClassPrivateMethod": case "ObjectMethod": if (parent.key === node) { return !!parent.computed; } if (parent.value === node) { return !grandparent || grandparent.type !== "ObjectPattern"; } return true; case "ClassDeclaration": case "ClassExpression": return parent.superClass === node; case "AssignmentExpression": return parent.right === node; case "AssignmentPattern": return parent.right === node; case "LabeledStatement": return false; case "CatchClause": return false; case "RestElement": return false; case "BreakStatement": case "ContinueStatement": return false; case "FunctionDeclaration": case "FunctionExpression": return false; case "ExportNamespaceSpecifier": case "ExportDefaultSpecifier": return false; case "ImportDefaultSpecifier": case "ImportNamespaceSpecifier": case "ImportSpecifier": return false; case "JSXAttribute": return false; case "ObjectPattern": case "ArrayPattern": return false; case "MetaProperty": return false; case "ObjectTypeProperty": return parent.key !== node; case "TSEnumMember": return parent.id !== node; case "TSPropertySignature": if (parent.key === node) { return !!parent.computed; } return true; } return true; } function isScope(node, parent) { if (isBlockStatement(node) && isFunction(parent, { body: node })) { return false; } if (isBlockStatement(node) && isCatchClause(parent, { body: node })) { return false; } if (isPattern(node) && isFunction(parent)) { return true; } return isScopable(node); } function isSpecifierDefault(specifier) { return isImportDefaultSpecifier(specifier) || isIdentifier(specifier.imported || specifier.exported, { name: "default" }); } var RESERVED_WORDS_ES3_ONLY = new Set(["abstract", "boolean", "byte", "char", "double", "enum", "final", "float", "goto", "implements", "int", "interface", "long", "native", "package", "private", "protected", "public", "short", "static", "synchronized", "throws", "transient", "volatile"]); function isValidES3Identifier(name) { return isValidIdentifier(name) && !RESERVED_WORDS_ES3_ONLY.has(name); } function isVar(node) { return isVariableDeclaration(node, { kind: "var" }) && !node[BLOCK_SCOPED_SYMBOL]; } var react = { isReactComponent: isReactComponent, isCompatTag: isCompatTag, buildChildren: buildChildren }; var t = /*#__PURE__*/Object.freeze({ __proto__: null, react: react, assertNode: assertNode, createTypeAnnotationBasedOnTypeof: createTypeAnnotationBasedOnTypeof, createUnionTypeAnnotation: createUnionTypeAnnotation, cloneNode: cloneNode, clone: clone$1, cloneDeep: cloneDeep, cloneWithoutLoc: cloneWithoutLoc, addComment: addComment, addComments: addComments, inheritInnerComments: inheritInnerComments, inheritLeadingComments: inheritLeadingComments, inheritsComments: inheritsComments, inheritTrailingComments: inheritTrailingComments, removeComments: removeComments, ensureBlock: ensureBlock, toBindingIdentifierName: toBindingIdentifierName, toBlock: toBlock, toComputedKey: toComputedKey, toExpression: toExpression, toIdentifier: toIdentifier, toKeyAlias: toKeyAlias, toSequenceExpression: toSequenceExpression, toStatement: toStatement, valueToNode: valueToNode, appendToMemberExpression: appendToMemberExpression, inherits: inherits, prependToMemberExpression: prependToMemberExpression, removeProperties: removeProperties, removePropertiesDeep: removePropertiesDeep, removeTypeDuplicates: removeTypeDuplicates, getBindingIdentifiers: getBindingIdentifiers, getOuterBindingIdentifiers: getOuterBindingIdentifiers, traverse: traverse, traverseFast: traverseFast, shallowEqual: shallowEqual, is: is, isBinding: isBinding, isBlockScoped: isBlockScoped, isImmutable: isImmutable, isLet: isLet, isNode: isNode, isNodesEquivalent: isNodesEquivalent, isPlaceholderType: isPlaceholderType, isReferenced: isReferenced, isScope: isScope, isSpecifierDefault: isSpecifierDefault, isType: isType, isValidES3Identifier: isValidES3Identifier, isValidIdentifier: isValidIdentifier, isVar: isVar, matchesPattern: matchesPattern, validate: validate, buildMatchMemberExpression: buildMatchMemberExpression, assertArrayExpression: assertArrayExpression, assertAssignmentExpression: assertAssignmentExpression, assertBinaryExpression: assertBinaryExpression, assertInterpreterDirective: assertInterpreterDirective, assertDirective: assertDirective, assertDirectiveLiteral: assertDirectiveLiteral, assertBlockStatement: assertBlockStatement, assertBreakStatement: assertBreakStatement, assertCallExpression: assertCallExpression, assertCatchClause: assertCatchClause, assertConditionalExpression: assertConditionalExpression, assertContinueStatement: assertContinueStatement, assertDebuggerStatement: assertDebuggerStatement, assertDoWhileStatement: assertDoWhileStatement, assertEmptyStatement: assertEmptyStatement, assertExpressionStatement: assertExpressionStatement, assertFile: assertFile, assertForInStatement: assertForInStatement, assertForStatement: assertForStatement, assertFunctionDeclaration: assertFunctionDeclaration, assertFunctionExpression: assertFunctionExpression, assertIdentifier: assertIdentifier, assertIfStatement: assertIfStatement, assertLabeledStatement: assertLabeledStatement, assertStringLiteral: assertStringLiteral, assertNumericLiteral: assertNumericLiteral, assertNullLiteral: assertNullLiteral, assertBooleanLiteral: assertBooleanLiteral, assertRegExpLiteral: assertRegExpLiteral, assertLogicalExpression: assertLogicalExpression, assertMemberExpression: assertMemberExpression, assertNewExpression: assertNewExpression, assertProgram: assertProgram, assertObjectExpression: assertObjectExpression, assertObjectMethod: assertObjectMethod, assertObjectProperty: assertObjectProperty, assertRestElement: assertRestElement, assertReturnStatement: assertReturnStatement, assertSequenceExpression: assertSequenceExpression, assertParenthesizedExpression: assertParenthesizedExpression, assertSwitchCase: assertSwitchCase, assertSwitchStatement: assertSwitchStatement, assertThisExpression: assertThisExpression, assertThrowStatement: assertThrowStatement, assertTryStatement: assertTryStatement, assertUnaryExpression: assertUnaryExpression, assertUpdateExpression: assertUpdateExpression, assertVariableDeclaration: assertVariableDeclaration, assertVariableDeclarator: assertVariableDeclarator, assertWhileStatement: assertWhileStatement, assertWithStatement: assertWithStatement, assertAssignmentPattern: assertAssignmentPattern, assertArrayPattern: assertArrayPattern, assertArrowFunctionExpression: assertArrowFunctionExpression, assertClassBody: assertClassBody, assertClassExpression: assertClassExpression, assertClassDeclaration: assertClassDeclaration, assertExportAllDeclaration: assertExportAllDeclaration, assertExportDefaultDeclaration: assertExportDefaultDeclaration, assertExportNamedDeclaration: assertExportNamedDeclaration, assertExportSpecifier: assertExportSpecifier, assertForOfStatement: assertForOfStatement, assertImportDeclaration: assertImportDeclaration, assertImportDefaultSpecifier: assertImportDefaultSpecifier, assertImportNamespaceSpecifier: assertImportNamespaceSpecifier, assertImportSpecifier: assertImportSpecifier, assertMetaProperty: assertMetaProperty, assertClassMethod: assertClassMethod, assertObjectPattern: assertObjectPattern, assertSpreadElement: assertSpreadElement, assertSuper: assertSuper, assertTaggedTemplateExpression: assertTaggedTemplateExpression, assertTemplateElement: assertTemplateElement, assertTemplateLiteral: assertTemplateLiteral, assertYieldExpression: assertYieldExpression, assertAnyTypeAnnotation: assertAnyTypeAnnotation, assertArrayTypeAnnotation: assertArrayTypeAnnotation, assertBooleanTypeAnnotation: assertBooleanTypeAnnotation, assertBooleanLiteralTypeAnnotation: assertBooleanLiteralTypeAnnotation, assertNullLiteralTypeAnnotation: assertNullLiteralTypeAnnotation, assertClassImplements: assertClassImplements, assertDeclareClass: assertDeclareClass, assertDeclareFunction: assertDeclareFunction, assertDeclareInterface: assertDeclareInterface, assertDeclareModule: assertDeclareModule, assertDeclareModuleExports: assertDeclareModuleExports, assertDeclareTypeAlias: assertDeclareTypeAlias, assertDeclareOpaqueType: assertDeclareOpaqueType, assertDeclareVariable: assertDeclareVariable, assertDeclareExportDeclaration: assertDeclareExportDeclaration, assertDeclareExportAllDeclaration: assertDeclareExportAllDeclaration, assertDeclaredPredicate: assertDeclaredPredicate, assertExistsTypeAnnotation: assertExistsTypeAnnotation, assertFunctionTypeAnnotation: assertFunctionTypeAnnotation, assertFunctionTypeParam: assertFunctionTypeParam, assertGenericTypeAnnotation: assertGenericTypeAnnotation, assertInferredPredicate: assertInferredPredicate, assertInterfaceExtends: assertInterfaceExtends, assertInterfaceDeclaration: assertInterfaceDeclaration, assertInterfaceTypeAnnotation: assertInterfaceTypeAnnotation, assertIntersectionTypeAnnotation: assertIntersectionTypeAnnotation, assertMixedTypeAnnotation: assertMixedTypeAnnotation, assertEmptyTypeAnnotation: assertEmptyTypeAnnotation, assertNullableTypeAnnotation: assertNullableTypeAnnotation, assertNumberLiteralTypeAnnotation: assertNumberLiteralTypeAnnotation, assertNumberTypeAnnotation: assertNumberTypeAnnotation, assertObjectTypeAnnotation: assertObjectTypeAnnotation, assertObjectTypeInternalSlot: assertObjectTypeInternalSlot, assertObjectTypeCallProperty: assertObjectTypeCallProperty, assertObjectTypeIndexer: assertObjectTypeIndexer, assertObjectTypeProperty: assertObjectTypeProperty, assertObjectTypeSpreadProperty: assertObjectTypeSpreadProperty, assertOpaqueType: assertOpaqueType, assertQualifiedTypeIdentifier: assertQualifiedTypeIdentifier, assertStringLiteralTypeAnnotation: assertStringLiteralTypeAnnotation, assertStringTypeAnnotation: assertStringTypeAnnotation, assertThisTypeAnnotation: assertThisTypeAnnotation, assertTupleTypeAnnotation: assertTupleTypeAnnotation, assertTypeofTypeAnnotation: assertTypeofTypeAnnotation, assertTypeAlias: assertTypeAlias, assertTypeAnnotation: assertTypeAnnotation, assertTypeCastExpression: assertTypeCastExpression, assertTypeParameter: assertTypeParameter, assertTypeParameterDeclaration: assertTypeParameterDeclaration, assertTypeParameterInstantiation: assertTypeParameterInstantiation, assertUnionTypeAnnotation: assertUnionTypeAnnotation, assertVariance: assertVariance, assertVoidTypeAnnotation: assertVoidTypeAnnotation, assertEnumDeclaration: assertEnumDeclaration, assertEnumBooleanBody: assertEnumBooleanBody, assertEnumNumberBody: assertEnumNumberBody, assertEnumStringBody: assertEnumStringBody, assertEnumSymbolBody: assertEnumSymbolBody, assertEnumBooleanMember: assertEnumBooleanMember, assertEnumNumberMember: assertEnumNumberMember, assertEnumStringMember: assertEnumStringMember, assertEnumDefaultedMember: assertEnumDefaultedMember, assertJSXAttribute: assertJSXAttribute, assertJSXClosingElement: assertJSXClosingElement, assertJSXElement: assertJSXElement, assertJSXEmptyExpression: assertJSXEmptyExpression, assertJSXExpressionContainer: assertJSXExpressionContainer, assertJSXSpreadChild: assertJSXSpreadChild, assertJSXIdentifier: assertJSXIdentifier, assertJSXMemberExpression: assertJSXMemberExpression, assertJSXNamespacedName: assertJSXNamespacedName, assertJSXOpeningElement: assertJSXOpeningElement, assertJSXSpreadAttribute: assertJSXSpreadAttribute, assertJSXText: assertJSXText, assertJSXFragment: assertJSXFragment, assertJSXOpeningFragment: assertJSXOpeningFragment, assertJSXClosingFragment: assertJSXClosingFragment, assertNoop: assertNoop, assertPlaceholder: assertPlaceholder, assertV8IntrinsicIdentifier: assertV8IntrinsicIdentifier, assertArgumentPlaceholder: assertArgumentPlaceholder, assertAwaitExpression: assertAwaitExpression, assertBindExpression: assertBindExpression, assertClassProperty: assertClassProperty, assertOptionalMemberExpression: assertOptionalMemberExpression, assertPipelineTopicExpression: assertPipelineTopicExpression, assertPipelineBareFunction: assertPipelineBareFunction, assertPipelinePrimaryTopicReference: assertPipelinePrimaryTopicReference, assertOptionalCallExpression: assertOptionalCallExpression, assertClassPrivateProperty: assertClassPrivateProperty, assertClassPrivateMethod: assertClassPrivateMethod, assertImport: assertImport, assertDecorator: assertDecorator, assertDoExpression: assertDoExpression, assertExportDefaultSpecifier: assertExportDefaultSpecifier, assertExportNamespaceSpecifier: assertExportNamespaceSpecifier, assertPrivateName: assertPrivateName, assertBigIntLiteral: assertBigIntLiteral, assertTSParameterProperty: assertTSParameterProperty, assertTSDeclareFunction: assertTSDeclareFunction, assertTSDeclareMethod: assertTSDeclareMethod, assertTSQualifiedName: assertTSQualifiedName, assertTSCallSignatureDeclaration: assertTSCallSignatureDeclaration, assertTSConstructSignatureDeclaration: assertTSConstructSignatureDeclaration, assertTSPropertySignature: assertTSPropertySignature, assertTSMethodSignature: assertTSMethodSignature, assertTSIndexSignature: assertTSIndexSignature, assertTSAnyKeyword: assertTSAnyKeyword, assertTSBooleanKeyword: assertTSBooleanKeyword, assertTSBigIntKeyword: assertTSBigIntKeyword, assertTSNeverKeyword: assertTSNeverKeyword, assertTSNullKeyword: assertTSNullKeyword, assertTSNumberKeyword: assertTSNumberKeyword, assertTSObjectKeyword: assertTSObjectKeyword, assertTSStringKeyword: assertTSStringKeyword, assertTSSymbolKeyword: assertTSSymbolKeyword, assertTSUndefinedKeyword: assertTSUndefinedKeyword, assertTSUnknownKeyword: assertTSUnknownKeyword, assertTSVoidKeyword: assertTSVoidKeyword, assertTSThisType: assertTSThisType, assertTSFunctionType: assertTSFunctionType, assertTSConstructorType: assertTSConstructorType, assertTSTypeReference: assertTSTypeReference, assertTSTypePredicate: assertTSTypePredicate, assertTSTypeQuery: assertTSTypeQuery, assertTSTypeLiteral: assertTSTypeLiteral, assertTSArrayType: assertTSArrayType, assertTSTupleType: assertTSTupleType, assertTSOptionalType: assertTSOptionalType, assertTSRestType: assertTSRestType, assertTSUnionType: assertTSUnionType, assertTSIntersectionType: assertTSIntersectionType, assertTSConditionalType: assertTSConditionalType, assertTSInferType: assertTSInferType, assertTSParenthesizedType: assertTSParenthesizedType, assertTSTypeOperator: assertTSTypeOperator, assertTSIndexedAccessType: assertTSIndexedAccessType, assertTSMappedType: assertTSMappedType, assertTSLiteralType: assertTSLiteralType, assertTSExpressionWithTypeArguments: assertTSExpressionWithTypeArguments, assertTSInterfaceDeclaration: assertTSInterfaceDeclaration, assertTSInterfaceBody: assertTSInterfaceBody, assertTSTypeAliasDeclaration: assertTSTypeAliasDeclaration, assertTSAsExpression: assertTSAsExpression, assertTSTypeAssertion: assertTSTypeAssertion, assertTSEnumDeclaration: assertTSEnumDeclaration, assertTSEnumMember: assertTSEnumMember, assertTSModuleDeclaration: assertTSModuleDeclaration, assertTSModuleBlock: assertTSModuleBlock, assertTSImportType: assertTSImportType, assertTSImportEqualsDeclaration: assertTSImportEqualsDeclaration, assertTSExternalModuleReference: assertTSExternalModuleReference, assertTSNonNullExpression: assertTSNonNullExpression, assertTSExportAssignment: assertTSExportAssignment, assertTSNamespaceExportDeclaration: assertTSNamespaceExportDeclaration, assertTSTypeAnnotation: assertTSTypeAnnotation, assertTSTypeParameterInstantiation: assertTSTypeParameterInstantiation, assertTSTypeParameterDeclaration: assertTSTypeParameterDeclaration, assertTSTypeParameter: assertTSTypeParameter, assertExpression: assertExpression, assertBinary: assertBinary, assertScopable: assertScopable, assertBlockParent: assertBlockParent, assertBlock: assertBlock, assertStatement: assertStatement, assertTerminatorless: assertTerminatorless, assertCompletionStatement: assertCompletionStatement, assertConditional: assertConditional, assertLoop: assertLoop, assertWhile: assertWhile, assertExpressionWrapper: assertExpressionWrapper, assertFor: assertFor, assertForXStatement: assertForXStatement, assertFunction: assertFunction, assertFunctionParent: assertFunctionParent, assertPureish: assertPureish, assertDeclaration: assertDeclaration, assertPatternLike: assertPatternLike, assertLVal: assertLVal, assertTSEntityName: assertTSEntityName, assertLiteral: assertLiteral, assertImmutable: assertImmutable, assertUserWhitespacable: assertUserWhitespacable, assertMethod: assertMethod, assertObjectMember: assertObjectMember, assertProperty: assertProperty, assertUnaryLike: assertUnaryLike, assertPattern: assertPattern, assertClass: assertClass, assertModuleDeclaration: assertModuleDeclaration, assertExportDeclaration: assertExportDeclaration, assertModuleSpecifier: assertModuleSpecifier, assertFlow: assertFlow, assertFlowType: assertFlowType, assertFlowBaseAnnotation: assertFlowBaseAnnotation, assertFlowDeclaration: assertFlowDeclaration, assertFlowPredicate: assertFlowPredicate, assertEnumBody: assertEnumBody, assertEnumMember: assertEnumMember, assertJSX: assertJSX, assertPrivate: assertPrivate, assertTSTypeElement: assertTSTypeElement, assertTSType: assertTSType, assertNumberLiteral: assertNumberLiteral, assertRegexLiteral: assertRegexLiteral, assertRestProperty: assertRestProperty, assertSpreadProperty: assertSpreadProperty, ArrayExpression: ArrayExpression, arrayExpression: ArrayExpression, AssignmentExpression: AssignmentExpression, assignmentExpression: AssignmentExpression, BinaryExpression: BinaryExpression, binaryExpression: BinaryExpression, InterpreterDirective: InterpreterDirective, interpreterDirective: InterpreterDirective, Directive: Directive, directive: Directive, DirectiveLiteral: DirectiveLiteral, directiveLiteral: DirectiveLiteral, BlockStatement: BlockStatement, blockStatement: BlockStatement, BreakStatement: BreakStatement, breakStatement: BreakStatement, CallExpression: CallExpression, callExpression: CallExpression, CatchClause: CatchClause, catchClause: CatchClause, ConditionalExpression: ConditionalExpression, conditionalExpression: ConditionalExpression, ContinueStatement: ContinueStatement, continueStatement: ContinueStatement, DebuggerStatement: DebuggerStatement, debuggerStatement: DebuggerStatement, DoWhileStatement: DoWhileStatement, doWhileStatement: DoWhileStatement, EmptyStatement: EmptyStatement, emptyStatement: EmptyStatement, ExpressionStatement: ExpressionStatement, expressionStatement: ExpressionStatement, File: File, file: File, ForInStatement: ForInStatement, forInStatement: ForInStatement, ForStatement: ForStatement, forStatement: ForStatement, FunctionDeclaration: FunctionDeclaration, functionDeclaration: FunctionDeclaration, FunctionExpression: FunctionExpression, functionExpression: FunctionExpression, Identifier: Identifier, identifier: Identifier, IfStatement: IfStatement, ifStatement: IfStatement, LabeledStatement: LabeledStatement, labeledStatement: LabeledStatement, StringLiteral: StringLiteral, stringLiteral: StringLiteral, NumericLiteral: NumericLiteral, numericLiteral: NumericLiteral, NullLiteral: NullLiteral, nullLiteral: NullLiteral, BooleanLiteral: BooleanLiteral, booleanLiteral: BooleanLiteral, RegExpLiteral: RegExpLiteral, regExpLiteral: RegExpLiteral, LogicalExpression: LogicalExpression, logicalExpression: LogicalExpression, MemberExpression: MemberExpression, memberExpression: MemberExpression, NewExpression: NewExpression, newExpression: NewExpression, Program: Program, program: Program, ObjectExpression: ObjectExpression, objectExpression: ObjectExpression, ObjectMethod: ObjectMethod, objectMethod: ObjectMethod, ObjectProperty: ObjectProperty, objectProperty: ObjectProperty, RestElement: RestElement, restElement: RestElement, ReturnStatement: ReturnStatement, returnStatement: ReturnStatement, SequenceExpression: SequenceExpression, sequenceExpression: SequenceExpression, ParenthesizedExpression: ParenthesizedExpression, parenthesizedExpression: ParenthesizedExpression, SwitchCase: SwitchCase, switchCase: SwitchCase, SwitchStatement: SwitchStatement, switchStatement: SwitchStatement, ThisExpression: ThisExpression, thisExpression: ThisExpression, ThrowStatement: ThrowStatement, throwStatement: ThrowStatement, TryStatement: TryStatement, tryStatement: TryStatement, UnaryExpression: UnaryExpression, unaryExpression: UnaryExpression, UpdateExpression: UpdateExpression, updateExpression: UpdateExpression, VariableDeclaration: VariableDeclaration, variableDeclaration: VariableDeclaration, VariableDeclarator: VariableDeclarator, variableDeclarator: VariableDeclarator, WhileStatement: WhileStatement, whileStatement: WhileStatement, WithStatement: WithStatement, withStatement: WithStatement, AssignmentPattern: AssignmentPattern, assignmentPattern: AssignmentPattern, ArrayPattern: ArrayPattern, arrayPattern: ArrayPattern, ArrowFunctionExpression: ArrowFunctionExpression, arrowFunctionExpression: ArrowFunctionExpression, ClassBody: ClassBody, classBody: ClassBody, ClassExpression: ClassExpression, classExpression: ClassExpression, ClassDeclaration: ClassDeclaration, classDeclaration: ClassDeclaration, ExportAllDeclaration: ExportAllDeclaration, exportAllDeclaration: ExportAllDeclaration, ExportDefaultDeclaration: ExportDefaultDeclaration, exportDefaultDeclaration: ExportDefaultDeclaration, ExportNamedDeclaration: ExportNamedDeclaration, exportNamedDeclaration: ExportNamedDeclaration, ExportSpecifier: ExportSpecifier, exportSpecifier: ExportSpecifier, ForOfStatement: ForOfStatement, forOfStatement: ForOfStatement, ImportDeclaration: ImportDeclaration, importDeclaration: ImportDeclaration, ImportDefaultSpecifier: ImportDefaultSpecifier, importDefaultSpecifier: ImportDefaultSpecifier, ImportNamespaceSpecifier: ImportNamespaceSpecifier, importNamespaceSpecifier: ImportNamespaceSpecifier, ImportSpecifier: ImportSpecifier, importSpecifier: ImportSpecifier, MetaProperty: MetaProperty, metaProperty: MetaProperty, ClassMethod: ClassMethod, classMethod: ClassMethod, ObjectPattern: ObjectPattern, objectPattern: ObjectPattern, SpreadElement: SpreadElement, spreadElement: SpreadElement, Super: Super, 'super': Super, TaggedTemplateExpression: TaggedTemplateExpression, taggedTemplateExpression: TaggedTemplateExpression, TemplateElement: TemplateElement, templateElement: TemplateElement, TemplateLiteral: TemplateLiteral, templateLiteral: TemplateLiteral, YieldExpression: YieldExpression, yieldExpression: YieldExpression, AnyTypeAnnotation: AnyTypeAnnotation, anyTypeAnnotation: AnyTypeAnnotation, ArrayTypeAnnotation: ArrayTypeAnnotation, arrayTypeAnnotation: ArrayTypeAnnotation, BooleanTypeAnnotation: BooleanTypeAnnotation, booleanTypeAnnotation: BooleanTypeAnnotation, BooleanLiteralTypeAnnotation: BooleanLiteralTypeAnnotation, booleanLiteralTypeAnnotation: BooleanLiteralTypeAnnotation, NullLiteralTypeAnnotation: NullLiteralTypeAnnotation, nullLiteralTypeAnnotation: NullLiteralTypeAnnotation, ClassImplements: ClassImplements, classImplements: ClassImplements, DeclareClass: DeclareClass, declareClass: DeclareClass, DeclareFunction: DeclareFunction, declareFunction: DeclareFunction, DeclareInterface: DeclareInterface, declareInterface: DeclareInterface, DeclareModule: DeclareModule, declareModule: DeclareModule, DeclareModuleExports: DeclareModuleExports, declareModuleExports: DeclareModuleExports, DeclareTypeAlias: DeclareTypeAlias, declareTypeAlias: DeclareTypeAlias, DeclareOpaqueType: DeclareOpaqueType, declareOpaqueType: DeclareOpaqueType, DeclareVariable: DeclareVariable, declareVariable: DeclareVariable, DeclareExportDeclaration: DeclareExportDeclaration, declareExportDeclaration: DeclareExportDeclaration, DeclareExportAllDeclaration: DeclareExportAllDeclaration, declareExportAllDeclaration: DeclareExportAllDeclaration, DeclaredPredicate: DeclaredPredicate, declaredPredicate: DeclaredPredicate, ExistsTypeAnnotation: ExistsTypeAnnotation, existsTypeAnnotation: ExistsTypeAnnotation, FunctionTypeAnnotation: FunctionTypeAnnotation, functionTypeAnnotation: FunctionTypeAnnotation, FunctionTypeParam: FunctionTypeParam, functionTypeParam: FunctionTypeParam, GenericTypeAnnotation: GenericTypeAnnotation, genericTypeAnnotation: GenericTypeAnnotation, InferredPredicate: InferredPredicate, inferredPredicate: InferredPredicate, InterfaceExtends: InterfaceExtends, interfaceExtends: InterfaceExtends, InterfaceDeclaration: InterfaceDeclaration, interfaceDeclaration: InterfaceDeclaration, InterfaceTypeAnnotation: InterfaceTypeAnnotation, interfaceTypeAnnotation: InterfaceTypeAnnotation, IntersectionTypeAnnotation: IntersectionTypeAnnotation, intersectionTypeAnnotation: IntersectionTypeAnnotation, MixedTypeAnnotation: MixedTypeAnnotation, mixedTypeAnnotation: MixedTypeAnnotation, EmptyTypeAnnotation: EmptyTypeAnnotation, emptyTypeAnnotation: EmptyTypeAnnotation, NullableTypeAnnotation: NullableTypeAnnotation, nullableTypeAnnotation: NullableTypeAnnotation, NumberLiteralTypeAnnotation: NumberLiteralTypeAnnotation, numberLiteralTypeAnnotation: NumberLiteralTypeAnnotation, NumberTypeAnnotation: NumberTypeAnnotation, numberTypeAnnotation: NumberTypeAnnotation, ObjectTypeAnnotation: ObjectTypeAnnotation, objectTypeAnnotation: ObjectTypeAnnotation, ObjectTypeInternalSlot: ObjectTypeInternalSlot, objectTypeInternalSlot: ObjectTypeInternalSlot, ObjectTypeCallProperty: ObjectTypeCallProperty, objectTypeCallProperty: ObjectTypeCallProperty, ObjectTypeIndexer: ObjectTypeIndexer, objectTypeIndexer: ObjectTypeIndexer, ObjectTypeProperty: ObjectTypeProperty, objectTypeProperty: ObjectTypeProperty, ObjectTypeSpreadProperty: ObjectTypeSpreadProperty, objectTypeSpreadProperty: ObjectTypeSpreadProperty, OpaqueType: OpaqueType, opaqueType: OpaqueType, QualifiedTypeIdentifier: QualifiedTypeIdentifier, qualifiedTypeIdentifier: QualifiedTypeIdentifier, StringLiteralTypeAnnotation: StringLiteralTypeAnnotation, stringLiteralTypeAnnotation: StringLiteralTypeAnnotation, StringTypeAnnotation: StringTypeAnnotation, stringTypeAnnotation: StringTypeAnnotation, ThisTypeAnnotation: ThisTypeAnnotation, thisTypeAnnotation: ThisTypeAnnotation, TupleTypeAnnotation: TupleTypeAnnotation, tupleTypeAnnotation: TupleTypeAnnotation, TypeofTypeAnnotation: TypeofTypeAnnotation, typeofTypeAnnotation: TypeofTypeAnnotation, TypeAlias: TypeAlias, typeAlias: TypeAlias, TypeAnnotation: TypeAnnotation, typeAnnotation: TypeAnnotation, TypeCastExpression: TypeCastExpression, typeCastExpression: TypeCastExpression, TypeParameter: TypeParameter, typeParameter: TypeParameter, TypeParameterDeclaration: TypeParameterDeclaration, typeParameterDeclaration: TypeParameterDeclaration, TypeParameterInstantiation: TypeParameterInstantiation, typeParameterInstantiation: TypeParameterInstantiation, UnionTypeAnnotation: UnionTypeAnnotation, unionTypeAnnotation: UnionTypeAnnotation, Variance: Variance, variance: Variance, VoidTypeAnnotation: VoidTypeAnnotation, voidTypeAnnotation: VoidTypeAnnotation, EnumDeclaration: EnumDeclaration, enumDeclaration: EnumDeclaration, EnumBooleanBody: EnumBooleanBody, enumBooleanBody: EnumBooleanBody, EnumNumberBody: EnumNumberBody, enumNumberBody: EnumNumberBody, EnumStringBody: EnumStringBody, enumStringBody: EnumStringBody, EnumSymbolBody: EnumSymbolBody, enumSymbolBody: EnumSymbolBody, EnumBooleanMember: EnumBooleanMember, enumBooleanMember: EnumBooleanMember, EnumNumberMember: EnumNumberMember, enumNumberMember: EnumNumberMember, EnumStringMember: EnumStringMember, enumStringMember: EnumStringMember, EnumDefaultedMember: EnumDefaultedMember, enumDefaultedMember: EnumDefaultedMember, JSXAttribute: JSXAttribute, jsxAttribute: JSXAttribute, jSXAttribute: JSXAttribute, JSXClosingElement: JSXClosingElement, jsxClosingElement: JSXClosingElement, jSXClosingElement: JSXClosingElement, JSXElement: JSXElement, jsxElement: JSXElement, jSXElement: JSXElement, JSXEmptyExpression: JSXEmptyExpression, jsxEmptyExpression: JSXEmptyExpression, jSXEmptyExpression: JSXEmptyExpression, JSXExpressionContainer: JSXExpressionContainer, jsxExpressionContainer: JSXExpressionContainer, jSXExpressionContainer: JSXExpressionContainer, JSXSpreadChild: JSXSpreadChild, jsxSpreadChild: JSXSpreadChild, jSXSpreadChild: JSXSpreadChild, JSXIdentifier: JSXIdentifier, jsxIdentifier: JSXIdentifier, jSXIdentifier: JSXIdentifier, JSXMemberExpression: JSXMemberExpression, jsxMemberExpression: JSXMemberExpression, jSXMemberExpression: JSXMemberExpression, JSXNamespacedName: JSXNamespacedName, jsxNamespacedName: JSXNamespacedName, jSXNamespacedName: JSXNamespacedName, JSXOpeningElement: JSXOpeningElement, jsxOpeningElement: JSXOpeningElement, jSXOpeningElement: JSXOpeningElement, JSXSpreadAttribute: JSXSpreadAttribute, jsxSpreadAttribute: JSXSpreadAttribute, jSXSpreadAttribute: JSXSpreadAttribute, JSXText: JSXText, jsxText: JSXText, jSXText: JSXText, JSXFragment: JSXFragment, jsxFragment: JSXFragment, jSXFragment: JSXFragment, JSXOpeningFragment: JSXOpeningFragment, jsxOpeningFragment: JSXOpeningFragment, jSXOpeningFragment: JSXOpeningFragment, JSXClosingFragment: JSXClosingFragment, jsxClosingFragment: JSXClosingFragment, jSXClosingFragment: JSXClosingFragment, Noop: Noop, noop: Noop, Placeholder: Placeholder, placeholder: Placeholder, V8IntrinsicIdentifier: V8IntrinsicIdentifier, v8IntrinsicIdentifier: V8IntrinsicIdentifier, ArgumentPlaceholder: ArgumentPlaceholder, argumentPlaceholder: ArgumentPlaceholder, AwaitExpression: AwaitExpression, awaitExpression: AwaitExpression, BindExpression: BindExpression, bindExpression: BindExpression, ClassProperty: ClassProperty, classProperty: ClassProperty, OptionalMemberExpression: OptionalMemberExpression, optionalMemberExpression: OptionalMemberExpression, PipelineTopicExpression: PipelineTopicExpression, pipelineTopicExpression: PipelineTopicExpression, PipelineBareFunction: PipelineBareFunction, pipelineBareFunction: PipelineBareFunction, PipelinePrimaryTopicReference: PipelinePrimaryTopicReference, pipelinePrimaryTopicReference: PipelinePrimaryTopicReference, OptionalCallExpression: OptionalCallExpression, optionalCallExpression: OptionalCallExpression, ClassPrivateProperty: ClassPrivateProperty, classPrivateProperty: ClassPrivateProperty, ClassPrivateMethod: ClassPrivateMethod, classPrivateMethod: ClassPrivateMethod, Import: Import, 'import': Import, Decorator: Decorator, decorator: Decorator, DoExpression: DoExpression, doExpression: DoExpression, ExportDefaultSpecifier: ExportDefaultSpecifier, exportDefaultSpecifier: ExportDefaultSpecifier, ExportNamespaceSpecifier: ExportNamespaceSpecifier, exportNamespaceSpecifier: ExportNamespaceSpecifier, PrivateName: PrivateName, privateName: PrivateName, BigIntLiteral: BigIntLiteral, bigIntLiteral: BigIntLiteral, TSParameterProperty: TSParameterProperty, tsParameterProperty: TSParameterProperty, tSParameterProperty: TSParameterProperty, TSDeclareFunction: TSDeclareFunction, tsDeclareFunction: TSDeclareFunction, tSDeclareFunction: TSDeclareFunction, TSDeclareMethod: TSDeclareMethod, tsDeclareMethod: TSDeclareMethod, tSDeclareMethod: TSDeclareMethod, TSQualifiedName: TSQualifiedName, tsQualifiedName: TSQualifiedName, tSQualifiedName: TSQualifiedName, TSCallSignatureDeclaration: TSCallSignatureDeclaration, tsCallSignatureDeclaration: TSCallSignatureDeclaration, tSCallSignatureDeclaration: TSCallSignatureDeclaration, TSConstructSignatureDeclaration: TSConstructSignatureDeclaration, tsConstructSignatureDeclaration: TSConstructSignatureDeclaration, tSConstructSignatureDeclaration: TSConstructSignatureDeclaration, TSPropertySignature: TSPropertySignature, tsPropertySignature: TSPropertySignature, tSPropertySignature: TSPropertySignature, TSMethodSignature: TSMethodSignature, tsMethodSignature: TSMethodSignature, tSMethodSignature: TSMethodSignature, TSIndexSignature: TSIndexSignature, tsIndexSignature: TSIndexSignature, tSIndexSignature: TSIndexSignature, TSAnyKeyword: TSAnyKeyword, tsAnyKeyword: TSAnyKeyword, tSAnyKeyword: TSAnyKeyword, TSBooleanKeyword: TSBooleanKeyword, tsBooleanKeyword: TSBooleanKeyword, tSBooleanKeyword: TSBooleanKeyword, TSBigIntKeyword: TSBigIntKeyword, tsBigIntKeyword: TSBigIntKeyword, tSBigIntKeyword: TSBigIntKeyword, TSNeverKeyword: TSNeverKeyword, tsNeverKeyword: TSNeverKeyword, tSNeverKeyword: TSNeverKeyword, TSNullKeyword: TSNullKeyword, tsNullKeyword: TSNullKeyword, tSNullKeyword: TSNullKeyword, TSNumberKeyword: TSNumberKeyword, tsNumberKeyword: TSNumberKeyword, tSNumberKeyword: TSNumberKeyword, TSObjectKeyword: TSObjectKeyword, tsObjectKeyword: TSObjectKeyword, tSObjectKeyword: TSObjectKeyword, TSStringKeyword: TSStringKeyword, tsStringKeyword: TSStringKeyword, tSStringKeyword: TSStringKeyword, TSSymbolKeyword: TSSymbolKeyword, tsSymbolKeyword: TSSymbolKeyword, tSSymbolKeyword: TSSymbolKeyword, TSUndefinedKeyword: TSUndefinedKeyword, tsUndefinedKeyword: TSUndefinedKeyword, tSUndefinedKeyword: TSUndefinedKeyword, TSUnknownKeyword: TSUnknownKeyword, tsUnknownKeyword: TSUnknownKeyword, tSUnknownKeyword: TSUnknownKeyword, TSVoidKeyword: TSVoidKeyword, tsVoidKeyword: TSVoidKeyword, tSVoidKeyword: TSVoidKeyword, TSThisType: TSThisType, tsThisType: TSThisType, tSThisType: TSThisType, TSFunctionType: TSFunctionType, tsFunctionType: TSFunctionType, tSFunctionType: TSFunctionType, TSConstructorType: TSConstructorType, tsConstructorType: TSConstructorType, tSConstructorType: TSConstructorType, TSTypeReference: TSTypeReference, tsTypeReference: TSTypeReference, tSTypeReference: TSTypeReference, TSTypePredicate: TSTypePredicate, tsTypePredicate: TSTypePredicate, tSTypePredicate: TSTypePredicate, TSTypeQuery: TSTypeQuery, tsTypeQuery: TSTypeQuery, tSTypeQuery: TSTypeQuery, TSTypeLiteral: TSTypeLiteral, tsTypeLiteral: TSTypeLiteral, tSTypeLiteral: TSTypeLiteral, TSArrayType: TSArrayType, tsArrayType: TSArrayType, tSArrayType: TSArrayType, TSTupleType: TSTupleType, tsTupleType: TSTupleType, tSTupleType: TSTupleType, TSOptionalType: TSOptionalType, tsOptionalType: TSOptionalType, tSOptionalType: TSOptionalType, TSRestType: TSRestType, tsRestType: TSRestType, tSRestType: TSRestType, TSUnionType: TSUnionType, tsUnionType: TSUnionType, tSUnionType: TSUnionType, TSIntersectionType: TSIntersectionType, tsIntersectionType: TSIntersectionType, tSIntersectionType: TSIntersectionType, TSConditionalType: TSConditionalType, tsConditionalType: TSConditionalType, tSConditionalType: TSConditionalType, TSInferType: TSInferType, tsInferType: TSInferType, tSInferType: TSInferType, TSParenthesizedType: TSParenthesizedType, tsParenthesizedType: TSParenthesizedType, tSParenthesizedType: TSParenthesizedType, TSTypeOperator: TSTypeOperator, tsTypeOperator: TSTypeOperator, tSTypeOperator: TSTypeOperator, TSIndexedAccessType: TSIndexedAccessType, tsIndexedAccessType: TSIndexedAccessType, tSIndexedAccessType: TSIndexedAccessType, TSMappedType: TSMappedType, tsMappedType: TSMappedType, tSMappedType: TSMappedType, TSLiteralType: TSLiteralType, tsLiteralType: TSLiteralType, tSLiteralType: TSLiteralType, TSExpressionWithTypeArguments: TSExpressionWithTypeArguments, tsExpressionWithTypeArguments: TSExpressionWithTypeArguments, tSExpressionWithTypeArguments: TSExpressionWithTypeArguments, TSInterfaceDeclaration: TSInterfaceDeclaration, tsInterfaceDeclaration: TSInterfaceDeclaration, tSInterfaceDeclaration: TSInterfaceDeclaration, TSInterfaceBody: TSInterfaceBody, tsInterfaceBody: TSInterfaceBody, tSInterfaceBody: TSInterfaceBody, TSTypeAliasDeclaration: TSTypeAliasDeclaration, tsTypeAliasDeclaration: TSTypeAliasDeclaration, tSTypeAliasDeclaration: TSTypeAliasDeclaration, TSAsExpression: TSAsExpression, tsAsExpression: TSAsExpression, tSAsExpression: TSAsExpression, TSTypeAssertion: TSTypeAssertion, tsTypeAssertion: TSTypeAssertion, tSTypeAssertion: TSTypeAssertion, TSEnumDeclaration: TSEnumDeclaration, tsEnumDeclaration: TSEnumDeclaration, tSEnumDeclaration: TSEnumDeclaration, TSEnumMember: TSEnumMember, tsEnumMember: TSEnumMember, tSEnumMember: TSEnumMember, TSModuleDeclaration: TSModuleDeclaration, tsModuleDeclaration: TSModuleDeclaration, tSModuleDeclaration: TSModuleDeclaration, TSModuleBlock: TSModuleBlock, tsModuleBlock: TSModuleBlock, tSModuleBlock: TSModuleBlock, TSImportType: TSImportType, tsImportType: TSImportType, tSImportType: TSImportType, TSImportEqualsDeclaration: TSImportEqualsDeclaration, tsImportEqualsDeclaration: TSImportEqualsDeclaration, tSImportEqualsDeclaration: TSImportEqualsDeclaration, TSExternalModuleReference: TSExternalModuleReference, tsExternalModuleReference: TSExternalModuleReference, tSExternalModuleReference: TSExternalModuleReference, TSNonNullExpression: TSNonNullExpression, tsNonNullExpression: TSNonNullExpression, tSNonNullExpression: TSNonNullExpression, TSExportAssignment: TSExportAssignment, tsExportAssignment: TSExportAssignment, tSExportAssignment: TSExportAssignment, TSNamespaceExportDeclaration: TSNamespaceExportDeclaration, tsNamespaceExportDeclaration: TSNamespaceExportDeclaration, tSNamespaceExportDeclaration: TSNamespaceExportDeclaration, TSTypeAnnotation: TSTypeAnnotation, tsTypeAnnotation: TSTypeAnnotation, tSTypeAnnotation: TSTypeAnnotation, TSTypeParameterInstantiation: TSTypeParameterInstantiation, tsTypeParameterInstantiation: TSTypeParameterInstantiation, tSTypeParameterInstantiation: TSTypeParameterInstantiation, TSTypeParameterDeclaration: TSTypeParameterDeclaration, tsTypeParameterDeclaration: TSTypeParameterDeclaration, tSTypeParameterDeclaration: TSTypeParameterDeclaration, TSTypeParameter: TSTypeParameter, tsTypeParameter: TSTypeParameter, tSTypeParameter: TSTypeParameter, NumberLiteral: NumberLiteral, numberLiteral: NumberLiteral, RegexLiteral: RegexLiteral, regexLiteral: RegexLiteral, RestProperty: RestProperty, restProperty: RestProperty, SpreadProperty: SpreadProperty, spreadProperty: SpreadProperty, EXPRESSION_TYPES: EXPRESSION_TYPES, BINARY_TYPES: BINARY_TYPES, SCOPABLE_TYPES: SCOPABLE_TYPES, BLOCKPARENT_TYPES: BLOCKPARENT_TYPES, BLOCK_TYPES: BLOCK_TYPES, STATEMENT_TYPES: STATEMENT_TYPES, TERMINATORLESS_TYPES: TERMINATORLESS_TYPES, COMPLETIONSTATEMENT_TYPES: COMPLETIONSTATEMENT_TYPES, CONDITIONAL_TYPES: CONDITIONAL_TYPES, LOOP_TYPES: LOOP_TYPES, WHILE_TYPES: WHILE_TYPES, EXPRESSIONWRAPPER_TYPES: EXPRESSIONWRAPPER_TYPES, FOR_TYPES: FOR_TYPES, FORXSTATEMENT_TYPES: FORXSTATEMENT_TYPES, FUNCTION_TYPES: FUNCTION_TYPES, FUNCTIONPARENT_TYPES: FUNCTIONPARENT_TYPES, PUREISH_TYPES: PUREISH_TYPES, DECLARATION_TYPES: DECLARATION_TYPES, PATTERNLIKE_TYPES: PATTERNLIKE_TYPES, LVAL_TYPES: LVAL_TYPES, TSENTITYNAME_TYPES: TSENTITYNAME_TYPES, LITERAL_TYPES: LITERAL_TYPES, IMMUTABLE_TYPES: IMMUTABLE_TYPES, USERWHITESPACABLE_TYPES: USERWHITESPACABLE_TYPES, METHOD_TYPES: METHOD_TYPES, OBJECTMEMBER_TYPES: OBJECTMEMBER_TYPES, PROPERTY_TYPES: PROPERTY_TYPES, UNARYLIKE_TYPES: UNARYLIKE_TYPES, PATTERN_TYPES: PATTERN_TYPES, CLASS_TYPES: CLASS_TYPES, MODULEDECLARATION_TYPES: MODULEDECLARATION_TYPES, EXPORTDECLARATION_TYPES: EXPORTDECLARATION_TYPES, MODULESPECIFIER_TYPES: MODULESPECIFIER_TYPES, FLOW_TYPES: FLOW_TYPES, FLOWTYPE_TYPES: FLOWTYPE_TYPES, FLOWBASEANNOTATION_TYPES: FLOWBASEANNOTATION_TYPES, FLOWDECLARATION_TYPES: FLOWDECLARATION_TYPES, FLOWPREDICATE_TYPES: FLOWPREDICATE_TYPES, ENUMBODY_TYPES: ENUMBODY_TYPES, ENUMMEMBER_TYPES: ENUMMEMBER_TYPES, JSX_TYPES: JSX_TYPES, PRIVATE_TYPES: PRIVATE_TYPES, TSTYPEELEMENT_TYPES: TSTYPEELEMENT_TYPES, TSTYPE_TYPES: TSTYPE_TYPES, STATEMENT_OR_BLOCK_KEYS: STATEMENT_OR_BLOCK_KEYS, FLATTENABLE_KEYS: FLATTENABLE_KEYS, FOR_INIT_KEYS: FOR_INIT_KEYS, COMMENT_KEYS: COMMENT_KEYS, LOGICAL_OPERATORS: LOGICAL_OPERATORS, UPDATE_OPERATORS: UPDATE_OPERATORS, BOOLEAN_NUMBER_BINARY_OPERATORS: BOOLEAN_NUMBER_BINARY_OPERATORS, EQUALITY_BINARY_OPERATORS: EQUALITY_BINARY_OPERATORS, COMPARISON_BINARY_OPERATORS: COMPARISON_BINARY_OPERATORS, BOOLEAN_BINARY_OPERATORS: BOOLEAN_BINARY_OPERATORS, NUMBER_BINARY_OPERATORS: NUMBER_BINARY_OPERATORS, BINARY_OPERATORS: BINARY_OPERATORS, ASSIGNMENT_OPERATORS: ASSIGNMENT_OPERATORS, BOOLEAN_UNARY_OPERATORS: BOOLEAN_UNARY_OPERATORS, NUMBER_UNARY_OPERATORS: NUMBER_UNARY_OPERATORS, STRING_UNARY_OPERATORS: STRING_UNARY_OPERATORS, UNARY_OPERATORS: UNARY_OPERATORS, INHERIT_KEYS: INHERIT_KEYS, BLOCK_SCOPED_SYMBOL: BLOCK_SCOPED_SYMBOL, NOT_LOCAL_BINDING: NOT_LOCAL_BINDING, VISITOR_KEYS: VISITOR_KEYS, ALIAS_KEYS: ALIAS_KEYS, FLIPPED_ALIAS_KEYS: FLIPPED_ALIAS_KEYS, NODE_FIELDS: NODE_FIELDS, BUILDER_KEYS: BUILDER_KEYS, DEPRECATED_KEYS: DEPRECATED_KEYS, NODE_PARENT_VALIDATIONS: NODE_PARENT_VALIDATIONS, PLACEHOLDERS: PLACEHOLDERS, PLACEHOLDERS_ALIAS: PLACEHOLDERS_ALIAS, PLACEHOLDERS_FLIPPED_ALIAS: PLACEHOLDERS_FLIPPED_ALIAS, TYPES: TYPES, isArrayExpression: isArrayExpression, isAssignmentExpression: isAssignmentExpression, isBinaryExpression: isBinaryExpression, isInterpreterDirective: isInterpreterDirective, isDirective: isDirective, isDirectiveLiteral: isDirectiveLiteral, isBlockStatement: isBlockStatement, isBreakStatement: isBreakStatement, isCallExpression: isCallExpression, isCatchClause: isCatchClause, isConditionalExpression: isConditionalExpression, isContinueStatement: isContinueStatement, isDebuggerStatement: isDebuggerStatement, isDoWhileStatement: isDoWhileStatement, isEmptyStatement: isEmptyStatement, isExpressionStatement: isExpressionStatement, isFile: isFile, isForInStatement: isForInStatement, isForStatement: isForStatement, isFunctionDeclaration: isFunctionDeclaration, isFunctionExpression: isFunctionExpression, isIdentifier: isIdentifier, isIfStatement: isIfStatement, isLabeledStatement: isLabeledStatement, isStringLiteral: isStringLiteral, isNumericLiteral: isNumericLiteral, isNullLiteral: isNullLiteral, isBooleanLiteral: isBooleanLiteral, isRegExpLiteral: isRegExpLiteral, isLogicalExpression: isLogicalExpression, isMemberExpression: isMemberExpression, isNewExpression: isNewExpression, isProgram: isProgram, isObjectExpression: isObjectExpression, isObjectMethod: isObjectMethod, isObjectProperty: isObjectProperty, isRestElement: isRestElement, isReturnStatement: isReturnStatement, isSequenceExpression: isSequenceExpression, isParenthesizedExpression: isParenthesizedExpression, isSwitchCase: isSwitchCase, isSwitchStatement: isSwitchStatement, isThisExpression: isThisExpression, isThrowStatement: isThrowStatement, isTryStatement: isTryStatement, isUnaryExpression: isUnaryExpression, isUpdateExpression: isUpdateExpression, isVariableDeclaration: isVariableDeclaration, isVariableDeclarator: isVariableDeclarator, isWhileStatement: isWhileStatement, isWithStatement: isWithStatement, isAssignmentPattern: isAssignmentPattern, isArrayPattern: isArrayPattern, isArrowFunctionExpression: isArrowFunctionExpression, isClassBody: isClassBody, isClassExpression: isClassExpression, isClassDeclaration: isClassDeclaration, isExportAllDeclaration: isExportAllDeclaration, isExportDefaultDeclaration: isExportDefaultDeclaration, isExportNamedDeclaration: isExportNamedDeclaration, isExportSpecifier: isExportSpecifier, isForOfStatement: isForOfStatement, isImportDeclaration: isImportDeclaration, isImportDefaultSpecifier: isImportDefaultSpecifier, isImportNamespaceSpecifier: isImportNamespaceSpecifier, isImportSpecifier: isImportSpecifier, isMetaProperty: isMetaProperty, isClassMethod: isClassMethod, isObjectPattern: isObjectPattern, isSpreadElement: isSpreadElement, isSuper: isSuper, isTaggedTemplateExpression: isTaggedTemplateExpression, isTemplateElement: isTemplateElement, isTemplateLiteral: isTemplateLiteral, isYieldExpression: isYieldExpression, isAnyTypeAnnotation: isAnyTypeAnnotation, isArrayTypeAnnotation: isArrayTypeAnnotation, isBooleanTypeAnnotation: isBooleanTypeAnnotation, isBooleanLiteralTypeAnnotation: isBooleanLiteralTypeAnnotation, isNullLiteralTypeAnnotation: isNullLiteralTypeAnnotation, isClassImplements: isClassImplements, isDeclareClass: isDeclareClass, isDeclareFunction: isDeclareFunction, isDeclareInterface: isDeclareInterface, isDeclareModule: isDeclareModule, isDeclareModuleExports: isDeclareModuleExports, isDeclareTypeAlias: isDeclareTypeAlias, isDeclareOpaqueType: isDeclareOpaqueType, isDeclareVariable: isDeclareVariable, isDeclareExportDeclaration: isDeclareExportDeclaration, isDeclareExportAllDeclaration: isDeclareExportAllDeclaration, isDeclaredPredicate: isDeclaredPredicate, isExistsTypeAnnotation: isExistsTypeAnnotation, isFunctionTypeAnnotation: isFunctionTypeAnnotation, isFunctionTypeParam: isFunctionTypeParam, isGenericTypeAnnotation: isGenericTypeAnnotation, isInferredPredicate: isInferredPredicate, isInterfaceExtends: isInterfaceExtends, isInterfaceDeclaration: isInterfaceDeclaration, isInterfaceTypeAnnotation: isInterfaceTypeAnnotation, isIntersectionTypeAnnotation: isIntersectionTypeAnnotation, isMixedTypeAnnotation: isMixedTypeAnnotation, isEmptyTypeAnnotation: isEmptyTypeAnnotation, isNullableTypeAnnotation: isNullableTypeAnnotation, isNumberLiteralTypeAnnotation: isNumberLiteralTypeAnnotation, isNumberTypeAnnotation: isNumberTypeAnnotation, isObjectTypeAnnotation: isObjectTypeAnnotation, isObjectTypeInternalSlot: isObjectTypeInternalSlot, isObjectTypeCallProperty: isObjectTypeCallProperty, isObjectTypeIndexer: isObjectTypeIndexer, isObjectTypeProperty: isObjectTypeProperty, isObjectTypeSpreadProperty: isObjectTypeSpreadProperty, isOpaqueType: isOpaqueType, isQualifiedTypeIdentifier: isQualifiedTypeIdentifier, isStringLiteralTypeAnnotation: isStringLiteralTypeAnnotation, isStringTypeAnnotation: isStringTypeAnnotation, isThisTypeAnnotation: isThisTypeAnnotation, isTupleTypeAnnotation: isTupleTypeAnnotation, isTypeofTypeAnnotation: isTypeofTypeAnnotation, isTypeAlias: isTypeAlias, isTypeAnnotation: isTypeAnnotation, isTypeCastExpression: isTypeCastExpression, isTypeParameter: isTypeParameter, isTypeParameterDeclaration: isTypeParameterDeclaration, isTypeParameterInstantiation: isTypeParameterInstantiation, isUnionTypeAnnotation: isUnionTypeAnnotation, isVariance: isVariance, isVoidTypeAnnotation: isVoidTypeAnnotation, isEnumDeclaration: isEnumDeclaration, isEnumBooleanBody: isEnumBooleanBody, isEnumNumberBody: isEnumNumberBody, isEnumStringBody: isEnumStringBody, isEnumSymbolBody: isEnumSymbolBody, isEnumBooleanMember: isEnumBooleanMember, isEnumNumberMember: isEnumNumberMember, isEnumStringMember: isEnumStringMember, isEnumDefaultedMember: isEnumDefaultedMember, isJSXAttribute: isJSXAttribute, isJSXClosingElement: isJSXClosingElement, isJSXElement: isJSXElement, isJSXEmptyExpression: isJSXEmptyExpression, isJSXExpressionContainer: isJSXExpressionContainer, isJSXSpreadChild: isJSXSpreadChild, isJSXIdentifier: isJSXIdentifier, isJSXMemberExpression: isJSXMemberExpression, isJSXNamespacedName: isJSXNamespacedName, isJSXOpeningElement: isJSXOpeningElement, isJSXSpreadAttribute: isJSXSpreadAttribute, isJSXText: isJSXText, isJSXFragment: isJSXFragment, isJSXOpeningFragment: isJSXOpeningFragment, isJSXClosingFragment: isJSXClosingFragment, isNoop: isNoop, isPlaceholder: isPlaceholder, isV8IntrinsicIdentifier: isV8IntrinsicIdentifier, isArgumentPlaceholder: isArgumentPlaceholder, isAwaitExpression: isAwaitExpression, isBindExpression: isBindExpression, isClassProperty: isClassProperty, isOptionalMemberExpression: isOptionalMemberExpression, isPipelineTopicExpression: isPipelineTopicExpression, isPipelineBareFunction: isPipelineBareFunction, isPipelinePrimaryTopicReference: isPipelinePrimaryTopicReference, isOptionalCallExpression: isOptionalCallExpression, isClassPrivateProperty: isClassPrivateProperty, isClassPrivateMethod: isClassPrivateMethod, isImport: isImport, isDecorator: isDecorator, isDoExpression: isDoExpression, isExportDefaultSpecifier: isExportDefaultSpecifier, isExportNamespaceSpecifier: isExportNamespaceSpecifier, isPrivateName: isPrivateName, isBigIntLiteral: isBigIntLiteral, isTSParameterProperty: isTSParameterProperty, isTSDeclareFunction: isTSDeclareFunction, isTSDeclareMethod: isTSDeclareMethod, isTSQualifiedName: isTSQualifiedName, isTSCallSignatureDeclaration: isTSCallSignatureDeclaration, isTSConstructSignatureDeclaration: isTSConstructSignatureDeclaration, isTSPropertySignature: isTSPropertySignature, isTSMethodSignature: isTSMethodSignature, isTSIndexSignature: isTSIndexSignature, isTSAnyKeyword: isTSAnyKeyword, isTSBooleanKeyword: isTSBooleanKeyword, isTSBigIntKeyword: isTSBigIntKeyword, isTSNeverKeyword: isTSNeverKeyword, isTSNullKeyword: isTSNullKeyword, isTSNumberKeyword: isTSNumberKeyword, isTSObjectKeyword: isTSObjectKeyword, isTSStringKeyword: isTSStringKeyword, isTSSymbolKeyword: isTSSymbolKeyword, isTSUndefinedKeyword: isTSUndefinedKeyword, isTSUnknownKeyword: isTSUnknownKeyword, isTSVoidKeyword: isTSVoidKeyword, isTSThisType: isTSThisType, isTSFunctionType: isTSFunctionType, isTSConstructorType: isTSConstructorType, isTSTypeReference: isTSTypeReference, isTSTypePredicate: isTSTypePredicate, isTSTypeQuery: isTSTypeQuery, isTSTypeLiteral: isTSTypeLiteral, isTSArrayType: isTSArrayType, isTSTupleType: isTSTupleType, isTSOptionalType: isTSOptionalType, isTSRestType: isTSRestType, isTSUnionType: isTSUnionType, isTSIntersectionType: isTSIntersectionType, isTSConditionalType: isTSConditionalType, isTSInferType: isTSInferType, isTSParenthesizedType: isTSParenthesizedType, isTSTypeOperator: isTSTypeOperator, isTSIndexedAccessType: isTSIndexedAccessType, isTSMappedType: isTSMappedType, isTSLiteralType: isTSLiteralType, isTSExpressionWithTypeArguments: isTSExpressionWithTypeArguments, isTSInterfaceDeclaration: isTSInterfaceDeclaration, isTSInterfaceBody: isTSInterfaceBody, isTSTypeAliasDeclaration: isTSTypeAliasDeclaration, isTSAsExpression: isTSAsExpression, isTSTypeAssertion: isTSTypeAssertion, isTSEnumDeclaration: isTSEnumDeclaration, isTSEnumMember: isTSEnumMember, isTSModuleDeclaration: isTSModuleDeclaration, isTSModuleBlock: isTSModuleBlock, isTSImportType: isTSImportType, isTSImportEqualsDeclaration: isTSImportEqualsDeclaration, isTSExternalModuleReference: isTSExternalModuleReference, isTSNonNullExpression: isTSNonNullExpression, isTSExportAssignment: isTSExportAssignment, isTSNamespaceExportDeclaration: isTSNamespaceExportDeclaration, isTSTypeAnnotation: isTSTypeAnnotation, isTSTypeParameterInstantiation: isTSTypeParameterInstantiation, isTSTypeParameterDeclaration: isTSTypeParameterDeclaration, isTSTypeParameter: isTSTypeParameter, isExpression: isExpression, isBinary: isBinary, isScopable: isScopable, isBlockParent: isBlockParent, isBlock: isBlock, isStatement: isStatement, isTerminatorless: isTerminatorless, isCompletionStatement: isCompletionStatement, isConditional: isConditional, isLoop: isLoop, isWhile: isWhile, isExpressionWrapper: isExpressionWrapper, isFor: isFor, isForXStatement: isForXStatement, isFunction: isFunction, isFunctionParent: isFunctionParent, isPureish: isPureish, isDeclaration: isDeclaration, isPatternLike: isPatternLike, isLVal: isLVal, isTSEntityName: isTSEntityName, isLiteral: isLiteral, isUserWhitespacable: isUserWhitespacable, isMethod: isMethod, isObjectMember: isObjectMember, isProperty: isProperty, isUnaryLike: isUnaryLike, isPattern: isPattern, isClass: isClass, isModuleDeclaration: isModuleDeclaration, isExportDeclaration: isExportDeclaration, isModuleSpecifier: isModuleSpecifier, isFlow: isFlow, isFlowType: isFlowType, isFlowBaseAnnotation: isFlowBaseAnnotation, isFlowDeclaration: isFlowDeclaration, isFlowPredicate: isFlowPredicate, isEnumBody: isEnumBody, isEnumMember: isEnumMember, isJSX: isJSX, isPrivate: isPrivate, isTSTypeElement: isTSTypeElement, isTSType: isTSType, isNumberLiteral: isNumberLiteral, isRegexLiteral: isRegexLiteral, isRestProperty: isRestProperty, isSpreadProperty: isSpreadProperty }); var ReferencedIdentifier = { types: ["Identifier", "JSXIdentifier"], checkPath: function checkPath(path, opts) { var node = path.node, parent = path.parent; if (!isIdentifier(node, opts) && !isJSXMemberExpression(parent, opts)) { if (isJSXIdentifier(node, opts)) { if (react.isCompatTag(node.name)) return false; } else { return false; } } return isReferenced(node, parent, path.parentPath.parent); } }; var ReferencedMemberExpression = { types: ["MemberExpression"], checkPath: function checkPath(_ref) { var node = _ref.node, parent = _ref.parent; return isMemberExpression(node) && isReferenced(node, parent); } }; var BindingIdentifier = { types: ["Identifier"], checkPath: function checkPath(path) { var node = path.node, parent = path.parent; var grandparent = path.parentPath.parent; return isIdentifier(node) && isBinding(node, parent, grandparent); } }; var Statement = { types: ["Statement"], checkPath: function checkPath(_ref2) { var node = _ref2.node, parent = _ref2.parent; if (isStatement(node)) { if (isVariableDeclaration(node)) { if (isForXStatement(parent, { left: node })) return false; if (isForStatement(parent, { init: node })) return false; } return true; } else { return false; } } }; var Expression = { types: ["Expression"], checkPath: function checkPath(path) { if (path.isIdentifier()) { return path.isReferencedIdentifier(); } else { return isExpression(path.node); } } }; var Scope = { types: ["Scopable", "Pattern"], checkPath: function checkPath(path) { return isScope(path.node, path.parent); } }; var Referenced = { checkPath: function checkPath(path) { return isReferenced(path.node, path.parent); } }; var BlockScoped = { checkPath: function checkPath(path) { return isBlockScoped(path.node); } }; var Var = { types: ["VariableDeclaration"], checkPath: function checkPath(path) { return isVar(path.node); } }; var User = { checkPath: function checkPath(path) { return path.node && !!path.node.loc; } }; var Generated = { checkPath: function checkPath(path) { return !path.isUser(); } }; var Pure = { checkPath: function checkPath(path, opts) { return path.scope.isPure(path.node, opts); } }; var Flow = { types: ["Flow", "ImportDeclaration", "ExportDeclaration", "ImportSpecifier"], checkPath: function checkPath(_ref3) { var node = _ref3.node; if (isFlow(node)) { return true; } else if (isImportDeclaration(node)) { return node.importKind === "type" || node.importKind === "typeof"; } else if (isExportDeclaration(node)) { return node.exportKind === "type"; } else if (isImportSpecifier(node)) { return node.importKind === "type" || node.importKind === "typeof"; } else { return false; } } }; var RestProperty$1 = { types: ["RestElement"], checkPath: function checkPath(path) { return path.parentPath && path.parentPath.isObjectPattern(); } }; var SpreadProperty$1 = { types: ["RestElement"], checkPath: function checkPath(path) { return path.parentPath && path.parentPath.isObjectExpression(); } }; var ExistentialTypeParam = { types: ["ExistsTypeAnnotation"] }; var NumericLiteralTypeAnnotation = { types: ["NumberLiteralTypeAnnotation"] }; var ForAwaitStatement = { types: ["ForOfStatement"], checkPath: function checkPath(_ref4) { var node = _ref4.node; return node["await"] === true; } }; var virtualTypes = /*#__PURE__*/Object.freeze({ __proto__: null, ReferencedIdentifier: ReferencedIdentifier, ReferencedMemberExpression: ReferencedMemberExpression, BindingIdentifier: BindingIdentifier, Statement: Statement, Expression: Expression, Scope: Scope, Referenced: Referenced, BlockScoped: BlockScoped, Var: Var, User: User, Generated: Generated, Pure: Pure, Flow: Flow, RestProperty: RestProperty$1, SpreadProperty: SpreadProperty$1, ExistentialTypeParam: ExistentialTypeParam, NumericLiteralTypeAnnotation: NumericLiteralTypeAnnotation, ForAwaitStatement: ForAwaitStatement }); var s = 1000; var m = s * 60; var h = m * 60; var d = h * 24; var w = d * 7; var y = d * 365.25; var ms = function (val, options) { options = options || {}; var type = typeof val; if (type === 'string' && val.length > 0) { return parse(val); } else if (type === 'number' && isFinite(val)) { return options["long"] ? fmtLong(val) : fmtShort(val); } throw new Error('val is not a non-empty string or a valid number. val=' + JSON.stringify(val)); }; function parse(str) { str = String(str); if (str.length > 100) { return; } var match = /^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(str); if (!match) { return; } var n = parseFloat(match[1]); var type = (match[2] || 'ms').toLowerCase(); switch (type) { case 'years': case 'year': case 'yrs': case 'yr': case 'y': return n * y; case 'weeks': case 'week': case 'w': return n * w; case 'days': case 'day': case 'd': return n * d; case 'hours': case 'hour': case 'hrs': case 'hr': case 'h': return n * h; case 'minutes': case 'minute': case 'mins': case 'min': case 'm': return n * m; case 'seconds': case 'second': case 'secs': case 'sec': case 's': return n * s; case 'milliseconds': case 'millisecond': case 'msecs': case 'msec': case 'ms': return n; default: return undefined; } } function fmtShort(ms) { var msAbs = Math.abs(ms); if (msAbs >= d) { return Math.round(ms / d) + 'd'; } if (msAbs >= h) { return Math.round(ms / h) + 'h'; } if (msAbs >= m) { return Math.round(ms / m) + 'm'; } if (msAbs >= s) { return Math.round(ms / s) + 's'; } return ms + 'ms'; } function fmtLong(ms) { var msAbs = Math.abs(ms); if (msAbs >= d) { return plural(ms, msAbs, d, 'day'); } if (msAbs >= h) { return plural(ms, msAbs, h, 'hour'); } if (msAbs >= m) { return plural(ms, msAbs, m, 'minute'); } if (msAbs >= s) { return plural(ms, msAbs, s, 'second'); } return ms + ' ms'; } function plural(ms, msAbs, n, name) { var isPlural = msAbs >= n * 1.5; return Math.round(ms / n) + ' ' + name + (isPlural ? 's' : ''); } function setup(env) { createDebug.debug = createDebug; createDebug["default"] = createDebug; createDebug.coerce = coerce; createDebug.disable = disable; createDebug.enable = enable; createDebug.enabled = enabled; createDebug.humanize = ms; Object.keys(env).forEach(function (key) { createDebug[key] = env[key]; }); createDebug.instances = []; createDebug.names = []; createDebug.skips = []; createDebug.formatters = {}; function selectColor(namespace) { var hash = 0; for (var i = 0; i < namespace.length; i++) { hash = (hash << 5) - hash + namespace.charCodeAt(i); hash |= 0; } return createDebug.colors[Math.abs(hash) % createDebug.colors.length]; } createDebug.selectColor = selectColor; function createDebug(namespace) { var prevTime; function debug() { for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) { args[_key] = arguments[_key]; } if (!debug.enabled) { return; } var self = debug; var curr = Number(new Date()); var ms = curr - (prevTime || curr); self.diff = ms; self.prev = prevTime; self.curr = curr; prevTime = curr; args[0] = createDebug.coerce(args[0]); if (typeof args[0] !== 'string') { args.unshift('%O'); } var index = 0; args[0] = args[0].replace(/%([a-zA-Z%])/g, function (match, format) { if (match === '%%') { return match; } index++; var formatter = createDebug.formatters[format]; if (typeof formatter === 'function') { var val = args[index]; match = formatter.call(self, val); args.splice(index, 1); index--; } return match; }); createDebug.formatArgs.call(self, args); var logFn = self.log || createDebug.log; logFn.apply(self, args); } debug.namespace = namespace; debug.enabled = createDebug.enabled(namespace); debug.useColors = createDebug.useColors(); debug.color = selectColor(namespace); debug.destroy = destroy; debug.extend = extend; if (typeof createDebug.init === 'function') { createDebug.init(debug); } createDebug.instances.push(debug); return debug; } function destroy() { var index = createDebug.instances.indexOf(this); if (index !== -1) { createDebug.instances.splice(index, 1); return true; } return false; } function extend(namespace, delimiter) { var newDebug = createDebug(this.namespace + (typeof delimiter === 'undefined' ? ':' : delimiter) + namespace); newDebug.log = this.log; return newDebug; } function enable(namespaces) { createDebug.save(namespaces); createDebug.names = []; createDebug.skips = []; var i; var split = (typeof namespaces === 'string' ? namespaces : '').split(/[\s,]+/); var len = split.length; for (i = 0; i < len; i++) { if (!split[i]) { continue; } namespaces = split[i].replace(/\*/g, '.*?'); if (namespaces[0] === '-') { createDebug.skips.push(new RegExp('^' + namespaces.substr(1) + '$')); } else { createDebug.names.push(new RegExp('^' + namespaces + '$')); } } for (i = 0; i < createDebug.instances.length; i++) { var instance = createDebug.instances[i]; instance.enabled = createDebug.enabled(instance.namespace); } } function disable() { var namespaces = [].concat(createDebug.names.map(toNamespace), createDebug.skips.map(toNamespace).map(function (namespace) { return '-' + namespace; })).join(','); createDebug.enable(''); return namespaces; } function enabled(name) { if (name[name.length - 1] === '*') { return true; } var i; var len; for (i = 0, len = createDebug.skips.length; i < len; i++) { if (createDebug.skips[i].test(name)) { return false; } } for (i = 0, len = createDebug.names.length; i < len; i++) { if (createDebug.names[i].test(name)) { return true; } } return false; } function toNamespace(regexp) { return regexp.toString().substring(2, regexp.toString().length - 2).replace(/\.\*\?$/, '*'); } function coerce(val) { if (val instanceof Error) { return val.stack || val.message; } return val; } createDebug.enable(createDebug.load()); return createDebug; } var common = setup; var browser$1 = createCommonjsModule(function (module, exports) { exports.log = log; exports.formatArgs = formatArgs; exports.save = save; exports.load = load; exports.useColors = useColors; exports.storage = localstorage(); exports.colors = ['#0000CC', '#0000FF', '#0033CC', '#0033FF', '#0066CC', '#0066FF', '#0099CC', '#0099FF', '#00CC00', '#00CC33', '#00CC66', '#00CC99', '#00CCCC', '#00CCFF', '#3300CC', '#3300FF', '#3333CC', '#3333FF', '#3366CC', '#3366FF', '#3399CC', '#3399FF', '#33CC00', '#33CC33', '#33CC66', '#33CC99', '#33CCCC', '#33CCFF', '#6600CC', '#6600FF', '#6633CC', '#6633FF', '#66CC00', '#66CC33', '#9900CC', '#9900FF', '#9933CC', '#9933FF', '#99CC00', '#99CC33', '#CC0000', '#CC0033', '#CC0066', '#CC0099', '#CC00CC', '#CC00FF', '#CC3300', '#CC3333', '#CC3366', '#CC3399', '#CC33CC', '#CC33FF', '#CC6600', '#CC6633', '#CC9900', '#CC9933', '#CCCC00', '#CCCC33', '#FF0000', '#FF0033', '#FF0066', '#FF0099', '#FF00CC', '#FF00FF', '#FF3300', '#FF3333', '#FF3366', '#FF3399', '#FF33CC', '#FF33FF', '#FF6600', '#FF6633', '#FF9900', '#FF9933', '#FFCC00', '#FFCC33']; function useColors() { if (typeof window !== 'undefined' && window.process && (window.process.type === 'renderer' || window.process.__nwjs)) { return true; } if (typeof navigator !== 'undefined' && navigator.userAgent && navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/)) { return false; } return typeof document !== 'undefined' && document.documentElement && document.documentElement.style && document.documentElement.style.WebkitAppearance || typeof window !== 'undefined' && window.console && (window.console.firebug || window.console.exception && window.console.table) || typeof navigator !== 'undefined' && navigator.userAgent && navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/) && parseInt(RegExp.$1, 10) >= 31 || typeof navigator !== 'undefined' && navigator.userAgent && navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/); } function formatArgs(args) { args[0] = (this.useColors ? '%c' : '') + this.namespace + (this.useColors ? ' %c' : ' ') + args[0] + (this.useColors ? '%c ' : ' ') + '+' + module.exports.humanize(this.diff); if (!this.useColors) { return; } var c = 'color: ' + this.color; args.splice(1, 0, c, 'color: inherit'); var index = 0; var lastC = 0; args[0].replace(/%[a-zA-Z%]/g, function (match) { if (match === '%%') { return; } index++; if (match === '%c') { lastC = index; } }); args.splice(lastC, 0, c); } function log() { var _console; return typeof console === 'object' && console.log && (_console = console).log.apply(_console, arguments); } function save(namespaces) { try { if (namespaces) { exports.storage.setItem('debug', namespaces); } else { exports.storage.removeItem('debug'); } } catch (error) {} } function load() { var r; try { r = exports.storage.getItem('debug'); } catch (error) {} if (!r && typeof process !== 'undefined' && 'env' in process) { r = process.env.DEBUG; } return r; } function localstorage() { try { return localStorage; } catch (error) {} } module.exports = common(exports); var formatters = module.exports.formatters; formatters.j = function (v) { try { return JSON.stringify(v); } catch (error) { return '[UnexpectedJSONParseError]: ' + error.message; } }; }); var browser_1 = browser$1.log; var browser_2 = browser$1.formatArgs; var browser_3 = browser$1.save; var browser_4 = browser$1.load; var browser_5 = browser$1.useColors; var browser_6 = browser$1.storage; var browser_7 = browser$1.colors; var stringTag$3 = '[object String]'; function isString(value) { return typeof value == 'string' || !isArray_1(value) && isObjectLike_1(value) && _baseGetTag(value) == stringTag$3; } var isString_1 = isString; var symbolTag$2 = '[object Symbol]'; function isSymbol(value) { return typeof value == 'symbol' || isObjectLike_1(value) && _baseGetTag(value) == symbolTag$2; } var isSymbol_1 = isSymbol; var NAN = 0 / 0; var reTrim = /^\s+|\s+$/g; var reIsBadHex = /^[-+]0x[0-9a-f]+$/i; var reIsBinary = /^0b[01]+$/i; var reIsOctal = /^0o[0-7]+$/i; var freeParseInt = parseInt; function toNumber(value) { if (typeof value == 'number') { return value; } if (isSymbol_1(value)) { return NAN; } if (isObject_1(value)) { var other = typeof value.valueOf == 'function' ? value.valueOf() : value; value = isObject_1(other) ? other + '' : other; } if (typeof value != 'string') { return value === 0 ? value : +value; } value = value.replace(reTrim, ''); var isBinary = reIsBinary.test(value); return isBinary || reIsOctal.test(value) ? freeParseInt(value.slice(2), isBinary ? 2 : 8) : reIsBadHex.test(value) ? NAN : +value; } var toNumber_1 = toNumber; var INFINITY$1 = 1 / 0, MAX_INTEGER = 1.7976931348623157e+308; function toFinite(value) { if (!value) { return value === 0 ? value : 0; } value = toNumber_1(value); if (value === INFINITY$1 || value === -INFINITY$1) { var sign = value < 0 ? -1 : 1; return sign * MAX_INTEGER; } return value === value ? value : 0; } var toFinite_1 = toFinite; function toInteger(value) { var result = toFinite_1(value), remainder = result % 1; return result === result ? remainder ? result - remainder : result : 0; } var toInteger_1 = toInteger; function arrayMap(array, iteratee) { var index = -1, length = array == null ? 0 : array.length, result = Array(length); while (++index < length) { result[index] = iteratee(array[index], index, array); } return result; } var _arrayMap = arrayMap; function baseValues(object, props) { return _arrayMap(props, function (key) { return object[key]; }); } var _baseValues = baseValues; function values(object) { return object == null ? [] : _baseValues(object, keys_1(object)); } var values_1 = values; var nativeMax = Math.max; function includes(collection, value, fromIndex, guard) { collection = isArrayLike_1(collection) ? collection : values_1(collection); fromIndex = fromIndex && !guard ? toInteger_1(fromIndex) : 0; var length = collection.length; if (fromIndex < 0) { fromIndex = nativeMax(length + fromIndex, 0); } return isString_1(collection) ? fromIndex <= length && collection.indexOf(value, fromIndex) > -1 : !!length && _baseIndexOf(collection, value, fromIndex) > -1; } var includes_1 = includes; var MAX_SAFE_INTEGER$2 = 9007199254740991; var nativeFloor = Math.floor; function baseRepeat(string, n) { var result = ''; if (!string || n < 1 || n > MAX_SAFE_INTEGER$2) { return result; } do { if (n % 2) { result += string; } n = nativeFloor(n / 2); if (n) { string += string; } } while (n); return result; } var _baseRepeat = baseRepeat; function isIterateeCall(value, index, object) { if (!isObject_1(object)) { return false; } var type = typeof index; if (type == 'number' ? isArrayLike_1(object) && _isIndex(index, object.length) : type == 'string' && index in object) { return eq_1(object[index], value); } return false; } var _isIterateeCall = isIterateeCall; var INFINITY$2 = 1 / 0; var symbolProto$1 = _Symbol ? _Symbol.prototype : undefined, symbolToString = symbolProto$1 ? symbolProto$1.toString : undefined; function baseToString(value) { if (typeof value == 'string') { return value; } if (isArray_1(value)) { return _arrayMap(value, baseToString) + ''; } if (isSymbol_1(value)) { return symbolToString ? symbolToString.call(value) : ''; } var result = value + ''; return result == '0' && 1 / value == -INFINITY$2 ? '-0' : result; } var _baseToString = baseToString; function toString(value) { return value == null ? '' : _baseToString(value); } var toString_1 = toString; function repeat(string, n, guard) { if (guard ? _isIterateeCall(string, n, guard) : n === undefined) { n = 1; } else { n = toInteger_1(n); } return _baseRepeat(toString_1(string), n); } var repeat_1 = repeat; var Binding = function () { function Binding(_ref) { var identifier = _ref.identifier, scope = _ref.scope, path = _ref.path, kind = _ref.kind; this.identifier = identifier; this.scope = scope; this.path = path; this.kind = kind; this.constantViolations = []; this.constant = true; this.referencePaths = []; this.referenced = false; this.references = 0; this.clearValue(); } var _proto = Binding.prototype; _proto.deoptValue = function deoptValue() { this.clearValue(); this.hasDeoptedValue = true; }; _proto.setValue = function setValue(value) { if (this.hasDeoptedValue) return; this.hasValue = true; this.value = value; }; _proto.clearValue = function clearValue() { this.hasDeoptedValue = false; this.hasValue = false; this.value = null; }; _proto.reassign = function reassign(path) { this.constant = false; if (this.constantViolations.indexOf(path) !== -1) { return; } this.constantViolations.push(path); }; _proto.reference = function reference(path) { if (this.referencePaths.indexOf(path) !== -1) { return; } this.referenced = true; this.references++; this.referencePaths.push(path); }; _proto.dereference = function dereference() { this.references--; this.referenced = !!this.references; }; return Binding; }(); function splitExportDeclaration(exportDeclaration) { if (!exportDeclaration.isExportDeclaration()) { throw new Error("Only export declarations can be splitted."); } var isDefault = exportDeclaration.isExportDefaultDeclaration(); var declaration = exportDeclaration.get("declaration"); var isClassDeclaration = declaration.isClassDeclaration(); if (isDefault) { var standaloneDeclaration = declaration.isFunctionDeclaration() || isClassDeclaration; var scope = declaration.isScope() ? declaration.scope.parent : declaration.scope; var id = declaration.node.id; var needBindingRegistration = false; if (!id) { needBindingRegistration = true; id = scope.generateUidIdentifier("default"); if (standaloneDeclaration || declaration.isFunctionExpression() || declaration.isClassExpression()) { declaration.node.id = cloneNode(id); } } var updatedDeclaration = standaloneDeclaration ? declaration : VariableDeclaration("var", [VariableDeclarator(cloneNode(id), declaration.node)]); var updatedExportDeclaration = ExportNamedDeclaration(null, [ExportSpecifier(cloneNode(id), Identifier("default"))]); exportDeclaration.insertAfter(updatedExportDeclaration); exportDeclaration.replaceWith(updatedDeclaration); if (needBindingRegistration) { scope.registerDeclaration(exportDeclaration); } return exportDeclaration; } if (exportDeclaration.get("specifiers").length > 0) { throw new Error("It doesn't make sense to split exported specifiers."); } var bindingIdentifiers = declaration.getOuterBindingIdentifiers(); var specifiers = Object.keys(bindingIdentifiers).map(function (name) { return ExportSpecifier(Identifier(name), Identifier(name)); }); var aliasDeclar = ExportNamedDeclaration(null, specifiers); exportDeclaration.insertAfter(aliasDeclar); exportDeclaration.replaceWith(declaration.node); return exportDeclaration; } var renameVisitor = { ReferencedIdentifier: function ReferencedIdentifier(_ref, state) { var node = _ref.node; if (node.name === state.oldName) { node.name = state.newName; } }, Scope: function Scope(path, state) { if (!path.scope.bindingIdentifierEquals(state.oldName, state.binding.identifier)) { path.skip(); } }, "AssignmentExpression|Declaration": function AssignmentExpressionDeclaration(path, state) { var ids = path.getOuterBindingIdentifiers(); for (var name in ids) { if (name === state.oldName) ids[name].name = state.newName; } } }; var Renamer = function () { function Renamer(binding, oldName, newName) { this.newName = newName; this.oldName = oldName; this.binding = binding; } var _proto = Renamer.prototype; _proto.maybeConvertFromExportDeclaration = function maybeConvertFromExportDeclaration(parentDeclar) { var maybeExportDeclar = parentDeclar.parentPath; if (!maybeExportDeclar.isExportDeclaration()) { return; } if (maybeExportDeclar.isExportDefaultDeclaration() && !maybeExportDeclar.get("declaration").node.id) { return; } splitExportDeclaration(maybeExportDeclar); }; _proto.maybeConvertFromClassFunctionDeclaration = function maybeConvertFromClassFunctionDeclaration(path) { return; }; _proto.maybeConvertFromClassFunctionExpression = function maybeConvertFromClassFunctionExpression(path) { return; }; _proto.rename = function rename(block) { var binding = this.binding, oldName = this.oldName, newName = this.newName; var scope = binding.scope, path = binding.path; var parentDeclar = path.find(function (path) { return path.isDeclaration() || path.isFunctionExpression() || path.isClassExpression(); }); if (parentDeclar) { var bindingIds = parentDeclar.getOuterBindingIdentifiers(); if (bindingIds[oldName] === binding.identifier) { this.maybeConvertFromExportDeclaration(parentDeclar); } } scope.traverse(block || scope.block, renameVisitor, this); if (!block) { scope.removeOwnBinding(oldName); scope.bindings[newName] = binding; this.binding.identifier.name = newName; } if (binding.type === "hoisted") ; if (parentDeclar) { this.maybeConvertFromClassFunctionDeclaration(parentDeclar); this.maybeConvertFromClassFunctionExpression(parentDeclar); } }; return Renamer; }(); function identity(value) { return value; } var identity_1 = identity; function apply(func, thisArg, args) { switch (args.length) { case 0: return func.call(thisArg); case 1: return func.call(thisArg, args[0]); case 2: return func.call(thisArg, args[0], args[1]); case 3: return func.call(thisArg, args[0], args[1], args[2]); } return func.apply(thisArg, args); } var _apply = apply; var nativeMax$1 = Math.max; function overRest(func, start, transform) { start = nativeMax$1(start === undefined ? func.length - 1 : start, 0); return function () { var args = arguments, index = -1, length = nativeMax$1(args.length - start, 0), array = Array(length); while (++index < length) { array[index] = args[start + index]; } index = -1; var otherArgs = Array(start + 1); while (++index < start) { otherArgs[index] = args[index]; } otherArgs[start] = transform(array); return _apply(func, this, otherArgs); }; } var _overRest = overRest; function constant(value) { return function () { return value; }; } var constant_1 = constant; var baseSetToString = !_defineProperty ? identity_1 : function (func, string) { return _defineProperty(func, 'toString', { 'configurable': true, 'enumerable': false, 'value': constant_1(string), 'writable': true }); }; var _baseSetToString = baseSetToString; var HOT_COUNT = 800, HOT_SPAN = 16; var nativeNow = Date.now; function shortOut(func) { var count = 0, lastCalled = 0; return function () { var stamp = nativeNow(), remaining = HOT_SPAN - (stamp - lastCalled); lastCalled = stamp; if (remaining > 0) { if (++count >= HOT_COUNT) { return arguments[0]; } } else { count = 0; } return func.apply(undefined, arguments); }; } var _shortOut = shortOut; var setToString = _shortOut(_baseSetToString); var _setToString = setToString; function baseRest(func, start) { return _setToString(_overRest(func, start, identity_1), func + ''); } var _baseRest = baseRest; var objectProto$e = Object.prototype; var hasOwnProperty$b = objectProto$e.hasOwnProperty; var defaults = _baseRest(function (object, sources) { object = Object(object); var index = -1; var length = sources.length; var guard = length > 2 ? sources[2] : undefined; if (guard && _isIterateeCall(sources[0], sources[1], guard)) { length = 1; } while (++index < length) { var source = sources[index]; var props = keysIn_1(source); var propsIndex = -1; var propsLength = props.length; while (++propsIndex < propsLength) { var key = props[propsIndex]; var value = object[key]; if (value === undefined || eq_1(value, objectProto$e[key]) && !hasOwnProperty$b.call(object, key)) { object[key] = source[key]; } } } return object; }); var defaults_1 = defaults; var builtin = { "Array": false, "ArrayBuffer": false, Atomics: false, BigInt: false, BigInt64Array: false, BigUint64Array: false, "Boolean": false, constructor: false, "DataView": false, "Date": false, "decodeURI": false, "decodeURIComponent": false, "encodeURI": false, "encodeURIComponent": false, "Error": false, "escape": false, "eval": false, "EvalError": false, "Float32Array": false, "Float64Array": false, "Function": false, globalThis: false, hasOwnProperty: false, "Infinity": false, "Int16Array": false, "Int32Array": false, "Int8Array": false, "isFinite": false, "isNaN": false, isPrototypeOf: false, "JSON": false, "Map": false, "Math": false, "NaN": false, "Number": false, "Object": false, "parseFloat": false, "parseInt": false, "Promise": false, propertyIsEnumerable: false, "Proxy": false, "RangeError": false, "ReferenceError": false, "Reflect": false, "RegExp": false, "Set": false, SharedArrayBuffer: false, "String": false, "Symbol": false, "SyntaxError": false, toLocaleString: false, toString: false, "TypeError": false, "Uint16Array": false, "Uint32Array": false, "Uint8Array": false, "Uint8ClampedArray": false, "undefined": false, "unescape": false, "URIError": false, valueOf: false, "WeakMap": false, "WeakSet": false }; var es5 = { "Array": false, "Boolean": false, constructor: false, "Date": false, "decodeURI": false, "decodeURIComponent": false, "encodeURI": false, "encodeURIComponent": false, "Error": false, "escape": false, "eval": false, "EvalError": false, "Function": false, hasOwnProperty: false, "Infinity": false, "isFinite": false, "isNaN": false, isPrototypeOf: false, "JSON": false, "Math": false, "NaN": false, "Number": false, "Object": false, "parseFloat": false, "parseInt": false, propertyIsEnumerable: false, "RangeError": false, "ReferenceError": false, "RegExp": false, "String": false, "SyntaxError": false, toLocaleString: false, toString: false, "TypeError": false, "undefined": false, "unescape": false, "URIError": false, valueOf: false }; var es2015 = { "Array": false, "ArrayBuffer": false, "Boolean": false, constructor: false, "DataView": false, "Date": false, "decodeURI": false, "decodeURIComponent": false, "encodeURI": false, "encodeURIComponent": false, "Error": false, "escape": false, "eval": false, "EvalError": false, "Float32Array": false, "Float64Array": false, "Function": false, hasOwnProperty: false, "Infinity": false, "Int16Array": false, "Int32Array": false, "Int8Array": false, "isFinite": false, "isNaN": false, isPrototypeOf: false, "JSON": false, "Map": false, "Math": false, "NaN": false, "Number": false, "Object": false, "parseFloat": false, "parseInt": false, "Promise": false, propertyIsEnumerable: false, "Proxy": false, "RangeError": false, "ReferenceError": false, "Reflect": false, "RegExp": false, "Set": false, "String": false, "Symbol": false, "SyntaxError": false, toLocaleString: false, toString: false, "TypeError": false, "Uint16Array": false, "Uint32Array": false, "Uint8Array": false, "Uint8ClampedArray": false, "undefined": false, "unescape": false, "URIError": false, valueOf: false, "WeakMap": false, "WeakSet": false }; var es2017 = { "Array": false, "ArrayBuffer": false, Atomics: false, "Boolean": false, constructor: false, "DataView": false, "Date": false, "decodeURI": false, "decodeURIComponent": false, "encodeURI": false, "encodeURIComponent": false, "Error": false, "escape": false, "eval": false, "EvalError": false, "Float32Array": false, "Float64Array": false, "Function": false, hasOwnProperty: false, "Infinity": false, "Int16Array": false, "Int32Array": false, "Int8Array": false, "isFinite": false, "isNaN": false, isPrototypeOf: false, "JSON": false, "Map": false, "Math": false, "NaN": false, "Number": false, "Object": false, "parseFloat": false, "parseInt": false, "Promise": false, propertyIsEnumerable: false, "Proxy": false, "RangeError": false, "ReferenceError": false, "Reflect": false, "RegExp": false, "Set": false, SharedArrayBuffer: false, "String": false, "Symbol": false, "SyntaxError": false, toLocaleString: false, toString: false, "TypeError": false, "Uint16Array": false, "Uint32Array": false, "Uint8Array": false, "Uint8ClampedArray": false, "undefined": false, "unescape": false, "URIError": false, valueOf: false, "WeakMap": false, "WeakSet": false }; var browser$2 = { AbortController: false, AbortSignal: false, addEventListener: false, alert: false, AnalyserNode: false, Animation: false, AnimationEffectReadOnly: false, AnimationEffectTiming: false, AnimationEffectTimingReadOnly: false, AnimationEvent: false, AnimationPlaybackEvent: false, AnimationTimeline: false, applicationCache: false, ApplicationCache: false, ApplicationCacheErrorEvent: false, atob: false, Attr: false, Audio: false, AudioBuffer: false, AudioBufferSourceNode: false, AudioContext: false, AudioDestinationNode: false, AudioListener: false, AudioNode: false, AudioParam: false, AudioProcessingEvent: false, AudioScheduledSourceNode: false, "AudioWorkletGlobalScope ": false, AudioWorkletNode: false, AudioWorkletProcessor: false, BarProp: false, BaseAudioContext: false, BatteryManager: false, BeforeUnloadEvent: false, BiquadFilterNode: false, Blob: false, BlobEvent: false, blur: false, BroadcastChannel: false, btoa: false, BudgetService: false, ByteLengthQueuingStrategy: false, Cache: false, caches: false, CacheStorage: false, cancelAnimationFrame: false, cancelIdleCallback: false, CanvasCaptureMediaStreamTrack: false, CanvasGradient: false, CanvasPattern: false, CanvasRenderingContext2D: false, ChannelMergerNode: false, ChannelSplitterNode: false, CharacterData: false, clearInterval: false, clearTimeout: false, clientInformation: false, ClipboardEvent: false, close: false, closed: false, CloseEvent: false, Comment: false, CompositionEvent: false, confirm: false, console: false, ConstantSourceNode: false, ConvolverNode: false, CountQueuingStrategy: false, createImageBitmap: false, Credential: false, CredentialsContainer: false, crypto: false, Crypto: false, CryptoKey: false, CSS: false, CSSConditionRule: false, CSSFontFaceRule: false, CSSGroupingRule: false, CSSImportRule: false, CSSKeyframeRule: false, CSSKeyframesRule: false, CSSMediaRule: false, CSSNamespaceRule: false, CSSPageRule: false, CSSRule: false, CSSRuleList: false, CSSStyleDeclaration: false, CSSStyleRule: false, CSSStyleSheet: false, CSSSupportsRule: false, CustomElementRegistry: false, customElements: false, CustomEvent: false, DataTransfer: false, DataTransferItem: false, DataTransferItemList: false, defaultstatus: false, defaultStatus: false, DelayNode: false, DeviceMotionEvent: false, DeviceOrientationEvent: false, devicePixelRatio: false, dispatchEvent: false, document: false, Document: false, DocumentFragment: false, DocumentType: false, DOMError: false, DOMException: false, DOMImplementation: false, DOMMatrix: false, DOMMatrixReadOnly: false, DOMParser: false, DOMPoint: false, DOMPointReadOnly: false, DOMQuad: false, DOMRect: false, DOMRectReadOnly: false, DOMStringList: false, DOMStringMap: false, DOMTokenList: false, DragEvent: false, DynamicsCompressorNode: false, Element: false, ErrorEvent: false, event: false, Event: false, EventSource: false, EventTarget: false, external: false, fetch: false, File: false, FileList: false, FileReader: false, find: false, focus: false, FocusEvent: false, FontFace: false, FontFaceSetLoadEvent: false, FormData: false, frameElement: false, frames: false, GainNode: false, Gamepad: false, GamepadButton: false, GamepadEvent: false, getComputedStyle: false, getSelection: false, HashChangeEvent: false, Headers: false, history: false, History: false, HTMLAllCollection: false, HTMLAnchorElement: false, HTMLAreaElement: false, HTMLAudioElement: false, HTMLBaseElement: false, HTMLBodyElement: false, HTMLBRElement: false, HTMLButtonElement: false, HTMLCanvasElement: false, HTMLCollection: false, HTMLContentElement: false, HTMLDataElement: false, HTMLDataListElement: false, HTMLDetailsElement: false, HTMLDialogElement: false, HTMLDirectoryElement: false, HTMLDivElement: false, HTMLDListElement: false, HTMLDocument: false, HTMLElement: false, HTMLEmbedElement: false, HTMLFieldSetElement: false, HTMLFontElement: false, HTMLFormControlsCollection: false, HTMLFormElement: false, HTMLFrameElement: false, HTMLFrameSetElement: false, HTMLHeadElement: false, HTMLHeadingElement: false, HTMLHRElement: false, HTMLHtmlElement: false, HTMLIFrameElement: false, HTMLImageElement: false, HTMLInputElement: false, HTMLLabelElement: false, HTMLLegendElement: false, HTMLLIElement: false, HTMLLinkElement: false, HTMLMapElement: false, HTMLMarqueeElement: false, HTMLMediaElement: false, HTMLMenuElement: false, HTMLMetaElement: false, HTMLMeterElement: false, HTMLModElement: false, HTMLObjectElement: false, HTMLOListElement: false, HTMLOptGroupElement: false, HTMLOptionElement: false, HTMLOptionsCollection: false, HTMLOutputElement: false, HTMLParagraphElement: false, HTMLParamElement: false, HTMLPictureElement: false, HTMLPreElement: false, HTMLProgressElement: false, HTMLQuoteElement: false, HTMLScriptElement: false, HTMLSelectElement: false, HTMLShadowElement: false, HTMLSlotElement: false, HTMLSourceElement: false, HTMLSpanElement: false, HTMLStyleElement: false, HTMLTableCaptionElement: false, HTMLTableCellElement: false, HTMLTableColElement: false, HTMLTableElement: false, HTMLTableRowElement: false, HTMLTableSectionElement: false, HTMLTemplateElement: false, HTMLTextAreaElement: false, HTMLTimeElement: false, HTMLTitleElement: false, HTMLTrackElement: false, HTMLUListElement: false, HTMLUnknownElement: false, HTMLVideoElement: false, IDBCursor: false, IDBCursorWithValue: false, IDBDatabase: false, IDBFactory: false, IDBIndex: false, IDBKeyRange: false, IDBObjectStore: false, IDBOpenDBRequest: false, IDBRequest: false, IDBTransaction: false, IDBVersionChangeEvent: false, IdleDeadline: false, IIRFilterNode: false, Image: false, ImageBitmap: false, ImageBitmapRenderingContext: false, ImageCapture: false, ImageData: false, indexedDB: false, innerHeight: false, innerWidth: false, InputEvent: false, IntersectionObserver: false, IntersectionObserverEntry: false, "Intl": false, isSecureContext: false, KeyboardEvent: false, KeyframeEffect: false, KeyframeEffectReadOnly: false, length: false, localStorage: false, location: true, Location: false, locationbar: false, matchMedia: false, MediaDeviceInfo: false, MediaDevices: false, MediaElementAudioSourceNode: false, MediaEncryptedEvent: false, MediaError: false, MediaKeyMessageEvent: false, MediaKeySession: false, MediaKeyStatusMap: false, MediaKeySystemAccess: false, MediaList: false, MediaQueryList: false, MediaQueryListEvent: false, MediaRecorder: false, MediaSettingsRange: false, MediaSource: false, MediaStream: false, MediaStreamAudioDestinationNode: false, MediaStreamAudioSourceNode: false, MediaStreamEvent: false, MediaStreamTrack: false, MediaStreamTrackEvent: false, menubar: false, MessageChannel: false, MessageEvent: false, MessagePort: false, MIDIAccess: false, MIDIConnectionEvent: false, MIDIInput: false, MIDIInputMap: false, MIDIMessageEvent: false, MIDIOutput: false, MIDIOutputMap: false, MIDIPort: false, MimeType: false, MimeTypeArray: false, MouseEvent: false, moveBy: false, moveTo: false, MutationEvent: false, MutationObserver: false, MutationRecord: false, name: false, NamedNodeMap: false, NavigationPreloadManager: false, navigator: false, Navigator: false, NetworkInformation: false, Node: false, NodeFilter: false, NodeIterator: false, NodeList: false, Notification: false, OfflineAudioCompletionEvent: false, OfflineAudioContext: false, offscreenBuffering: false, OffscreenCanvas: true, onabort: true, onafterprint: true, onanimationend: true, onanimationiteration: true, onanimationstart: true, onappinstalled: true, onauxclick: true, onbeforeinstallprompt: true, onbeforeprint: true, onbeforeunload: true, onblur: true, oncancel: true, oncanplay: true, oncanplaythrough: true, onchange: true, onclick: true, onclose: true, oncontextmenu: true, oncuechange: true, ondblclick: true, ondevicemotion: true, ondeviceorientation: true, ondeviceorientationabsolute: true, ondrag: true, ondragend: true, ondragenter: true, ondragleave: true, ondragover: true, ondragstart: true, ondrop: true, ondurationchange: true, onemptied: true, onended: true, onerror: true, onfocus: true, ongotpointercapture: true, onhashchange: true, oninput: true, oninvalid: true, onkeydown: true, onkeypress: true, onkeyup: true, onlanguagechange: true, onload: true, onloadeddata: true, onloadedmetadata: true, onloadstart: true, onlostpointercapture: true, onmessage: true, onmessageerror: true, onmousedown: true, onmouseenter: true, onmouseleave: true, onmousemove: true, onmouseout: true, onmouseover: true, onmouseup: true, onmousewheel: true, onoffline: true, ononline: true, onpagehide: true, onpageshow: true, onpause: true, onplay: true, onplaying: true, onpointercancel: true, onpointerdown: true, onpointerenter: true, onpointerleave: true, onpointermove: true, onpointerout: true, onpointerover: true, onpointerup: true, onpopstate: true, onprogress: true, onratechange: true, onrejectionhandled: true, onreset: true, onresize: true, onscroll: true, onsearch: true, onseeked: true, onseeking: true, onselect: true, onstalled: true, onstorage: true, onsubmit: true, onsuspend: true, ontimeupdate: true, ontoggle: true, ontransitionend: true, onunhandledrejection: true, onunload: true, onvolumechange: true, onwaiting: true, onwheel: true, open: false, openDatabase: false, opener: false, Option: false, origin: false, OscillatorNode: false, outerHeight: false, outerWidth: false, PageTransitionEvent: false, pageXOffset: false, pageYOffset: false, PannerNode: false, parent: false, Path2D: false, PaymentAddress: false, PaymentRequest: false, PaymentRequestUpdateEvent: false, PaymentResponse: false, performance: false, Performance: false, PerformanceEntry: false, PerformanceLongTaskTiming: false, PerformanceMark: false, PerformanceMeasure: false, PerformanceNavigation: false, PerformanceNavigationTiming: false, PerformanceObserver: false, PerformanceObserverEntryList: false, PerformancePaintTiming: false, PerformanceResourceTiming: false, PerformanceTiming: false, PeriodicWave: false, Permissions: false, PermissionStatus: false, personalbar: false, PhotoCapabilities: false, Plugin: false, PluginArray: false, PointerEvent: false, PopStateEvent: false, postMessage: false, Presentation: false, PresentationAvailability: false, PresentationConnection: false, PresentationConnectionAvailableEvent: false, PresentationConnectionCloseEvent: false, PresentationConnectionList: false, PresentationReceiver: false, PresentationRequest: false, print: false, ProcessingInstruction: false, ProgressEvent: false, PromiseRejectionEvent: false, prompt: false, PushManager: false, PushSubscription: false, PushSubscriptionOptions: false, queueMicrotask: false, RadioNodeList: false, Range: false, ReadableStream: false, registerProcessor: false, RemotePlayback: false, removeEventListener: false, Request: false, requestAnimationFrame: false, requestIdleCallback: false, resizeBy: false, ResizeObserver: false, ResizeObserverEntry: false, resizeTo: false, Response: false, RTCCertificate: false, RTCDataChannel: false, RTCDataChannelEvent: false, RTCDtlsTransport: false, RTCIceCandidate: false, RTCIceGatherer: false, RTCIceTransport: false, RTCPeerConnection: false, RTCPeerConnectionIceEvent: false, RTCRtpContributingSource: false, RTCRtpReceiver: false, RTCRtpSender: false, RTCSctpTransport: false, RTCSessionDescription: false, RTCStatsReport: false, RTCTrackEvent: false, screen: false, Screen: false, screenLeft: false, ScreenOrientation: false, screenTop: false, screenX: false, screenY: false, ScriptProcessorNode: false, scroll: false, scrollbars: false, scrollBy: false, scrollTo: false, scrollX: false, scrollY: false, SecurityPolicyViolationEvent: false, Selection: false, self: false, ServiceWorker: false, ServiceWorkerContainer: false, ServiceWorkerRegistration: false, sessionStorage: false, setInterval: false, setTimeout: false, ShadowRoot: false, SharedWorker: false, SourceBuffer: false, SourceBufferList: false, speechSynthesis: false, SpeechSynthesisEvent: false, SpeechSynthesisUtterance: false, StaticRange: false, status: false, statusbar: false, StereoPannerNode: false, stop: false, Storage: false, StorageEvent: false, StorageManager: false, styleMedia: false, StyleSheet: false, StyleSheetList: false, SubtleCrypto: false, SVGAElement: false, SVGAngle: false, SVGAnimatedAngle: false, SVGAnimatedBoolean: false, SVGAnimatedEnumeration: false, SVGAnimatedInteger: false, SVGAnimatedLength: false, SVGAnimatedLengthList: false, SVGAnimatedNumber: false, SVGAnimatedNumberList: false, SVGAnimatedPreserveAspectRatio: false, SVGAnimatedRect: false, SVGAnimatedString: false, SVGAnimatedTransformList: false, SVGAnimateElement: false, SVGAnimateMotionElement: false, SVGAnimateTransformElement: false, SVGAnimationElement: false, SVGCircleElement: false, SVGClipPathElement: false, SVGComponentTransferFunctionElement: false, SVGDefsElement: false, SVGDescElement: false, SVGDiscardElement: false, SVGElement: false, SVGEllipseElement: false, SVGFEBlendElement: false, SVGFEColorMatrixElement: false, SVGFEComponentTransferElement: false, SVGFECompositeElement: false, SVGFEConvolveMatrixElement: false, SVGFEDiffuseLightingElement: false, SVGFEDisplacementMapElement: false, SVGFEDistantLightElement: false, SVGFEDropShadowElement: false, SVGFEFloodElement: false, SVGFEFuncAElement: false, SVGFEFuncBElement: false, SVGFEFuncGElement: false, SVGFEFuncRElement: false, SVGFEGaussianBlurElement: false, SVGFEImageElement: false, SVGFEMergeElement: false, SVGFEMergeNodeElement: false, SVGFEMorphologyElement: false, SVGFEOffsetElement: false, SVGFEPointLightElement: false, SVGFESpecularLightingElement: false, SVGFESpotLightElement: false, SVGFETileElement: false, SVGFETurbulenceElement: false, SVGFilterElement: false, SVGForeignObjectElement: false, SVGGElement: false, SVGGeometryElement: false, SVGGradientElement: false, SVGGraphicsElement: false, SVGImageElement: false, SVGLength: false, SVGLengthList: false, SVGLinearGradientElement: false, SVGLineElement: false, SVGMarkerElement: false, SVGMaskElement: false, SVGMatrix: false, SVGMetadataElement: false, SVGMPathElement: false, SVGNumber: false, SVGNumberList: false, SVGPathElement: false, SVGPatternElement: false, SVGPoint: false, SVGPointList: false, SVGPolygonElement: false, SVGPolylineElement: false, SVGPreserveAspectRatio: false, SVGRadialGradientElement: false, SVGRect: false, SVGRectElement: false, SVGScriptElement: false, SVGSetElement: false, SVGStopElement: false, SVGStringList: false, SVGStyleElement: false, SVGSVGElement: false, SVGSwitchElement: false, SVGSymbolElement: false, SVGTextContentElement: false, SVGTextElement: false, SVGTextPathElement: false, SVGTextPositioningElement: false, SVGTitleElement: false, SVGTransform: false, SVGTransformList: false, SVGTSpanElement: false, SVGUnitTypes: false, SVGUseElement: false, SVGViewElement: false, TaskAttributionTiming: false, Text: false, TextDecoder: false, TextEncoder: false, TextEvent: false, TextMetrics: false, TextTrack: false, TextTrackCue: false, TextTrackCueList: false, TextTrackList: false, TimeRanges: false, toolbar: false, top: false, Touch: false, TouchEvent: false, TouchList: false, TrackEvent: false, TransitionEvent: false, TreeWalker: false, UIEvent: false, URL: false, URLSearchParams: false, ValidityState: false, visualViewport: false, VisualViewport: false, VTTCue: false, WaveShaperNode: false, WebAssembly: false, WebGL2RenderingContext: false, WebGLActiveInfo: false, WebGLBuffer: false, WebGLContextEvent: false, WebGLFramebuffer: false, WebGLProgram: false, WebGLQuery: false, WebGLRenderbuffer: false, WebGLRenderingContext: false, WebGLSampler: false, WebGLShader: false, WebGLShaderPrecisionFormat: false, WebGLSync: false, WebGLTexture: false, WebGLTransformFeedback: false, WebGLUniformLocation: false, WebGLVertexArrayObject: false, WebSocket: false, WheelEvent: false, window: false, Window: false, Worker: false, WritableStream: false, XMLDocument: false, XMLHttpRequest: false, XMLHttpRequestEventTarget: false, XMLHttpRequestUpload: false, XMLSerializer: false, XPathEvaluator: false, XPathExpression: false, XPathResult: false, XSLTProcessor: false }; var worker = { addEventListener: false, applicationCache: false, atob: false, Blob: false, BroadcastChannel: false, btoa: false, Cache: false, caches: false, clearInterval: false, clearTimeout: false, close: true, console: false, fetch: false, FileReaderSync: false, FormData: false, Headers: false, IDBCursor: false, IDBCursorWithValue: false, IDBDatabase: false, IDBFactory: false, IDBIndex: false, IDBKeyRange: false, IDBObjectStore: false, IDBOpenDBRequest: false, IDBRequest: false, IDBTransaction: false, IDBVersionChangeEvent: false, ImageData: false, importScripts: true, indexedDB: false, location: false, MessageChannel: false, MessagePort: false, name: false, navigator: false, Notification: false, onclose: true, onconnect: true, onerror: true, onlanguagechange: true, onmessage: true, onoffline: true, ononline: true, onrejectionhandled: true, onunhandledrejection: true, performance: false, Performance: false, PerformanceEntry: false, PerformanceMark: false, PerformanceMeasure: false, PerformanceNavigation: false, PerformanceResourceTiming: false, PerformanceTiming: false, postMessage: true, "Promise": false, queueMicrotask: false, removeEventListener: false, Request: false, Response: false, self: true, ServiceWorkerRegistration: false, setInterval: false, setTimeout: false, TextDecoder: false, TextEncoder: false, URL: false, URLSearchParams: false, WebSocket: false, Worker: false, WorkerGlobalScope: false, XMLHttpRequest: false }; var node = { __dirname: false, __filename: false, Buffer: false, clearImmediate: false, clearInterval: false, clearTimeout: false, console: false, exports: true, global: false, "Intl": false, module: false, process: false, queueMicrotask: false, require: false, setImmediate: false, setInterval: false, setTimeout: false, TextDecoder: false, TextEncoder: false, URL: false, URLSearchParams: false }; var commonjs = { exports: true, global: false, module: false, require: false }; var amd = { define: false, require: false }; var mocha = { after: false, afterEach: false, before: false, beforeEach: false, context: false, describe: false, it: false, mocha: false, run: false, setup: false, specify: false, suite: false, suiteSetup: false, suiteTeardown: false, teardown: false, test: false, xcontext: false, xdescribe: false, xit: false, xspecify: false }; var jasmine = { afterAll: false, afterEach: false, beforeAll: false, beforeEach: false, describe: false, expect: false, fail: false, fdescribe: false, fit: false, it: false, jasmine: false, pending: false, runs: false, spyOn: false, spyOnProperty: false, waits: false, waitsFor: false, xdescribe: false, xit: false }; var jest = { afterAll: false, afterEach: false, beforeAll: false, beforeEach: false, describe: false, expect: false, fdescribe: false, fit: false, it: false, jest: false, pit: false, require: false, test: false, xdescribe: false, xit: false, xtest: false }; var qunit = { asyncTest: false, deepEqual: false, equal: false, expect: false, module: false, notDeepEqual: false, notEqual: false, notOk: false, notPropEqual: false, notStrictEqual: false, ok: false, propEqual: false, QUnit: false, raises: false, start: false, stop: false, strictEqual: false, test: false, throws: false }; var phantomjs = { console: true, exports: true, phantom: true, require: true, WebPage: true }; var couch = { emit: false, exports: false, getRow: false, log: false, module: false, provides: false, require: false, respond: false, send: false, start: false, sum: false }; var rhino = { defineClass: false, deserialize: false, gc: false, help: false, importClass: false, importPackage: false, java: false, load: false, loadClass: false, Packages: false, print: false, quit: false, readFile: false, readUrl: false, runCommand: false, seal: false, serialize: false, spawn: false, sync: false, toint32: false, version: false }; var nashorn = { __DIR__: false, __FILE__: false, __LINE__: false, com: false, edu: false, exit: false, java: false, Java: false, javafx: false, JavaImporter: false, javax: false, JSAdapter: false, load: false, loadWithNewGlobal: false, org: false, Packages: false, print: false, quit: false }; var wsh = { ActiveXObject: true, Enumerator: true, GetObject: true, ScriptEngine: true, ScriptEngineBuildVersion: true, ScriptEngineMajorVersion: true, ScriptEngineMinorVersion: true, VBArray: true, WScript: true, WSH: true, XDomainRequest: true }; var jquery = { $: false, jQuery: false }; var yui = { YAHOO: false, YAHOO_config: false, YUI: false, YUI_config: false }; var shelljs = { cat: false, cd: false, chmod: false, config: false, cp: false, dirs: false, echo: false, env: false, error: false, exec: false, exit: false, find: false, grep: false, ln: false, ls: false, mkdir: false, mv: false, popd: false, pushd: false, pwd: false, rm: false, sed: false, set: false, target: false, tempdir: false, test: false, touch: false, which: false }; var prototypejs = { $: false, $$: false, $A: false, $break: false, $continue: false, $F: false, $H: false, $R: false, $w: false, Abstract: false, Ajax: false, Autocompleter: false, Builder: false, Class: false, Control: false, Draggable: false, Draggables: false, Droppables: false, Effect: false, Element: false, Enumerable: false, Event: false, Field: false, Form: false, Hash: false, Insertion: false, ObjectRange: false, PeriodicalExecuter: false, Position: false, Prototype: false, Scriptaculous: false, Selector: false, Sortable: false, SortableObserver: false, Sound: false, Template: false, Toggle: false, Try: false }; var meteor = { _: false, $: false, Accounts: false, AccountsClient: false, AccountsCommon: false, AccountsServer: false, App: false, Assets: false, Blaze: false, check: false, Cordova: false, DDP: false, DDPRateLimiter: false, DDPServer: false, Deps: false, EJSON: false, Email: false, HTTP: false, Log: false, Match: false, Meteor: false, Mongo: false, MongoInternals: false, Npm: false, Package: false, Plugin: false, process: false, Random: false, ReactiveDict: false, ReactiveVar: false, Router: false, ServiceConfiguration: false, Session: false, share: false, Spacebars: false, Template: false, Tinytest: false, Tracker: false, UI: false, Utils: false, WebApp: false, WebAppInternals: false }; var mongo = { _isWindows: false, _rand: false, BulkWriteResult: false, cat: false, cd: false, connect: false, db: false, getHostName: false, getMemInfo: false, hostname: false, ISODate: false, listFiles: false, load: false, ls: false, md5sumFile: false, mkdir: false, Mongo: false, NumberInt: false, NumberLong: false, ObjectId: false, PlanCache: false, print: false, printjson: false, pwd: false, quit: false, removeFile: false, rs: false, sh: false, UUID: false, version: false, WriteResult: false }; var applescript = { $: false, Application: false, Automation: false, console: false, delay: false, Library: false, ObjC: false, ObjectSpecifier: false, Path: false, Progress: false, Ref: false }; var serviceworker = { addEventListener: false, applicationCache: false, atob: false, Blob: false, BroadcastChannel: false, btoa: false, Cache: false, caches: false, CacheStorage: false, clearInterval: false, clearTimeout: false, Client: false, clients: false, Clients: false, close: true, console: false, ExtendableEvent: false, ExtendableMessageEvent: false, fetch: false, FetchEvent: false, FileReaderSync: false, FormData: false, Headers: false, IDBCursor: false, IDBCursorWithValue: false, IDBDatabase: false, IDBFactory: false, IDBIndex: false, IDBKeyRange: false, IDBObjectStore: false, IDBOpenDBRequest: false, IDBRequest: false, IDBTransaction: false, IDBVersionChangeEvent: false, ImageData: false, importScripts: false, indexedDB: false, location: false, MessageChannel: false, MessagePort: false, name: false, navigator: false, Notification: false, onclose: true, onconnect: true, onerror: true, onfetch: true, oninstall: true, onlanguagechange: true, onmessage: true, onmessageerror: true, onnotificationclick: true, onnotificationclose: true, onoffline: true, ononline: true, onpush: true, onpushsubscriptionchange: true, onrejectionhandled: true, onsync: true, onunhandledrejection: true, performance: false, Performance: false, PerformanceEntry: false, PerformanceMark: false, PerformanceMeasure: false, PerformanceNavigation: false, PerformanceResourceTiming: false, PerformanceTiming: false, postMessage: true, "Promise": false, queueMicrotask: false, registration: false, removeEventListener: false, Request: false, Response: false, self: false, ServiceWorker: false, ServiceWorkerContainer: false, ServiceWorkerGlobalScope: false, ServiceWorkerMessageEvent: false, ServiceWorkerRegistration: false, setInterval: false, setTimeout: false, skipWaiting: false, TextDecoder: false, TextEncoder: false, URL: false, URLSearchParams: false, WebSocket: false, WindowClient: false, Worker: false, WorkerGlobalScope: false, XMLHttpRequest: false }; var atomtest = { advanceClock: false, fakeClearInterval: false, fakeClearTimeout: false, fakeSetInterval: false, fakeSetTimeout: false, resetTimeouts: false, waitsForPromise: false }; var embertest = { andThen: false, click: false, currentPath: false, currentRouteName: false, currentURL: false, fillIn: false, find: false, findAll: false, findWithAssert: false, keyEvent: false, pauseTest: false, resumeTest: false, triggerEvent: false, visit: false, wait: false }; var protractor = { $: false, $$: false, browser: false, by: false, By: false, DartObject: false, element: false, protractor: false }; var webextensions = { browser: false, chrome: false, opr: false }; var greasemonkey = { cloneInto: false, createObjectIn: false, exportFunction: false, GM: false, GM_addStyle: false, GM_deleteValue: false, GM_getResourceText: false, GM_getResourceURL: false, GM_getValue: false, GM_info: false, GM_listValues: false, GM_log: false, GM_openInTab: false, GM_registerMenuCommand: false, GM_setClipboard: false, GM_setValue: false, GM_xmlhttpRequest: false, unsafeWindow: false }; var devtools = { $: false, $_: false, $$: false, $0: false, $1: false, $2: false, $3: false, $4: false, $x: false, chrome: false, clear: false, copy: false, debug: false, dir: false, dirxml: false, getEventListeners: false, inspect: false, keys: false, monitor: false, monitorEvents: false, profile: false, profileEnd: false, queryObjects: false, table: false, undebug: false, unmonitor: false, unmonitorEvents: false, values: false }; var globals = { builtin: builtin, es5: es5, es2015: es2015, es2017: es2017, browser: browser$2, worker: worker, node: node, commonjs: commonjs, amd: amd, mocha: mocha, jasmine: jasmine, jest: jest, qunit: qunit, phantomjs: phantomjs, couch: couch, rhino: rhino, nashorn: nashorn, wsh: wsh, jquery: jquery, yui: yui, shelljs: shelljs, prototypejs: prototypejs, meteor: meteor, mongo: mongo, applescript: applescript, serviceworker: serviceworker, atomtest: atomtest, embertest: embertest, protractor: protractor, "shared-node-browser": { clearInterval: false, clearTimeout: false, console: false, setInterval: false, setTimeout: false, URL: false, URLSearchParams: false }, webextensions: webextensions, greasemonkey: greasemonkey, devtools: devtools }; var globals$1 = /*#__PURE__*/Object.freeze({ __proto__: null, builtin: builtin, es5: es5, es2015: es2015, es2017: es2017, browser: browser$2, worker: worker, node: node, commonjs: commonjs, amd: amd, mocha: mocha, jasmine: jasmine, jest: jest, qunit: qunit, phantomjs: phantomjs, couch: couch, rhino: rhino, nashorn: nashorn, wsh: wsh, jquery: jquery, yui: yui, shelljs: shelljs, prototypejs: prototypejs, meteor: meteor, mongo: mongo, applescript: applescript, serviceworker: serviceworker, atomtest: atomtest, embertest: embertest, protractor: protractor, webextensions: webextensions, greasemonkey: greasemonkey, devtools: devtools, 'default': globals }); var require$$0 = getCjsExportFromNamespace(globals$1); var globals$2 = require$$0; var path = new WeakMap(); var scope = new WeakMap(); function clear() { clearPath(); clearScope(); } function clearPath() { path = new WeakMap(); } function clearScope() { scope = new WeakMap(); } var cache = /*#__PURE__*/Object.freeze({ __proto__: null, get path () { return path; }, get scope () { return scope; }, clear: clear, clearPath: clearPath, clearScope: clearScope }); function gatherNodeParts(node, parts) { if (isModuleDeclaration(node)) { if (node.source) { gatherNodeParts(node.source, parts); } else if (node.specifiers && node.specifiers.length) { for (var _i = 0, _arr = node.specifiers; _i < _arr.length; _i++) { var specifier = _arr[_i]; gatherNodeParts(specifier, parts); } } else if (node.declaration) { gatherNodeParts(node.declaration, parts); } } else if (isModuleSpecifier(node)) { gatherNodeParts(node.local, parts); } else if (isMemberExpression(node)) { gatherNodeParts(node.object, parts); gatherNodeParts(node.property, parts); } else if (isIdentifier(node)) { parts.push(node.name); } else if (isLiteral(node)) { parts.push(node.value); } else if (isCallExpression(node)) { gatherNodeParts(node.callee, parts); } else if (isObjectExpression(node) || isObjectPattern(node)) { for (var _i2 = 0, _arr2 = node.properties; _i2 < _arr2.length; _i2++) { var prop = _arr2[_i2]; gatherNodeParts(prop.key || prop.argument, parts); } } else if (isPrivateName(node)) { gatherNodeParts(node.id, parts); } else if (isThisExpression(node)) { parts.push("this"); } else if (isSuper(node)) { parts.push("super"); } } var collectorVisitor = { For: function For(path) { for (var _i3 = 0, _arr3 = FOR_INIT_KEYS; _i3 < _arr3.length; _i3++) { var key = _arr3[_i3]; var declar = path.get(key); if (declar.isVar()) { var parentScope = path.scope.getFunctionParent() || path.scope.getProgramParent(); parentScope.registerBinding("var", declar); } } }, Declaration: function Declaration(path) { if (path.isBlockScoped()) return; if (path.isExportDeclaration() && path.get("declaration").isDeclaration()) { return; } var parent = path.scope.getFunctionParent() || path.scope.getProgramParent(); parent.registerDeclaration(path); }, ReferencedIdentifier: function ReferencedIdentifier(path, state) { state.references.push(path); }, ForXStatement: function ForXStatement(path, state) { var left = path.get("left"); if (left.isPattern() || left.isIdentifier()) { state.constantViolations.push(path); } }, ExportDeclaration: { exit: function exit(path) { var node = path.node, scope = path.scope; var declar = node.declaration; if (isClassDeclaration(declar) || isFunctionDeclaration(declar)) { var id = declar.id; if (!id) return; var binding = scope.getBinding(id.name); if (binding) binding.reference(path); } else if (isVariableDeclaration(declar)) { for (var _i4 = 0, _arr4 = declar.declarations; _i4 < _arr4.length; _i4++) { var decl = _arr4[_i4]; for (var _i5 = 0, _Object$keys = Object.keys(getBindingIdentifiers(decl)); _i5 < _Object$keys.length; _i5++) { var name = _Object$keys[_i5]; var _binding = scope.getBinding(name); if (_binding) _binding.reference(path); } } } } }, LabeledStatement: function LabeledStatement(path) { path.scope.getProgramParent().addGlobal(path.node); path.scope.getBlockParent().registerDeclaration(path); }, AssignmentExpression: function AssignmentExpression(path, state) { state.assignments.push(path); }, UpdateExpression: function UpdateExpression(path, state) { state.constantViolations.push(path); }, UnaryExpression: function UnaryExpression(path, state) { if (path.node.operator === "delete") { state.constantViolations.push(path); } }, BlockScoped: function BlockScoped(path) { var scope = path.scope; if (scope.path === path) scope = scope.parent; scope.getBlockParent().registerDeclaration(path); }, ClassDeclaration: function ClassDeclaration(path) { var id = path.node.id; if (!id) return; var name = id.name; path.scope.bindings[name] = path.scope.getBinding(name); }, Block: function Block(path) { var paths = path.get("body"); for (var _i6 = 0, _arr5 = paths; _i6 < _arr5.length; _i6++) { var bodyPath = _arr5[_i6]; if (bodyPath.isFunctionDeclaration()) { path.scope.getBlockParent().registerDeclaration(bodyPath); } } } }; var uid = 0; var Scope$1 = function () { function Scope(path) { var node = path.node; var cached = scope.get(node); if (cached && cached.path === path) { return cached; } scope.set(node, this); this.uid = uid++; this.block = node; this.path = path; this.labels = new Map(); } var _proto = Scope.prototype; _proto.traverse = function traverse(node, opts, state) { traverse$1(node, opts, this, state, this.path); }; _proto.generateDeclaredUidIdentifier = function generateDeclaredUidIdentifier(name) { var id = this.generateUidIdentifier(name); this.push({ id: id }); return cloneNode(id); }; _proto.generateUidIdentifier = function generateUidIdentifier(name) { return Identifier(this.generateUid(name)); }; _proto.generateUid = function generateUid(name) { if (name === void 0) { name = "temp"; } name = toIdentifier(name).replace(/^_+/, "").replace(/[0-9]+$/g, ""); var uid; var i = 0; do { uid = this._generateUid(name, i); i++; } while (this.hasLabel(uid) || this.hasBinding(uid) || this.hasGlobal(uid) || this.hasReference(uid)); var program = this.getProgramParent(); program.references[uid] = true; program.uids[uid] = true; return uid; }; _proto._generateUid = function _generateUid(name, i) { var id = name; if (i > 1) id += i; return "_" + id; }; _proto.generateUidBasedOnNode = function generateUidBasedOnNode(parent, defaultName) { var node = parent; if (isAssignmentExpression(parent)) { node = parent.left; } else if (isVariableDeclarator(parent)) { node = parent.id; } else if (isObjectProperty(node) || isObjectMethod(node)) { node = node.key; } var parts = []; gatherNodeParts(node, parts); var id = parts.join("$"); id = id.replace(/^_/, "") || defaultName || "ref"; return this.generateUid(id.slice(0, 20)); }; _proto.generateUidIdentifierBasedOnNode = function generateUidIdentifierBasedOnNode(parent, defaultName) { return Identifier(this.generateUidBasedOnNode(parent, defaultName)); }; _proto.isStatic = function isStatic(node) { if (isThisExpression(node) || isSuper(node)) { return true; } if (isIdentifier(node)) { var binding = this.getBinding(node.name); if (binding) { return binding.constant; } else { return this.hasBinding(node.name); } } return false; }; _proto.maybeGenerateMemoised = function maybeGenerateMemoised(node, dontPush) { if (this.isStatic(node)) { return null; } else { var id = this.generateUidIdentifierBasedOnNode(node); if (!dontPush) { this.push({ id: id }); return cloneNode(id); } return id; } }; _proto.checkBlockScopedCollisions = function checkBlockScopedCollisions(local, kind, name, id) { if (kind === "param") return; if (local.kind === "local") return; var duplicate = kind === "let" || local.kind === "let" || local.kind === "const" || local.kind === "module" || local.kind === "param" && (kind === "let" || kind === "const"); if (duplicate) { throw this.hub.buildError(id, "Duplicate declaration \"" + name + "\"", TypeError); } }; _proto.rename = function rename(oldName, newName, block) { var binding = this.getBinding(oldName); if (binding) { newName = newName || this.generateUidIdentifier(oldName).name; return new Renamer(binding, oldName, newName).rename(block); } }; _proto._renameFromMap = function _renameFromMap(map, oldName, newName, value) { if (map[oldName]) { map[newName] = value; map[oldName] = null; } }; _proto.dump = function dump() { var sep = repeat_1("-", 60); console.log(sep); var scope = this; do { console.log("#", scope.block.type); for (var _i7 = 0, _Object$keys2 = Object.keys(scope.bindings); _i7 < _Object$keys2.length; _i7++) { var name = _Object$keys2[_i7]; var binding = scope.bindings[name]; console.log(" -", name, { constant: binding.constant, references: binding.references, violations: binding.constantViolations.length, kind: binding.kind }); } } while (scope = scope.parent); console.log(sep); }; _proto.toArray = function toArray(node, i) { if (isIdentifier(node)) { var binding = this.getBinding(node.name); if (binding && binding.constant && binding.path.isGenericType("Array")) { return node; } } if (isArrayExpression(node)) { return node; } if (isIdentifier(node, { name: "arguments" })) { return CallExpression(MemberExpression(MemberExpression(MemberExpression(Identifier("Array"), Identifier("prototype")), Identifier("slice")), Identifier("call")), [node]); } var helperName; var args = [node]; if (i === true) { helperName = "toConsumableArray"; } else if (i) { args.push(NumericLiteral(i)); helperName = "slicedToArray"; } else { helperName = "toArray"; } return CallExpression(this.hub.addHelper(helperName), args); }; _proto.hasLabel = function hasLabel(name) { return !!this.getLabel(name); }; _proto.getLabel = function getLabel(name) { return this.labels.get(name); }; _proto.registerLabel = function registerLabel(path) { this.labels.set(path.node.label.name, path); }; _proto.registerDeclaration = function registerDeclaration(path) { if (path.isLabeledStatement()) { this.registerLabel(path); } else if (path.isFunctionDeclaration()) { this.registerBinding("hoisted", path.get("id"), path); } else if (path.isVariableDeclaration()) { var declarations = path.get("declarations"); for (var _i8 = 0, _arr6 = declarations; _i8 < _arr6.length; _i8++) { var declar = _arr6[_i8]; this.registerBinding(path.node.kind, declar); } } else if (path.isClassDeclaration()) { this.registerBinding("let", path); } else if (path.isImportDeclaration()) { var specifiers = path.get("specifiers"); for (var _i9 = 0, _arr7 = specifiers; _i9 < _arr7.length; _i9++) { var specifier = _arr7[_i9]; this.registerBinding("module", specifier); } } else if (path.isExportDeclaration()) { var _declar = path.get("declaration"); if (_declar.isClassDeclaration() || _declar.isFunctionDeclaration() || _declar.isVariableDeclaration()) { this.registerDeclaration(_declar); } } else { this.registerBinding("unknown", path); } }; _proto.buildUndefinedNode = function buildUndefinedNode() { return UnaryExpression("void", NumericLiteral(0), true); }; _proto.registerConstantViolation = function registerConstantViolation(path) { var ids = path.getBindingIdentifiers(); for (var _i10 = 0, _Object$keys3 = Object.keys(ids); _i10 < _Object$keys3.length; _i10++) { var name = _Object$keys3[_i10]; var binding = this.getBinding(name); if (binding) binding.reassign(path); } }; _proto.registerBinding = function registerBinding(kind, path, bindingPath) { if (bindingPath === void 0) { bindingPath = path; } if (!kind) throw new ReferenceError("no `kind`"); if (path.isVariableDeclaration()) { var declarators = path.get("declarations"); for (var _iterator = declarators, _isArray = Array.isArray(_iterator), _i11 = 0, _iterator = _isArray ? _iterator : _iterator[Symbol.iterator]();;) { var _ref; if (_isArray) { if (_i11 >= _iterator.length) break; _ref = _iterator[_i11++]; } else { _i11 = _iterator.next(); if (_i11.done) break; _ref = _i11.value; } var declar = _ref; this.registerBinding(kind, declar); } return; } var parent = this.getProgramParent(); var ids = path.getOuterBindingIdentifiers(true); for (var _i12 = 0, _Object$keys4 = Object.keys(ids); _i12 < _Object$keys4.length; _i12++) { var name = _Object$keys4[_i12]; for (var _i13 = 0, _arr8 = ids[name]; _i13 < _arr8.length; _i13++) { var id = _arr8[_i13]; var local = this.getOwnBinding(name); if (local) { if (local.identifier === id) continue; this.checkBlockScopedCollisions(local, kind, name, id); } parent.references[name] = true; if (local) { this.registerConstantViolation(bindingPath); } else { this.bindings[name] = new Binding({ identifier: id, scope: this, path: bindingPath, kind: kind }); } } } }; _proto.addGlobal = function addGlobal(node) { this.globals[node.name] = node; }; _proto.hasUid = function hasUid(name) { var scope = this; do { if (scope.uids[name]) return true; } while (scope = scope.parent); return false; }; _proto.hasGlobal = function hasGlobal(name) { var scope = this; do { if (scope.globals[name]) return true; } while (scope = scope.parent); return false; }; _proto.hasReference = function hasReference(name) { var scope = this; do { if (scope.references[name]) return true; } while (scope = scope.parent); return false; }; _proto.isPure = function isPure(node, constantsOnly) { if (isIdentifier(node)) { var binding = this.getBinding(node.name); if (!binding) return false; if (constantsOnly) return binding.constant; return true; } else if (isClass(node)) { if (node.superClass && !this.isPure(node.superClass, constantsOnly)) { return false; } return this.isPure(node.body, constantsOnly); } else if (isClassBody(node)) { for (var _iterator2 = node.body, _isArray2 = Array.isArray(_iterator2), _i14 = 0, _iterator2 = _isArray2 ? _iterator2 : _iterator2[Symbol.iterator]();;) { var _ref2; if (_isArray2) { if (_i14 >= _iterator2.length) break; _ref2 = _iterator2[_i14++]; } else { _i14 = _iterator2.next(); if (_i14.done) break; _ref2 = _i14.value; } var method = _ref2; if (!this.isPure(method, constantsOnly)) return false; } return true; } else if (isBinary(node)) { return this.isPure(node.left, constantsOnly) && this.isPure(node.right, constantsOnly); } else if (isArrayExpression(node)) { for (var _i15 = 0, _arr9 = node.elements; _i15 < _arr9.length; _i15++) { var elem = _arr9[_i15]; if (!this.isPure(elem, constantsOnly)) return false; } return true; } else if (isObjectExpression(node)) { for (var _i16 = 0, _arr10 = node.properties; _i16 < _arr10.length; _i16++) { var prop = _arr10[_i16]; if (!this.isPure(prop, constantsOnly)) return false; } return true; } else if (isClassMethod(node)) { if (node.computed && !this.isPure(node.key, constantsOnly)) return false; if (node.kind === "get" || node.kind === "set") return false; return true; } else if (isProperty(node)) { if (node.computed && !this.isPure(node.key, constantsOnly)) return false; return this.isPure(node.value, constantsOnly); } else if (isUnaryExpression(node)) { return this.isPure(node.argument, constantsOnly); } else if (isTaggedTemplateExpression(node)) { return matchesPattern(node.tag, "String.raw") && !this.hasBinding("String", true) && this.isPure(node.quasi, constantsOnly); } else if (isTemplateLiteral(node)) { for (var _i17 = 0, _arr11 = node.expressions; _i17 < _arr11.length; _i17++) { var expression = _arr11[_i17]; if (!this.isPure(expression, constantsOnly)) return false; } return true; } else { return isPureish(node); } }; _proto.setData = function setData(key, val) { return this.data[key] = val; }; _proto.getData = function getData(key) { var scope = this; do { var data = scope.data[key]; if (data != null) return data; } while (scope = scope.parent); }; _proto.removeData = function removeData(key) { var scope = this; do { var data = scope.data[key]; if (data != null) scope.data[key] = null; } while (scope = scope.parent); }; _proto.init = function init() { if (!this.references) this.crawl(); }; _proto.crawl = function crawl() { var path = this.path; this.references = Object.create(null); this.bindings = Object.create(null); this.globals = Object.create(null); this.uids = Object.create(null); this.data = Object.create(null); if (path.isLoop()) { for (var _i18 = 0, _arr12 = FOR_INIT_KEYS; _i18 < _arr12.length; _i18++) { var key = _arr12[_i18]; var node = path.get(key); if (node.isBlockScoped()) this.registerBinding(node.node.kind, node); } } if (path.isFunctionExpression() && path.has("id")) { if (!path.get("id").node[NOT_LOCAL_BINDING]) { this.registerBinding("local", path.get("id"), path); } } if (path.isClassExpression() && path.has("id")) { if (!path.get("id").node[NOT_LOCAL_BINDING]) { this.registerBinding("local", path); } } if (path.isFunction()) { var params = path.get("params"); for (var _iterator3 = params, _isArray3 = Array.isArray(_iterator3), _i19 = 0, _iterator3 = _isArray3 ? _iterator3 : _iterator3[Symbol.iterator]();;) { var _ref3; if (_isArray3) { if (_i19 >= _iterator3.length) break; _ref3 = _iterator3[_i19++]; } else { _i19 = _iterator3.next(); if (_i19.done) break; _ref3 = _i19.value; } var param = _ref3; this.registerBinding("param", param); } } if (path.isCatchClause()) { this.registerBinding("let", path); } var parent = this.getProgramParent(); if (parent.crawling) return; var state = { references: [], constantViolations: [], assignments: [] }; this.crawling = true; path.traverse(collectorVisitor, state); this.crawling = false; for (var _iterator4 = state.assignments, _isArray4 = Array.isArray(_iterator4), _i20 = 0, _iterator4 = _isArray4 ? _iterator4 : _iterator4[Symbol.iterator]();;) { var _ref4; if (_isArray4) { if (_i20 >= _iterator4.length) break; _ref4 = _iterator4[_i20++]; } else { _i20 = _iterator4.next(); if (_i20.done) break; _ref4 = _i20.value; } var _path = _ref4; var ids = _path.getBindingIdentifiers(); var programParent = void 0; for (var _i23 = 0, _Object$keys5 = Object.keys(ids); _i23 < _Object$keys5.length; _i23++) { var name = _Object$keys5[_i23]; if (_path.scope.getBinding(name)) continue; programParent = programParent || _path.scope.getProgramParent(); programParent.addGlobal(ids[name]); } _path.scope.registerConstantViolation(_path); } for (var _iterator5 = state.references, _isArray5 = Array.isArray(_iterator5), _i21 = 0, _iterator5 = _isArray5 ? _iterator5 : _iterator5[Symbol.iterator]();;) { var _ref5; if (_isArray5) { if (_i21 >= _iterator5.length) break; _ref5 = _iterator5[_i21++]; } else { _i21 = _iterator5.next(); if (_i21.done) break; _ref5 = _i21.value; } var ref = _ref5; var binding = ref.scope.getBinding(ref.node.name); if (binding) { binding.reference(ref); } else { ref.scope.getProgramParent().addGlobal(ref.node); } } for (var _iterator6 = state.constantViolations, _isArray6 = Array.isArray(_iterator6), _i22 = 0, _iterator6 = _isArray6 ? _iterator6 : _iterator6[Symbol.iterator]();;) { var _ref6; if (_isArray6) { if (_i22 >= _iterator6.length) break; _ref6 = _iterator6[_i22++]; } else { _i22 = _iterator6.next(); if (_i22.done) break; _ref6 = _i22.value; } var _path2 = _ref6; _path2.scope.registerConstantViolation(_path2); } }; _proto.push = function push(opts) { var path = this.path; if (!path.isBlockStatement() && !path.isProgram()) { path = this.getBlockParent().path; } if (path.isSwitchStatement()) { path = (this.getFunctionParent() || this.getProgramParent()).path; } if (path.isLoop() || path.isCatchClause() || path.isFunction()) { path.ensureBlock(); path = path.get("body"); } var unique = opts.unique; var kind = opts.kind || "var"; var blockHoist = opts._blockHoist == null ? 2 : opts._blockHoist; var dataKey = "declaration:" + kind + ":" + blockHoist; var declarPath = !unique && path.getData(dataKey); if (!declarPath) { var declar = VariableDeclaration(kind, []); declar._blockHoist = blockHoist; var _path$unshiftContaine = path.unshiftContainer("body", [declar]); declarPath = _path$unshiftContaine[0]; if (!unique) path.setData(dataKey, declarPath); } var declarator = VariableDeclarator(opts.id, opts.init); declarPath.node.declarations.push(declarator); this.registerBinding(kind, declarPath.get("declarations").pop()); }; _proto.getProgramParent = function getProgramParent() { var scope = this; do { if (scope.path.isProgram()) { return scope; } } while (scope = scope.parent); throw new Error("Couldn't find a Program"); }; _proto.getFunctionParent = function getFunctionParent() { var scope = this; do { if (scope.path.isFunctionParent()) { return scope; } } while (scope = scope.parent); return null; }; _proto.getBlockParent = function getBlockParent() { var scope = this; do { if (scope.path.isBlockParent()) { return scope; } } while (scope = scope.parent); throw new Error("We couldn't find a BlockStatement, For, Switch, Function, Loop or Program..."); }; _proto.getAllBindings = function getAllBindings() { var ids = Object.create(null); var scope = this; do { defaults_1(ids, scope.bindings); scope = scope.parent; } while (scope); return ids; }; _proto.getAllBindingsOfKind = function getAllBindingsOfKind() { var ids = Object.create(null); for (var _i24 = 0, _arr13 = arguments; _i24 < _arr13.length; _i24++) { var kind = _arr13[_i24]; var scope = this; do { for (var _i25 = 0, _Object$keys6 = Object.keys(scope.bindings); _i25 < _Object$keys6.length; _i25++) { var name = _Object$keys6[_i25]; var binding = scope.bindings[name]; if (binding.kind === kind) ids[name] = binding; } scope = scope.parent; } while (scope); } return ids; }; _proto.bindingIdentifierEquals = function bindingIdentifierEquals(name, node) { return this.getBindingIdentifier(name) === node; }; _proto.getBinding = function getBinding(name) { var scope = this; var previousPath; do { var binding = scope.getOwnBinding(name); if (binding) { if (previousPath && previousPath.isPattern() && previousPath.parentPath.isFunction() && binding.kind !== "param") ; else { return binding; } } previousPath = scope.path; } while (scope = scope.parent); }; _proto.getOwnBinding = function getOwnBinding(name) { return this.bindings[name]; }; _proto.getBindingIdentifier = function getBindingIdentifier(name) { var info = this.getBinding(name); return info && info.identifier; }; _proto.getOwnBindingIdentifier = function getOwnBindingIdentifier(name) { var binding = this.bindings[name]; return binding && binding.identifier; }; _proto.hasOwnBinding = function hasOwnBinding(name) { return !!this.getOwnBinding(name); }; _proto.hasBinding = function hasBinding(name, noGlobals) { if (!name) return false; if (this.hasOwnBinding(name)) return true; if (this.parentHasBinding(name, noGlobals)) return true; if (this.hasUid(name)) return true; if (!noGlobals && includes_1(Scope.globals, name)) return true; if (!noGlobals && includes_1(Scope.contextVariables, name)) return true; return false; }; _proto.parentHasBinding = function parentHasBinding(name, noGlobals) { return this.parent && this.parent.hasBinding(name, noGlobals); }; _proto.moveBindingTo = function moveBindingTo(name, scope) { var info = this.getBinding(name); if (info) { info.scope.removeOwnBinding(name); info.scope = scope; scope.bindings[name] = info; } }; _proto.removeOwnBinding = function removeOwnBinding(name) { delete this.bindings[name]; }; _proto.removeBinding = function removeBinding(name) { var info = this.getBinding(name); if (info) { info.scope.removeOwnBinding(name); } var scope = this; do { if (scope.uids[name]) { scope.uids[name] = false; } } while (scope = scope.parent); }; _createClass(Scope, [{ key: "parent", get: function get() { var parent = this.path.findParent(function (p) { return p.isScope(); }); return parent && parent.scope; } }, { key: "parentBlock", get: function get() { return this.path.parent; } }, { key: "hub", get: function get() { return this.path.hub; } }]); return Scope; }(); Scope$1.globals = Object.keys(globals$2.builtin); Scope$1.contextVariables = ["arguments", "undefined", "Infinity", "NaN"]; var intToCharMap = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/'.split(''); var encode = function (number) { if (0 <= number && number < intToCharMap.length) { return intToCharMap[number]; } throw new TypeError("Must be between 0 and 63: " + number); }; var decode = function (charCode) { var bigA = 65; var bigZ = 90; var littleA = 97; var littleZ = 122; var zero = 48; var nine = 57; var plus = 43; var slash = 47; var littleOffset = 26; var numberOffset = 52; if (bigA <= charCode && charCode <= bigZ) { return charCode - bigA; } if (littleA <= charCode && charCode <= littleZ) { return charCode - littleA + littleOffset; } if (zero <= charCode && charCode <= nine) { return charCode - zero + numberOffset; } if (charCode == plus) { return 62; } if (charCode == slash) { return 63; } return -1; }; var base64 = { encode: encode, decode: decode }; var VLQ_BASE_SHIFT = 5; var VLQ_BASE = 1 << VLQ_BASE_SHIFT; var VLQ_BASE_MASK = VLQ_BASE - 1; var VLQ_CONTINUATION_BIT = VLQ_BASE; function toVLQSigned(aValue) { return aValue < 0 ? (-aValue << 1) + 1 : (aValue << 1) + 0; } function fromVLQSigned(aValue) { var isNegative = (aValue & 1) === 1; var shifted = aValue >> 1; return isNegative ? -shifted : shifted; } var encode$1 = function base64VLQ_encode(aValue) { var encoded = ""; var digit; var vlq = toVLQSigned(aValue); do { digit = vlq & VLQ_BASE_MASK; vlq >>>= VLQ_BASE_SHIFT; if (vlq > 0) { digit |= VLQ_CONTINUATION_BIT; } encoded += base64.encode(digit); } while (vlq > 0); return encoded; }; var decode$1 = function base64VLQ_decode(aStr, aIndex, aOutParam) { var strLen = aStr.length; var result = 0; var shift = 0; var continuation, digit; do { if (aIndex >= strLen) { throw new Error("Expected more digits in base 64 VLQ value."); } digit = base64.decode(aStr.charCodeAt(aIndex++)); if (digit === -1) { throw new Error("Invalid base64 digit: " + aStr.charAt(aIndex - 1)); } continuation = !!(digit & VLQ_CONTINUATION_BIT); digit &= VLQ_BASE_MASK; result = result + (digit << shift); shift += VLQ_BASE_SHIFT; } while (continuation); aOutParam.value = fromVLQSigned(result); aOutParam.rest = aIndex; }; var base64Vlq = { encode: encode$1, decode: decode$1 }; var util = createCommonjsModule(function (module, exports) { function getArg(aArgs, aName, aDefaultValue) { if (aName in aArgs) { return aArgs[aName]; } else if (arguments.length === 3) { return aDefaultValue; } else { throw new Error('"' + aName + '" is a required argument.'); } } exports.getArg = getArg; var urlRegexp = /^(?:([\w+\-.]+):)?\/\/(?:(\w+:\w+)@)?([\w.-]*)(?::(\d+))?(.*)$/; var dataUrlRegexp = /^data:.+\,.+$/; function urlParse(aUrl) { var match = aUrl.match(urlRegexp); if (!match) { return null; } return { scheme: match[1], auth: match[2], host: match[3], port: match[4], path: match[5] }; } exports.urlParse = urlParse; function urlGenerate(aParsedUrl) { var url = ''; if (aParsedUrl.scheme) { url += aParsedUrl.scheme + ':'; } url += '//'; if (aParsedUrl.auth) { url += aParsedUrl.auth + '@'; } if (aParsedUrl.host) { url += aParsedUrl.host; } if (aParsedUrl.port) { url += ":" + aParsedUrl.port; } if (aParsedUrl.path) { url += aParsedUrl.path; } return url; } exports.urlGenerate = urlGenerate; function normalize(aPath) { var path = aPath; var url = urlParse(aPath); if (url) { if (!url.path) { return aPath; } path = url.path; } var isAbsolute = exports.isAbsolute(path); var parts = path.split(/\/+/); for (var part, up = 0, i = parts.length - 1; i >= 0; i--) { part = parts[i]; if (part === '.') { parts.splice(i, 1); } else if (part === '..') { up++; } else if (up > 0) { if (part === '') { parts.splice(i + 1, up); up = 0; } else { parts.splice(i, 2); up--; } } } path = parts.join('/'); if (path === '') { path = isAbsolute ? '/' : '.'; } if (url) { url.path = path; return urlGenerate(url); } return path; } exports.normalize = normalize; function join(aRoot, aPath) { if (aRoot === "") { aRoot = "."; } if (aPath === "") { aPath = "."; } var aPathUrl = urlParse(aPath); var aRootUrl = urlParse(aRoot); if (aRootUrl) { aRoot = aRootUrl.path || '/'; } if (aPathUrl && !aPathUrl.scheme) { if (aRootUrl) { aPathUrl.scheme = aRootUrl.scheme; } return urlGenerate(aPathUrl); } if (aPathUrl || aPath.match(dataUrlRegexp)) { return aPath; } if (aRootUrl && !aRootUrl.host && !aRootUrl.path) { aRootUrl.host = aPath; return urlGenerate(aRootUrl); } var joined = aPath.charAt(0) === '/' ? aPath : normalize(aRoot.replace(/\/+$/, '') + '/' + aPath); if (aRootUrl) { aRootUrl.path = joined; return urlGenerate(aRootUrl); } return joined; } exports.join = join; exports.isAbsolute = function (aPath) { return aPath.charAt(0) === '/' || urlRegexp.test(aPath); }; function relative(aRoot, aPath) { if (aRoot === "") { aRoot = "."; } aRoot = aRoot.replace(/\/$/, ''); var level = 0; while (aPath.indexOf(aRoot + '/') !== 0) { var index = aRoot.lastIndexOf("/"); if (index < 0) { return aPath; } aRoot = aRoot.slice(0, index); if (aRoot.match(/^([^\/]+:\/)?\/*$/)) { return aPath; } ++level; } return Array(level + 1).join("../") + aPath.substr(aRoot.length + 1); } exports.relative = relative; var supportsNullProto = function () { var obj = Object.create(null); return !('__proto__' in obj); }(); function identity(s) { return s; } function toSetString(aStr) { if (isProtoString(aStr)) { return '$' + aStr; } return aStr; } exports.toSetString = supportsNullProto ? identity : toSetString; function fromSetString(aStr) { if (isProtoString(aStr)) { return aStr.slice(1); } return aStr; } exports.fromSetString = supportsNullProto ? identity : fromSetString; function isProtoString(s) { if (!s) { return false; } var length = s.length; if (length < 9) { return false; } if (s.charCodeAt(length - 1) !== 95 || s.charCodeAt(length - 2) !== 95 || s.charCodeAt(length - 3) !== 111 || s.charCodeAt(length - 4) !== 116 || s.charCodeAt(length - 5) !== 111 || s.charCodeAt(length - 6) !== 114 || s.charCodeAt(length - 7) !== 112 || s.charCodeAt(length - 8) !== 95 || s.charCodeAt(length - 9) !== 95) { return false; } for (var i = length - 10; i >= 0; i--) { if (s.charCodeAt(i) !== 36) { return false; } } return true; } function compareByOriginalPositions(mappingA, mappingB, onlyCompareOriginal) { var cmp = strcmp(mappingA.source, mappingB.source); if (cmp !== 0) { return cmp; } cmp = mappingA.originalLine - mappingB.originalLine; if (cmp !== 0) { return cmp; } cmp = mappingA.originalColumn - mappingB.originalColumn; if (cmp !== 0 || onlyCompareOriginal) { return cmp; } cmp = mappingA.generatedColumn - mappingB.generatedColumn; if (cmp !== 0) { return cmp; } cmp = mappingA.generatedLine - mappingB.generatedLine; if (cmp !== 0) { return cmp; } return strcmp(mappingA.name, mappingB.name); } exports.compareByOriginalPositions = compareByOriginalPositions; function compareByGeneratedPositionsDeflated(mappingA, mappingB, onlyCompareGenerated) { var cmp = mappingA.generatedLine - mappingB.generatedLine; if (cmp !== 0) { return cmp; } cmp = mappingA.generatedColumn - mappingB.generatedColumn; if (cmp !== 0 || onlyCompareGenerated) { return cmp; } cmp = strcmp(mappingA.source, mappingB.source); if (cmp !== 0) { return cmp; } cmp = mappingA.originalLine - mappingB.originalLine; if (cmp !== 0) { return cmp; } cmp = mappingA.originalColumn - mappingB.originalColumn; if (cmp !== 0) { return cmp; } return strcmp(mappingA.name, mappingB.name); } exports.compareByGeneratedPositionsDeflated = compareByGeneratedPositionsDeflated; function strcmp(aStr1, aStr2) { if (aStr1 === aStr2) { return 0; } if (aStr1 === null) { return 1; } if (aStr2 === null) { return -1; } if (aStr1 > aStr2) { return 1; } return -1; } function compareByGeneratedPositionsInflated(mappingA, mappingB) { var cmp = mappingA.generatedLine - mappingB.generatedLine; if (cmp !== 0) { return cmp; } cmp = mappingA.generatedColumn - mappingB.generatedColumn; if (cmp !== 0) { return cmp; } cmp = strcmp(mappingA.source, mappingB.source); if (cmp !== 0) { return cmp; } cmp = mappingA.originalLine - mappingB.originalLine; if (cmp !== 0) { return cmp; } cmp = mappingA.originalColumn - mappingB.originalColumn; if (cmp !== 0) { return cmp; } return strcmp(mappingA.name, mappingB.name); } exports.compareByGeneratedPositionsInflated = compareByGeneratedPositionsInflated; function parseSourceMapInput(str) { return JSON.parse(str.replace(/^\)]}'[^\n]*\n/, '')); } exports.parseSourceMapInput = parseSourceMapInput; function computeSourceURL(sourceRoot, sourceURL, sourceMapURL) { sourceURL = sourceURL || ''; if (sourceRoot) { if (sourceRoot[sourceRoot.length - 1] !== '/' && sourceURL[0] !== '/') { sourceRoot += '/'; } sourceURL = sourceRoot + sourceURL; } if (sourceMapURL) { var parsed = urlParse(sourceMapURL); if (!parsed) { throw new Error("sourceMapURL could not be parsed"); } if (parsed.path) { var index = parsed.path.lastIndexOf('/'); if (index >= 0) { parsed.path = parsed.path.substring(0, index + 1); } } sourceURL = join(urlGenerate(parsed), sourceURL); } return normalize(sourceURL); } exports.computeSourceURL = computeSourceURL; }); var util_1 = util.getArg; var util_2 = util.urlParse; var util_3 = util.urlGenerate; var util_4 = util.normalize; var util_5 = util.join; var util_6 = util.isAbsolute; var util_7 = util.relative; var util_8 = util.toSetString; var util_9 = util.fromSetString; var util_10 = util.compareByOriginalPositions; var util_11 = util.compareByGeneratedPositionsDeflated; var util_12 = util.compareByGeneratedPositionsInflated; var util_13 = util.parseSourceMapInput; var util_14 = util.computeSourceURL; var has$1 = Object.prototype.hasOwnProperty; var hasNativeMap = typeof Map !== "undefined"; function ArraySet() { this._array = []; this._set = hasNativeMap ? new Map() : Object.create(null); } ArraySet.fromArray = function ArraySet_fromArray(aArray, aAllowDuplicates) { var set = new ArraySet(); for (var i = 0, len = aArray.length; i < len; i++) { set.add(aArray[i], aAllowDuplicates); } return set; }; ArraySet.prototype.size = function ArraySet_size() { return hasNativeMap ? this._set.size : Object.getOwnPropertyNames(this._set).length; }; ArraySet.prototype.add = function ArraySet_add(aStr, aAllowDuplicates) { var sStr = hasNativeMap ? aStr : util.toSetString(aStr); var isDuplicate = hasNativeMap ? this.has(aStr) : has$1.call(this._set, sStr); var idx = this._array.length; if (!isDuplicate || aAllowDuplicates) { this._array.push(aStr); } if (!isDuplicate) { if (hasNativeMap) { this._set.set(aStr, idx); } else { this._set[sStr] = idx; } } }; ArraySet.prototype.has = function ArraySet_has(aStr) { if (hasNativeMap) { return this._set.has(aStr); } else { var sStr = util.toSetString(aStr); return has$1.call(this._set, sStr); } }; ArraySet.prototype.indexOf = function ArraySet_indexOf(aStr) { if (hasNativeMap) { var idx = this._set.get(aStr); if (idx >= 0) { return idx; } } else { var sStr = util.toSetString(aStr); if (has$1.call(this._set, sStr)) { return this._set[sStr]; } } throw new Error('"' + aStr + '" is not in the set.'); }; ArraySet.prototype.at = function ArraySet_at(aIdx) { if (aIdx >= 0 && aIdx < this._array.length) { return this._array[aIdx]; } throw new Error('No element indexed by ' + aIdx); }; ArraySet.prototype.toArray = function ArraySet_toArray() { return this._array.slice(); }; var ArraySet_1 = ArraySet; var arraySet = { ArraySet: ArraySet_1 }; function generatedPositionAfter(mappingA, mappingB) { var lineA = mappingA.generatedLine; var lineB = mappingB.generatedLine; var columnA = mappingA.generatedColumn; var columnB = mappingB.generatedColumn; return lineB > lineA || lineB == lineA && columnB >= columnA || util.compareByGeneratedPositionsInflated(mappingA, mappingB) <= 0; } function MappingList() { this._array = []; this._sorted = true; this._last = { generatedLine: -1, generatedColumn: 0 }; } MappingList.prototype.unsortedForEach = function MappingList_forEach(aCallback, aThisArg) { this._array.forEach(aCallback, aThisArg); }; MappingList.prototype.add = function MappingList_add(aMapping) { if (generatedPositionAfter(this._last, aMapping)) { this._last = aMapping; this._array.push(aMapping); } else { this._sorted = false; this._array.push(aMapping); } }; MappingList.prototype.toArray = function MappingList_toArray() { if (!this._sorted) { this._array.sort(util.compareByGeneratedPositionsInflated); this._sorted = true; } return this._array; }; var MappingList_1 = MappingList; var mappingList = { MappingList: MappingList_1 }; var ArraySet$1 = arraySet.ArraySet; var MappingList$1 = mappingList.MappingList; function SourceMapGenerator(aArgs) { if (!aArgs) { aArgs = {}; } this._file = util.getArg(aArgs, 'file', null); this._sourceRoot = util.getArg(aArgs, 'sourceRoot', null); this._skipValidation = util.getArg(aArgs, 'skipValidation', false); this._sources = new ArraySet$1(); this._names = new ArraySet$1(); this._mappings = new MappingList$1(); this._sourcesContents = null; } SourceMapGenerator.prototype._version = 3; SourceMapGenerator.fromSourceMap = function SourceMapGenerator_fromSourceMap(aSourceMapConsumer) { var sourceRoot = aSourceMapConsumer.sourceRoot; var generator = new SourceMapGenerator({ file: aSourceMapConsumer.file, sourceRoot: sourceRoot }); aSourceMapConsumer.eachMapping(function (mapping) { var newMapping = { generated: { line: mapping.generatedLine, column: mapping.generatedColumn } }; if (mapping.source != null) { newMapping.source = mapping.source; if (sourceRoot != null) { newMapping.source = util.relative(sourceRoot, newMapping.source); } newMapping.original = { line: mapping.originalLine, column: mapping.originalColumn }; if (mapping.name != null) { newMapping.name = mapping.name; } } generator.addMapping(newMapping); }); aSourceMapConsumer.sources.forEach(function (sourceFile) { var sourceRelative = sourceFile; if (sourceRoot !== null) { sourceRelative = util.relative(sourceRoot, sourceFile); } if (!generator._sources.has(sourceRelative)) { generator._sources.add(sourceRelative); } var content = aSourceMapConsumer.sourceContentFor(sourceFile); if (content != null) { generator.setSourceContent(sourceFile, content); } }); return generator; }; SourceMapGenerator.prototype.addMapping = function SourceMapGenerator_addMapping(aArgs) { var generated = util.getArg(aArgs, 'generated'); var original = util.getArg(aArgs, 'original', null); var source = util.getArg(aArgs, 'source', null); var name = util.getArg(aArgs, 'name', null); if (!this._skipValidation) { this._validateMapping(generated, original, source, name); } if (source != null) { source = String(source); if (!this._sources.has(source)) { this._sources.add(source); } } if (name != null) { name = String(name); if (!this._names.has(name)) { this._names.add(name); } } this._mappings.add({ generatedLine: generated.line, generatedColumn: generated.column, originalLine: original != null && original.line, originalColumn: original != null && original.column, source: source, name: name }); }; SourceMapGenerator.prototype.setSourceContent = function SourceMapGenerator_setSourceContent(aSourceFile, aSourceContent) { var source = aSourceFile; if (this._sourceRoot != null) { source = util.relative(this._sourceRoot, source); } if (aSourceContent != null) { if (!this._sourcesContents) { this._sourcesContents = Object.create(null); } this._sourcesContents[util.toSetString(source)] = aSourceContent; } else if (this._sourcesContents) { delete this._sourcesContents[util.toSetString(source)]; if (Object.keys(this._sourcesContents).length === 0) { this._sourcesContents = null; } } }; SourceMapGenerator.prototype.applySourceMap = function SourceMapGenerator_applySourceMap(aSourceMapConsumer, aSourceFile, aSourceMapPath) { var sourceFile = aSourceFile; if (aSourceFile == null) { if (aSourceMapConsumer.file == null) { throw new Error('SourceMapGenerator.prototype.applySourceMap requires either an explicit source file, ' + 'or the source map\'s "file" property. Both were omitted.'); } sourceFile = aSourceMapConsumer.file; } var sourceRoot = this._sourceRoot; if (sourceRoot != null) { sourceFile = util.relative(sourceRoot, sourceFile); } var newSources = new ArraySet$1(); var newNames = new ArraySet$1(); this._mappings.unsortedForEach(function (mapping) { if (mapping.source === sourceFile && mapping.originalLine != null) { var original = aSourceMapConsumer.originalPositionFor({ line: mapping.originalLine, column: mapping.originalColumn }); if (original.source != null) { mapping.source = original.source; if (aSourceMapPath != null) { mapping.source = util.join(aSourceMapPath, mapping.source); } if (sourceRoot != null) { mapping.source = util.relative(sourceRoot, mapping.source); } mapping.originalLine = original.line; mapping.originalColumn = original.column; if (original.name != null) { mapping.name = original.name; } } } var source = mapping.source; if (source != null && !newSources.has(source)) { newSources.add(source); } var name = mapping.name; if (name != null && !newNames.has(name)) { newNames.add(name); } }, this); this._sources = newSources; this._names = newNames; aSourceMapConsumer.sources.forEach(function (sourceFile) { var content = aSourceMapConsumer.sourceContentFor(sourceFile); if (content != null) { if (aSourceMapPath != null) { sourceFile = util.join(aSourceMapPath, sourceFile); } if (sourceRoot != null) { sourceFile = util.relative(sourceRoot, sourceFile); } this.setSourceContent(sourceFile, content); } }, this); }; SourceMapGenerator.prototype._validateMapping = function SourceMapGenerator_validateMapping(aGenerated, aOriginal, aSource, aName) { if (aOriginal && typeof aOriginal.line !== 'number' && typeof aOriginal.column !== 'number') { throw new Error('original.line and original.column are not numbers -- you probably meant to omit ' + 'the original mapping entirely and only map the generated position. If so, pass ' + 'null for the original mapping instead of an object with empty or null values.'); } if (aGenerated && 'line' in aGenerated && 'column' in aGenerated && aGenerated.line > 0 && aGenerated.column >= 0 && !aOriginal && !aSource && !aName) { return; } else if (aGenerated && 'line' in aGenerated && 'column' in aGenerated && aOriginal && 'line' in aOriginal && 'column' in aOriginal && aGenerated.line > 0 && aGenerated.column >= 0 && aOriginal.line > 0 && aOriginal.column >= 0 && aSource) { return; } else { throw new Error('Invalid mapping: ' + JSON.stringify({ generated: aGenerated, source: aSource, original: aOriginal, name: aName })); } }; SourceMapGenerator.prototype._serializeMappings = function SourceMapGenerator_serializeMappings() { var previousGeneratedColumn = 0; var previousGeneratedLine = 1; var previousOriginalColumn = 0; var previousOriginalLine = 0; var previousName = 0; var previousSource = 0; var result = ''; var next; var mapping; var nameIdx; var sourceIdx; var mappings = this._mappings.toArray(); for (var i = 0, len = mappings.length; i < len; i++) { mapping = mappings[i]; next = ''; if (mapping.generatedLine !== previousGeneratedLine) { previousGeneratedColumn = 0; while (mapping.generatedLine !== previousGeneratedLine) { next += ';'; previousGeneratedLine++; } } else { if (i > 0) { if (!util.compareByGeneratedPositionsInflated(mapping, mappings[i - 1])) { continue; } next += ','; } } next += base64Vlq.encode(mapping.generatedColumn - previousGeneratedColumn); previousGeneratedColumn = mapping.generatedColumn; if (mapping.source != null) { sourceIdx = this._sources.indexOf(mapping.source); next += base64Vlq.encode(sourceIdx - previousSource); previousSource = sourceIdx; next += base64Vlq.encode(mapping.originalLine - 1 - previousOriginalLine); previousOriginalLine = mapping.originalLine - 1; next += base64Vlq.encode(mapping.originalColumn - previousOriginalColumn); previousOriginalColumn = mapping.originalColumn; if (mapping.name != null) { nameIdx = this._names.indexOf(mapping.name); next += base64Vlq.encode(nameIdx - previousName); previousName = nameIdx; } } result += next; } return result; }; SourceMapGenerator.prototype._generateSourcesContent = function SourceMapGenerator_generateSourcesContent(aSources, aSourceRoot) { return aSources.map(function (source) { if (!this._sourcesContents) { return null; } if (aSourceRoot != null) { source = util.relative(aSourceRoot, source); } var key = util.toSetString(source); return Object.prototype.hasOwnProperty.call(this._sourcesContents, key) ? this._sourcesContents[key] : null; }, this); }; SourceMapGenerator.prototype.toJSON = function SourceMapGenerator_toJSON() { var map = { version: this._version, sources: this._sources.toArray(), names: this._names.toArray(), mappings: this._serializeMappings() }; if (this._file != null) { map.file = this._file; } if (this._sourceRoot != null) { map.sourceRoot = this._sourceRoot; } if (this._sourcesContents) { map.sourcesContent = this._generateSourcesContent(map.sources, map.sourceRoot); } return map; }; SourceMapGenerator.prototype.toString = function SourceMapGenerator_toString() { return JSON.stringify(this.toJSON()); }; var SourceMapGenerator_1 = SourceMapGenerator; var sourceMapGenerator = { SourceMapGenerator: SourceMapGenerator_1 }; var binarySearch = createCommonjsModule(function (module, exports) { exports.GREATEST_LOWER_BOUND = 1; exports.LEAST_UPPER_BOUND = 2; function recursiveSearch(aLow, aHigh, aNeedle, aHaystack, aCompare, aBias) { var mid = Math.floor((aHigh - aLow) / 2) + aLow; var cmp = aCompare(aNeedle, aHaystack[mid], true); if (cmp === 0) { return mid; } else if (cmp > 0) { if (aHigh - mid > 1) { return recursiveSearch(mid, aHigh, aNeedle, aHaystack, aCompare, aBias); } if (aBias == exports.LEAST_UPPER_BOUND) { return aHigh < aHaystack.length ? aHigh : -1; } else { return mid; } } else { if (mid - aLow > 1) { return recursiveSearch(aLow, mid, aNeedle, aHaystack, aCompare, aBias); } if (aBias == exports.LEAST_UPPER_BOUND) { return mid; } else { return aLow < 0 ? -1 : aLow; } } } exports.search = function search(aNeedle, aHaystack, aCompare, aBias) { if (aHaystack.length === 0) { return -1; } var index = recursiveSearch(-1, aHaystack.length, aNeedle, aHaystack, aCompare, aBias || exports.GREATEST_LOWER_BOUND); if (index < 0) { return -1; } while (index - 1 >= 0) { if (aCompare(aHaystack[index], aHaystack[index - 1], true) !== 0) { break; } --index; } return index; }; }); var binarySearch_1 = binarySearch.GREATEST_LOWER_BOUND; var binarySearch_2 = binarySearch.LEAST_UPPER_BOUND; var binarySearch_3 = binarySearch.search; function swap(ary, x, y) { var temp = ary[x]; ary[x] = ary[y]; ary[y] = temp; } function randomIntInRange(low, high) { return Math.round(low + Math.random() * (high - low)); } function doQuickSort(ary, comparator, p, r) { if (p < r) { var pivotIndex = randomIntInRange(p, r); var i = p - 1; swap(ary, pivotIndex, r); var pivot = ary[r]; for (var j = p; j < r; j++) { if (comparator(ary[j], pivot) <= 0) { i += 1; swap(ary, i, j); } } swap(ary, i + 1, j); var q = i + 1; doQuickSort(ary, comparator, p, q - 1); doQuickSort(ary, comparator, q + 1, r); } } var quickSort_1 = function (ary, comparator) { doQuickSort(ary, comparator, 0, ary.length - 1); }; var quickSort = { quickSort: quickSort_1 }; var ArraySet$2 = arraySet.ArraySet; var quickSort$1 = quickSort.quickSort; function SourceMapConsumer(aSourceMap, aSourceMapURL) { var sourceMap = aSourceMap; if (typeof aSourceMap === 'string') { sourceMap = util.parseSourceMapInput(aSourceMap); } return sourceMap.sections != null ? new IndexedSourceMapConsumer(sourceMap, aSourceMapURL) : new BasicSourceMapConsumer(sourceMap, aSourceMapURL); } SourceMapConsumer.fromSourceMap = function (aSourceMap, aSourceMapURL) { return BasicSourceMapConsumer.fromSourceMap(aSourceMap, aSourceMapURL); }; SourceMapConsumer.prototype._version = 3; SourceMapConsumer.prototype.__generatedMappings = null; Object.defineProperty(SourceMapConsumer.prototype, '_generatedMappings', { configurable: true, enumerable: true, get: function get() { if (!this.__generatedMappings) { this._parseMappings(this._mappings, this.sourceRoot); } return this.__generatedMappings; } }); SourceMapConsumer.prototype.__originalMappings = null; Object.defineProperty(SourceMapConsumer.prototype, '_originalMappings', { configurable: true, enumerable: true, get: function get() { if (!this.__originalMappings) { this._parseMappings(this._mappings, this.sourceRoot); } return this.__originalMappings; } }); SourceMapConsumer.prototype._charIsMappingSeparator = function SourceMapConsumer_charIsMappingSeparator(aStr, index) { var c = aStr.charAt(index); return c === ";" || c === ","; }; SourceMapConsumer.prototype._parseMappings = function SourceMapConsumer_parseMappings(aStr, aSourceRoot) { throw new Error("Subclasses must implement _parseMappings"); }; SourceMapConsumer.GENERATED_ORDER = 1; SourceMapConsumer.ORIGINAL_ORDER = 2; SourceMapConsumer.GREATEST_LOWER_BOUND = 1; SourceMapConsumer.LEAST_UPPER_BOUND = 2; SourceMapConsumer.prototype.eachMapping = function SourceMapConsumer_eachMapping(aCallback, aContext, aOrder) { var context = aContext || null; var order = aOrder || SourceMapConsumer.GENERATED_ORDER; var mappings; switch (order) { case SourceMapConsumer.GENERATED_ORDER: mappings = this._generatedMappings; break; case SourceMapConsumer.ORIGINAL_ORDER: mappings = this._originalMappings; break; default: throw new Error("Unknown order of iteration."); } var sourceRoot = this.sourceRoot; mappings.map(function (mapping) { var source = mapping.source === null ? null : this._sources.at(mapping.source); source = util.computeSourceURL(sourceRoot, source, this._sourceMapURL); return { source: source, generatedLine: mapping.generatedLine, generatedColumn: mapping.generatedColumn, originalLine: mapping.originalLine, originalColumn: mapping.originalColumn, name: mapping.name === null ? null : this._names.at(mapping.name) }; }, this).forEach(aCallback, context); }; SourceMapConsumer.prototype.allGeneratedPositionsFor = function SourceMapConsumer_allGeneratedPositionsFor(aArgs) { var line = util.getArg(aArgs, 'line'); var needle = { source: util.getArg(aArgs, 'source'), originalLine: line, originalColumn: util.getArg(aArgs, 'column', 0) }; needle.source = this._findSourceIndex(needle.source); if (needle.source < 0) { return []; } var mappings = []; var index = this._findMapping(needle, this._originalMappings, "originalLine", "originalColumn", util.compareByOriginalPositions, binarySearch.LEAST_UPPER_BOUND); if (index >= 0) { var mapping = this._originalMappings[index]; if (aArgs.column === undefined) { var originalLine = mapping.originalLine; while (mapping && mapping.originalLine === originalLine) { mappings.push({ line: util.getArg(mapping, 'generatedLine', null), column: util.getArg(mapping, 'generatedColumn', null), lastColumn: util.getArg(mapping, 'lastGeneratedColumn', null) }); mapping = this._originalMappings[++index]; } } else { var originalColumn = mapping.originalColumn; while (mapping && mapping.originalLine === line && mapping.originalColumn == originalColumn) { mappings.push({ line: util.getArg(mapping, 'generatedLine', null), column: util.getArg(mapping, 'generatedColumn', null), lastColumn: util.getArg(mapping, 'lastGeneratedColumn', null) }); mapping = this._originalMappings[++index]; } } } return mappings; }; var SourceMapConsumer_1 = SourceMapConsumer; function BasicSourceMapConsumer(aSourceMap, aSourceMapURL) { var sourceMap = aSourceMap; if (typeof aSourceMap === 'string') { sourceMap = util.parseSourceMapInput(aSourceMap); } var version = util.getArg(sourceMap, 'version'); var sources = util.getArg(sourceMap, 'sources'); var names = util.getArg(sourceMap, 'names', []); var sourceRoot = util.getArg(sourceMap, 'sourceRoot', null); var sourcesContent = util.getArg(sourceMap, 'sourcesContent', null); var mappings = util.getArg(sourceMap, 'mappings'); var file = util.getArg(sourceMap, 'file', null); if (version != this._version) { throw new Error('Unsupported version: ' + version); } if (sourceRoot) { sourceRoot = util.normalize(sourceRoot); } sources = sources.map(String).map(util.normalize).map(function (source) { return sourceRoot && util.isAbsolute(sourceRoot) && util.isAbsolute(source) ? util.relative(sourceRoot, source) : source; }); this._names = ArraySet$2.fromArray(names.map(String), true); this._sources = ArraySet$2.fromArray(sources, true); this._absoluteSources = this._sources.toArray().map(function (s) { return util.computeSourceURL(sourceRoot, s, aSourceMapURL); }); this.sourceRoot = sourceRoot; this.sourcesContent = sourcesContent; this._mappings = mappings; this._sourceMapURL = aSourceMapURL; this.file = file; } BasicSourceMapConsumer.prototype = Object.create(SourceMapConsumer.prototype); BasicSourceMapConsumer.prototype.consumer = SourceMapConsumer; BasicSourceMapConsumer.prototype._findSourceIndex = function (aSource) { var relativeSource = aSource; if (this.sourceRoot != null) { relativeSource = util.relative(this.sourceRoot, relativeSource); } if (this._sources.has(relativeSource)) { return this._sources.indexOf(relativeSource); } var i; for (i = 0; i < this._absoluteSources.length; ++i) { if (this._absoluteSources[i] == aSource) { return i; } } return -1; }; BasicSourceMapConsumer.fromSourceMap = function SourceMapConsumer_fromSourceMap(aSourceMap, aSourceMapURL) { var smc = Object.create(BasicSourceMapConsumer.prototype); var names = smc._names = ArraySet$2.fromArray(aSourceMap._names.toArray(), true); var sources = smc._sources = ArraySet$2.fromArray(aSourceMap._sources.toArray(), true); smc.sourceRoot = aSourceMap._sourceRoot; smc.sourcesContent = aSourceMap._generateSourcesContent(smc._sources.toArray(), smc.sourceRoot); smc.file = aSourceMap._file; smc._sourceMapURL = aSourceMapURL; smc._absoluteSources = smc._sources.toArray().map(function (s) { return util.computeSourceURL(smc.sourceRoot, s, aSourceMapURL); }); var generatedMappings = aSourceMap._mappings.toArray().slice(); var destGeneratedMappings = smc.__generatedMappings = []; var destOriginalMappings = smc.__originalMappings = []; for (var i = 0, length = generatedMappings.length; i < length; i++) { var srcMapping = generatedMappings[i]; var destMapping = new Mapping(); destMapping.generatedLine = srcMapping.generatedLine; destMapping.generatedColumn = srcMapping.generatedColumn; if (srcMapping.source) { destMapping.source = sources.indexOf(srcMapping.source); destMapping.originalLine = srcMapping.originalLine; destMapping.originalColumn = srcMapping.originalColumn; if (srcMapping.name) { destMapping.name = names.indexOf(srcMapping.name); } destOriginalMappings.push(destMapping); } destGeneratedMappings.push(destMapping); } quickSort$1(smc.__originalMappings, util.compareByOriginalPositions); return smc; }; BasicSourceMapConsumer.prototype._version = 3; Object.defineProperty(BasicSourceMapConsumer.prototype, 'sources', { get: function get() { return this._absoluteSources.slice(); } }); function Mapping() { this.generatedLine = 0; this.generatedColumn = 0; this.source = null; this.originalLine = null; this.originalColumn = null; this.name = null; } BasicSourceMapConsumer.prototype._parseMappings = function SourceMapConsumer_parseMappings(aStr, aSourceRoot) { var generatedLine = 1; var previousGeneratedColumn = 0; var previousOriginalLine = 0; var previousOriginalColumn = 0; var previousSource = 0; var previousName = 0; var length = aStr.length; var index = 0; var cachedSegments = {}; var temp = {}; var originalMappings = []; var generatedMappings = []; var mapping, str, segment, end, value; while (index < length) { if (aStr.charAt(index) === ';') { generatedLine++; index++; previousGeneratedColumn = 0; } else if (aStr.charAt(index) === ',') { index++; } else { mapping = new Mapping(); mapping.generatedLine = generatedLine; for (end = index; end < length; end++) { if (this._charIsMappingSeparator(aStr, end)) { break; } } str = aStr.slice(index, end); segment = cachedSegments[str]; if (segment) { index += str.length; } else { segment = []; while (index < end) { base64Vlq.decode(aStr, index, temp); value = temp.value; index = temp.rest; segment.push(value); } if (segment.length === 2) { throw new Error('Found a source, but no line and column'); } if (segment.length === 3) { throw new Error('Found a source and line, but no column'); } cachedSegments[str] = segment; } mapping.generatedColumn = previousGeneratedColumn + segment[0]; previousGeneratedColumn = mapping.generatedColumn; if (segment.length > 1) { mapping.source = previousSource + segment[1]; previousSource += segment[1]; mapping.originalLine = previousOriginalLine + segment[2]; previousOriginalLine = mapping.originalLine; mapping.originalLine += 1; mapping.originalColumn = previousOriginalColumn + segment[3]; previousOriginalColumn = mapping.originalColumn; if (segment.length > 4) { mapping.name = previousName + segment[4]; previousName += segment[4]; } } generatedMappings.push(mapping); if (typeof mapping.originalLine === 'number') { originalMappings.push(mapping); } } } quickSort$1(generatedMappings, util.compareByGeneratedPositionsDeflated); this.__generatedMappings = generatedMappings; quickSort$1(originalMappings, util.compareByOriginalPositions); this.__originalMappings = originalMappings; }; BasicSourceMapConsumer.prototype._findMapping = function SourceMapConsumer_findMapping(aNeedle, aMappings, aLineName, aColumnName, aComparator, aBias) { if (aNeedle[aLineName] <= 0) { throw new TypeError('Line must be greater than or equal to 1, got ' + aNeedle[aLineName]); } if (aNeedle[aColumnName] < 0) { throw new TypeError('Column must be greater than or equal to 0, got ' + aNeedle[aColumnName]); } return binarySearch.search(aNeedle, aMappings, aComparator, aBias); }; BasicSourceMapConsumer.prototype.computeColumnSpans = function SourceMapConsumer_computeColumnSpans() { for (var index = 0; index < this._generatedMappings.length; ++index) { var mapping = this._generatedMappings[index]; if (index + 1 < this._generatedMappings.length) { var nextMapping = this._generatedMappings[index + 1]; if (mapping.generatedLine === nextMapping.generatedLine) { mapping.lastGeneratedColumn = nextMapping.generatedColumn - 1; continue; } } mapping.lastGeneratedColumn = Infinity; } }; BasicSourceMapConsumer.prototype.originalPositionFor = function SourceMapConsumer_originalPositionFor(aArgs) { var needle = { generatedLine: util.getArg(aArgs, 'line'), generatedColumn: util.getArg(aArgs, 'column') }; var index = this._findMapping(needle, this._generatedMappings, "generatedLine", "generatedColumn", util.compareByGeneratedPositionsDeflated, util.getArg(aArgs, 'bias', SourceMapConsumer.GREATEST_LOWER_BOUND)); if (index >= 0) { var mapping = this._generatedMappings[index]; if (mapping.generatedLine === needle.generatedLine) { var source = util.getArg(mapping, 'source', null); if (source !== null) { source = this._sources.at(source); source = util.computeSourceURL(this.sourceRoot, source, this._sourceMapURL); } var name = util.getArg(mapping, 'name', null); if (name !== null) { name = this._names.at(name); } return { source: source, line: util.getArg(mapping, 'originalLine', null), column: util.getArg(mapping, 'originalColumn', null), name: name }; } } return { source: null, line: null, column: null, name: null }; }; BasicSourceMapConsumer.prototype.hasContentsOfAllSources = function BasicSourceMapConsumer_hasContentsOfAllSources() { if (!this.sourcesContent) { return false; } return this.sourcesContent.length >= this._sources.size() && !this.sourcesContent.some(function (sc) { return sc == null; }); }; BasicSourceMapConsumer.prototype.sourceContentFor = function SourceMapConsumer_sourceContentFor(aSource, nullOnMissing) { if (!this.sourcesContent) { return null; } var index = this._findSourceIndex(aSource); if (index >= 0) { return this.sourcesContent[index]; } var relativeSource = aSource; if (this.sourceRoot != null) { relativeSource = util.relative(this.sourceRoot, relativeSource); } var url; if (this.sourceRoot != null && (url = util.urlParse(this.sourceRoot))) { var fileUriAbsPath = relativeSource.replace(/^file:\/\//, ""); if (url.scheme == "file" && this._sources.has(fileUriAbsPath)) { return this.sourcesContent[this._sources.indexOf(fileUriAbsPath)]; } if ((!url.path || url.path == "/") && this._sources.has("/" + relativeSource)) { return this.sourcesContent[this._sources.indexOf("/" + relativeSource)]; } } if (nullOnMissing) { return null; } else { throw new Error('"' + relativeSource + '" is not in the SourceMap.'); } }; BasicSourceMapConsumer.prototype.generatedPositionFor = function SourceMapConsumer_generatedPositionFor(aArgs) { var source = util.getArg(aArgs, 'source'); source = this._findSourceIndex(source); if (source < 0) { return { line: null, column: null, lastColumn: null }; } var needle = { source: source, originalLine: util.getArg(aArgs, 'line'), originalColumn: util.getArg(aArgs, 'column') }; var index = this._findMapping(needle, this._originalMappings, "originalLine", "originalColumn", util.compareByOriginalPositions, util.getArg(aArgs, 'bias', SourceMapConsumer.GREATEST_LOWER_BOUND)); if (index >= 0) { var mapping = this._originalMappings[index]; if (mapping.source === needle.source) { return { line: util.getArg(mapping, 'generatedLine', null), column: util.getArg(mapping, 'generatedColumn', null), lastColumn: util.getArg(mapping, 'lastGeneratedColumn', null) }; } } return { line: null, column: null, lastColumn: null }; }; var BasicSourceMapConsumer_1 = BasicSourceMapConsumer; function IndexedSourceMapConsumer(aSourceMap, aSourceMapURL) { var sourceMap = aSourceMap; if (typeof aSourceMap === 'string') { sourceMap = util.parseSourceMapInput(aSourceMap); } var version = util.getArg(sourceMap, 'version'); var sections = util.getArg(sourceMap, 'sections'); if (version != this._version) { throw new Error('Unsupported version: ' + version); } this._sources = new ArraySet$2(); this._names = new ArraySet$2(); var lastOffset = { line: -1, column: 0 }; this._sections = sections.map(function (s) { if (s.url) { throw new Error('Support for url field in sections not implemented.'); } var offset = util.getArg(s, 'offset'); var offsetLine = util.getArg(offset, 'line'); var offsetColumn = util.getArg(offset, 'column'); if (offsetLine < lastOffset.line || offsetLine === lastOffset.line && offsetColumn < lastOffset.column) { throw new Error('Section offsets must be ordered and non-overlapping.'); } lastOffset = offset; return { generatedOffset: { generatedLine: offsetLine + 1, generatedColumn: offsetColumn + 1 }, consumer: new SourceMapConsumer(util.getArg(s, 'map'), aSourceMapURL) }; }); } IndexedSourceMapConsumer.prototype = Object.create(SourceMapConsumer.prototype); IndexedSourceMapConsumer.prototype.constructor = SourceMapConsumer; IndexedSourceMapConsumer.prototype._version = 3; Object.defineProperty(IndexedSourceMapConsumer.prototype, 'sources', { get: function get() { var sources = []; for (var i = 0; i < this._sections.length; i++) { for (var j = 0; j < this._sections[i].consumer.sources.length; j++) { sources.push(this._sections[i].consumer.sources[j]); } } return sources; } }); IndexedSourceMapConsumer.prototype.originalPositionFor = function IndexedSourceMapConsumer_originalPositionFor(aArgs) { var needle = { generatedLine: util.getArg(aArgs, 'line'), generatedColumn: util.getArg(aArgs, 'column') }; var sectionIndex = binarySearch.search(needle, this._sections, function (needle, section) { var cmp = needle.generatedLine - section.generatedOffset.generatedLine; if (cmp) { return cmp; } return needle.generatedColumn - section.generatedOffset.generatedColumn; }); var section = this._sections[sectionIndex]; if (!section) { return { source: null, line: null, column: null, name: null }; } return section.consumer.originalPositionFor({ line: needle.generatedLine - (section.generatedOffset.generatedLine - 1), column: needle.generatedColumn - (section.generatedOffset.generatedLine === needle.generatedLine ? section.generatedOffset.generatedColumn - 1 : 0), bias: aArgs.bias }); }; IndexedSourceMapConsumer.prototype.hasContentsOfAllSources = function IndexedSourceMapConsumer_hasContentsOfAllSources() { return this._sections.every(function (s) { return s.consumer.hasContentsOfAllSources(); }); }; IndexedSourceMapConsumer.prototype.sourceContentFor = function IndexedSourceMapConsumer_sourceContentFor(aSource, nullOnMissing) { for (var i = 0; i < this._sections.length; i++) { var section = this._sections[i]; var content = section.consumer.sourceContentFor(aSource, true); if (content) { return content; } } if (nullOnMissing) { return null; } else { throw new Error('"' + aSource + '" is not in the SourceMap.'); } }; IndexedSourceMapConsumer.prototype.generatedPositionFor = function IndexedSourceMapConsumer_generatedPositionFor(aArgs) { for (var i = 0; i < this._sections.length; i++) { var section = this._sections[i]; if (section.consumer._findSourceIndex(util.getArg(aArgs, 'source')) === -1) { continue; } var generatedPosition = section.consumer.generatedPositionFor(aArgs); if (generatedPosition) { var ret = { line: generatedPosition.line + (section.generatedOffset.generatedLine - 1), column: generatedPosition.column + (section.generatedOffset.generatedLine === generatedPosition.line ? section.generatedOffset.generatedColumn - 1 : 0) }; return ret; } } return { line: null, column: null }; }; IndexedSourceMapConsumer.prototype._parseMappings = function IndexedSourceMapConsumer_parseMappings(aStr, aSourceRoot) { this.__generatedMappings = []; this.__originalMappings = []; for (var i = 0; i < this._sections.length; i++) { var section = this._sections[i]; var sectionMappings = section.consumer._generatedMappings; for (var j = 0; j < sectionMappings.length; j++) { var mapping = sectionMappings[j]; var source = section.consumer._sources.at(mapping.source); source = util.computeSourceURL(section.consumer.sourceRoot, source, this._sourceMapURL); this._sources.add(source); source = this._sources.indexOf(source); var name = null; if (mapping.name) { name = section.consumer._names.at(mapping.name); this._names.add(name); name = this._names.indexOf(name); } var adjustedMapping = { source: source, generatedLine: mapping.generatedLine + (section.generatedOffset.generatedLine - 1), generatedColumn: mapping.generatedColumn + (section.generatedOffset.generatedLine === mapping.generatedLine ? section.generatedOffset.generatedColumn - 1 : 0), originalLine: mapping.originalLine, originalColumn: mapping.originalColumn, name: name }; this.__generatedMappings.push(adjustedMapping); if (typeof adjustedMapping.originalLine === 'number') { this.__originalMappings.push(adjustedMapping); } } } quickSort$1(this.__generatedMappings, util.compareByGeneratedPositionsDeflated); quickSort$1(this.__originalMappings, util.compareByOriginalPositions); }; var IndexedSourceMapConsumer_1 = IndexedSourceMapConsumer; var sourceMapConsumer = { SourceMapConsumer: SourceMapConsumer_1, BasicSourceMapConsumer: BasicSourceMapConsumer_1, IndexedSourceMapConsumer: IndexedSourceMapConsumer_1 }; var SourceMapGenerator$1 = sourceMapGenerator.SourceMapGenerator; var REGEX_NEWLINE = /(\r?\n)/; var NEWLINE_CODE = 10; var isSourceNode = "$$$isSourceNode$$$"; function SourceNode(aLine, aColumn, aSource, aChunks, aName) { this.children = []; this.sourceContents = {}; this.line = aLine == null ? null : aLine; this.column = aColumn == null ? null : aColumn; this.source = aSource == null ? null : aSource; this.name = aName == null ? null : aName; this[isSourceNode] = true; if (aChunks != null) this.add(aChunks); } SourceNode.fromStringWithSourceMap = function SourceNode_fromStringWithSourceMap(aGeneratedCode, aSourceMapConsumer, aRelativePath) { var node = new SourceNode(); var remainingLines = aGeneratedCode.split(REGEX_NEWLINE); var remainingLinesIndex = 0; var shiftNextLine = function shiftNextLine() { var lineContents = getNextLine(); var newLine = getNextLine() || ""; return lineContents + newLine; function getNextLine() { return remainingLinesIndex < remainingLines.length ? remainingLines[remainingLinesIndex++] : undefined; } }; var lastGeneratedLine = 1, lastGeneratedColumn = 0; var lastMapping = null; aSourceMapConsumer.eachMapping(function (mapping) { if (lastMapping !== null) { if (lastGeneratedLine < mapping.generatedLine) { addMappingWithCode(lastMapping, shiftNextLine()); lastGeneratedLine++; lastGeneratedColumn = 0; } else { var nextLine = remainingLines[remainingLinesIndex] || ''; var code = nextLine.substr(0, mapping.generatedColumn - lastGeneratedColumn); remainingLines[remainingLinesIndex] = nextLine.substr(mapping.generatedColumn - lastGeneratedColumn); lastGeneratedColumn = mapping.generatedColumn; addMappingWithCode(lastMapping, code); lastMapping = mapping; return; } } while (lastGeneratedLine < mapping.generatedLine) { node.add(shiftNextLine()); lastGeneratedLine++; } if (lastGeneratedColumn < mapping.generatedColumn) { var nextLine = remainingLines[remainingLinesIndex] || ''; node.add(nextLine.substr(0, mapping.generatedColumn)); remainingLines[remainingLinesIndex] = nextLine.substr(mapping.generatedColumn); lastGeneratedColumn = mapping.generatedColumn; } lastMapping = mapping; }, this); if (remainingLinesIndex < remainingLines.length) { if (lastMapping) { addMappingWithCode(lastMapping, shiftNextLine()); } node.add(remainingLines.splice(remainingLinesIndex).join("")); } aSourceMapConsumer.sources.forEach(function (sourceFile) { var content = aSourceMapConsumer.sourceContentFor(sourceFile); if (content != null) { if (aRelativePath != null) { sourceFile = util.join(aRelativePath, sourceFile); } node.setSourceContent(sourceFile, content); } }); return node; function addMappingWithCode(mapping, code) { if (mapping === null || mapping.source === undefined) { node.add(code); } else { var source = aRelativePath ? util.join(aRelativePath, mapping.source) : mapping.source; node.add(new SourceNode(mapping.originalLine, mapping.originalColumn, source, code, mapping.name)); } } }; SourceNode.prototype.add = function SourceNode_add(aChunk) { if (Array.isArray(aChunk)) { aChunk.forEach(function (chunk) { this.add(chunk); }, this); } else if (aChunk[isSourceNode] || typeof aChunk === "string") { if (aChunk) { this.children.push(aChunk); } } else { throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got " + aChunk); } return this; }; SourceNode.prototype.prepend = function SourceNode_prepend(aChunk) { if (Array.isArray(aChunk)) { for (var i = aChunk.length - 1; i >= 0; i--) { this.prepend(aChunk[i]); } } else if (aChunk[isSourceNode] || typeof aChunk === "string") { this.children.unshift(aChunk); } else { throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got " + aChunk); } return this; }; SourceNode.prototype.walk = function SourceNode_walk(aFn) { var chunk; for (var i = 0, len = this.children.length; i < len; i++) { chunk = this.children[i]; if (chunk[isSourceNode]) { chunk.walk(aFn); } else { if (chunk !== '') { aFn(chunk, { source: this.source, line: this.line, column: this.column, name: this.name }); } } } }; SourceNode.prototype.join = function SourceNode_join(aSep) { var newChildren; var i; var len = this.children.length; if (len > 0) { newChildren = []; for (i = 0; i < len - 1; i++) { newChildren.push(this.children[i]); newChildren.push(aSep); } newChildren.push(this.children[i]); this.children = newChildren; } return this; }; SourceNode.prototype.replaceRight = function SourceNode_replaceRight(aPattern, aReplacement) { var lastChild = this.children[this.children.length - 1]; if (lastChild[isSourceNode]) { lastChild.replaceRight(aPattern, aReplacement); } else if (typeof lastChild === 'string') { this.children[this.children.length - 1] = lastChild.replace(aPattern, aReplacement); } else { this.children.push(''.replace(aPattern, aReplacement)); } return this; }; SourceNode.prototype.setSourceContent = function SourceNode_setSourceContent(aSourceFile, aSourceContent) { this.sourceContents[util.toSetString(aSourceFile)] = aSourceContent; }; SourceNode.prototype.walkSourceContents = function SourceNode_walkSourceContents(aFn) { for (var i = 0, len = this.children.length; i < len; i++) { if (this.children[i][isSourceNode]) { this.children[i].walkSourceContents(aFn); } } var sources = Object.keys(this.sourceContents); for (var i = 0, len = sources.length; i < len; i++) { aFn(util.fromSetString(sources[i]), this.sourceContents[sources[i]]); } }; SourceNode.prototype.toString = function SourceNode_toString() { var str = ""; this.walk(function (chunk) { str += chunk; }); return str; }; SourceNode.prototype.toStringWithSourceMap = function SourceNode_toStringWithSourceMap(aArgs) { var generated = { code: "", line: 1, column: 0 }; var map = new SourceMapGenerator$1(aArgs); var sourceMappingActive = false; var lastOriginalSource = null; var lastOriginalLine = null; var lastOriginalColumn = null; var lastOriginalName = null; this.walk(function (chunk, original) { generated.code += chunk; if (original.source !== null && original.line !== null && original.column !== null) { if (lastOriginalSource !== original.source || lastOriginalLine !== original.line || lastOriginalColumn !== original.column || lastOriginalName !== original.name) { map.addMapping({ source: original.source, original: { line: original.line, column: original.column }, generated: { line: generated.line, column: generated.column }, name: original.name }); } lastOriginalSource = original.source; lastOriginalLine = original.line; lastOriginalColumn = original.column; lastOriginalName = original.name; sourceMappingActive = true; } else if (sourceMappingActive) { map.addMapping({ generated: { line: generated.line, column: generated.column } }); lastOriginalSource = null; sourceMappingActive = false; } for (var idx = 0, length = chunk.length; idx < length; idx++) { if (chunk.charCodeAt(idx) === NEWLINE_CODE) { generated.line++; generated.column = 0; if (idx + 1 === length) { lastOriginalSource = null; sourceMappingActive = false; } else if (sourceMappingActive) { map.addMapping({ source: original.source, original: { line: original.line, column: original.column }, generated: { line: generated.line, column: generated.column }, name: original.name }); } } else { generated.column++; } } }); this.walkSourceContents(function (sourceFile, sourceContent) { map.setSourceContent(sourceFile, sourceContent); }); return { code: generated.code, map: map }; }; var SourceNode_1 = SourceNode; var sourceNode = { SourceNode: SourceNode_1 }; var SourceMapGenerator$2 = sourceMapGenerator.SourceMapGenerator; var SourceMapConsumer$1 = sourceMapConsumer.SourceMapConsumer; var SourceNode$1 = sourceNode.SourceNode; var sourceMap = { SourceMapGenerator: SourceMapGenerator$2, SourceMapConsumer: SourceMapConsumer$1, SourceNode: SourceNode$1 }; var SourceMap = function () { function SourceMap(opts, code) { this._cachedMap = null; this._code = code; this._opts = opts; this._rawMappings = []; } var _proto = SourceMap.prototype; _proto.get = function get() { if (!this._cachedMap) { var map = this._cachedMap = new sourceMap.SourceMapGenerator({ sourceRoot: this._opts.sourceRoot }); var code = this._code; if (typeof code === "string") { map.setSourceContent(this._opts.sourceFileName.replace(/\\/g, "/"), code); } else if (typeof code === "object") { Object.keys(code).forEach(function (sourceFileName) { map.setSourceContent(sourceFileName.replace(/\\/g, "/"), code[sourceFileName]); }); } this._rawMappings.forEach(function (mapping) { return map.addMapping(mapping); }, map); } return this._cachedMap.toJSON(); }; _proto.getRawMappings = function getRawMappings() { return this._rawMappings.slice(); }; _proto.mark = function mark(generatedLine, generatedColumn, line, column, identifierName, filename, force) { if (this._lastGenLine !== generatedLine && line === null) return; if (!force && this._lastGenLine === generatedLine && this._lastSourceLine === line && this._lastSourceColumn === column) { return; } this._cachedMap = null; this._lastGenLine = generatedLine; this._lastSourceLine = line; this._lastSourceColumn = column; this._rawMappings.push({ name: identifierName || undefined, generated: { line: generatedLine, column: generatedColumn }, source: line == null ? undefined : (filename || this._opts.sourceFileName).replace(/\\/g, "/"), original: line == null ? undefined : { line: line, column: column } }); }; return SourceMap; }(); function isInteger(value) { return typeof value == 'number' && value == toInteger_1(value); } var isInteger_1 = isInteger; var SPACES_RE = /^[ \t]+$/; var Buffer = function () { function Buffer(map) { this._map = null; this._buf = []; this._last = ""; this._queue = []; this._position = { line: 1, column: 0 }; this._sourcePosition = { identifierName: null, line: null, column: null, filename: null }; this._disallowedPop = null; this._map = map; } var _proto = Buffer.prototype; _proto.get = function get() { this._flush(); var map = this._map; var result = { code: this._buf.join("").trimRight(), map: null, rawMappings: map && map.getRawMappings() }; if (map) { Object.defineProperty(result, "map", { configurable: true, enumerable: true, get: function get() { return this.map = map.get(); }, set: function set(value) { Object.defineProperty(this, "map", { value: value, writable: true }); } }); } return result; }; _proto.append = function append(str) { this._flush(); var _this$_sourcePosition = this._sourcePosition, line = _this$_sourcePosition.line, column = _this$_sourcePosition.column, filename = _this$_sourcePosition.filename, identifierName = _this$_sourcePosition.identifierName, force = _this$_sourcePosition.force; this._append(str, line, column, identifierName, filename, force); }; _proto.queue = function queue(str) { if (str === "\n") { while (this._queue.length > 0 && SPACES_RE.test(this._queue[0][0])) { this._queue.shift(); } } var _this$_sourcePosition2 = this._sourcePosition, line = _this$_sourcePosition2.line, column = _this$_sourcePosition2.column, filename = _this$_sourcePosition2.filename, identifierName = _this$_sourcePosition2.identifierName, force = _this$_sourcePosition2.force; this._queue.unshift([str, line, column, identifierName, filename, force]); }; _proto._flush = function _flush() { var item; while (item = this._queue.pop()) { this._append.apply(this, item); } }; _proto._append = function _append(str, line, column, identifierName, filename, force) { if (this._map && str[0] !== "\n") { this._map.mark(this._position.line, this._position.column, line, column, identifierName, filename, force); } this._buf.push(str); this._last = str[str.length - 1]; for (var i = 0; i < str.length; i++) { if (str[i] === "\n") { this._position.line++; this._position.column = 0; } else { this._position.column++; } } }; _proto.removeTrailingNewline = function removeTrailingNewline() { if (this._queue.length > 0 && this._queue[0][0] === "\n") { this._queue.shift(); } }; _proto.removeLastSemicolon = function removeLastSemicolon() { if (this._queue.length > 0 && this._queue[0][0] === ";") { this._queue.shift(); } }; _proto.endsWith = function endsWith(suffix) { if (suffix.length === 1) { var last; if (this._queue.length > 0) { var str = this._queue[0][0]; last = str[str.length - 1]; } else { last = this._last; } return last === suffix; } var end = this._last + this._queue.reduce(function (acc, item) { return item[0] + acc; }, ""); if (suffix.length <= end.length) { return end.slice(-suffix.length) === suffix; } return false; }; _proto.hasContent = function hasContent() { return this._queue.length > 0 || !!this._last; }; _proto.exactSource = function exactSource(loc, cb) { this.source("start", loc, true); cb(); this.source("end", loc); this._disallowPop("start", loc); }; _proto.source = function source(prop, loc, force) { if (prop && !loc) return; this._normalizePosition(prop, loc, this._sourcePosition, force); }; _proto.withSource = function withSource(prop, loc, cb) { if (!this._map) return cb(); var originalLine = this._sourcePosition.line; var originalColumn = this._sourcePosition.column; var originalFilename = this._sourcePosition.filename; var originalIdentifierName = this._sourcePosition.identifierName; this.source(prop, loc); cb(); if ((!this._sourcePosition.force || this._sourcePosition.line !== originalLine || this._sourcePosition.column !== originalColumn || this._sourcePosition.filename !== originalFilename) && (!this._disallowedPop || this._disallowedPop.line !== originalLine || this._disallowedPop.column !== originalColumn || this._disallowedPop.filename !== originalFilename)) { this._sourcePosition.line = originalLine; this._sourcePosition.column = originalColumn; this._sourcePosition.filename = originalFilename; this._sourcePosition.identifierName = originalIdentifierName; this._sourcePosition.force = false; this._disallowedPop = null; } }; _proto._disallowPop = function _disallowPop(prop, loc) { if (prop && !loc) return; this._disallowedPop = this._normalizePosition(prop, loc); }; _proto._normalizePosition = function _normalizePosition(prop, loc, targetObj, force) { var pos = loc ? loc[prop] : null; if (targetObj === undefined) { targetObj = { identifierName: null, line: null, column: null, filename: null, force: false }; } var origLine = targetObj.line; var origColumn = targetObj.column; var origFilename = targetObj.filename; targetObj.identifierName = prop === "start" && loc && loc.identifierName || null; targetObj.line = pos ? pos.line : null; targetObj.column = pos ? pos.column : null; targetObj.filename = loc && loc.filename || null; if (force || targetObj.line !== origLine || targetObj.column !== origColumn || targetObj.filename !== origFilename) { targetObj.force = force; } return targetObj; }; _proto.getCurrentColumn = function getCurrentColumn() { var extra = this._queue.reduce(function (acc, item) { return item[0] + acc; }, ""); var lastIndex = extra.lastIndexOf("\n"); return lastIndex === -1 ? this._position.column + extra.length : extra.length - 1 - lastIndex; }; _proto.getCurrentLine = function getCurrentLine() { var extra = this._queue.reduce(function (acc, item) { return item[0] + acc; }, ""); var count = 0; for (var i = 0; i < extra.length; i++) { if (extra[i] === "\n") count++; } return this._position.line + count; }; return Buffer; }(); function crawl(node, state) { if (state === void 0) { state = {}; } if (isMemberExpression(node)) { crawl(node.object, state); if (node.computed) crawl(node.property, state); } else if (isBinary(node) || isAssignmentExpression(node)) { crawl(node.left, state); crawl(node.right, state); } else if (isCallExpression(node)) { state.hasCall = true; crawl(node.callee, state); } else if (isFunction(node)) { state.hasFunction = true; } else if (isIdentifier(node)) { state.hasHelper = state.hasHelper || isHelper(node.callee); } return state; } function isHelper(node) { if (isMemberExpression(node)) { return isHelper(node.object) || isHelper(node.property); } else if (isIdentifier(node)) { return node.name === "require" || node.name[0] === "_"; } else if (isCallExpression(node)) { return isHelper(node.callee); } else if (isBinary(node) || isAssignmentExpression(node)) { return isIdentifier(node.left) && isHelper(node.left) || isHelper(node.right); } else { return false; } } function isType$1(node) { return isLiteral(node) || isObjectExpression(node) || isArrayExpression(node) || isIdentifier(node) || isMemberExpression(node); } var nodes = { AssignmentExpression: function AssignmentExpression(node) { var state = crawl(node.right); if (state.hasCall && state.hasHelper || state.hasFunction) { return { before: state.hasFunction, after: true }; } }, SwitchCase: function SwitchCase(node, parent) { return { before: node.consequent.length || parent.cases[0] === node, after: !node.consequent.length && parent.cases[parent.cases.length - 1] === node }; }, LogicalExpression: function LogicalExpression(node) { if (isFunction(node.left) || isFunction(node.right)) { return { after: true }; } }, Literal: function Literal(node) { if (node.value === "use strict") { return { after: true }; } }, CallExpression: function CallExpression(node) { if (isFunction(node.callee) || isHelper(node)) { return { before: true, after: true }; } }, VariableDeclaration: function VariableDeclaration(node) { for (var i = 0; i < node.declarations.length; i++) { var declar = node.declarations[i]; var enabled = isHelper(declar.id) && !isType$1(declar.init); if (!enabled) { var state = crawl(declar.init); enabled = isHelper(declar.init) && state.hasCall || state.hasFunction; } if (enabled) { return { before: true, after: true }; } } }, IfStatement: function IfStatement(node) { if (isBlockStatement(node.consequent)) { return { before: true, after: true }; } } }; nodes.ObjectProperty = nodes.ObjectTypeProperty = nodes.ObjectMethod = function (node, parent) { if (parent.properties[0] === node) { return { before: true }; } }; nodes.ObjectTypeCallProperty = function (node, parent) { if (parent.callProperties[0] === node && (!parent.properties || !parent.properties.length)) { return { before: true }; } }; nodes.ObjectTypeIndexer = function (node, parent) { if (parent.indexers[0] === node && (!parent.properties || !parent.properties.length) && (!parent.callProperties || !parent.callProperties.length)) { return { before: true }; } }; nodes.ObjectTypeInternalSlot = function (node, parent) { if (parent.internalSlots[0] === node && (!parent.properties || !parent.properties.length) && (!parent.callProperties || !parent.callProperties.length) && (!parent.indexers || !parent.indexers.length)) { return { before: true }; } }; var list = { VariableDeclaration: function VariableDeclaration(node) { return node.declarations.map(function (decl) { return decl.init; }); }, ArrayExpression: function ArrayExpression(node) { return node.elements; }, ObjectExpression: function ObjectExpression(node) { return node.properties; } }; [["Function", true], ["Class", true], ["Loop", true], ["LabeledStatement", true], ["SwitchStatement", true], ["TryStatement", true]].forEach(function (_ref) { var type = _ref[0], amounts = _ref[1]; if (typeof amounts === "boolean") { amounts = { after: amounts, before: amounts }; } [type].concat(FLIPPED_ALIAS_KEYS[type] || []).forEach(function (type) { nodes[type] = function () { return amounts; }; }); }); var PRECEDENCE = { "||": 0, "&&": 1, "|": 2, "^": 3, "&": 4, "==": 5, "===": 5, "!=": 5, "!==": 5, "<": 6, ">": 6, "<=": 6, ">=": 6, "in": 6, "instanceof": 6, ">>": 7, "<<": 7, ">>>": 7, "+": 8, "-": 8, "*": 9, "/": 9, "%": 9, "**": 10 }; var isClassExtendsClause = function isClassExtendsClause(node, parent) { return (isClassDeclaration(parent) || isClassExpression(parent)) && parent.superClass === node; }; function NullableTypeAnnotation$1(node, parent) { return isArrayTypeAnnotation(parent); } function FunctionTypeAnnotation$1(node, parent, printStack) { return isUnionTypeAnnotation(parent) || isIntersectionTypeAnnotation(parent) || isArrayTypeAnnotation(parent) || isTypeAnnotation(parent) && isArrowFunctionExpression(printStack[printStack.length - 3]); } function UpdateExpression$1(node, parent) { return isMemberExpression(parent, { object: node }) || isCallExpression(parent, { callee: node }) || isNewExpression(parent, { callee: node }) || isClassExtendsClause(node, parent); } function ObjectExpression$1(node, parent, printStack) { return isFirstInStatement(printStack, { considerArrow: true }); } function DoExpression$1(node, parent, printStack) { return isFirstInStatement(printStack); } function Binary(node, parent) { if (node.operator === "**" && isBinaryExpression(parent, { operator: "**" })) { return parent.left === node; } if (isClassExtendsClause(node, parent)) { return true; } if ((isCallExpression(parent) || isNewExpression(parent)) && parent.callee === node || isUnaryLike(parent) || isMemberExpression(parent) && parent.object === node || isAwaitExpression(parent)) { return true; } if (isBinary(parent)) { var parentOp = parent.operator; var parentPos = PRECEDENCE[parentOp]; var nodeOp = node.operator; var nodePos = PRECEDENCE[nodeOp]; if (parentPos === nodePos && parent.right === node && !isLogicalExpression(parent) || parentPos > nodePos) { return true; } } return false; } function UnionTypeAnnotation$1(node, parent) { return isArrayTypeAnnotation(parent) || isNullableTypeAnnotation(parent) || isIntersectionTypeAnnotation(parent) || isUnionTypeAnnotation(parent); } function TSAsExpression$1() { return true; } function TSTypeAssertion$1() { return true; } function TSUnionType$1(node, parent) { return isTSArrayType(parent) || isTSOptionalType(parent) || isTSIntersectionType(parent) || isTSUnionType(parent) || isTSRestType(parent); } function BinaryExpression$1(node, parent) { return node.operator === "in" && (isVariableDeclarator(parent) || isFor(parent)); } function SequenceExpression$1(node, parent) { if (isForStatement(parent) || isThrowStatement(parent) || isReturnStatement(parent) || isIfStatement(parent) && parent.test === node || isWhileStatement(parent) && parent.test === node || isForInStatement(parent) && parent.right === node || isSwitchStatement(parent) && parent.discriminant === node || isExpressionStatement(parent) && parent.expression === node) { return false; } return true; } function YieldExpression$1(node, parent) { return isBinary(parent) || isUnaryLike(parent) || isCallExpression(parent) || isMemberExpression(parent) || isNewExpression(parent) || isAwaitExpression(parent) && isYieldExpression(node) || isConditionalExpression(parent) && node === parent.test || isClassExtendsClause(node, parent); } function ClassExpression$1(node, parent, printStack) { return isFirstInStatement(printStack, { considerDefaultExports: true }); } function UnaryLike(node, parent) { return isMemberExpression(parent, { object: node }) || isCallExpression(parent, { callee: node }) || isNewExpression(parent, { callee: node }) || isBinaryExpression(parent, { operator: "**", left: node }) || isClassExtendsClause(node, parent); } function FunctionExpression$1(node, parent, printStack) { return isFirstInStatement(printStack, { considerDefaultExports: true }); } function ArrowFunctionExpression$1(node, parent) { return isExportDeclaration(parent) || ConditionalExpression$1(node, parent); } function ConditionalExpression$1(node, parent) { if (isUnaryLike(parent) || isBinary(parent) || isConditionalExpression(parent, { test: node }) || isAwaitExpression(parent) || isOptionalMemberExpression(parent) || isTaggedTemplateExpression(parent) || isTSTypeAssertion(parent) || isTSAsExpression(parent)) { return true; } return UnaryLike(node, parent); } function OptionalMemberExpression$1(node, parent) { return isCallExpression(parent) || isMemberExpression(parent); } function AssignmentExpression$1(node) { if (isObjectPattern(node.left)) { return true; } else { return ConditionalExpression$1.apply(void 0, arguments); } } function NewExpression$1(node, parent) { return isClassExtendsClause(node, parent); } function isFirstInStatement(printStack, _temp) { var _ref = _temp === void 0 ? {} : _temp, _ref$considerArrow = _ref.considerArrow, considerArrow = _ref$considerArrow === void 0 ? false : _ref$considerArrow, _ref$considerDefaultE = _ref.considerDefaultExports, considerDefaultExports = _ref$considerDefaultE === void 0 ? false : _ref$considerDefaultE; var i = printStack.length - 1; var node = printStack[i]; i--; var parent = printStack[i]; while (i > 0) { if (isExpressionStatement(parent, { expression: node }) || isTaggedTemplateExpression(parent) || considerDefaultExports && isExportDefaultDeclaration(parent, { declaration: node }) || considerArrow && isArrowFunctionExpression(parent, { body: node })) { return true; } if (isCallExpression(parent, { callee: node }) || isSequenceExpression(parent) && parent.expressions[0] === node || isMemberExpression(parent, { object: node }) || isConditional(parent, { test: node }) || isBinary(parent, { left: node }) || isAssignmentExpression(parent, { left: node })) { node = parent; i--; parent = printStack[i]; } else { return false; } } return false; } var parens = /*#__PURE__*/Object.freeze({ __proto__: null, NullableTypeAnnotation: NullableTypeAnnotation$1, FunctionTypeAnnotation: FunctionTypeAnnotation$1, UpdateExpression: UpdateExpression$1, ObjectExpression: ObjectExpression$1, DoExpression: DoExpression$1, Binary: Binary, UnionTypeAnnotation: UnionTypeAnnotation$1, IntersectionTypeAnnotation: UnionTypeAnnotation$1, TSAsExpression: TSAsExpression$1, TSTypeAssertion: TSTypeAssertion$1, TSUnionType: TSUnionType$1, TSIntersectionType: TSUnionType$1, BinaryExpression: BinaryExpression$1, SequenceExpression: SequenceExpression$1, YieldExpression: YieldExpression$1, AwaitExpression: YieldExpression$1, ClassExpression: ClassExpression$1, UnaryLike: UnaryLike, FunctionExpression: FunctionExpression$1, ArrowFunctionExpression: ArrowFunctionExpression$1, ConditionalExpression: ConditionalExpression$1, OptionalMemberExpression: OptionalMemberExpression$1, AssignmentExpression: AssignmentExpression$1, NewExpression: NewExpression$1 }); function expandAliases(obj) { var newObj = {}; function add(type, func) { var fn = newObj[type]; newObj[type] = fn ? function (node, parent, stack) { var result = fn(node, parent, stack); return result == null ? func(node, parent, stack) : result; } : func; } for (var _i = 0, _Object$keys = Object.keys(obj); _i < _Object$keys.length; _i++) { var type = _Object$keys[_i]; var aliases = FLIPPED_ALIAS_KEYS[type]; if (aliases) { for (var _iterator = aliases, _isArray = Array.isArray(_iterator), _i2 = 0, _iterator = _isArray ? _iterator : _iterator[Symbol.iterator]();;) { var _ref; if (_isArray) { if (_i2 >= _iterator.length) break; _ref = _iterator[_i2++]; } else { _i2 = _iterator.next(); if (_i2.done) break; _ref = _i2.value; } var alias = _ref; add(alias, obj[type]); } } else { add(type, obj[type]); } } return newObj; } var expandedParens = expandAliases(parens); var expandedWhitespaceNodes = expandAliases(nodes); var expandedWhitespaceList = expandAliases(list); function find(obj, node, parent, printStack) { var fn = obj[node.type]; return fn ? fn(node, parent, printStack) : null; } function isOrHasCallExpression(node) { if (isCallExpression(node)) { return true; } if (isMemberExpression(node)) { return isOrHasCallExpression(node.object) || !node.computed && isOrHasCallExpression(node.property); } else { return false; } } function needsWhitespace(node, parent, type) { if (!node) return 0; if (isExpressionStatement(node)) { node = node.expression; } var linesInfo = find(expandedWhitespaceNodes, node, parent); if (!linesInfo) { var items = find(expandedWhitespaceList, node, parent); if (items) { for (var i = 0; i < items.length; i++) { linesInfo = needsWhitespace(items[i], node, type); if (linesInfo) break; } } } if (typeof linesInfo === "object" && linesInfo !== null) { return linesInfo[type] || 0; } return 0; } function needsWhitespaceBefore(node, parent) { return needsWhitespace(node, parent, "before"); } function needsWhitespaceAfter(node, parent) { return needsWhitespace(node, parent, "after"); } function needsParens(node, parent, printStack) { if (!parent) return false; if (isNewExpression(parent) && parent.callee === node) { if (isOrHasCallExpression(node)) return true; } if (isLogicalExpression(node) && parent.operator === "??") return true; return find(expandedParens, node, parent, printStack); } function TaggedTemplateExpression$1(node) { this.print(node.tag, node); this.print(node.typeParameters, node); this.print(node.quasi, node); } function TemplateElement$1(node, parent) { var isFirst = parent.quasis[0] === node; var isLast = parent.quasis[parent.quasis.length - 1] === node; var value = (isFirst ? "`" : "}") + node.value.raw + (isLast ? "`" : "${"); this.token(value); } function TemplateLiteral$1(node) { var quasis = node.quasis; for (var i = 0; i < quasis.length; i++) { this.print(quasis[i], node); if (i + 1 < quasis.length) { this.print(node.expressions[i], node); } } } function UnaryExpression$1(node) { if (node.operator === "void" || node.operator === "delete" || node.operator === "typeof" || node.operator === "throw") { this.word(node.operator); this.space(); } else { this.token(node.operator); } this.print(node.argument, node); } function DoExpression$2(node) { this.word("do"); this.space(); this.print(node.body, node); } function ParenthesizedExpression$1(node) { this.token("("); this.print(node.expression, node); this.token(")"); } function UpdateExpression$2(node) { if (node.prefix) { this.token(node.operator); this.print(node.argument, node); } else { this.startTerminatorless(true); this.print(node.argument, node); this.endTerminatorless(); this.token(node.operator); } } function ConditionalExpression$2(node) { this.print(node.test, node); this.space(); this.token("?"); this.space(); this.print(node.consequent, node); this.space(); this.token(":"); this.space(); this.print(node.alternate, node); } function NewExpression$2(node, parent) { this.word("new"); this.space(); this.print(node.callee, node); if (this.format.minified && node.arguments.length === 0 && !node.optional && !isCallExpression(parent, { callee: node }) && !isMemberExpression(parent) && !isNewExpression(parent)) { return; } this.print(node.typeArguments, node); this.print(node.typeParameters, node); if (node.optional) { this.token("?."); } this.token("("); this.printList(node.arguments, node); this.token(")"); } function SequenceExpression$2(node) { this.printList(node.expressions, node); } function ThisExpression$1() { this.word("this"); } function Super$1() { this.word("super"); } function Decorator$1(node) { this.token("@"); this.print(node.expression, node); this.newline(); } function OptionalMemberExpression$2(node) { this.print(node.object, node); if (!node.computed && isMemberExpression(node.property)) { throw new TypeError("Got a MemberExpression for MemberExpression property"); } var computed = node.computed; if (isLiteral(node.property) && typeof node.property.value === "number") { computed = true; } if (node.optional) { this.token("?."); } if (computed) { this.token("["); this.print(node.property, node); this.token("]"); } else { if (!node.optional) { this.token("."); } this.print(node.property, node); } } function OptionalCallExpression$1(node) { this.print(node.callee, node); this.print(node.typeArguments, node); this.print(node.typeParameters, node); if (node.optional) { this.token("?."); } this.token("("); this.printList(node.arguments, node); this.token(")"); } function CallExpression$1(node) { this.print(node.callee, node); this.print(node.typeArguments, node); this.print(node.typeParameters, node); this.token("("); this.printList(node.arguments, node); this.token(")"); } function Import$1() { this.word("import"); } function buildYieldAwait(keyword) { return function (node) { this.word(keyword); if (node.delegate) { this.token("*"); } if (node.argument) { this.space(); var terminatorState = this.startTerminatorless(); this.print(node.argument, node); this.endTerminatorless(terminatorState); } }; } var YieldExpression$2 = buildYieldAwait("yield"); var AwaitExpression$1 = buildYieldAwait("await"); function EmptyStatement$1() { this.semicolon(true); } function ExpressionStatement$1(node) { this.print(node.expression, node); this.semicolon(); } function AssignmentPattern$1(node) { this.print(node.left, node); if (node.left.optional) this.token("?"); this.print(node.left.typeAnnotation, node); this.space(); this.token("="); this.space(); this.print(node.right, node); } function AssignmentExpression$2(node, parent) { var parens = this.inForStatementInitCounter && node.operator === "in" && !needsParens(node, parent); if (parens) { this.token("("); } this.print(node.left, node); this.space(); if (node.operator === "in" || node.operator === "instanceof") { this.word(node.operator); } else { this.token(node.operator); } this.space(); this.print(node.right, node); if (parens) { this.token(")"); } } function BindExpression$1(node) { this.print(node.object, node); this.token("::"); this.print(node.callee, node); } function MemberExpression$1(node) { this.print(node.object, node); if (!node.computed && isMemberExpression(node.property)) { throw new TypeError("Got a MemberExpression for MemberExpression property"); } var computed = node.computed; if (isLiteral(node.property) && typeof node.property.value === "number") { computed = true; } if (computed) { this.token("["); this.print(node.property, node); this.token("]"); } else { this.token("."); this.print(node.property, node); } } function MetaProperty$1(node) { this.print(node.meta, node); this.token("."); this.print(node.property, node); } function PrivateName$1(node) { this.token("#"); this.print(node.id, node); } function V8IntrinsicIdentifier$1(node) { this.token("%"); this.word(node.name); } function WithStatement$1(node) { this.word("with"); this.space(); this.token("("); this.print(node.object, node); this.token(")"); this.printBlock(node); } function IfStatement$1(node) { this.word("if"); this.space(); this.token("("); this.print(node.test, node); this.token(")"); this.space(); var needsBlock = node.alternate && isIfStatement(getLastStatement(node.consequent)); if (needsBlock) { this.token("{"); this.newline(); this.indent(); } this.printAndIndentOnComments(node.consequent, node); if (needsBlock) { this.dedent(); this.newline(); this.token("}"); } if (node.alternate) { if (this.endsWith("}")) this.space(); this.word("else"); this.space(); this.printAndIndentOnComments(node.alternate, node); } } function getLastStatement(statement) { if (!isStatement(statement.body)) return statement; return getLastStatement(statement.body); } function ForStatement$1(node) { this.word("for"); this.space(); this.token("("); this.inForStatementInitCounter++; this.print(node.init, node); this.inForStatementInitCounter--; this.token(";"); if (node.test) { this.space(); this.print(node.test, node); } this.token(";"); if (node.update) { this.space(); this.print(node.update, node); } this.token(")"); this.printBlock(node); } function WhileStatement$1(node) { this.word("while"); this.space(); this.token("("); this.print(node.test, node); this.token(")"); this.printBlock(node); } var buildForXStatement = function buildForXStatement(op) { return function (node) { this.word("for"); this.space(); if (op === "of" && node["await"]) { this.word("await"); this.space(); } this.token("("); this.print(node.left, node); this.space(); this.word(op); this.space(); this.print(node.right, node); this.token(")"); this.printBlock(node); }; }; var ForInStatement$1 = buildForXStatement("in"); var ForOfStatement$1 = buildForXStatement("of"); function DoWhileStatement$1(node) { this.word("do"); this.space(); this.print(node.body, node); this.space(); this.word("while"); this.space(); this.token("("); this.print(node.test, node); this.token(")"); this.semicolon(); } function buildLabelStatement(prefix, key) { if (key === void 0) { key = "label"; } return function (node) { this.word(prefix); var label = node[key]; if (label) { this.space(); var isLabel = key == "label"; var terminatorState = this.startTerminatorless(isLabel); this.print(label, node); this.endTerminatorless(terminatorState); } this.semicolon(); }; } var ContinueStatement$1 = buildLabelStatement("continue"); var ReturnStatement$1 = buildLabelStatement("return", "argument"); var BreakStatement$1 = buildLabelStatement("break"); var ThrowStatement$1 = buildLabelStatement("throw", "argument"); function LabeledStatement$1(node) { this.print(node.label, node); this.token(":"); this.space(); this.print(node.body, node); } function TryStatement$1(node) { this.word("try"); this.space(); this.print(node.block, node); this.space(); if (node.handlers) { this.print(node.handlers[0], node); } else { this.print(node.handler, node); } if (node.finalizer) { this.space(); this.word("finally"); this.space(); this.print(node.finalizer, node); } } function CatchClause$1(node) { this.word("catch"); this.space(); if (node.param) { this.token("("); this.print(node.param, node); this.token(")"); this.space(); } this.print(node.body, node); } function SwitchStatement$1(node) { this.word("switch"); this.space(); this.token("("); this.print(node.discriminant, node); this.token(")"); this.space(); this.token("{"); this.printSequence(node.cases, node, { indent: true, addNewlines: function addNewlines(leading, cas) { if (!leading && node.cases[node.cases.length - 1] === cas) return -1; } }); this.token("}"); } function SwitchCase$1(node) { if (node.test) { this.word("case"); this.space(); this.print(node.test, node); this.token(":"); } else { this.word("default"); this.token(":"); } if (node.consequent.length) { this.newline(); this.printSequence(node.consequent, node, { indent: true }); } } function DebuggerStatement$1() { this.word("debugger"); this.semicolon(); } function variableDeclarationIndent() { this.token(","); this.newline(); if (this.endsWith("\n")) for (var i = 0; i < 4; i++) { this.space(true); } } function constDeclarationIndent() { this.token(","); this.newline(); if (this.endsWith("\n")) for (var i = 0; i < 6; i++) { this.space(true); } } function VariableDeclaration$1(node, parent) { if (node.declare) { this.word("declare"); this.space(); } this.word(node.kind); this.space(); var hasInits = false; if (!isFor(parent)) { for (var _i = 0, _arr = node.declarations; _i < _arr.length; _i++) { var declar = _arr[_i]; if (declar.init) { hasInits = true; } } } var separator; if (hasInits) { separator = node.kind === "const" ? constDeclarationIndent : variableDeclarationIndent; } this.printList(node.declarations, node, { separator: separator }); if (isFor(parent)) { if (parent.left === node || parent.init === node) return; } this.semicolon(); } function VariableDeclarator$1(node) { this.print(node.id, node); if (node.definite) this.token("!"); this.print(node.id.typeAnnotation, node); if (node.init) { this.space(); this.token("="); this.space(); this.print(node.init, node); } } function ClassDeclaration$1(node, parent) { if (!this.format.decoratorsBeforeExport || !isExportDefaultDeclaration(parent) && !isExportNamedDeclaration(parent)) { this.printJoin(node.decorators, node); } if (node.declare) { this.word("declare"); this.space(); } if (node["abstract"]) { this.word("abstract"); this.space(); } this.word("class"); if (node.id) { this.space(); this.print(node.id, node); } this.print(node.typeParameters, node); if (node.superClass) { this.space(); this.word("extends"); this.space(); this.print(node.superClass, node); this.print(node.superTypeParameters, node); } if (node["implements"]) { this.space(); this.word("implements"); this.space(); this.printList(node["implements"], node); } this.space(); this.print(node.body, node); } function ClassBody$1(node) { this.token("{"); this.printInnerComments(node); if (node.body.length === 0) { this.token("}"); } else { this.newline(); this.indent(); this.printSequence(node.body, node); this.dedent(); if (!this.endsWith("\n")) this.newline(); this.rightBrace(); } } function ClassProperty$1(node) { this.printJoin(node.decorators, node); this.tsPrintClassMemberModifiers(node, true); if (node.computed) { this.token("["); this.print(node.key, node); this.token("]"); } else { this._variance(node); this.print(node.key, node); } if (node.optional) { this.token("?"); } if (node.definite) { this.token("!"); } this.print(node.typeAnnotation, node); if (node.value) { this.space(); this.token("="); this.space(); this.print(node.value, node); } this.semicolon(); } function ClassPrivateProperty$1(node) { if (node["static"]) { this.word("static"); this.space(); } this.print(node.key, node); this.print(node.typeAnnotation, node); if (node.value) { this.space(); this.token("="); this.space(); this.print(node.value, node); } this.semicolon(); } function ClassMethod$1(node) { this._classMethodHead(node); this.space(); this.print(node.body, node); } function ClassPrivateMethod$1(node) { this._classMethodHead(node); this.space(); this.print(node.body, node); } function _classMethodHead(node) { this.printJoin(node.decorators, node); this.tsPrintClassMemberModifiers(node, false); this._methodHead(node); } function _params(node) { this.print(node.typeParameters, node); this.token("("); this._parameters(node.params, node); this.token(")"); this.print(node.returnType, node); } function _parameters(parameters, parent) { for (var i = 0; i < parameters.length; i++) { this._param(parameters[i], parent); if (i < parameters.length - 1) { this.token(","); this.space(); } } } function _param(parameter, parent) { this.printJoin(parameter.decorators, parameter); this.print(parameter, parent); if (parameter.optional) this.token("?"); this.print(parameter.typeAnnotation, parameter); } function _methodHead(node) { var kind = node.kind; var key = node.key; if (kind === "get" || kind === "set") { this.word(kind); this.space(); } if (node.async) { this.word("async"); this.space(); } if (kind === "method" || kind === "init") { if (node.generator) { this.token("*"); } } if (node.computed) { this.token("["); this.print(key, node); this.token("]"); } else { this.print(key, node); } if (node.optional) { this.token("?"); } this._params(node); } function _predicate(node) { if (node.predicate) { if (!node.returnType) { this.token(":"); } this.space(); this.print(node.predicate, node); } } function _functionHead(node) { if (node.async) { this.word("async"); this.space(); } this.word("function"); if (node.generator) this.token("*"); this.space(); if (node.id) { this.print(node.id, node); } this._params(node); this._predicate(node); } function FunctionExpression$2(node) { this._functionHead(node); this.space(); this.print(node.body, node); } function ArrowFunctionExpression$2(node) { if (node.async) { this.word("async"); this.space(); } var firstParam = node.params[0]; if (node.params.length === 1 && isIdentifier(firstParam) && !hasTypes(node, firstParam)) { if (this.format.retainLines && node.loc && node.body.loc && node.loc.start.line < node.body.loc.start.line) { this.token("("); if (firstParam.loc && firstParam.loc.start.line > node.loc.start.line) { this.indent(); this.print(firstParam, node); this.dedent(); this._catchUp("start", node.body.loc); } else { this.print(firstParam, node); } this.token(")"); } else { this.print(firstParam, node); } } else { this._params(node); } this._predicate(node); this.space(); this.token("=>"); this.space(); this.print(node.body, node); } function hasTypes(node, param) { return node.typeParameters || node.returnType || param.typeAnnotation || param.optional || param.trailingComments; } function ImportSpecifier$1(node) { if (node.importKind === "type" || node.importKind === "typeof") { this.word(node.importKind); this.space(); } this.print(node.imported, node); if (node.local && node.local.name !== node.imported.name) { this.space(); this.word("as"); this.space(); this.print(node.local, node); } } function ImportDefaultSpecifier$1(node) { this.print(node.local, node); } function ExportDefaultSpecifier$1(node) { this.print(node.exported, node); } function ExportSpecifier$1(node) { this.print(node.local, node); if (node.exported && node.local.name !== node.exported.name) { this.space(); this.word("as"); this.space(); this.print(node.exported, node); } } function ExportNamespaceSpecifier$1(node) { this.token("*"); this.space(); this.word("as"); this.space(); this.print(node.exported, node); } function ExportAllDeclaration$1(node) { this.word("export"); this.space(); if (node.exportKind === "type") { this.word("type"); this.space(); } this.token("*"); this.space(); this.word("from"); this.space(); this.print(node.source, node); this.semicolon(); } function ExportNamedDeclaration$1(node) { if (this.format.decoratorsBeforeExport && isClassDeclaration(node.declaration)) { this.printJoin(node.declaration.decorators, node); } this.word("export"); this.space(); ExportDeclaration.apply(this, arguments); } function ExportDefaultDeclaration$1(node) { if (this.format.decoratorsBeforeExport && isClassDeclaration(node.declaration)) { this.printJoin(node.declaration.decorators, node); } this.word("export"); this.space(); this.word("default"); this.space(); ExportDeclaration.apply(this, arguments); } function ExportDeclaration(node) { if (node.declaration) { var declar = node.declaration; this.print(declar, node); if (!isStatement(declar)) this.semicolon(); } else { if (node.exportKind === "type") { this.word("type"); this.space(); } var specifiers = node.specifiers.slice(0); var hasSpecial = false; while (true) { var first = specifiers[0]; if (isExportDefaultSpecifier(first) || isExportNamespaceSpecifier(first)) { hasSpecial = true; this.print(specifiers.shift(), node); if (specifiers.length) { this.token(","); this.space(); } } else { break; } } if (specifiers.length || !specifiers.length && !hasSpecial) { this.token("{"); if (specifiers.length) { this.space(); this.printList(specifiers, node); this.space(); } this.token("}"); } if (node.source) { this.space(); this.word("from"); this.space(); this.print(node.source, node); } this.semicolon(); } } function ImportDeclaration$1(node) { this.word("import"); this.space(); if (node.importKind === "type" || node.importKind === "typeof") { this.word(node.importKind); this.space(); } var specifiers = node.specifiers.slice(0); if (specifiers && specifiers.length) { while (true) { var first = specifiers[0]; if (isImportDefaultSpecifier(first) || isImportNamespaceSpecifier(first)) { this.print(specifiers.shift(), node); if (specifiers.length) { this.token(","); this.space(); } } else { break; } } if (specifiers.length) { this.token("{"); this.space(); this.printList(specifiers, node); this.space(); this.token("}"); } this.space(); this.word("from"); this.space(); } this.print(node.source, node); this.semicolon(); } function ImportNamespaceSpecifier$1(node) { this.token("*"); this.space(); this.word("as"); this.space(); this.print(node.local, node); } var lookup = []; var revLookup = []; var Arr = typeof Uint8Array !== 'undefined' ? Uint8Array : Array; var inited = false; function init() { inited = true; var code = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/'; for (var i = 0, len = code.length; i < len; ++i) { lookup[i] = code[i]; revLookup[code.charCodeAt(i)] = i; } revLookup['-'.charCodeAt(0)] = 62; revLookup['_'.charCodeAt(0)] = 63; } function toByteArray(b64) { if (!inited) { init(); } var i, j, l, tmp, placeHolders, arr; var len = b64.length; if (len % 4 > 0) { throw new Error('Invalid string. Length must be a multiple of 4'); } placeHolders = b64[len - 2] === '=' ? 2 : b64[len - 1] === '=' ? 1 : 0; arr = new Arr(len * 3 / 4 - placeHolders); l = placeHolders > 0 ? len - 4 : len; var L = 0; for (i = 0, j = 0; i < l; i += 4, j += 3) { tmp = revLookup[b64.charCodeAt(i)] << 18 | revLookup[b64.charCodeAt(i + 1)] << 12 | revLookup[b64.charCodeAt(i + 2)] << 6 | revLookup[b64.charCodeAt(i + 3)]; arr[L++] = tmp >> 16 & 0xFF; arr[L++] = tmp >> 8 & 0xFF; arr[L++] = tmp & 0xFF; } if (placeHolders === 2) { tmp = revLookup[b64.charCodeAt(i)] << 2 | revLookup[b64.charCodeAt(i + 1)] >> 4; arr[L++] = tmp & 0xFF; } else if (placeHolders === 1) { tmp = revLookup[b64.charCodeAt(i)] << 10 | revLookup[b64.charCodeAt(i + 1)] << 4 | revLookup[b64.charCodeAt(i + 2)] >> 2; arr[L++] = tmp >> 8 & 0xFF; arr[L++] = tmp & 0xFF; } return arr; } function tripletToBase64(num) { return lookup[num >> 18 & 0x3F] + lookup[num >> 12 & 0x3F] + lookup[num >> 6 & 0x3F] + lookup[num & 0x3F]; } function encodeChunk(uint8, start, end) { var tmp; var output = []; for (var i = start; i < end; i += 3) { tmp = (uint8[i] << 16) + (uint8[i + 1] << 8) + uint8[i + 2]; output.push(tripletToBase64(tmp)); } return output.join(''); } function fromByteArray(uint8) { if (!inited) { init(); } var tmp; var len = uint8.length; var extraBytes = len % 3; var output = ''; var parts = []; var maxChunkLength = 16383; for (var i = 0, len2 = len - extraBytes; i < len2; i += maxChunkLength) { parts.push(encodeChunk(uint8, i, i + maxChunkLength > len2 ? len2 : i + maxChunkLength)); } if (extraBytes === 1) { tmp = uint8[len - 1]; output += lookup[tmp >> 2]; output += lookup[tmp << 4 & 0x3F]; output += '=='; } else if (extraBytes === 2) { tmp = (uint8[len - 2] << 8) + uint8[len - 1]; output += lookup[tmp >> 10]; output += lookup[tmp >> 4 & 0x3F]; output += lookup[tmp << 2 & 0x3F]; output += '='; } parts.push(output); return parts.join(''); } function read(buffer, offset, isLE, mLen, nBytes) { var e, m; var eLen = nBytes * 8 - mLen - 1; var eMax = (1 << eLen) - 1; var eBias = eMax >> 1; var nBits = -7; var i = isLE ? nBytes - 1 : 0; var d = isLE ? -1 : 1; var s = buffer[offset + i]; i += d; e = s & (1 << -nBits) - 1; s >>= -nBits; nBits += eLen; for (; nBits > 0; e = e * 256 + buffer[offset + i], i += d, nBits -= 8) {} m = e & (1 << -nBits) - 1; e >>= -nBits; nBits += mLen; for (; nBits > 0; m = m * 256 + buffer[offset + i], i += d, nBits -= 8) {} if (e === 0) { e = 1 - eBias; } else if (e === eMax) { return m ? NaN : (s ? -1 : 1) * Infinity; } else { m = m + Math.pow(2, mLen); e = e - eBias; } return (s ? -1 : 1) * m * Math.pow(2, e - mLen); } function write(buffer, value, offset, isLE, mLen, nBytes) { var e, m, c; var eLen = nBytes * 8 - mLen - 1; var eMax = (1 << eLen) - 1; var eBias = eMax >> 1; var rt = mLen === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0; var i = isLE ? 0 : nBytes - 1; var d = isLE ? 1 : -1; var s = value < 0 || value === 0 && 1 / value < 0 ? 1 : 0; value = Math.abs(value); if (isNaN(value) || value === Infinity) { m = isNaN(value) ? 1 : 0; e = eMax; } else { e = Math.floor(Math.log(value) / Math.LN2); if (value * (c = Math.pow(2, -e)) < 1) { e--; c *= 2; } if (e + eBias >= 1) { value += rt / c; } else { value += rt * Math.pow(2, 1 - eBias); } if (value * c >= 2) { e++; c /= 2; } if (e + eBias >= eMax) { m = 0; e = eMax; } else if (e + eBias >= 1) { m = (value * c - 1) * Math.pow(2, mLen); e = e + eBias; } else { m = value * Math.pow(2, eBias - 1) * Math.pow(2, mLen); e = 0; } } for (; mLen >= 8; buffer[offset + i] = m & 0xff, i += d, m /= 256, mLen -= 8) {} e = e << mLen | m; eLen += mLen; for (; eLen > 0; buffer[offset + i] = e & 0xff, i += d, e /= 256, eLen -= 8) {} buffer[offset + i - d] |= s * 128; } var toString$1 = {}.toString; var isArray$1 = Array.isArray || function (arr) { return toString$1.call(arr) == '[object Array]'; }; var INSPECT_MAX_BYTES = 50; Buffer$1.TYPED_ARRAY_SUPPORT = global$1.TYPED_ARRAY_SUPPORT !== undefined ? global$1.TYPED_ARRAY_SUPPORT : true; var _kMaxLength = kMaxLength(); function kMaxLength() { return Buffer$1.TYPED_ARRAY_SUPPORT ? 0x7fffffff : 0x3fffffff; } function createBuffer(that, length) { if (kMaxLength() < length) { throw new RangeError('Invalid typed array length'); } if (Buffer$1.TYPED_ARRAY_SUPPORT) { that = new Uint8Array(length); that.__proto__ = Buffer$1.prototype; } else { if (that === null) { that = new Buffer$1(length); } that.length = length; } return that; } function Buffer$1(arg, encodingOrOffset, length) { if (!Buffer$1.TYPED_ARRAY_SUPPORT && !(this instanceof Buffer$1)) { return new Buffer$1(arg, encodingOrOffset, length); } if (typeof arg === 'number') { if (typeof encodingOrOffset === 'string') { throw new Error('If encoding is specified then the first argument must be a string'); } return allocUnsafe(this, arg); } return from(this, arg, encodingOrOffset, length); } Buffer$1.poolSize = 8192; Buffer$1._augment = function (arr) { arr.__proto__ = Buffer$1.prototype; return arr; }; function from(that, value, encodingOrOffset, length) { if (typeof value === 'number') { throw new TypeError('"value" argument must not be a number'); } if (typeof ArrayBuffer !== 'undefined' && value instanceof ArrayBuffer) { return fromArrayBuffer(that, value, encodingOrOffset, length); } if (typeof value === 'string') { return fromString(that, value, encodingOrOffset); } return fromObject(that, value); } Buffer$1.from = function (value, encodingOrOffset, length) { return from(null, value, encodingOrOffset, length); }; if (Buffer$1.TYPED_ARRAY_SUPPORT) { Buffer$1.prototype.__proto__ = Uint8Array.prototype; Buffer$1.__proto__ = Uint8Array; } function assertSize(size) { if (typeof size !== 'number') { throw new TypeError('"size" argument must be a number'); } else if (size < 0) { throw new RangeError('"size" argument must not be negative'); } } function alloc(that, size, fill, encoding) { assertSize(size); if (size <= 0) { return createBuffer(that, size); } if (fill !== undefined) { return typeof encoding === 'string' ? createBuffer(that, size).fill(fill, encoding) : createBuffer(that, size).fill(fill); } return createBuffer(that, size); } Buffer$1.alloc = function (size, fill, encoding) { return alloc(null, size, fill, encoding); }; function allocUnsafe(that, size) { assertSize(size); that = createBuffer(that, size < 0 ? 0 : checked(size) | 0); if (!Buffer$1.TYPED_ARRAY_SUPPORT) { for (var i = 0; i < size; ++i) { that[i] = 0; } } return that; } Buffer$1.allocUnsafe = function (size) { return allocUnsafe(null, size); }; Buffer$1.allocUnsafeSlow = function (size) { return allocUnsafe(null, size); }; function fromString(that, string, encoding) { if (typeof encoding !== 'string' || encoding === '') { encoding = 'utf8'; } if (!Buffer$1.isEncoding(encoding)) { throw new TypeError('"encoding" must be a valid string encoding'); } var length = byteLength(string, encoding) | 0; that = createBuffer(that, length); var actual = that.write(string, encoding); if (actual !== length) { that = that.slice(0, actual); } return that; } function fromArrayLike(that, array) { var length = array.length < 0 ? 0 : checked(array.length) | 0; that = createBuffer(that, length); for (var i = 0; i < length; i += 1) { that[i] = array[i] & 255; } return that; } function fromArrayBuffer(that, array, byteOffset, length) { array.byteLength; if (byteOffset < 0 || array.byteLength < byteOffset) { throw new RangeError('\'offset\' is out of bounds'); } if (array.byteLength < byteOffset + (length || 0)) { throw new RangeError('\'length\' is out of bounds'); } if (byteOffset === undefined && length === undefined) { array = new Uint8Array(array); } else if (length === undefined) { array = new Uint8Array(array, byteOffset); } else { array = new Uint8Array(array, byteOffset, length); } if (Buffer$1.TYPED_ARRAY_SUPPORT) { that = array; that.__proto__ = Buffer$1.prototype; } else { that = fromArrayLike(that, array); } return that; } function fromObject(that, obj) { if (internalIsBuffer(obj)) { var len = checked(obj.length) | 0; that = createBuffer(that, len); if (that.length === 0) { return that; } obj.copy(that, 0, 0, len); return that; } if (obj) { if (typeof ArrayBuffer !== 'undefined' && obj.buffer instanceof ArrayBuffer || 'length' in obj) { if (typeof obj.length !== 'number' || isnan(obj.length)) { return createBuffer(that, 0); } return fromArrayLike(that, obj); } if (obj.type === 'Buffer' && isArray$1(obj.data)) { return fromArrayLike(that, obj.data); } } throw new TypeError('First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.'); } function checked(length) { if (length >= kMaxLength()) { throw new RangeError('Attempt to allocate Buffer larger than maximum ' + 'size: 0x' + kMaxLength().toString(16) + ' bytes'); } return length | 0; } function SlowBuffer(length) { if (+length != length) { length = 0; } return Buffer$1.alloc(+length); } Buffer$1.isBuffer = isBuffer; function internalIsBuffer(b) { return !!(b != null && b._isBuffer); } Buffer$1.compare = function compare(a, b) { if (!internalIsBuffer(a) || !internalIsBuffer(b)) { throw new TypeError('Arguments must be Buffers'); } if (a === b) return 0; var x = a.length; var y = b.length; for (var i = 0, len = Math.min(x, y); i < len; ++i) { if (a[i] !== b[i]) { x = a[i]; y = b[i]; break; } } if (x < y) return -1; if (y < x) return 1; return 0; }; Buffer$1.isEncoding = function isEncoding(encoding) { switch (String(encoding).toLowerCase()) { case 'hex': case 'utf8': case 'utf-8': case 'ascii': case 'latin1': case 'binary': case 'base64': case 'ucs2': case 'ucs-2': case 'utf16le': case 'utf-16le': return true; default: return false; } }; Buffer$1.concat = function concat(list, length) { if (!isArray$1(list)) { throw new TypeError('"list" argument must be an Array of Buffers'); } if (list.length === 0) { return Buffer$1.alloc(0); } var i; if (length === undefined) { length = 0; for (i = 0; i < list.length; ++i) { length += list[i].length; } } var buffer = Buffer$1.allocUnsafe(length); var pos = 0; for (i = 0; i < list.length; ++i) { var buf = list[i]; if (!internalIsBuffer(buf)) { throw new TypeError('"list" argument must be an Array of Buffers'); } buf.copy(buffer, pos); pos += buf.length; } return buffer; }; function byteLength(string, encoding) { if (internalIsBuffer(string)) { return string.length; } if (typeof ArrayBuffer !== 'undefined' && typeof ArrayBuffer.isView === 'function' && (ArrayBuffer.isView(string) || string instanceof ArrayBuffer)) { return string.byteLength; } if (typeof string !== 'string') { string = '' + string; } var len = string.length; if (len === 0) return 0; var loweredCase = false; for (;;) { switch (encoding) { case 'ascii': case 'latin1': case 'binary': return len; case 'utf8': case 'utf-8': case undefined: return utf8ToBytes(string).length; case 'ucs2': case 'ucs-2': case 'utf16le': case 'utf-16le': return len * 2; case 'hex': return len >>> 1; case 'base64': return base64ToBytes(string).length; default: if (loweredCase) return utf8ToBytes(string).length; encoding = ('' + encoding).toLowerCase(); loweredCase = true; } } } Buffer$1.byteLength = byteLength; function slowToString(encoding, start, end) { var loweredCase = false; if (start === undefined || start < 0) { start = 0; } if (start > this.length) { return ''; } if (end === undefined || end > this.length) { end = this.length; } if (end <= 0) { return ''; } end >>>= 0; start >>>= 0; if (end <= start) { return ''; } if (!encoding) encoding = 'utf8'; while (true) { switch (encoding) { case 'hex': return hexSlice(this, start, end); case 'utf8': case 'utf-8': return utf8Slice(this, start, end); case 'ascii': return asciiSlice(this, start, end); case 'latin1': case 'binary': return latin1Slice(this, start, end); case 'base64': return base64Slice(this, start, end); case 'ucs2': case 'ucs-2': case 'utf16le': case 'utf-16le': return utf16leSlice(this, start, end); default: if (loweredCase) throw new TypeError('Unknown encoding: ' + encoding); encoding = (encoding + '').toLowerCase(); loweredCase = true; } } } Buffer$1.prototype._isBuffer = true; function swap$1(b, n, m) { var i = b[n]; b[n] = b[m]; b[m] = i; } Buffer$1.prototype.swap16 = function swap16() { var len = this.length; if (len % 2 !== 0) { throw new RangeError('Buffer size must be a multiple of 16-bits'); } for (var i = 0; i < len; i += 2) { swap$1(this, i, i + 1); } return this; }; Buffer$1.prototype.swap32 = function swap32() { var len = this.length; if (len % 4 !== 0) { throw new RangeError('Buffer size must be a multiple of 32-bits'); } for (var i = 0; i < len; i += 4) { swap$1(this, i, i + 3); swap$1(this, i + 1, i + 2); } return this; }; Buffer$1.prototype.swap64 = function swap64() { var len = this.length; if (len % 8 !== 0) { throw new RangeError('Buffer size must be a multiple of 64-bits'); } for (var i = 0; i < len; i += 8) { swap$1(this, i, i + 7); swap$1(this, i + 1, i + 6); swap$1(this, i + 2, i + 5); swap$1(this, i + 3, i + 4); } return this; }; Buffer$1.prototype.toString = function toString() { var length = this.length | 0; if (length === 0) return ''; if (arguments.length === 0) return utf8Slice(this, 0, length); return slowToString.apply(this, arguments); }; Buffer$1.prototype.equals = function equals(b) { if (!internalIsBuffer(b)) throw new TypeError('Argument must be a Buffer'); if (this === b) return true; return Buffer$1.compare(this, b) === 0; }; Buffer$1.prototype.inspect = function inspect() { var str = ''; var max = INSPECT_MAX_BYTES; if (this.length > 0) { str = this.toString('hex', 0, max).match(/.{2}/g).join(' '); if (this.length > max) str += ' ... '; } return ''; }; Buffer$1.prototype.compare = function compare(target, start, end, thisStart, thisEnd) { if (!internalIsBuffer(target)) { throw new TypeError('Argument must be a Buffer'); } if (start === undefined) { start = 0; } if (end === undefined) { end = target ? target.length : 0; } if (thisStart === undefined) { thisStart = 0; } if (thisEnd === undefined) { thisEnd = this.length; } if (start < 0 || end > target.length || thisStart < 0 || thisEnd > this.length) { throw new RangeError('out of range index'); } if (thisStart >= thisEnd && start >= end) { return 0; } if (thisStart >= thisEnd) { return -1; } if (start >= end) { return 1; } start >>>= 0; end >>>= 0; thisStart >>>= 0; thisEnd >>>= 0; if (this === target) return 0; var x = thisEnd - thisStart; var y = end - start; var len = Math.min(x, y); var thisCopy = this.slice(thisStart, thisEnd); var targetCopy = target.slice(start, end); for (var i = 0; i < len; ++i) { if (thisCopy[i] !== targetCopy[i]) { x = thisCopy[i]; y = targetCopy[i]; break; } } if (x < y) return -1; if (y < x) return 1; return 0; }; function bidirectionalIndexOf(buffer, val, byteOffset, encoding, dir) { if (buffer.length === 0) return -1; if (typeof byteOffset === 'string') { encoding = byteOffset; byteOffset = 0; } else if (byteOffset > 0x7fffffff) { byteOffset = 0x7fffffff; } else if (byteOffset < -0x80000000) { byteOffset = -0x80000000; } byteOffset = +byteOffset; if (isNaN(byteOffset)) { byteOffset = dir ? 0 : buffer.length - 1; } if (byteOffset < 0) byteOffset = buffer.length + byteOffset; if (byteOffset >= buffer.length) { if (dir) return -1;else byteOffset = buffer.length - 1; } else if (byteOffset < 0) { if (dir) byteOffset = 0;else return -1; } if (typeof val === 'string') { val = Buffer$1.from(val, encoding); } if (internalIsBuffer(val)) { if (val.length === 0) { return -1; } return arrayIndexOf(buffer, val, byteOffset, encoding, dir); } else if (typeof val === 'number') { val = val & 0xFF; if (Buffer$1.TYPED_ARRAY_SUPPORT && typeof Uint8Array.prototype.indexOf === 'function') { if (dir) { return Uint8Array.prototype.indexOf.call(buffer, val, byteOffset); } else { return Uint8Array.prototype.lastIndexOf.call(buffer, val, byteOffset); } } return arrayIndexOf(buffer, [val], byteOffset, encoding, dir); } throw new TypeError('val must be string, number or Buffer'); } function arrayIndexOf(arr, val, byteOffset, encoding, dir) { var indexSize = 1; var arrLength = arr.length; var valLength = val.length; if (encoding !== undefined) { encoding = String(encoding).toLowerCase(); if (encoding === 'ucs2' || encoding === 'ucs-2' || encoding === 'utf16le' || encoding === 'utf-16le') { if (arr.length < 2 || val.length < 2) { return -1; } indexSize = 2; arrLength /= 2; valLength /= 2; byteOffset /= 2; } } function read(buf, i) { if (indexSize === 1) { return buf[i]; } else { return buf.readUInt16BE(i * indexSize); } } var i; if (dir) { var foundIndex = -1; for (i = byteOffset; i < arrLength; i++) { if (read(arr, i) === read(val, foundIndex === -1 ? 0 : i - foundIndex)) { if (foundIndex === -1) foundIndex = i; if (i - foundIndex + 1 === valLength) return foundIndex * indexSize; } else { if (foundIndex !== -1) i -= i - foundIndex; foundIndex = -1; } } } else { if (byteOffset + valLength > arrLength) byteOffset = arrLength - valLength; for (i = byteOffset; i >= 0; i--) { var found = true; for (var j = 0; j < valLength; j++) { if (read(arr, i + j) !== read(val, j)) { found = false; break; } } if (found) return i; } } return -1; } Buffer$1.prototype.includes = function includes(val, byteOffset, encoding) { return this.indexOf(val, byteOffset, encoding) !== -1; }; Buffer$1.prototype.indexOf = function indexOf(val, byteOffset, encoding) { return bidirectionalIndexOf(this, val, byteOffset, encoding, true); }; Buffer$1.prototype.lastIndexOf = function lastIndexOf(val, byteOffset, encoding) { return bidirectionalIndexOf(this, val, byteOffset, encoding, false); }; function hexWrite(buf, string, offset, length) { offset = Number(offset) || 0; var remaining = buf.length - offset; if (!length) { length = remaining; } else { length = Number(length); if (length > remaining) { length = remaining; } } var strLen = string.length; if (strLen % 2 !== 0) throw new TypeError('Invalid hex string'); if (length > strLen / 2) { length = strLen / 2; } for (var i = 0; i < length; ++i) { var parsed = parseInt(string.substr(i * 2, 2), 16); if (isNaN(parsed)) return i; buf[offset + i] = parsed; } return i; } function utf8Write(buf, string, offset, length) { return blitBuffer(utf8ToBytes(string, buf.length - offset), buf, offset, length); } function asciiWrite(buf, string, offset, length) { return blitBuffer(asciiToBytes(string), buf, offset, length); } function latin1Write(buf, string, offset, length) { return asciiWrite(buf, string, offset, length); } function base64Write(buf, string, offset, length) { return blitBuffer(base64ToBytes(string), buf, offset, length); } function ucs2Write(buf, string, offset, length) { return blitBuffer(utf16leToBytes(string, buf.length - offset), buf, offset, length); } Buffer$1.prototype.write = function write(string, offset, length, encoding) { if (offset === undefined) { encoding = 'utf8'; length = this.length; offset = 0; } else if (length === undefined && typeof offset === 'string') { encoding = offset; length = this.length; offset = 0; } else if (isFinite(offset)) { offset = offset | 0; if (isFinite(length)) { length = length | 0; if (encoding === undefined) encoding = 'utf8'; } else { encoding = length; length = undefined; } } else { throw new Error('Buffer.write(string, encoding, offset[, length]) is no longer supported'); } var remaining = this.length - offset; if (length === undefined || length > remaining) length = remaining; if (string.length > 0 && (length < 0 || offset < 0) || offset > this.length) { throw new RangeError('Attempt to write outside buffer bounds'); } if (!encoding) encoding = 'utf8'; var loweredCase = false; for (;;) { switch (encoding) { case 'hex': return hexWrite(this, string, offset, length); case 'utf8': case 'utf-8': return utf8Write(this, string, offset, length); case 'ascii': return asciiWrite(this, string, offset, length); case 'latin1': case 'binary': return latin1Write(this, string, offset, length); case 'base64': return base64Write(this, string, offset, length); case 'ucs2': case 'ucs-2': case 'utf16le': case 'utf-16le': return ucs2Write(this, string, offset, length); default: if (loweredCase) throw new TypeError('Unknown encoding: ' + encoding); encoding = ('' + encoding).toLowerCase(); loweredCase = true; } } }; Buffer$1.prototype.toJSON = function toJSON() { return { type: 'Buffer', data: Array.prototype.slice.call(this._arr || this, 0) }; }; function base64Slice(buf, start, end) { if (start === 0 && end === buf.length) { return fromByteArray(buf); } else { return fromByteArray(buf.slice(start, end)); } } function utf8Slice(buf, start, end) { end = Math.min(buf.length, end); var res = []; var i = start; while (i < end) { var firstByte = buf[i]; var codePoint = null; var bytesPerSequence = firstByte > 0xEF ? 4 : firstByte > 0xDF ? 3 : firstByte > 0xBF ? 2 : 1; if (i + bytesPerSequence <= end) { var secondByte, thirdByte, fourthByte, tempCodePoint; switch (bytesPerSequence) { case 1: if (firstByte < 0x80) { codePoint = firstByte; } break; case 2: secondByte = buf[i + 1]; if ((secondByte & 0xC0) === 0x80) { tempCodePoint = (firstByte & 0x1F) << 0x6 | secondByte & 0x3F; if (tempCodePoint > 0x7F) { codePoint = tempCodePoint; } } break; case 3: secondByte = buf[i + 1]; thirdByte = buf[i + 2]; if ((secondByte & 0xC0) === 0x80 && (thirdByte & 0xC0) === 0x80) { tempCodePoint = (firstByte & 0xF) << 0xC | (secondByte & 0x3F) << 0x6 | thirdByte & 0x3F; if (tempCodePoint > 0x7FF && (tempCodePoint < 0xD800 || tempCodePoint > 0xDFFF)) { codePoint = tempCodePoint; } } break; case 4: secondByte = buf[i + 1]; thirdByte = buf[i + 2]; fourthByte = buf[i + 3]; if ((secondByte & 0xC0) === 0x80 && (thirdByte & 0xC0) === 0x80 && (fourthByte & 0xC0) === 0x80) { tempCodePoint = (firstByte & 0xF) << 0x12 | (secondByte & 0x3F) << 0xC | (thirdByte & 0x3F) << 0x6 | fourthByte & 0x3F; if (tempCodePoint > 0xFFFF && tempCodePoint < 0x110000) { codePoint = tempCodePoint; } } } } if (codePoint === null) { codePoint = 0xFFFD; bytesPerSequence = 1; } else if (codePoint > 0xFFFF) { codePoint -= 0x10000; res.push(codePoint >>> 10 & 0x3FF | 0xD800); codePoint = 0xDC00 | codePoint & 0x3FF; } res.push(codePoint); i += bytesPerSequence; } return decodeCodePointsArray(res); } var MAX_ARGUMENTS_LENGTH = 0x1000; function decodeCodePointsArray(codePoints) { var len = codePoints.length; if (len <= MAX_ARGUMENTS_LENGTH) { return String.fromCharCode.apply(String, codePoints); } var res = ''; var i = 0; while (i < len) { res += String.fromCharCode.apply(String, codePoints.slice(i, i += MAX_ARGUMENTS_LENGTH)); } return res; } function asciiSlice(buf, start, end) { var ret = ''; end = Math.min(buf.length, end); for (var i = start; i < end; ++i) { ret += String.fromCharCode(buf[i] & 0x7F); } return ret; } function latin1Slice(buf, start, end) { var ret = ''; end = Math.min(buf.length, end); for (var i = start; i < end; ++i) { ret += String.fromCharCode(buf[i]); } return ret; } function hexSlice(buf, start, end) { var len = buf.length; if (!start || start < 0) start = 0; if (!end || end < 0 || end > len) end = len; var out = ''; for (var i = start; i < end; ++i) { out += toHex(buf[i]); } return out; } function utf16leSlice(buf, start, end) { var bytes = buf.slice(start, end); var res = ''; for (var i = 0; i < bytes.length; i += 2) { res += String.fromCharCode(bytes[i] + bytes[i + 1] * 256); } return res; } Buffer$1.prototype.slice = function slice(start, end) { var len = this.length; start = ~~start; end = end === undefined ? len : ~~end; if (start < 0) { start += len; if (start < 0) start = 0; } else if (start > len) { start = len; } if (end < 0) { end += len; if (end < 0) end = 0; } else if (end > len) { end = len; } if (end < start) end = start; var newBuf; if (Buffer$1.TYPED_ARRAY_SUPPORT) { newBuf = this.subarray(start, end); newBuf.__proto__ = Buffer$1.prototype; } else { var sliceLen = end - start; newBuf = new Buffer$1(sliceLen, undefined); for (var i = 0; i < sliceLen; ++i) { newBuf[i] = this[i + start]; } } return newBuf; }; function checkOffset(offset, ext, length) { if (offset % 1 !== 0 || offset < 0) throw new RangeError('offset is not uint'); if (offset + ext > length) throw new RangeError('Trying to access beyond buffer length'); } Buffer$1.prototype.readUIntLE = function readUIntLE(offset, byteLength, noAssert) { offset = offset | 0; byteLength = byteLength | 0; if (!noAssert) checkOffset(offset, byteLength, this.length); var val = this[offset]; var mul = 1; var i = 0; while (++i < byteLength && (mul *= 0x100)) { val += this[offset + i] * mul; } return val; }; Buffer$1.prototype.readUIntBE = function readUIntBE(offset, byteLength, noAssert) { offset = offset | 0; byteLength = byteLength | 0; if (!noAssert) { checkOffset(offset, byteLength, this.length); } var val = this[offset + --byteLength]; var mul = 1; while (byteLength > 0 && (mul *= 0x100)) { val += this[offset + --byteLength] * mul; } return val; }; Buffer$1.prototype.readUInt8 = function readUInt8(offset, noAssert) { if (!noAssert) checkOffset(offset, 1, this.length); return this[offset]; }; Buffer$1.prototype.readUInt16LE = function readUInt16LE(offset, noAssert) { if (!noAssert) checkOffset(offset, 2, this.length); return this[offset] | this[offset + 1] << 8; }; Buffer$1.prototype.readUInt16BE = function readUInt16BE(offset, noAssert) { if (!noAssert) checkOffset(offset, 2, this.length); return this[offset] << 8 | this[offset + 1]; }; Buffer$1.prototype.readUInt32LE = function readUInt32LE(offset, noAssert) { if (!noAssert) checkOffset(offset, 4, this.length); return (this[offset] | this[offset + 1] << 8 | this[offset + 2] << 16) + this[offset + 3] * 0x1000000; }; Buffer$1.prototype.readUInt32BE = function readUInt32BE(offset, noAssert) { if (!noAssert) checkOffset(offset, 4, this.length); return this[offset] * 0x1000000 + (this[offset + 1] << 16 | this[offset + 2] << 8 | this[offset + 3]); }; Buffer$1.prototype.readIntLE = function readIntLE(offset, byteLength, noAssert) { offset = offset | 0; byteLength = byteLength | 0; if (!noAssert) checkOffset(offset, byteLength, this.length); var val = this[offset]; var mul = 1; var i = 0; while (++i < byteLength && (mul *= 0x100)) { val += this[offset + i] * mul; } mul *= 0x80; if (val >= mul) val -= Math.pow(2, 8 * byteLength); return val; }; Buffer$1.prototype.readIntBE = function readIntBE(offset, byteLength, noAssert) { offset = offset | 0; byteLength = byteLength | 0; if (!noAssert) checkOffset(offset, byteLength, this.length); var i = byteLength; var mul = 1; var val = this[offset + --i]; while (i > 0 && (mul *= 0x100)) { val += this[offset + --i] * mul; } mul *= 0x80; if (val >= mul) val -= Math.pow(2, 8 * byteLength); return val; }; Buffer$1.prototype.readInt8 = function readInt8(offset, noAssert) { if (!noAssert) checkOffset(offset, 1, this.length); if (!(this[offset] & 0x80)) return this[offset]; return (0xff - this[offset] + 1) * -1; }; Buffer$1.prototype.readInt16LE = function readInt16LE(offset, noAssert) { if (!noAssert) checkOffset(offset, 2, this.length); var val = this[offset] | this[offset + 1] << 8; return val & 0x8000 ? val | 0xFFFF0000 : val; }; Buffer$1.prototype.readInt16BE = function readInt16BE(offset, noAssert) { if (!noAssert) checkOffset(offset, 2, this.length); var val = this[offset + 1] | this[offset] << 8; return val & 0x8000 ? val | 0xFFFF0000 : val; }; Buffer$1.prototype.readInt32LE = function readInt32LE(offset, noAssert) { if (!noAssert) checkOffset(offset, 4, this.length); return this[offset] | this[offset + 1] << 8 | this[offset + 2] << 16 | this[offset + 3] << 24; }; Buffer$1.prototype.readInt32BE = function readInt32BE(offset, noAssert) { if (!noAssert) checkOffset(offset, 4, this.length); return this[offset] << 24 | this[offset + 1] << 16 | this[offset + 2] << 8 | this[offset + 3]; }; Buffer$1.prototype.readFloatLE = function readFloatLE(offset, noAssert) { if (!noAssert) checkOffset(offset, 4, this.length); return read(this, offset, true, 23, 4); }; Buffer$1.prototype.readFloatBE = function readFloatBE(offset, noAssert) { if (!noAssert) checkOffset(offset, 4, this.length); return read(this, offset, false, 23, 4); }; Buffer$1.prototype.readDoubleLE = function readDoubleLE(offset, noAssert) { if (!noAssert) checkOffset(offset, 8, this.length); return read(this, offset, true, 52, 8); }; Buffer$1.prototype.readDoubleBE = function readDoubleBE(offset, noAssert) { if (!noAssert) checkOffset(offset, 8, this.length); return read(this, offset, false, 52, 8); }; function checkInt(buf, value, offset, ext, max, min) { if (!internalIsBuffer(buf)) throw new TypeError('"buffer" argument must be a Buffer instance'); if (value > max || value < min) throw new RangeError('"value" argument is out of bounds'); if (offset + ext > buf.length) throw new RangeError('Index out of range'); } Buffer$1.prototype.writeUIntLE = function writeUIntLE(value, offset, byteLength, noAssert) { value = +value; offset = offset | 0; byteLength = byteLength | 0; if (!noAssert) { var maxBytes = Math.pow(2, 8 * byteLength) - 1; checkInt(this, value, offset, byteLength, maxBytes, 0); } var mul = 1; var i = 0; this[offset] = value & 0xFF; while (++i < byteLength && (mul *= 0x100)) { this[offset + i] = value / mul & 0xFF; } return offset + byteLength; }; Buffer$1.prototype.writeUIntBE = function writeUIntBE(value, offset, byteLength, noAssert) { value = +value; offset = offset | 0; byteLength = byteLength | 0; if (!noAssert) { var maxBytes = Math.pow(2, 8 * byteLength) - 1; checkInt(this, value, offset, byteLength, maxBytes, 0); } var i = byteLength - 1; var mul = 1; this[offset + i] = value & 0xFF; while (--i >= 0 && (mul *= 0x100)) { this[offset + i] = value / mul & 0xFF; } return offset + byteLength; }; Buffer$1.prototype.writeUInt8 = function writeUInt8(value, offset, noAssert) { value = +value; offset = offset | 0; if (!noAssert) checkInt(this, value, offset, 1, 0xff, 0); if (!Buffer$1.TYPED_ARRAY_SUPPORT) value = Math.floor(value); this[offset] = value & 0xff; return offset + 1; }; function objectWriteUInt16(buf, value, offset, littleEndian) { if (value < 0) value = 0xffff + value + 1; for (var i = 0, j = Math.min(buf.length - offset, 2); i < j; ++i) { buf[offset + i] = (value & 0xff << 8 * (littleEndian ? i : 1 - i)) >>> (littleEndian ? i : 1 - i) * 8; } } Buffer$1.prototype.writeUInt16LE = function writeUInt16LE(value, offset, noAssert) { value = +value; offset = offset | 0; if (!noAssert) checkInt(this, value, offset, 2, 0xffff, 0); if (Buffer$1.TYPED_ARRAY_SUPPORT) { this[offset] = value & 0xff; this[offset + 1] = value >>> 8; } else { objectWriteUInt16(this, value, offset, true); } return offset + 2; }; Buffer$1.prototype.writeUInt16BE = function writeUInt16BE(value, offset, noAssert) { value = +value; offset = offset | 0; if (!noAssert) checkInt(this, value, offset, 2, 0xffff, 0); if (Buffer$1.TYPED_ARRAY_SUPPORT) { this[offset] = value >>> 8; this[offset + 1] = value & 0xff; } else { objectWriteUInt16(this, value, offset, false); } return offset + 2; }; function objectWriteUInt32(buf, value, offset, littleEndian) { if (value < 0) value = 0xffffffff + value + 1; for (var i = 0, j = Math.min(buf.length - offset, 4); i < j; ++i) { buf[offset + i] = value >>> (littleEndian ? i : 3 - i) * 8 & 0xff; } } Buffer$1.prototype.writeUInt32LE = function writeUInt32LE(value, offset, noAssert) { value = +value; offset = offset | 0; if (!noAssert) checkInt(this, value, offset, 4, 0xffffffff, 0); if (Buffer$1.TYPED_ARRAY_SUPPORT) { this[offset + 3] = value >>> 24; this[offset + 2] = value >>> 16; this[offset + 1] = value >>> 8; this[offset] = value & 0xff; } else { objectWriteUInt32(this, value, offset, true); } return offset + 4; }; Buffer$1.prototype.writeUInt32BE = function writeUInt32BE(value, offset, noAssert) { value = +value; offset = offset | 0; if (!noAssert) checkInt(this, value, offset, 4, 0xffffffff, 0); if (Buffer$1.TYPED_ARRAY_SUPPORT) { this[offset] = value >>> 24; this[offset + 1] = value >>> 16; this[offset + 2] = value >>> 8; this[offset + 3] = value & 0xff; } else { objectWriteUInt32(this, value, offset, false); } return offset + 4; }; Buffer$1.prototype.writeIntLE = function writeIntLE(value, offset, byteLength, noAssert) { value = +value; offset = offset | 0; if (!noAssert) { var limit = Math.pow(2, 8 * byteLength - 1); checkInt(this, value, offset, byteLength, limit - 1, -limit); } var i = 0; var mul = 1; var sub = 0; this[offset] = value & 0xFF; while (++i < byteLength && (mul *= 0x100)) { if (value < 0 && sub === 0 && this[offset + i - 1] !== 0) { sub = 1; } this[offset + i] = (value / mul >> 0) - sub & 0xFF; } return offset + byteLength; }; Buffer$1.prototype.writeIntBE = function writeIntBE(value, offset, byteLength, noAssert) { value = +value; offset = offset | 0; if (!noAssert) { var limit = Math.pow(2, 8 * byteLength - 1); checkInt(this, value, offset, byteLength, limit - 1, -limit); } var i = byteLength - 1; var mul = 1; var sub = 0; this[offset + i] = value & 0xFF; while (--i >= 0 && (mul *= 0x100)) { if (value < 0 && sub === 0 && this[offset + i + 1] !== 0) { sub = 1; } this[offset + i] = (value / mul >> 0) - sub & 0xFF; } return offset + byteLength; }; Buffer$1.prototype.writeInt8 = function writeInt8(value, offset, noAssert) { value = +value; offset = offset | 0; if (!noAssert) checkInt(this, value, offset, 1, 0x7f, -0x80); if (!Buffer$1.TYPED_ARRAY_SUPPORT) value = Math.floor(value); if (value < 0) value = 0xff + value + 1; this[offset] = value & 0xff; return offset + 1; }; Buffer$1.prototype.writeInt16LE = function writeInt16LE(value, offset, noAssert) { value = +value; offset = offset | 0; if (!noAssert) checkInt(this, value, offset, 2, 0x7fff, -0x8000); if (Buffer$1.TYPED_ARRAY_SUPPORT) { this[offset] = value & 0xff; this[offset + 1] = value >>> 8; } else { objectWriteUInt16(this, value, offset, true); } return offset + 2; }; Buffer$1.prototype.writeInt16BE = function writeInt16BE(value, offset, noAssert) { value = +value; offset = offset | 0; if (!noAssert) checkInt(this, value, offset, 2, 0x7fff, -0x8000); if (Buffer$1.TYPED_ARRAY_SUPPORT) { this[offset] = value >>> 8; this[offset + 1] = value & 0xff; } else { objectWriteUInt16(this, value, offset, false); } return offset + 2; }; Buffer$1.prototype.writeInt32LE = function writeInt32LE(value, offset, noAssert) { value = +value; offset = offset | 0; if (!noAssert) checkInt(this, value, offset, 4, 0x7fffffff, -0x80000000); if (Buffer$1.TYPED_ARRAY_SUPPORT) { this[offset] = value & 0xff; this[offset + 1] = value >>> 8; this[offset + 2] = value >>> 16; this[offset + 3] = value >>> 24; } else { objectWriteUInt32(this, value, offset, true); } return offset + 4; }; Buffer$1.prototype.writeInt32BE = function writeInt32BE(value, offset, noAssert) { value = +value; offset = offset | 0; if (!noAssert) checkInt(this, value, offset, 4, 0x7fffffff, -0x80000000); if (value < 0) value = 0xffffffff + value + 1; if (Buffer$1.TYPED_ARRAY_SUPPORT) { this[offset] = value >>> 24; this[offset + 1] = value >>> 16; this[offset + 2] = value >>> 8; this[offset + 3] = value & 0xff; } else { objectWriteUInt32(this, value, offset, false); } return offset + 4; }; function checkIEEE754(buf, value, offset, ext, max, min) { if (offset + ext > buf.length) throw new RangeError('Index out of range'); if (offset < 0) throw new RangeError('Index out of range'); } function writeFloat(buf, value, offset, littleEndian, noAssert) { if (!noAssert) { checkIEEE754(buf, value, offset, 4); } write(buf, value, offset, littleEndian, 23, 4); return offset + 4; } Buffer$1.prototype.writeFloatLE = function writeFloatLE(value, offset, noAssert) { return writeFloat(this, value, offset, true, noAssert); }; Buffer$1.prototype.writeFloatBE = function writeFloatBE(value, offset, noAssert) { return writeFloat(this, value, offset, false, noAssert); }; function writeDouble(buf, value, offset, littleEndian, noAssert) { if (!noAssert) { checkIEEE754(buf, value, offset, 8); } write(buf, value, offset, littleEndian, 52, 8); return offset + 8; } Buffer$1.prototype.writeDoubleLE = function writeDoubleLE(value, offset, noAssert) { return writeDouble(this, value, offset, true, noAssert); }; Buffer$1.prototype.writeDoubleBE = function writeDoubleBE(value, offset, noAssert) { return writeDouble(this, value, offset, false, noAssert); }; Buffer$1.prototype.copy = function copy(target, targetStart, start, end) { if (!start) start = 0; if (!end && end !== 0) end = this.length; if (targetStart >= target.length) targetStart = target.length; if (!targetStart) targetStart = 0; if (end > 0 && end < start) end = start; if (end === start) return 0; if (target.length === 0 || this.length === 0) return 0; if (targetStart < 0) { throw new RangeError('targetStart out of bounds'); } if (start < 0 || start >= this.length) throw new RangeError('sourceStart out of bounds'); if (end < 0) throw new RangeError('sourceEnd out of bounds'); if (end > this.length) end = this.length; if (target.length - targetStart < end - start) { end = target.length - targetStart + start; } var len = end - start; var i; if (this === target && start < targetStart && targetStart < end) { for (i = len - 1; i >= 0; --i) { target[i + targetStart] = this[i + start]; } } else if (len < 1000 || !Buffer$1.TYPED_ARRAY_SUPPORT) { for (i = 0; i < len; ++i) { target[i + targetStart] = this[i + start]; } } else { Uint8Array.prototype.set.call(target, this.subarray(start, start + len), targetStart); } return len; }; Buffer$1.prototype.fill = function fill(val, start, end, encoding) { if (typeof val === 'string') { if (typeof start === 'string') { encoding = start; start = 0; end = this.length; } else if (typeof end === 'string') { encoding = end; end = this.length; } if (val.length === 1) { var code = val.charCodeAt(0); if (code < 256) { val = code; } } if (encoding !== undefined && typeof encoding !== 'string') { throw new TypeError('encoding must be a string'); } if (typeof encoding === 'string' && !Buffer$1.isEncoding(encoding)) { throw new TypeError('Unknown encoding: ' + encoding); } } else if (typeof val === 'number') { val = val & 255; } if (start < 0 || this.length < start || this.length < end) { throw new RangeError('Out of range index'); } if (end <= start) { return this; } start = start >>> 0; end = end === undefined ? this.length : end >>> 0; if (!val) val = 0; var i; if (typeof val === 'number') { for (i = start; i < end; ++i) { this[i] = val; } } else { var bytes = internalIsBuffer(val) ? val : utf8ToBytes(new Buffer$1(val, encoding).toString()); var len = bytes.length; for (i = 0; i < end - start; ++i) { this[i + start] = bytes[i % len]; } } return this; }; var INVALID_BASE64_RE = /[^+\/0-9A-Za-z-_]/g; function base64clean(str) { str = stringtrim(str).replace(INVALID_BASE64_RE, ''); if (str.length < 2) return ''; while (str.length % 4 !== 0) { str = str + '='; } return str; } function stringtrim(str) { if (str.trim) return str.trim(); return str.replace(/^\s+|\s+$/g, ''); } function toHex(n) { if (n < 16) return '0' + n.toString(16); return n.toString(16); } function utf8ToBytes(string, units) { units = units || Infinity; var codePoint; var length = string.length; var leadSurrogate = null; var bytes = []; for (var i = 0; i < length; ++i) { codePoint = string.charCodeAt(i); if (codePoint > 0xD7FF && codePoint < 0xE000) { if (!leadSurrogate) { if (codePoint > 0xDBFF) { if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD); continue; } else if (i + 1 === length) { if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD); continue; } leadSurrogate = codePoint; continue; } if (codePoint < 0xDC00) { if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD); leadSurrogate = codePoint; continue; } codePoint = (leadSurrogate - 0xD800 << 10 | codePoint - 0xDC00) + 0x10000; } else if (leadSurrogate) { if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD); } leadSurrogate = null; if (codePoint < 0x80) { if ((units -= 1) < 0) break; bytes.push(codePoint); } else if (codePoint < 0x800) { if ((units -= 2) < 0) break; bytes.push(codePoint >> 0x6 | 0xC0, codePoint & 0x3F | 0x80); } else if (codePoint < 0x10000) { if ((units -= 3) < 0) break; bytes.push(codePoint >> 0xC | 0xE0, codePoint >> 0x6 & 0x3F | 0x80, codePoint & 0x3F | 0x80); } else if (codePoint < 0x110000) { if ((units -= 4) < 0) break; bytes.push(codePoint >> 0x12 | 0xF0, codePoint >> 0xC & 0x3F | 0x80, codePoint >> 0x6 & 0x3F | 0x80, codePoint & 0x3F | 0x80); } else { throw new Error('Invalid code point'); } } return bytes; } function asciiToBytes(str) { var byteArray = []; for (var i = 0; i < str.length; ++i) { byteArray.push(str.charCodeAt(i) & 0xFF); } return byteArray; } function utf16leToBytes(str, units) { var c, hi, lo; var byteArray = []; for (var i = 0; i < str.length; ++i) { if ((units -= 2) < 0) break; c = str.charCodeAt(i); hi = c >> 8; lo = c % 256; byteArray.push(lo); byteArray.push(hi); } return byteArray; } function base64ToBytes(str) { return toByteArray(base64clean(str)); } function blitBuffer(src, dst, offset, length) { for (var i = 0; i < length; ++i) { if (i + offset >= dst.length || i >= src.length) break; dst[i + offset] = src[i]; } return i; } function isnan(val) { return val !== val; } function isBuffer(obj) { return obj != null && (!!obj._isBuffer || isFastBuffer(obj) || isSlowBuffer(obj)); } function isFastBuffer(obj) { return !!obj.constructor && typeof obj.constructor.isBuffer === 'function' && obj.constructor.isBuffer(obj); } function isSlowBuffer(obj) { return typeof obj.readFloatLE === 'function' && typeof obj.slice === 'function' && isFastBuffer(obj.slice(0, 0)); } var bufferEs6 = /*#__PURE__*/Object.freeze({ __proto__: null, INSPECT_MAX_BYTES: INSPECT_MAX_BYTES, kMaxLength: _kMaxLength, Buffer: Buffer$1, SlowBuffer: SlowBuffer, isBuffer: isBuffer }); var object = {}; var hasOwnProperty$c = object.hasOwnProperty; var forOwn = function forOwn(object, callback) { for (var key in object) { if (hasOwnProperty$c.call(object, key)) { callback(key, object[key]); } } }; var extend = function extend(destination, source) { if (!source) { return destination; } forOwn(source, function (key, value) { destination[key] = value; }); return destination; }; var forEach = function forEach(array, callback) { var length = array.length; var index = -1; while (++index < length) { callback(array[index]); } }; var toString$2 = object.toString; var isArray$2 = Array.isArray; var isBuffer$1 = isBuffer; var isObject$1 = function isObject(value) { return toString$2.call(value) == '[object Object]'; }; var isString$1 = function isString(value) { return typeof value == 'string' || toString$2.call(value) == '[object String]'; }; var isNumber = function isNumber(value) { return typeof value == 'number' || toString$2.call(value) == '[object Number]'; }; var isFunction$2 = function isFunction(value) { return typeof value == 'function'; }; var isMap$1 = function isMap(value) { return toString$2.call(value) == '[object Map]'; }; var isSet$1 = function isSet(value) { return toString$2.call(value) == '[object Set]'; }; var singleEscapes = { '"': '\\"', '\'': '\\\'', '\\': '\\\\', '\b': '\\b', '\f': '\\f', '\n': '\\n', '\r': '\\r', '\t': '\\t' }; var regexSingleEscape = /["'\\\b\f\n\r\t]/; var regexDigit = /[0-9]/; var regexWhitelist = /[ !#-&\(-\[\]-_a-~]/; var jsesc = function jsesc(argument, options) { var increaseIndentation = function increaseIndentation() { oldIndent = indent; ++options.indentLevel; indent = options.indent.repeat(options.indentLevel); }; var defaults = { 'escapeEverything': false, 'minimal': false, 'isScriptContext': false, 'quotes': 'single', 'wrap': false, 'es6': false, 'json': false, 'compact': true, 'lowercaseHex': false, 'numbers': 'decimal', 'indent': '\t', 'indentLevel': 0, '__inline1__': false, '__inline2__': false }; var json = options && options.json; if (json) { defaults.quotes = 'double'; defaults.wrap = true; } options = extend(defaults, options); if (options.quotes != 'single' && options.quotes != 'double' && options.quotes != 'backtick') { options.quotes = 'single'; } var quote = options.quotes == 'double' ? '"' : options.quotes == 'backtick' ? '`' : '\''; var compact = options.compact; var lowercaseHex = options.lowercaseHex; var indent = options.indent.repeat(options.indentLevel); var oldIndent = ''; var inline1 = options.__inline1__; var inline2 = options.__inline2__; var newLine = compact ? '' : '\n'; var result; var isEmpty = true; var useBinNumbers = options.numbers == 'binary'; var useOctNumbers = options.numbers == 'octal'; var useDecNumbers = options.numbers == 'decimal'; var useHexNumbers = options.numbers == 'hexadecimal'; if (json && argument && isFunction$2(argument.toJSON)) { argument = argument.toJSON(); } if (!isString$1(argument)) { if (isMap$1(argument)) { if (argument.size == 0) { return 'new Map()'; } if (!compact) { options.__inline1__ = true; options.__inline2__ = false; } return 'new Map(' + jsesc(Array.from(argument), options) + ')'; } if (isSet$1(argument)) { if (argument.size == 0) { return 'new Set()'; } return 'new Set(' + jsesc(Array.from(argument), options) + ')'; } if (isBuffer$1(argument)) { if (argument.length == 0) { return 'Buffer.from([])'; } return 'Buffer.from(' + jsesc(Array.from(argument), options) + ')'; } if (isArray$2(argument)) { result = []; options.wrap = true; if (inline1) { options.__inline1__ = false; options.__inline2__ = true; } if (!inline2) { increaseIndentation(); } forEach(argument, function (value) { isEmpty = false; if (inline2) { options.__inline2__ = false; } result.push((compact || inline2 ? '' : indent) + jsesc(value, options)); }); if (isEmpty) { return '[]'; } if (inline2) { return '[' + result.join(', ') + ']'; } return '[' + newLine + result.join(',' + newLine) + newLine + (compact ? '' : oldIndent) + ']'; } else if (isNumber(argument)) { if (json) { return JSON.stringify(argument); } if (useDecNumbers) { return String(argument); } if (useHexNumbers) { var hexadecimal = argument.toString(16); if (!lowercaseHex) { hexadecimal = hexadecimal.toUpperCase(); } return '0x' + hexadecimal; } if (useBinNumbers) { return '0b' + argument.toString(2); } if (useOctNumbers) { return '0o' + argument.toString(8); } } else if (!isObject$1(argument)) { if (json) { return JSON.stringify(argument) || 'null'; } return String(argument); } else { result = []; options.wrap = true; increaseIndentation(); forOwn(argument, function (key, value) { isEmpty = false; result.push((compact ? '' : indent) + jsesc(key, options) + ':' + (compact ? '' : ' ') + jsesc(value, options)); }); if (isEmpty) { return '{}'; } return '{' + newLine + result.join(',' + newLine) + newLine + (compact ? '' : oldIndent) + '}'; } } var string = argument; var index = -1; var length = string.length; result = ''; while (++index < length) { var character = string.charAt(index); if (options.es6) { var first = string.charCodeAt(index); if (first >= 0xD800 && first <= 0xDBFF && length > index + 1) { var second = string.charCodeAt(index + 1); if (second >= 0xDC00 && second <= 0xDFFF) { var codePoint = (first - 0xD800) * 0x400 + second - 0xDC00 + 0x10000; var _hexadecimal2 = codePoint.toString(16); if (!lowercaseHex) { _hexadecimal2 = _hexadecimal2.toUpperCase(); } result += "\\u{" + _hexadecimal2 + '}'; ++index; continue; } } } if (!options.escapeEverything) { if (regexWhitelist.test(character)) { result += character; continue; } if (character == '"') { result += quote == character ? '\\"' : character; continue; } if (character == '`') { result += quote == character ? '\\`' : character; continue; } if (character == '\'') { result += quote == character ? '\\\'' : character; continue; } } if (character == '\0' && !json && !regexDigit.test(string.charAt(index + 1))) { result += '\\0'; continue; } if (regexSingleEscape.test(character)) { result += singleEscapes[character]; continue; } var charCode = character.charCodeAt(0); if (options.minimal && charCode != 0x2028 && charCode != 0x2029) { result += character; continue; } var _hexadecimal = charCode.toString(16); if (!lowercaseHex) { _hexadecimal = _hexadecimal.toUpperCase(); } var longhand = _hexadecimal.length > 2 || json; var escaped = '\\' + (longhand ? 'u' : 'x') + ('0000' + _hexadecimal).slice(longhand ? -4 : -2); result += escaped; continue; } if (options.wrap) { result = quote + result + quote; } if (quote == '`') { result = result.replace(/\$\{/g, '\\\$\{'); } if (options.isScriptContext) { return result.replace(/<\/(script|style)/gi, '<\\/$1').replace(/