From 715e673d06e8e92d416c1079c0db83d5dae9606c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C3=ABl=20Zasso?= Date: Fri, 22 Dec 2017 17:00:24 +0100 Subject: [PATCH] tools: add babel-eslint Create tools/update-babel-eslint.sh script and execute it to do the first installation of the package. Update tools/license-builder.sh and execute it to add babel-eslint's license to our LICENSE file. PR-URL: https://github.com/nodejs/node/pull/17820 Reviewed-By: Matteo Collina Reviewed-By: Benjamin Gruenbaum --- LICENSE | 26 + tools/license-builder.sh | 1 + tools/node_modules/babel-eslint/LICENSE | 22 + tools/node_modules/babel-eslint/README.md | 102 + .../babel-eslint/lib/analyze-scope.js | 338 + .../lib/babylon-to-espree/attachComments.js | 59 + .../lib/babylon-to-espree/convertComments.js | 17 + .../babylon-to-espree/convertTemplateType.js | 99 + .../lib/babylon-to-espree/index.js | 35 + .../lib/babylon-to-espree/toAST.js | 118 + .../lib/babylon-to-espree/toToken.js | 80 + .../lib/babylon-to-espree/toTokens.js | 19 + tools/node_modules/babel-eslint/lib/index.js | 22 + .../babel-eslint/lib/parse-with-patch.js | 9 + .../babel-eslint/lib/parse-with-scope.js | 12 + tools/node_modules/babel-eslint/lib/parse.js | 87 + .../babel-eslint/lib/patch-eslint-scope.js | 370 + .../babel-eslint/lib/visitor-keys.js | 15 + .../node_modules/@babel/code-frame/README.md | 126 + .../@babel/code-frame/lib/index.js | 232 + .../@babel/code-frame/package.json | 52 + .../@babel/helper-function-name/README.md | 5 + .../@babel/helper-function-name/lib/index.js | 129 + .../@babel/helper-function-name/package.json | 42 + .../helper-get-function-arity/README.md | 21 + .../helper-get-function-arity/lib/index.js | 22 + .../helper-get-function-arity/package.json | 40 + .../node_modules/@babel/template/README.md | 172 + .../@babel/template/lib/builder.js | 89 + .../@babel/template/lib/formatters.js | 73 + .../node_modules/@babel/template/lib/index.js | 34 + .../@babel/template/lib/literal.js | 81 + .../@babel/template/lib/options.js | 67 + .../node_modules/@babel/template/lib/parse.js | 130 + .../@babel/template/lib/populate.js | 120 + .../@babel/template/lib/string.js | 22 + .../node_modules/@babel/template/package.json | 48 + .../node_modules/@babel/traverse/README.md | 33 + .../node_modules/@babel/traverse/lib/cache.js | 24 + .../@babel/traverse/lib/context.js | 187 + .../node_modules/@babel/traverse/lib/hub.js | 10 + .../node_modules/@babel/traverse/lib/index.js | 112 + .../@babel/traverse/lib/path/ancestry.js | 192 + .../@babel/traverse/lib/path/comments.js | 37 + .../@babel/traverse/lib/path/context.js | 273 + .../@babel/traverse/lib/path/conversion.js | 446 + .../@babel/traverse/lib/path/evaluation.js | 451 + .../@babel/traverse/lib/path/family.js | 244 + .../@babel/traverse/lib/path/index.js | 228 + .../traverse/lib/path/inference/index.js | 126 + .../lib/path/inference/inferer-reference.js | 175 + .../traverse/lib/path/inference/inferers.js | 207 + .../@babel/traverse/lib/path/introspection.js | 361 + .../@babel/traverse/lib/path/lib/hoister.js | 182 + .../traverse/lib/path/lib/removal-hooks.js | 36 + .../traverse/lib/path/lib/virtual-types.js | 172 + .../@babel/traverse/lib/path/modification.js | 216 + .../@babel/traverse/lib/path/removal.js | 58 + .../@babel/traverse/lib/path/replacement.js | 251 + .../@babel/traverse/lib/scope/binding.js | 79 + .../@babel/traverse/lib/scope/index.js | 970 + .../@babel/traverse/lib/scope/lib/renamer.js | 131 + .../@babel/traverse/lib/visitors.js | 292 + .../node_modules/@babel/traverse/package.json | 56 + .../node_modules/@babel/types/README.md | 2835 +++ .../@babel/types/lib/asserts/assertNode.js | 15 + .../types/lib/asserts/generated/index.js | 2215 ++ .../@babel/types/lib/builders/builder.js | 44 + .../flow/createTypeAnnotationBasedOnTypeof.js | 26 + .../flow/createUnionTypeAnnotation.js | 20 + .../types/lib/builders/generated/index.js | 1869 ++ .../types/lib/builders/react/buildChildren.js | 29 + .../@babel/types/lib/clone/clone.js | 14 + .../@babel/types/lib/clone/cloneDeep.js | 24 + .../@babel/types/lib/clone/cloneWithoutLoc.js | 14 + .../@babel/types/lib/comments/addComment.js | 15 + .../@babel/types/lib/comments/addComments.js | 21 + .../lib/comments/inheritInnerComments.js | 12 + .../lib/comments/inheritLeadingComments.js | 12 + .../lib/comments/inheritTrailingComments.js | 12 + .../types/lib/comments/inheritsComments.js | 19 + .../types/lib/comments/removeComments.js | 14 + .../types/lib/constants/generated/index.js | 87 + .../@babel/types/lib/constants/index.js | 45 + .../types/lib/converters/ensureBlock.js | 16 + .../converters/gatherSequenceExpressions.js | 83 + .../lib/converters/toBindingIdentifierName.js | 14 + .../@babel/types/lib/converters/toBlock.js | 32 + .../types/lib/converters/toComputedKey.js | 17 + .../types/lib/converters/toExpression.js | 28 + .../types/lib/converters/toIdentifier.js | 23 + .../@babel/types/lib/converters/toKeyAlias.js | 50 + .../lib/converters/toSequenceExpression.js | 22 + .../types/lib/converters/toStatement.js | 42 + .../types/lib/converters/valueToNode.js | 66 + .../@babel/types/lib/definitions/core.js | 693 + .../@babel/types/lib/definitions/es2015.js | 379 + .../types/lib/definitions/experimental.js | 84 + .../@babel/types/lib/definitions/flow.js | 263 + .../@babel/types/lib/definitions/index.js | 40 + .../@babel/types/lib/definitions/jsx.js | 156 + .../@babel/types/lib/definitions/misc.js | 18 + .../types/lib/definitions/typescript.js | 413 + .../@babel/types/lib/definitions/utils.js | 198 + .../node_modules/@babel/types/lib/index.js | 325 + .../modifications/appendToMemberExpression.js | 17 + .../flow/removeTypeDuplicates.js | 72 + .../types/lib/modifications/inherits.js | 37 + .../prependToMemberExpression.js | 11 + .../lib/modifications/removeProperties.js | 56 + .../lib/modifications/removePropertiesDeep.js | 15 + .../lib/retrievers/getBindingIdentifiers.js | 95 + .../retrievers/getOuterBindingIdentifiers.js | 12 + .../@babel/types/lib/traverse/traverse.js | 64 + .../@babel/types/lib/traverse/traverseFast.js | 50 + .../@babel/types/lib/utils/inherit.js | 14 + .../react/cleanJSXElementLiteralChild.js | 45 + .../@babel/types/lib/utils/shallowEqual.js | 19 + .../validators/buildMatchMemberExpression.js | 15 + .../types/lib/validators/generated/index.js | 1241 ++ .../@babel/types/lib/validators/is.js | 22 + .../@babel/types/lib/validators/isBinding.js | 27 + .../types/lib/validators/isBlockScoped.js | 14 + .../types/lib/validators/isImmutable.js | 24 + .../@babel/types/lib/validators/isLet.js | 12 + .../@babel/types/lib/validators/isNode.js | 10 + .../types/lib/validators/isNodesEquivalent.js | 50 + .../types/lib/validators/isReferenced.js | 99 + .../@babel/types/lib/validators/isScope.js | 22 + .../lib/validators/isSpecifierDefault.js | 12 + .../@babel/types/lib/validators/isType.js | 34 + .../lib/validators/isValidES3Identifier.js | 14 + .../types/lib/validators/isValidIdentifier.js | 18 + .../@babel/types/lib/validators/isVar.js | 14 + .../types/lib/validators/matchesPattern.js | 38 + .../types/lib/validators/react/isCompatTag.js | 8 + .../lib/validators/react/isReactComponent.js | 12 + .../@babel/types/lib/validators/validate.js | 16 + .../node_modules/@babel/types/package.json | 55 + .../types/scripts/generateTypeHelpers.js | 31 + .../scripts/generators/generateAsserts.js | 43 + .../scripts/generators/generateBuilders.js | 43 + .../scripts/generators/generateConstants.js | 17 + .../scripts/generators/generateValidators.js | 35 + .../types/scripts/utils/formatBuilderName.js | 9 + .../@babel/types/scripts/utils/formatCode.js | 9 + .../@babel/types/scripts/utils/lowerFirst.js | 4 + .../node_modules/ansi-styles/index.js | 152 + .../node_modules/ansi-styles/license | 9 + .../node_modules/ansi-styles/package.json | 86 + .../node_modules/ansi-styles/readme.md | 147 + .../babel-eslint/node_modules/babylon/LICENSE | 19 + .../node_modules/babylon/README.md | 163 + .../node_modules/babylon/bin/babylon.js | 16 + .../node_modules/babylon/lib/index.js | 10635 ++++++++++ .../node_modules/babylon/package.json | 74 + .../babel-eslint/node_modules/chalk/index.js | 228 + .../babel-eslint/node_modules/chalk/license | 9 + .../node_modules/chalk/package.json | 98 + .../babel-eslint/node_modules/chalk/readme.md | 309 + .../node_modules/chalk/templates.js | 128 + .../node_modules/chalk/types/index.d.ts | 97 + .../node_modules/color-convert/LICENSE | 21 + .../node_modules/color-convert/README.md | 68 + .../node_modules/color-convert/conversions.js | 861 + .../node_modules/color-convert/index.js | 78 + .../node_modules/color-convert/package.json | 81 + .../node_modules/color-convert/route.js | 97 + .../node_modules/color-name/.eslintrc.json | 43 + .../node_modules/color-name/LICENSE | 8 + .../node_modules/color-name/README.md | 11 + .../node_modules/color-name/index.js | 152 + .../node_modules/color-name/package.json | 53 + .../node_modules/debug/.coveralls.yml | 1 + .../babel-eslint/node_modules/debug/LICENSE | 19 + .../babel-eslint/node_modules/debug/Makefile | 58 + .../babel-eslint/node_modules/debug/README.md | 368 + .../node_modules/debug/karma.conf.js | 70 + .../babel-eslint/node_modules/debug/node.js | 1 + .../node_modules/debug/package.json | 82 + .../node_modules/debug/src/browser.js | 195 + .../node_modules/debug/src/debug.js | 225 + .../node_modules/debug/src/index.js | 10 + .../node_modules/debug/src/node.js | 186 + .../escape-string-regexp/index.js | 11 + .../node_modules/escape-string-regexp/license | 21 + .../escape-string-regexp/package.json | 81 + .../escape-string-regexp/readme.md | 27 + .../node_modules/eslint-scope/LICENSE | 23 + .../node_modules/eslint-scope/README.md | 54 + .../eslint-scope/lib/definition.js | 86 + .../node_modules/eslint-scope/lib/index.js | 165 + .../eslint-scope/lib/pattern-visitor.js | 152 + .../eslint-scope/lib/reference.js | 167 + .../eslint-scope/lib/referencer.js | 638 + .../eslint-scope/lib/scope-manager.js | 255 + .../node_modules/eslint-scope/lib/scope.js | 722 + .../node_modules/eslint-scope/lib/variable.js | 89 + .../node_modules/eslint-scope/package.json | 74 + .../node_modules/eslint-visitor-keys/LICENSE | 201 + .../eslint-visitor-keys/README.md | 98 + .../eslint-visitor-keys/lib/index.js | 81 + .../eslint-visitor-keys/lib/visitor-keys.json | 277 + .../eslint-visitor-keys/package.json | 68 + .../node_modules/esrecurse/.babelrc | 3 + .../node_modules/esrecurse/README.md | 170 + .../node_modules/esrecurse/esrecurse.js | 135 + .../node_modules/esrecurse/package-lock.json | 4322 ++++ .../node_modules/esrecurse/package.json | 81 + .../node_modules/estraverse/.babelrc | 3 + .../node_modules/estraverse/LICENSE.BSD | 19 + .../node_modules/estraverse/estraverse.js | 849 + .../node_modules/estraverse/package.json | 69 + .../node_modules/esutils/LICENSE.BSD | 19 + .../node_modules/esutils/README.md | 169 + .../node_modules/esutils/lib/ast.js | 144 + .../node_modules/esutils/lib/code.js | 135 + .../node_modules/esutils/lib/keyword.js | 165 + .../node_modules/esutils/lib/utils.js | 33 + .../node_modules/esutils/package.json | 78 + .../node_modules/globals/globals.json | 1456 ++ .../node_modules/globals/index.js | 2 + .../babel-eslint/node_modules/globals/license | 9 + .../node_modules/globals/package.json | 73 + .../node_modules/globals/readme.md | 41 + .../node_modules/has-flag/index.js | 10 + .../node_modules/has-flag/license | 21 + .../node_modules/has-flag/package.json | 93 + .../node_modules/has-flag/readme.md | 67 + .../node_modules/invariant/LICENSE | 27 + .../node_modules/invariant/README.md | 37 + .../node_modules/invariant/browser.js | 51 + .../node_modules/invariant/invariant.js | 53 + .../node_modules/invariant/invariant.js.flow | 7 + .../node_modules/invariant/package.json | 70 + .../node_modules/js-tokens/LICENSE | 21 + .../node_modules/js-tokens/README.md | 222 + .../node_modules/js-tokens/index.js | 23 + .../node_modules/js-tokens/package.json | 65 + .../babel-eslint/node_modules/lodash/LICENSE | 47 + .../node_modules/lodash/README.md | 39 + .../node_modules/lodash/_DataView.js | 7 + .../babel-eslint/node_modules/lodash/_Hash.js | 32 + .../node_modules/lodash/_LazyWrapper.js | 28 + .../node_modules/lodash/_ListCache.js | 32 + .../node_modules/lodash/_LodashWrapper.js | 22 + .../babel-eslint/node_modules/lodash/_Map.js | 7 + .../node_modules/lodash/_MapCache.js | 32 + .../node_modules/lodash/_Promise.js | 7 + .../babel-eslint/node_modules/lodash/_Set.js | 7 + .../node_modules/lodash/_SetCache.js | 27 + .../node_modules/lodash/_Stack.js | 27 + .../node_modules/lodash/_Symbol.js | 6 + .../node_modules/lodash/_Uint8Array.js | 6 + .../node_modules/lodash/_WeakMap.js | 7 + .../node_modules/lodash/_addMapEntry.js | 15 + .../node_modules/lodash/_addSetEntry.js | 15 + .../node_modules/lodash/_apply.js | 21 + .../node_modules/lodash/_arrayAggregator.js | 22 + .../node_modules/lodash/_arrayEach.js | 22 + .../node_modules/lodash/_arrayEachRight.js | 21 + .../node_modules/lodash/_arrayEvery.js | 23 + .../node_modules/lodash/_arrayFilter.js | 25 + .../node_modules/lodash/_arrayIncludes.js | 17 + .../node_modules/lodash/_arrayIncludesWith.js | 22 + .../node_modules/lodash/_arrayLikeKeys.js | 49 + .../node_modules/lodash/_arrayMap.js | 21 + .../node_modules/lodash/_arrayPush.js | 20 + .../node_modules/lodash/_arrayReduce.js | 26 + .../node_modules/lodash/_arrayReduceRight.js | 24 + .../node_modules/lodash/_arraySample.js | 15 + .../node_modules/lodash/_arraySampleSize.js | 17 + .../node_modules/lodash/_arrayShuffle.js | 15 + .../node_modules/lodash/_arraySome.js | 23 + .../node_modules/lodash/_asciiSize.js | 12 + .../node_modules/lodash/_asciiToArray.js | 12 + .../node_modules/lodash/_asciiWords.js | 15 + .../node_modules/lodash/_assignMergeValue.js | 20 + .../node_modules/lodash/_assignValue.js | 28 + .../node_modules/lodash/_assocIndexOf.js | 21 + .../node_modules/lodash/_baseAggregator.js | 21 + .../node_modules/lodash/_baseAssign.js | 17 + .../node_modules/lodash/_baseAssignIn.js | 17 + .../node_modules/lodash/_baseAssignValue.js | 25 + .../node_modules/lodash/_baseAt.js | 23 + .../node_modules/lodash/_baseClamp.js | 22 + .../node_modules/lodash/_baseClone.js | 153 + .../node_modules/lodash/_baseConforms.js | 18 + .../node_modules/lodash/_baseConformsTo.js | 27 + .../node_modules/lodash/_baseCreate.js | 30 + .../node_modules/lodash/_baseDelay.js | 21 + .../node_modules/lodash/_baseDifference.js | 67 + .../node_modules/lodash/_baseEach.js | 14 + .../node_modules/lodash/_baseEachRight.js | 14 + .../node_modules/lodash/_baseEvery.js | 21 + .../node_modules/lodash/_baseExtremum.js | 32 + .../node_modules/lodash/_baseFill.js | 32 + .../node_modules/lodash/_baseFilter.js | 21 + .../node_modules/lodash/_baseFindIndex.js | 24 + .../node_modules/lodash/_baseFindKey.js | 23 + .../node_modules/lodash/_baseFlatten.js | 38 + .../node_modules/lodash/_baseFor.js | 16 + .../node_modules/lodash/_baseForOwn.js | 16 + .../node_modules/lodash/_baseForOwnRight.js | 16 + .../node_modules/lodash/_baseForRight.js | 15 + .../node_modules/lodash/_baseFunctions.js | 19 + .../node_modules/lodash/_baseGet.js | 24 + .../node_modules/lodash/_baseGetAllKeys.js | 20 + .../node_modules/lodash/_baseGetTag.js | 28 + .../node_modules/lodash/_baseGt.js | 14 + .../node_modules/lodash/_baseHas.js | 19 + .../node_modules/lodash/_baseHasIn.js | 13 + .../node_modules/lodash/_baseInRange.js | 18 + .../node_modules/lodash/_baseIndexOf.js | 20 + .../node_modules/lodash/_baseIndexOfWith.js | 23 + .../node_modules/lodash/_baseIntersection.js | 74 + .../node_modules/lodash/_baseInverter.js | 21 + .../node_modules/lodash/_baseInvoke.js | 24 + .../node_modules/lodash/_baseIsArguments.js | 18 + .../node_modules/lodash/_baseIsArrayBuffer.js | 17 + .../node_modules/lodash/_baseIsDate.js | 18 + .../node_modules/lodash/_baseIsEqual.js | 28 + .../node_modules/lodash/_baseIsEqualDeep.js | 83 + .../node_modules/lodash/_baseIsMap.js | 18 + .../node_modules/lodash/_baseIsMatch.js | 62 + .../node_modules/lodash/_baseIsNaN.js | 12 + .../node_modules/lodash/_baseIsNative.js | 47 + .../node_modules/lodash/_baseIsRegExp.js | 18 + .../node_modules/lodash/_baseIsSet.js | 18 + .../node_modules/lodash/_baseIsTypedArray.js | 60 + .../node_modules/lodash/_baseIteratee.js | 31 + .../node_modules/lodash/_baseKeys.js | 30 + .../node_modules/lodash/_baseKeysIn.js | 33 + .../node_modules/lodash/_baseLodash.js | 10 + .../node_modules/lodash/_baseLt.js | 14 + .../node_modules/lodash/_baseMap.js | 22 + .../node_modules/lodash/_baseMatches.js | 22 + .../lodash/_baseMatchesProperty.js | 33 + .../node_modules/lodash/_baseMean.js | 20 + .../node_modules/lodash/_baseMerge.js | 41 + .../node_modules/lodash/_baseMergeDeep.js | 93 + .../node_modules/lodash/_baseNth.js | 20 + .../node_modules/lodash/_baseOrderBy.js | 34 + .../node_modules/lodash/_basePick.js | 19 + .../node_modules/lodash/_basePickBy.js | 30 + .../node_modules/lodash/_baseProperty.js | 14 + .../node_modules/lodash/_basePropertyDeep.js | 16 + .../node_modules/lodash/_basePropertyOf.js | 14 + .../node_modules/lodash/_basePullAll.js | 51 + .../node_modules/lodash/_basePullAt.js | 37 + .../node_modules/lodash/_baseRandom.js | 18 + .../node_modules/lodash/_baseRange.js | 28 + .../node_modules/lodash/_baseReduce.js | 23 + .../node_modules/lodash/_baseRepeat.js | 35 + .../node_modules/lodash/_baseRest.js | 17 + .../node_modules/lodash/_baseSample.js | 15 + .../node_modules/lodash/_baseSampleSize.js | 18 + .../node_modules/lodash/_baseSet.js | 47 + .../node_modules/lodash/_baseSetData.js | 17 + .../node_modules/lodash/_baseSetToString.js | 22 + .../node_modules/lodash/_baseShuffle.js | 15 + .../node_modules/lodash/_baseSlice.js | 31 + .../node_modules/lodash/_baseSome.js | 22 + .../node_modules/lodash/_baseSortBy.js | 21 + .../node_modules/lodash/_baseSortedIndex.js | 42 + .../node_modules/lodash/_baseSortedIndexBy.js | 64 + .../node_modules/lodash/_baseSortedUniq.js | 30 + .../node_modules/lodash/_baseSum.js | 24 + .../node_modules/lodash/_baseTimes.js | 20 + .../node_modules/lodash/_baseToNumber.js | 24 + .../node_modules/lodash/_baseToPairs.js | 18 + .../node_modules/lodash/_baseToString.js | 37 + .../node_modules/lodash/_baseUnary.js | 14 + .../node_modules/lodash/_baseUniq.js | 72 + .../node_modules/lodash/_baseUnset.js | 20 + .../node_modules/lodash/_baseUpdate.js | 18 + .../node_modules/lodash/_baseValues.js | 19 + .../node_modules/lodash/_baseWhile.js | 26 + .../node_modules/lodash/_baseWrapperValue.js | 25 + .../node_modules/lodash/_baseXor.js | 36 + .../node_modules/lodash/_baseZipObject.js | 23 + .../node_modules/lodash/_cacheHas.js | 13 + .../lodash/_castArrayLikeObject.js | 14 + .../node_modules/lodash/_castFunction.js | 14 + .../node_modules/lodash/_castPath.js | 21 + .../node_modules/lodash/_castRest.js | 14 + .../node_modules/lodash/_castSlice.js | 18 + .../node_modules/lodash/_charsEndIndex.js | 19 + .../node_modules/lodash/_charsStartIndex.js | 20 + .../node_modules/lodash/_cloneArrayBuffer.js | 16 + .../node_modules/lodash/_cloneBuffer.js | 35 + .../node_modules/lodash/_cloneDataView.js | 16 + .../node_modules/lodash/_cloneMap.js | 22 + .../node_modules/lodash/_cloneRegExp.js | 17 + .../node_modules/lodash/_cloneSet.js | 22 + .../node_modules/lodash/_cloneSymbol.js | 18 + .../node_modules/lodash/_cloneTypedArray.js | 16 + .../node_modules/lodash/_compareAscending.js | 41 + .../node_modules/lodash/_compareMultiple.js | 44 + .../node_modules/lodash/_composeArgs.js | 39 + .../node_modules/lodash/_composeArgsRight.js | 41 + .../node_modules/lodash/_copyArray.js | 20 + .../node_modules/lodash/_copyObject.js | 40 + .../node_modules/lodash/_copySymbols.js | 16 + .../node_modules/lodash/_copySymbolsIn.js | 16 + .../node_modules/lodash/_coreJsData.js | 6 + .../node_modules/lodash/_countHolders.js | 21 + .../node_modules/lodash/_createAggregator.js | 23 + .../node_modules/lodash/_createAssigner.js | 37 + .../node_modules/lodash/_createBaseEach.js | 32 + .../node_modules/lodash/_createBaseFor.js | 25 + .../node_modules/lodash/_createBind.js | 28 + .../node_modules/lodash/_createCaseFirst.js | 33 + .../node_modules/lodash/_createCompounder.js | 24 + .../node_modules/lodash/_createCtor.js | 37 + .../node_modules/lodash/_createCurry.js | 46 + .../node_modules/lodash/_createFind.js | 25 + .../node_modules/lodash/_createFlow.js | 78 + .../node_modules/lodash/_createHybrid.js | 92 + .../node_modules/lodash/_createInverter.js | 17 + .../lodash/_createMathOperation.js | 38 + .../node_modules/lodash/_createOver.js | 27 + .../node_modules/lodash/_createPadding.js | 33 + .../node_modules/lodash/_createPartial.js | 43 + .../node_modules/lodash/_createRange.js | 30 + .../node_modules/lodash/_createRecurry.js | 56 + .../lodash/_createRelationalOperation.js | 20 + .../node_modules/lodash/_createRound.js | 33 + .../node_modules/lodash/_createSet.js | 19 + .../node_modules/lodash/_createToPairs.js | 30 + .../node_modules/lodash/_createWrap.js | 106 + .../lodash/_customDefaultsAssignIn.js | 29 + .../lodash/_customDefaultsMerge.js | 28 + .../node_modules/lodash/_customOmitClone.js | 16 + .../node_modules/lodash/_deburrLetter.js | 71 + .../node_modules/lodash/_defineProperty.js | 11 + .../node_modules/lodash/_equalArrays.js | 83 + .../node_modules/lodash/_equalByTag.js | 112 + .../node_modules/lodash/_equalObjects.js | 89 + .../node_modules/lodash/_escapeHtmlChar.js | 21 + .../node_modules/lodash/_escapeStringChar.js | 22 + .../node_modules/lodash/_flatRest.js | 16 + .../node_modules/lodash/_freeGlobal.js | 4 + .../node_modules/lodash/_getAllKeys.js | 16 + .../node_modules/lodash/_getAllKeysIn.js | 17 + .../node_modules/lodash/_getData.js | 15 + .../node_modules/lodash/_getFuncName.js | 31 + .../node_modules/lodash/_getHolder.js | 13 + .../node_modules/lodash/_getMapData.js | 18 + .../node_modules/lodash/_getMatchData.js | 24 + .../node_modules/lodash/_getNative.js | 17 + .../node_modules/lodash/_getPrototype.js | 6 + .../node_modules/lodash/_getRawTag.js | 46 + .../node_modules/lodash/_getSymbols.js | 30 + .../node_modules/lodash/_getSymbolsIn.js | 25 + .../node_modules/lodash/_getTag.js | 58 + .../node_modules/lodash/_getValue.js | 13 + .../node_modules/lodash/_getView.js | 33 + .../node_modules/lodash/_getWrapDetails.js | 17 + .../node_modules/lodash/_hasPath.js | 39 + .../node_modules/lodash/_hasUnicode.js | 26 + .../node_modules/lodash/_hasUnicodeWord.js | 15 + .../node_modules/lodash/_hashClear.js | 15 + .../node_modules/lodash/_hashDelete.js | 17 + .../node_modules/lodash/_hashGet.js | 30 + .../node_modules/lodash/_hashHas.js | 23 + .../node_modules/lodash/_hashSet.js | 23 + .../node_modules/lodash/_initCloneArray.js | 26 + .../node_modules/lodash/_initCloneByTag.js | 80 + .../node_modules/lodash/_initCloneObject.js | 18 + .../node_modules/lodash/_insertWrapDetails.js | 23 + .../node_modules/lodash/_isFlattenable.js | 20 + .../node_modules/lodash/_isIndex.js | 22 + .../node_modules/lodash/_isIterateeCall.js | 30 + .../node_modules/lodash/_isKey.js | 29 + .../node_modules/lodash/_isKeyable.js | 15 + .../node_modules/lodash/_isLaziable.js | 28 + .../node_modules/lodash/_isMaskable.js | 14 + .../node_modules/lodash/_isMasked.js | 20 + .../node_modules/lodash/_isPrototype.js | 18 + .../lodash/_isStrictComparable.js | 15 + .../node_modules/lodash/_iteratorToArray.js | 18 + .../node_modules/lodash/_lazyClone.js | 23 + .../node_modules/lodash/_lazyReverse.js | 23 + .../node_modules/lodash/_lazyValue.js | 69 + .../node_modules/lodash/_listCacheClear.js | 13 + .../node_modules/lodash/_listCacheDelete.js | 35 + .../node_modules/lodash/_listCacheGet.js | 19 + .../node_modules/lodash/_listCacheHas.js | 16 + .../node_modules/lodash/_listCacheSet.js | 26 + .../node_modules/lodash/_mapCacheClear.js | 21 + .../node_modules/lodash/_mapCacheDelete.js | 18 + .../node_modules/lodash/_mapCacheGet.js | 16 + .../node_modules/lodash/_mapCacheHas.js | 16 + .../node_modules/lodash/_mapCacheSet.js | 22 + .../node_modules/lodash/_mapToArray.js | 18 + .../lodash/_matchesStrictComparable.js | 20 + .../node_modules/lodash/_memoizeCapped.js | 26 + .../node_modules/lodash/_mergeData.js | 90 + .../node_modules/lodash/_metaMap.js | 6 + .../node_modules/lodash/_nativeCreate.js | 6 + .../node_modules/lodash/_nativeKeys.js | 6 + .../node_modules/lodash/_nativeKeysIn.js | 20 + .../node_modules/lodash/_nodeUtil.js | 22 + .../node_modules/lodash/_objectToString.js | 22 + .../node_modules/lodash/_overArg.js | 15 + .../node_modules/lodash/_overRest.js | 36 + .../node_modules/lodash/_parent.js | 16 + .../node_modules/lodash/_reEscape.js | 4 + .../node_modules/lodash/_reEvaluate.js | 4 + .../node_modules/lodash/_reInterpolate.js | 4 + .../node_modules/lodash/_realNames.js | 4 + .../node_modules/lodash/_reorder.js | 29 + .../node_modules/lodash/_replaceHolders.js | 29 + .../babel-eslint/node_modules/lodash/_root.js | 9 + .../node_modules/lodash/_setCacheAdd.js | 19 + .../node_modules/lodash/_setCacheHas.js | 14 + .../node_modules/lodash/_setData.js | 20 + .../node_modules/lodash/_setToArray.js | 18 + .../node_modules/lodash/_setToPairs.js | 18 + .../node_modules/lodash/_setToString.js | 14 + .../node_modules/lodash/_setWrapToString.js | 21 + .../node_modules/lodash/_shortOut.js | 37 + .../node_modules/lodash/_shuffleSelf.js | 28 + .../node_modules/lodash/_stackClear.js | 15 + .../node_modules/lodash/_stackDelete.js | 18 + .../node_modules/lodash/_stackGet.js | 14 + .../node_modules/lodash/_stackHas.js | 14 + .../node_modules/lodash/_stackSet.js | 34 + .../node_modules/lodash/_strictIndexOf.js | 23 + .../node_modules/lodash/_strictLastIndexOf.js | 21 + .../node_modules/lodash/_stringSize.js | 18 + .../node_modules/lodash/_stringToArray.js | 18 + .../node_modules/lodash/_stringToPath.js | 28 + .../node_modules/lodash/_toKey.js | 21 + .../node_modules/lodash/_toSource.js | 26 + .../node_modules/lodash/_unescapeHtmlChar.js | 21 + .../node_modules/lodash/_unicodeSize.js | 44 + .../node_modules/lodash/_unicodeToArray.js | 40 + .../node_modules/lodash/_unicodeWords.js | 69 + .../node_modules/lodash/_updateWrapDetails.js | 46 + .../node_modules/lodash/_wrapperClone.js | 23 + .../babel-eslint/node_modules/lodash/add.js | 22 + .../babel-eslint/node_modules/lodash/after.js | 42 + .../babel-eslint/node_modules/lodash/array.js | 67 + .../babel-eslint/node_modules/lodash/ary.js | 29 + .../node_modules/lodash/assign.js | 58 + .../node_modules/lodash/assignIn.js | 40 + .../node_modules/lodash/assignInWith.js | 38 + .../node_modules/lodash/assignWith.js | 37 + .../babel-eslint/node_modules/lodash/at.js | 23 + .../node_modules/lodash/attempt.js | 35 + .../node_modules/lodash/before.js | 40 + .../babel-eslint/node_modules/lodash/bind.js | 57 + .../node_modules/lodash/bindAll.js | 41 + .../node_modules/lodash/bindKey.js | 68 + .../node_modules/lodash/camelCase.js | 29 + .../node_modules/lodash/capitalize.js | 23 + .../node_modules/lodash/castArray.js | 44 + .../babel-eslint/node_modules/lodash/ceil.js | 26 + .../babel-eslint/node_modules/lodash/chain.js | 38 + .../babel-eslint/node_modules/lodash/chunk.js | 50 + .../babel-eslint/node_modules/lodash/clamp.js | 39 + .../babel-eslint/node_modules/lodash/clone.js | 36 + .../node_modules/lodash/cloneDeep.js | 29 + .../node_modules/lodash/cloneDeepWith.js | 40 + .../node_modules/lodash/cloneWith.js | 42 + .../node_modules/lodash/collection.js | 30 + .../node_modules/lodash/commit.js | 33 + .../node_modules/lodash/compact.js | 31 + .../node_modules/lodash/concat.js | 43 + .../babel-eslint/node_modules/lodash/cond.js | 60 + .../node_modules/lodash/conforms.js | 35 + .../node_modules/lodash/conformsTo.js | 32 + .../node_modules/lodash/constant.js | 26 + .../babel-eslint/node_modules/lodash/core.js | 3836 ++++ .../node_modules/lodash/core.min.js | 29 + .../node_modules/lodash/countBy.js | 40 + .../node_modules/lodash/create.js | 43 + .../babel-eslint/node_modules/lodash/curry.js | 57 + .../node_modules/lodash/curryRight.js | 54 + .../babel-eslint/node_modules/lodash/date.js | 3 + .../node_modules/lodash/debounce.js | 188 + .../node_modules/lodash/deburr.js | 45 + .../node_modules/lodash/defaultTo.js | 25 + .../node_modules/lodash/defaults.js | 32 + .../node_modules/lodash/defaultsDeep.js | 30 + .../babel-eslint/node_modules/lodash/defer.js | 26 + .../babel-eslint/node_modules/lodash/delay.js | 28 + .../node_modules/lodash/difference.js | 33 + .../node_modules/lodash/differenceBy.js | 44 + .../node_modules/lodash/differenceWith.js | 40 + .../node_modules/lodash/divide.js | 22 + .../babel-eslint/node_modules/lodash/drop.js | 38 + .../node_modules/lodash/dropRight.js | 39 + .../node_modules/lodash/dropRightWhile.js | 45 + .../node_modules/lodash/dropWhile.js | 45 + .../babel-eslint/node_modules/lodash/each.js | 1 + .../node_modules/lodash/eachRight.js | 1 + .../node_modules/lodash/endsWith.js | 43 + .../node_modules/lodash/entries.js | 1 + .../node_modules/lodash/entriesIn.js | 1 + .../babel-eslint/node_modules/lodash/eq.js | 37 + .../node_modules/lodash/escape.js | 43 + .../node_modules/lodash/escapeRegExp.js | 32 + .../babel-eslint/node_modules/lodash/every.js | 56 + .../node_modules/lodash/extend.js | 1 + .../node_modules/lodash/extendWith.js | 1 + .../babel-eslint/node_modules/lodash/fill.js | 45 + .../node_modules/lodash/filter.js | 48 + .../babel-eslint/node_modules/lodash/find.js | 42 + .../node_modules/lodash/findIndex.js | 55 + .../node_modules/lodash/findKey.js | 44 + .../node_modules/lodash/findLast.js | 25 + .../node_modules/lodash/findLastIndex.js | 59 + .../node_modules/lodash/findLastKey.js | 44 + .../babel-eslint/node_modules/lodash/first.js | 1 + .../node_modules/lodash/flatMap.js | 29 + .../node_modules/lodash/flatMapDeep.js | 31 + .../node_modules/lodash/flatMapDepth.js | 31 + .../node_modules/lodash/flatten.js | 22 + .../node_modules/lodash/flattenDeep.js | 25 + .../node_modules/lodash/flattenDepth.js | 33 + .../babel-eslint/node_modules/lodash/flip.js | 28 + .../babel-eslint/node_modules/lodash/floor.js | 26 + .../babel-eslint/node_modules/lodash/flow.js | 27 + .../node_modules/lodash/flowRight.js | 26 + .../node_modules/lodash/forEach.js | 41 + .../node_modules/lodash/forEachRight.js | 31 + .../babel-eslint/node_modules/lodash/forIn.js | 39 + .../node_modules/lodash/forInRight.js | 37 + .../node_modules/lodash/forOwn.js | 36 + .../node_modules/lodash/forOwnRight.js | 34 + .../babel-eslint/node_modules/lodash/fp.js | 2 + .../babel-eslint/node_modules/lodash/fp/F.js | 1 + .../babel-eslint/node_modules/lodash/fp/T.js | 1 + .../babel-eslint/node_modules/lodash/fp/__.js | 1 + .../node_modules/lodash/fp/_baseConvert.js | 568 + .../node_modules/lodash/fp/_convertBrowser.js | 18 + .../node_modules/lodash/fp/_falseOptions.js | 7 + .../node_modules/lodash/fp/_mapping.js | 368 + .../node_modules/lodash/fp/_util.js | 14 + .../node_modules/lodash/fp/add.js | 5 + .../node_modules/lodash/fp/after.js | 5 + .../node_modules/lodash/fp/all.js | 1 + .../node_modules/lodash/fp/allPass.js | 1 + .../node_modules/lodash/fp/always.js | 1 + .../node_modules/lodash/fp/any.js | 1 + .../node_modules/lodash/fp/anyPass.js | 1 + .../node_modules/lodash/fp/apply.js | 1 + .../node_modules/lodash/fp/array.js | 2 + .../node_modules/lodash/fp/ary.js | 5 + .../node_modules/lodash/fp/assign.js | 5 + .../node_modules/lodash/fp/assignAll.js | 5 + .../node_modules/lodash/fp/assignAllWith.js | 5 + .../node_modules/lodash/fp/assignIn.js | 5 + .../node_modules/lodash/fp/assignInAll.js | 5 + .../node_modules/lodash/fp/assignInAllWith.js | 5 + .../node_modules/lodash/fp/assignInWith.js | 5 + .../node_modules/lodash/fp/assignWith.js | 5 + .../node_modules/lodash/fp/assoc.js | 1 + .../node_modules/lodash/fp/assocPath.js | 1 + .../babel-eslint/node_modules/lodash/fp/at.js | 5 + .../node_modules/lodash/fp/attempt.js | 5 + .../node_modules/lodash/fp/before.js | 5 + .../node_modules/lodash/fp/bind.js | 5 + .../node_modules/lodash/fp/bindAll.js | 5 + .../node_modules/lodash/fp/bindKey.js | 5 + .../node_modules/lodash/fp/camelCase.js | 5 + .../node_modules/lodash/fp/capitalize.js | 5 + .../node_modules/lodash/fp/castArray.js | 5 + .../node_modules/lodash/fp/ceil.js | 5 + .../node_modules/lodash/fp/chain.js | 5 + .../node_modules/lodash/fp/chunk.js | 5 + .../node_modules/lodash/fp/clamp.js | 5 + .../node_modules/lodash/fp/clone.js | 5 + .../node_modules/lodash/fp/cloneDeep.js | 5 + .../node_modules/lodash/fp/cloneDeepWith.js | 5 + .../node_modules/lodash/fp/cloneWith.js | 5 + .../node_modules/lodash/fp/collection.js | 2 + .../node_modules/lodash/fp/commit.js | 5 + .../node_modules/lodash/fp/compact.js | 5 + .../node_modules/lodash/fp/complement.js | 1 + .../node_modules/lodash/fp/compose.js | 1 + .../node_modules/lodash/fp/concat.js | 5 + .../node_modules/lodash/fp/cond.js | 5 + .../node_modules/lodash/fp/conforms.js | 1 + .../node_modules/lodash/fp/conformsTo.js | 5 + .../node_modules/lodash/fp/constant.js | 5 + .../node_modules/lodash/fp/contains.js | 1 + .../node_modules/lodash/fp/convert.js | 18 + .../node_modules/lodash/fp/countBy.js | 5 + .../node_modules/lodash/fp/create.js | 5 + .../node_modules/lodash/fp/curry.js | 5 + .../node_modules/lodash/fp/curryN.js | 5 + .../node_modules/lodash/fp/curryRight.js | 5 + .../node_modules/lodash/fp/curryRightN.js | 5 + .../node_modules/lodash/fp/date.js | 2 + .../node_modules/lodash/fp/debounce.js | 5 + .../node_modules/lodash/fp/deburr.js | 5 + .../node_modules/lodash/fp/defaultTo.js | 5 + .../node_modules/lodash/fp/defaults.js | 5 + .../node_modules/lodash/fp/defaultsAll.js | 5 + .../node_modules/lodash/fp/defaultsDeep.js | 5 + .../node_modules/lodash/fp/defaultsDeepAll.js | 5 + .../node_modules/lodash/fp/defer.js | 5 + .../node_modules/lodash/fp/delay.js | 5 + .../node_modules/lodash/fp/difference.js | 5 + .../node_modules/lodash/fp/differenceBy.js | 5 + .../node_modules/lodash/fp/differenceWith.js | 5 + .../node_modules/lodash/fp/dissoc.js | 1 + .../node_modules/lodash/fp/dissocPath.js | 1 + .../node_modules/lodash/fp/divide.js | 5 + .../node_modules/lodash/fp/drop.js | 5 + .../node_modules/lodash/fp/dropLast.js | 1 + .../node_modules/lodash/fp/dropLastWhile.js | 1 + .../node_modules/lodash/fp/dropRight.js | 5 + .../node_modules/lodash/fp/dropRightWhile.js | 5 + .../node_modules/lodash/fp/dropWhile.js | 5 + .../node_modules/lodash/fp/each.js | 1 + .../node_modules/lodash/fp/eachRight.js | 1 + .../node_modules/lodash/fp/endsWith.js | 5 + .../node_modules/lodash/fp/entries.js | 1 + .../node_modules/lodash/fp/entriesIn.js | 1 + .../babel-eslint/node_modules/lodash/fp/eq.js | 5 + .../node_modules/lodash/fp/equals.js | 1 + .../node_modules/lodash/fp/escape.js | 5 + .../node_modules/lodash/fp/escapeRegExp.js | 5 + .../node_modules/lodash/fp/every.js | 5 + .../node_modules/lodash/fp/extend.js | 1 + .../node_modules/lodash/fp/extendAll.js | 1 + .../node_modules/lodash/fp/extendAllWith.js | 1 + .../node_modules/lodash/fp/extendWith.js | 1 + .../node_modules/lodash/fp/fill.js | 5 + .../node_modules/lodash/fp/filter.js | 5 + .../node_modules/lodash/fp/find.js | 5 + .../node_modules/lodash/fp/findFrom.js | 5 + .../node_modules/lodash/fp/findIndex.js | 5 + .../node_modules/lodash/fp/findIndexFrom.js | 5 + .../node_modules/lodash/fp/findKey.js | 5 + .../node_modules/lodash/fp/findLast.js | 5 + .../node_modules/lodash/fp/findLastFrom.js | 5 + .../node_modules/lodash/fp/findLastIndex.js | 5 + .../lodash/fp/findLastIndexFrom.js | 5 + .../node_modules/lodash/fp/findLastKey.js | 5 + .../node_modules/lodash/fp/first.js | 1 + .../node_modules/lodash/fp/flatMap.js | 5 + .../node_modules/lodash/fp/flatMapDeep.js | 5 + .../node_modules/lodash/fp/flatMapDepth.js | 5 + .../node_modules/lodash/fp/flatten.js | 5 + .../node_modules/lodash/fp/flattenDeep.js | 5 + .../node_modules/lodash/fp/flattenDepth.js | 5 + .../node_modules/lodash/fp/flip.js | 5 + .../node_modules/lodash/fp/floor.js | 5 + .../node_modules/lodash/fp/flow.js | 5 + .../node_modules/lodash/fp/flowRight.js | 5 + .../node_modules/lodash/fp/forEach.js | 5 + .../node_modules/lodash/fp/forEachRight.js | 5 + .../node_modules/lodash/fp/forIn.js | 5 + .../node_modules/lodash/fp/forInRight.js | 5 + .../node_modules/lodash/fp/forOwn.js | 5 + .../node_modules/lodash/fp/forOwnRight.js | 5 + .../node_modules/lodash/fp/fromPairs.js | 5 + .../node_modules/lodash/fp/function.js | 2 + .../node_modules/lodash/fp/functions.js | 5 + .../node_modules/lodash/fp/functionsIn.js | 5 + .../node_modules/lodash/fp/get.js | 5 + .../node_modules/lodash/fp/getOr.js | 5 + .../node_modules/lodash/fp/groupBy.js | 5 + .../babel-eslint/node_modules/lodash/fp/gt.js | 5 + .../node_modules/lodash/fp/gte.js | 5 + .../node_modules/lodash/fp/has.js | 5 + .../node_modules/lodash/fp/hasIn.js | 5 + .../node_modules/lodash/fp/head.js | 5 + .../node_modules/lodash/fp/identical.js | 1 + .../node_modules/lodash/fp/identity.js | 5 + .../node_modules/lodash/fp/inRange.js | 5 + .../node_modules/lodash/fp/includes.js | 5 + .../node_modules/lodash/fp/includesFrom.js | 5 + .../node_modules/lodash/fp/indexBy.js | 1 + .../node_modules/lodash/fp/indexOf.js | 5 + .../node_modules/lodash/fp/indexOfFrom.js | 5 + .../node_modules/lodash/fp/init.js | 1 + .../node_modules/lodash/fp/initial.js | 5 + .../node_modules/lodash/fp/intersection.js | 5 + .../node_modules/lodash/fp/intersectionBy.js | 5 + .../lodash/fp/intersectionWith.js | 5 + .../node_modules/lodash/fp/invert.js | 5 + .../node_modules/lodash/fp/invertBy.js | 5 + .../node_modules/lodash/fp/invertObj.js | 1 + .../node_modules/lodash/fp/invoke.js | 5 + .../node_modules/lodash/fp/invokeArgs.js | 5 + .../node_modules/lodash/fp/invokeArgsMap.js | 5 + .../node_modules/lodash/fp/invokeMap.js | 5 + .../node_modules/lodash/fp/isArguments.js | 5 + .../node_modules/lodash/fp/isArray.js | 5 + .../node_modules/lodash/fp/isArrayBuffer.js | 5 + .../node_modules/lodash/fp/isArrayLike.js | 5 + .../lodash/fp/isArrayLikeObject.js | 5 + .../node_modules/lodash/fp/isBoolean.js | 5 + .../node_modules/lodash/fp/isBuffer.js | 5 + .../node_modules/lodash/fp/isDate.js | 5 + .../node_modules/lodash/fp/isElement.js | 5 + .../node_modules/lodash/fp/isEmpty.js | 5 + .../node_modules/lodash/fp/isEqual.js | 5 + .../node_modules/lodash/fp/isEqualWith.js | 5 + .../node_modules/lodash/fp/isError.js | 5 + .../node_modules/lodash/fp/isFinite.js | 5 + .../node_modules/lodash/fp/isFunction.js | 5 + .../node_modules/lodash/fp/isInteger.js | 5 + .../node_modules/lodash/fp/isLength.js | 5 + .../node_modules/lodash/fp/isMap.js | 5 + .../node_modules/lodash/fp/isMatch.js | 5 + .../node_modules/lodash/fp/isMatchWith.js | 5 + .../node_modules/lodash/fp/isNaN.js | 5 + .../node_modules/lodash/fp/isNative.js | 5 + .../node_modules/lodash/fp/isNil.js | 5 + .../node_modules/lodash/fp/isNull.js | 5 + .../node_modules/lodash/fp/isNumber.js | 5 + .../node_modules/lodash/fp/isObject.js | 5 + .../node_modules/lodash/fp/isObjectLike.js | 5 + .../node_modules/lodash/fp/isPlainObject.js | 5 + .../node_modules/lodash/fp/isRegExp.js | 5 + .../node_modules/lodash/fp/isSafeInteger.js | 5 + .../node_modules/lodash/fp/isSet.js | 5 + .../node_modules/lodash/fp/isString.js | 5 + .../node_modules/lodash/fp/isSymbol.js | 5 + .../node_modules/lodash/fp/isTypedArray.js | 5 + .../node_modules/lodash/fp/isUndefined.js | 5 + .../node_modules/lodash/fp/isWeakMap.js | 5 + .../node_modules/lodash/fp/isWeakSet.js | 5 + .../node_modules/lodash/fp/iteratee.js | 5 + .../node_modules/lodash/fp/join.js | 5 + .../node_modules/lodash/fp/juxt.js | 1 + .../node_modules/lodash/fp/kebabCase.js | 5 + .../node_modules/lodash/fp/keyBy.js | 5 + .../node_modules/lodash/fp/keys.js | 5 + .../node_modules/lodash/fp/keysIn.js | 5 + .../node_modules/lodash/fp/lang.js | 2 + .../node_modules/lodash/fp/last.js | 5 + .../node_modules/lodash/fp/lastIndexOf.js | 5 + .../node_modules/lodash/fp/lastIndexOfFrom.js | 5 + .../node_modules/lodash/fp/lowerCase.js | 5 + .../node_modules/lodash/fp/lowerFirst.js | 5 + .../babel-eslint/node_modules/lodash/fp/lt.js | 5 + .../node_modules/lodash/fp/lte.js | 5 + .../node_modules/lodash/fp/map.js | 5 + .../node_modules/lodash/fp/mapKeys.js | 5 + .../node_modules/lodash/fp/mapValues.js | 5 + .../node_modules/lodash/fp/matches.js | 1 + .../node_modules/lodash/fp/matchesProperty.js | 5 + .../node_modules/lodash/fp/math.js | 2 + .../node_modules/lodash/fp/max.js | 5 + .../node_modules/lodash/fp/maxBy.js | 5 + .../node_modules/lodash/fp/mean.js | 5 + .../node_modules/lodash/fp/meanBy.js | 5 + .../node_modules/lodash/fp/memoize.js | 5 + .../node_modules/lodash/fp/merge.js | 5 + .../node_modules/lodash/fp/mergeAll.js | 5 + .../node_modules/lodash/fp/mergeAllWith.js | 5 + .../node_modules/lodash/fp/mergeWith.js | 5 + .../node_modules/lodash/fp/method.js | 5 + .../node_modules/lodash/fp/methodOf.js | 5 + .../node_modules/lodash/fp/min.js | 5 + .../node_modules/lodash/fp/minBy.js | 5 + .../node_modules/lodash/fp/mixin.js | 5 + .../node_modules/lodash/fp/multiply.js | 5 + .../node_modules/lodash/fp/nAry.js | 1 + .../node_modules/lodash/fp/negate.js | 5 + .../node_modules/lodash/fp/next.js | 5 + .../node_modules/lodash/fp/noop.js | 5 + .../node_modules/lodash/fp/now.js | 5 + .../node_modules/lodash/fp/nth.js | 5 + .../node_modules/lodash/fp/nthArg.js | 5 + .../node_modules/lodash/fp/number.js | 2 + .../node_modules/lodash/fp/object.js | 2 + .../node_modules/lodash/fp/omit.js | 5 + .../node_modules/lodash/fp/omitAll.js | 1 + .../node_modules/lodash/fp/omitBy.js | 5 + .../node_modules/lodash/fp/once.js | 5 + .../node_modules/lodash/fp/orderBy.js | 5 + .../node_modules/lodash/fp/over.js | 5 + .../node_modules/lodash/fp/overArgs.js | 5 + .../node_modules/lodash/fp/overEvery.js | 5 + .../node_modules/lodash/fp/overSome.js | 5 + .../node_modules/lodash/fp/pad.js | 5 + .../node_modules/lodash/fp/padChars.js | 5 + .../node_modules/lodash/fp/padCharsEnd.js | 5 + .../node_modules/lodash/fp/padCharsStart.js | 5 + .../node_modules/lodash/fp/padEnd.js | 5 + .../node_modules/lodash/fp/padStart.js | 5 + .../node_modules/lodash/fp/parseInt.js | 5 + .../node_modules/lodash/fp/partial.js | 5 + .../node_modules/lodash/fp/partialRight.js | 5 + .../node_modules/lodash/fp/partition.js | 5 + .../node_modules/lodash/fp/path.js | 1 + .../node_modules/lodash/fp/pathEq.js | 1 + .../node_modules/lodash/fp/pathOr.js | 1 + .../node_modules/lodash/fp/paths.js | 1 + .../node_modules/lodash/fp/pick.js | 5 + .../node_modules/lodash/fp/pickAll.js | 1 + .../node_modules/lodash/fp/pickBy.js | 5 + .../node_modules/lodash/fp/pipe.js | 1 + .../node_modules/lodash/fp/placeholder.js | 6 + .../node_modules/lodash/fp/plant.js | 5 + .../node_modules/lodash/fp/pluck.js | 1 + .../node_modules/lodash/fp/prop.js | 1 + .../node_modules/lodash/fp/propEq.js | 1 + .../node_modules/lodash/fp/propOr.js | 1 + .../node_modules/lodash/fp/property.js | 1 + .../node_modules/lodash/fp/propertyOf.js | 5 + .../node_modules/lodash/fp/props.js | 1 + .../node_modules/lodash/fp/pull.js | 5 + .../node_modules/lodash/fp/pullAll.js | 5 + .../node_modules/lodash/fp/pullAllBy.js | 5 + .../node_modules/lodash/fp/pullAllWith.js | 5 + .../node_modules/lodash/fp/pullAt.js | 5 + .../node_modules/lodash/fp/random.js | 5 + .../node_modules/lodash/fp/range.js | 5 + .../node_modules/lodash/fp/rangeRight.js | 5 + .../node_modules/lodash/fp/rangeStep.js | 5 + .../node_modules/lodash/fp/rangeStepRight.js | 5 + .../node_modules/lodash/fp/rearg.js | 5 + .../node_modules/lodash/fp/reduce.js | 5 + .../node_modules/lodash/fp/reduceRight.js | 5 + .../node_modules/lodash/fp/reject.js | 5 + .../node_modules/lodash/fp/remove.js | 5 + .../node_modules/lodash/fp/repeat.js | 5 + .../node_modules/lodash/fp/replace.js | 5 + .../node_modules/lodash/fp/rest.js | 5 + .../node_modules/lodash/fp/restFrom.js | 5 + .../node_modules/lodash/fp/result.js | 5 + .../node_modules/lodash/fp/reverse.js | 5 + .../node_modules/lodash/fp/round.js | 5 + .../node_modules/lodash/fp/sample.js | 5 + .../node_modules/lodash/fp/sampleSize.js | 5 + .../node_modules/lodash/fp/seq.js | 2 + .../node_modules/lodash/fp/set.js | 5 + .../node_modules/lodash/fp/setWith.js | 5 + .../node_modules/lodash/fp/shuffle.js | 5 + .../node_modules/lodash/fp/size.js | 5 + .../node_modules/lodash/fp/slice.js | 5 + .../node_modules/lodash/fp/snakeCase.js | 5 + .../node_modules/lodash/fp/some.js | 5 + .../node_modules/lodash/fp/sortBy.js | 5 + .../node_modules/lodash/fp/sortedIndex.js | 5 + .../node_modules/lodash/fp/sortedIndexBy.js | 5 + .../node_modules/lodash/fp/sortedIndexOf.js | 5 + .../node_modules/lodash/fp/sortedLastIndex.js | 5 + .../lodash/fp/sortedLastIndexBy.js | 5 + .../lodash/fp/sortedLastIndexOf.js | 5 + .../node_modules/lodash/fp/sortedUniq.js | 5 + .../node_modules/lodash/fp/sortedUniqBy.js | 5 + .../node_modules/lodash/fp/split.js | 5 + .../node_modules/lodash/fp/spread.js | 5 + .../node_modules/lodash/fp/spreadFrom.js | 5 + .../node_modules/lodash/fp/startCase.js | 5 + .../node_modules/lodash/fp/startsWith.js | 5 + .../node_modules/lodash/fp/string.js | 2 + .../node_modules/lodash/fp/stubArray.js | 5 + .../node_modules/lodash/fp/stubFalse.js | 5 + .../node_modules/lodash/fp/stubObject.js | 5 + .../node_modules/lodash/fp/stubString.js | 5 + .../node_modules/lodash/fp/stubTrue.js | 5 + .../node_modules/lodash/fp/subtract.js | 5 + .../node_modules/lodash/fp/sum.js | 5 + .../node_modules/lodash/fp/sumBy.js | 5 + .../lodash/fp/symmetricDifference.js | 1 + .../lodash/fp/symmetricDifferenceBy.js | 1 + .../lodash/fp/symmetricDifferenceWith.js | 1 + .../node_modules/lodash/fp/tail.js | 5 + .../node_modules/lodash/fp/take.js | 5 + .../node_modules/lodash/fp/takeLast.js | 1 + .../node_modules/lodash/fp/takeLastWhile.js | 1 + .../node_modules/lodash/fp/takeRight.js | 5 + .../node_modules/lodash/fp/takeRightWhile.js | 5 + .../node_modules/lodash/fp/takeWhile.js | 5 + .../node_modules/lodash/fp/tap.js | 5 + .../node_modules/lodash/fp/template.js | 5 + .../lodash/fp/templateSettings.js | 5 + .../node_modules/lodash/fp/throttle.js | 5 + .../node_modules/lodash/fp/thru.js | 5 + .../node_modules/lodash/fp/times.js | 5 + .../node_modules/lodash/fp/toArray.js | 5 + .../node_modules/lodash/fp/toFinite.js | 5 + .../node_modules/lodash/fp/toInteger.js | 5 + .../node_modules/lodash/fp/toIterator.js | 5 + .../node_modules/lodash/fp/toJSON.js | 5 + .../node_modules/lodash/fp/toLength.js | 5 + .../node_modules/lodash/fp/toLower.js | 5 + .../node_modules/lodash/fp/toNumber.js | 5 + .../node_modules/lodash/fp/toPairs.js | 5 + .../node_modules/lodash/fp/toPairsIn.js | 5 + .../node_modules/lodash/fp/toPath.js | 5 + .../node_modules/lodash/fp/toPlainObject.js | 5 + .../node_modules/lodash/fp/toSafeInteger.js | 5 + .../node_modules/lodash/fp/toString.js | 5 + .../node_modules/lodash/fp/toUpper.js | 5 + .../node_modules/lodash/fp/transform.js | 5 + .../node_modules/lodash/fp/trim.js | 5 + .../node_modules/lodash/fp/trimChars.js | 5 + .../node_modules/lodash/fp/trimCharsEnd.js | 5 + .../node_modules/lodash/fp/trimCharsStart.js | 5 + .../node_modules/lodash/fp/trimEnd.js | 5 + .../node_modules/lodash/fp/trimStart.js | 5 + .../node_modules/lodash/fp/truncate.js | 5 + .../node_modules/lodash/fp/unapply.js | 1 + .../node_modules/lodash/fp/unary.js | 5 + .../node_modules/lodash/fp/unescape.js | 5 + .../node_modules/lodash/fp/union.js | 5 + .../node_modules/lodash/fp/unionBy.js | 5 + .../node_modules/lodash/fp/unionWith.js | 5 + .../node_modules/lodash/fp/uniq.js | 5 + .../node_modules/lodash/fp/uniqBy.js | 5 + .../node_modules/lodash/fp/uniqWith.js | 5 + .../node_modules/lodash/fp/uniqueId.js | 5 + .../node_modules/lodash/fp/unnest.js | 1 + .../node_modules/lodash/fp/unset.js | 5 + .../node_modules/lodash/fp/unzip.js | 5 + .../node_modules/lodash/fp/unzipWith.js | 5 + .../node_modules/lodash/fp/update.js | 5 + .../node_modules/lodash/fp/updateWith.js | 5 + .../node_modules/lodash/fp/upperCase.js | 5 + .../node_modules/lodash/fp/upperFirst.js | 5 + .../node_modules/lodash/fp/useWith.js | 1 + .../node_modules/lodash/fp/util.js | 2 + .../node_modules/lodash/fp/value.js | 5 + .../node_modules/lodash/fp/valueOf.js | 5 + .../node_modules/lodash/fp/values.js | 5 + .../node_modules/lodash/fp/valuesIn.js | 5 + .../node_modules/lodash/fp/where.js | 1 + .../node_modules/lodash/fp/whereEq.js | 1 + .../node_modules/lodash/fp/without.js | 5 + .../node_modules/lodash/fp/words.js | 5 + .../node_modules/lodash/fp/wrap.js | 5 + .../node_modules/lodash/fp/wrapperAt.js | 5 + .../node_modules/lodash/fp/wrapperChain.js | 5 + .../node_modules/lodash/fp/wrapperLodash.js | 5 + .../node_modules/lodash/fp/wrapperReverse.js | 5 + .../node_modules/lodash/fp/wrapperValue.js | 5 + .../node_modules/lodash/fp/xor.js | 5 + .../node_modules/lodash/fp/xorBy.js | 5 + .../node_modules/lodash/fp/xorWith.js | 5 + .../node_modules/lodash/fp/zip.js | 5 + .../node_modules/lodash/fp/zipAll.js | 5 + .../node_modules/lodash/fp/zipObj.js | 1 + .../node_modules/lodash/fp/zipObject.js | 5 + .../node_modules/lodash/fp/zipObjectDeep.js | 5 + .../node_modules/lodash/fp/zipWith.js | 5 + .../node_modules/lodash/fromPairs.js | 28 + .../node_modules/lodash/function.js | 25 + .../node_modules/lodash/functions.js | 31 + .../node_modules/lodash/functionsIn.js | 31 + .../babel-eslint/node_modules/lodash/get.js | 33 + .../node_modules/lodash/groupBy.js | 41 + .../babel-eslint/node_modules/lodash/gt.js | 29 + .../babel-eslint/node_modules/lodash/gte.js | 30 + .../babel-eslint/node_modules/lodash/has.js | 35 + .../babel-eslint/node_modules/lodash/hasIn.js | 34 + .../babel-eslint/node_modules/lodash/head.js | 23 + .../node_modules/lodash/identity.js | 21 + .../node_modules/lodash/inRange.js | 55 + .../node_modules/lodash/includes.js | 53 + .../babel-eslint/node_modules/lodash/index.js | 1 + .../node_modules/lodash/indexOf.js | 42 + .../node_modules/lodash/initial.js | 22 + .../node_modules/lodash/intersection.js | 30 + .../node_modules/lodash/intersectionBy.js | 45 + .../node_modules/lodash/intersectionWith.js | 41 + .../node_modules/lodash/invert.js | 27 + .../node_modules/lodash/invertBy.js | 44 + .../node_modules/lodash/invoke.js | 24 + .../node_modules/lodash/invokeMap.js | 41 + .../node_modules/lodash/isArguments.js | 36 + .../node_modules/lodash/isArray.js | 26 + .../node_modules/lodash/isArrayBuffer.js | 27 + .../node_modules/lodash/isArrayLike.js | 33 + .../node_modules/lodash/isArrayLikeObject.js | 33 + .../node_modules/lodash/isBoolean.js | 29 + .../node_modules/lodash/isBuffer.js | 38 + .../node_modules/lodash/isDate.js | 27 + .../node_modules/lodash/isElement.js | 25 + .../node_modules/lodash/isEmpty.js | 77 + .../node_modules/lodash/isEqual.js | 35 + .../node_modules/lodash/isEqualWith.js | 41 + .../node_modules/lodash/isError.js | 36 + .../node_modules/lodash/isFinite.js | 36 + .../node_modules/lodash/isFunction.js | 37 + .../node_modules/lodash/isInteger.js | 33 + .../node_modules/lodash/isLength.js | 35 + .../babel-eslint/node_modules/lodash/isMap.js | 27 + .../node_modules/lodash/isMatch.js | 36 + .../node_modules/lodash/isMatchWith.js | 41 + .../babel-eslint/node_modules/lodash/isNaN.js | 38 + .../node_modules/lodash/isNative.js | 40 + .../babel-eslint/node_modules/lodash/isNil.js | 25 + .../node_modules/lodash/isNull.js | 22 + .../node_modules/lodash/isNumber.js | 38 + .../node_modules/lodash/isObject.js | 31 + .../node_modules/lodash/isObjectLike.js | 29 + .../node_modules/lodash/isPlainObject.js | 62 + .../node_modules/lodash/isRegExp.js | 27 + .../node_modules/lodash/isSafeInteger.js | 37 + .../babel-eslint/node_modules/lodash/isSet.js | 27 + .../node_modules/lodash/isString.js | 30 + .../node_modules/lodash/isSymbol.js | 29 + .../node_modules/lodash/isTypedArray.js | 27 + .../node_modules/lodash/isUndefined.js | 22 + .../node_modules/lodash/isWeakMap.js | 28 + .../node_modules/lodash/isWeakSet.js | 28 + .../node_modules/lodash/iteratee.js | 53 + .../babel-eslint/node_modules/lodash/join.js | 26 + .../node_modules/lodash/kebabCase.js | 28 + .../babel-eslint/node_modules/lodash/keyBy.js | 36 + .../babel-eslint/node_modules/lodash/keys.js | 37 + .../node_modules/lodash/keysIn.js | 32 + .../babel-eslint/node_modules/lodash/lang.js | 58 + .../babel-eslint/node_modules/lodash/last.js | 20 + .../node_modules/lodash/lastIndexOf.js | 46 + .../node_modules/lodash/lodash.js | 17084 ++++++++++++++++ .../node_modules/lodash/lodash.min.js | 136 + .../node_modules/lodash/lowerCase.js | 27 + .../node_modules/lodash/lowerFirst.js | 22 + .../babel-eslint/node_modules/lodash/lt.js | 29 + .../babel-eslint/node_modules/lodash/lte.js | 30 + .../babel-eslint/node_modules/lodash/map.js | 53 + .../node_modules/lodash/mapKeys.js | 36 + .../node_modules/lodash/mapValues.js | 43 + .../node_modules/lodash/matches.js | 39 + .../node_modules/lodash/matchesProperty.js | 37 + .../babel-eslint/node_modules/lodash/math.js | 17 + .../babel-eslint/node_modules/lodash/max.js | 29 + .../babel-eslint/node_modules/lodash/maxBy.js | 34 + .../babel-eslint/node_modules/lodash/mean.js | 22 + .../node_modules/lodash/meanBy.js | 31 + .../node_modules/lodash/memoize.js | 73 + .../babel-eslint/node_modules/lodash/merge.js | 39 + .../node_modules/lodash/mergeWith.js | 39 + .../node_modules/lodash/method.js | 34 + .../node_modules/lodash/methodOf.js | 33 + .../babel-eslint/node_modules/lodash/min.js | 29 + .../babel-eslint/node_modules/lodash/minBy.js | 34 + .../babel-eslint/node_modules/lodash/mixin.js | 74 + .../node_modules/lodash/multiply.js | 22 + .../node_modules/lodash/negate.js | 40 + .../babel-eslint/node_modules/lodash/next.js | 35 + .../babel-eslint/node_modules/lodash/noop.js | 17 + .../babel-eslint/node_modules/lodash/now.js | 23 + .../babel-eslint/node_modules/lodash/nth.js | 29 + .../node_modules/lodash/nthArg.js | 32 + .../node_modules/lodash/number.js | 5 + .../node_modules/lodash/object.js | 49 + .../babel-eslint/node_modules/lodash/omit.js | 57 + .../node_modules/lodash/omitBy.js | 29 + .../babel-eslint/node_modules/lodash/once.js | 25 + .../node_modules/lodash/orderBy.js | 47 + .../babel-eslint/node_modules/lodash/over.js | 24 + .../node_modules/lodash/overArgs.js | 61 + .../node_modules/lodash/overEvery.js | 30 + .../node_modules/lodash/overSome.js | 30 + .../node_modules/lodash/package.json | 68 + .../babel-eslint/node_modules/lodash/pad.js | 49 + .../node_modules/lodash/padEnd.js | 39 + .../node_modules/lodash/padStart.js | 39 + .../node_modules/lodash/parseInt.js | 43 + .../node_modules/lodash/partial.js | 50 + .../node_modules/lodash/partialRight.js | 49 + .../node_modules/lodash/partition.js | 43 + .../babel-eslint/node_modules/lodash/pick.js | 25 + .../node_modules/lodash/pickBy.js | 37 + .../babel-eslint/node_modules/lodash/plant.js | 48 + .../node_modules/lodash/property.js | 32 + .../node_modules/lodash/propertyOf.js | 30 + .../babel-eslint/node_modules/lodash/pull.js | 29 + .../node_modules/lodash/pullAll.js | 29 + .../node_modules/lodash/pullAllBy.js | 33 + .../node_modules/lodash/pullAllWith.js | 32 + .../node_modules/lodash/pullAt.js | 43 + .../node_modules/lodash/random.js | 82 + .../babel-eslint/node_modules/lodash/range.js | 46 + .../node_modules/lodash/rangeRight.js | 41 + .../babel-eslint/node_modules/lodash/rearg.js | 33 + .../node_modules/lodash/reduce.js | 51 + .../node_modules/lodash/reduceRight.js | 36 + .../node_modules/lodash/reject.js | 46 + .../node_modules/lodash/remove.js | 53 + .../node_modules/lodash/repeat.js | 37 + .../node_modules/lodash/replace.js | 29 + .../babel-eslint/node_modules/lodash/rest.js | 40 + .../node_modules/lodash/result.js | 56 + .../node_modules/lodash/reverse.js | 34 + .../babel-eslint/node_modules/lodash/round.js | 26 + .../node_modules/lodash/sample.js | 24 + .../node_modules/lodash/sampleSize.js | 37 + .../babel-eslint/node_modules/lodash/seq.js | 16 + .../babel-eslint/node_modules/lodash/set.js | 35 + .../node_modules/lodash/setWith.js | 32 + .../node_modules/lodash/shuffle.js | 25 + .../babel-eslint/node_modules/lodash/size.js | 46 + .../babel-eslint/node_modules/lodash/slice.js | 37 + .../node_modules/lodash/snakeCase.js | 28 + .../babel-eslint/node_modules/lodash/some.js | 51 + .../node_modules/lodash/sortBy.js | 48 + .../node_modules/lodash/sortedIndex.js | 24 + .../node_modules/lodash/sortedIndexBy.js | 33 + .../node_modules/lodash/sortedIndexOf.js | 31 + .../node_modules/lodash/sortedLastIndex.js | 25 + .../node_modules/lodash/sortedLastIndexBy.js | 33 + .../node_modules/lodash/sortedLastIndexOf.js | 31 + .../node_modules/lodash/sortedUniq.js | 24 + .../node_modules/lodash/sortedUniqBy.js | 26 + .../babel-eslint/node_modules/lodash/split.js | 52 + .../node_modules/lodash/spread.js | 63 + .../node_modules/lodash/startCase.js | 29 + .../node_modules/lodash/startsWith.js | 39 + .../node_modules/lodash/string.js | 33 + .../node_modules/lodash/stubArray.js | 23 + .../node_modules/lodash/stubFalse.js | 18 + .../node_modules/lodash/stubObject.js | 23 + .../node_modules/lodash/stubString.js | 18 + .../node_modules/lodash/stubTrue.js | 18 + .../node_modules/lodash/subtract.js | 22 + .../babel-eslint/node_modules/lodash/sum.js | 24 + .../babel-eslint/node_modules/lodash/sumBy.js | 33 + .../babel-eslint/node_modules/lodash/tail.js | 22 + .../babel-eslint/node_modules/lodash/take.js | 37 + .../node_modules/lodash/takeRight.js | 39 + .../node_modules/lodash/takeRightWhile.js | 45 + .../node_modules/lodash/takeWhile.js | 45 + .../babel-eslint/node_modules/lodash/tap.js | 29 + .../node_modules/lodash/template.js | 238 + .../node_modules/lodash/templateSettings.js | 67 + .../node_modules/lodash/throttle.js | 69 + .../babel-eslint/node_modules/lodash/thru.js | 28 + .../babel-eslint/node_modules/lodash/times.js | 51 + .../node_modules/lodash/toArray.js | 58 + .../node_modules/lodash/toFinite.js | 42 + .../node_modules/lodash/toInteger.js | 36 + .../node_modules/lodash/toIterator.js | 23 + .../node_modules/lodash/toJSON.js | 1 + .../node_modules/lodash/toLength.js | 38 + .../node_modules/lodash/toLower.js | 28 + .../node_modules/lodash/toNumber.js | 66 + .../node_modules/lodash/toPairs.js | 30 + .../node_modules/lodash/toPairsIn.js | 30 + .../node_modules/lodash/toPath.js | 33 + .../node_modules/lodash/toPlainObject.js | 32 + .../node_modules/lodash/toSafeInteger.js | 37 + .../node_modules/lodash/toString.js | 28 + .../node_modules/lodash/toUpper.js | 28 + .../node_modules/lodash/transform.js | 65 + .../babel-eslint/node_modules/lodash/trim.js | 49 + .../node_modules/lodash/trimEnd.js | 43 + .../node_modules/lodash/trimStart.js | 43 + .../node_modules/lodash/truncate.js | 111 + .../babel-eslint/node_modules/lodash/unary.js | 22 + .../node_modules/lodash/unescape.js | 34 + .../babel-eslint/node_modules/lodash/union.js | 26 + .../node_modules/lodash/unionBy.js | 39 + .../node_modules/lodash/unionWith.js | 34 + .../babel-eslint/node_modules/lodash/uniq.js | 25 + .../node_modules/lodash/uniqBy.js | 31 + .../node_modules/lodash/uniqWith.js | 28 + .../node_modules/lodash/uniqueId.js | 28 + .../babel-eslint/node_modules/lodash/unset.js | 34 + .../babel-eslint/node_modules/lodash/unzip.js | 45 + .../node_modules/lodash/unzipWith.js | 39 + .../node_modules/lodash/update.js | 35 + .../node_modules/lodash/updateWith.js | 33 + .../node_modules/lodash/upperCase.js | 27 + .../node_modules/lodash/upperFirst.js | 22 + .../babel-eslint/node_modules/lodash/util.js | 34 + .../babel-eslint/node_modules/lodash/value.js | 1 + .../node_modules/lodash/valueOf.js | 1 + .../node_modules/lodash/values.js | 34 + .../node_modules/lodash/valuesIn.js | 32 + .../node_modules/lodash/without.js | 31 + .../babel-eslint/node_modules/lodash/words.js | 35 + .../babel-eslint/node_modules/lodash/wrap.js | 30 + .../node_modules/lodash/wrapperAt.js | 48 + .../node_modules/lodash/wrapperChain.js | 34 + .../node_modules/lodash/wrapperLodash.js | 147 + .../node_modules/lodash/wrapperReverse.js | 44 + .../node_modules/lodash/wrapperValue.js | 21 + .../babel-eslint/node_modules/lodash/xor.js | 28 + .../babel-eslint/node_modules/lodash/xorBy.js | 39 + .../node_modules/lodash/xorWith.js | 34 + .../babel-eslint/node_modules/lodash/zip.js | 22 + .../node_modules/lodash/zipObject.js | 24 + .../node_modules/lodash/zipObjectDeep.js | 23 + .../node_modules/lodash/zipWith.js | 32 + .../node_modules/loose-envify/LICENSE | 21 + .../node_modules/loose-envify/README.md | 45 + .../node_modules/loose-envify/cli.js | 16 + .../node_modules/loose-envify/custom.js | 4 + .../node_modules/loose-envify/index.js | 3 + .../node_modules/loose-envify/loose-envify.js | 36 + .../node_modules/loose-envify/package.json | 67 + .../node_modules/loose-envify/replace.js | 65 + .../babel-eslint/node_modules/ms/index.js | 152 + .../babel-eslint/node_modules/ms/license.md | 21 + .../babel-eslint/node_modules/ms/package.json | 69 + .../babel-eslint/node_modules/ms/readme.md | 51 + .../node_modules/object-assign/index.js | 90 + .../node_modules/object-assign/license | 21 + .../node_modules/object-assign/package.json | 74 + .../node_modules/object-assign/readme.md | 61 + .../node_modules/supports-color/browser.js | 2 + .../node_modules/supports-color/index.js | 115 + .../node_modules/supports-color/license | 9 + .../node_modules/supports-color/package.json | 85 + .../node_modules/supports-color/readme.md | 66 + .../node_modules/to-fast-properties/index.js | 27 + .../node_modules/to-fast-properties/license | 10 + .../to-fast-properties/package.json | 67 + .../node_modules/to-fast-properties/readme.md | 37 + tools/node_modules/babel-eslint/package.json | 89 + tools/update-babel-eslint.sh | 26 + 1318 files changed, 93356 insertions(+) create mode 100644 tools/node_modules/babel-eslint/LICENSE create mode 100644 tools/node_modules/babel-eslint/README.md create mode 100644 tools/node_modules/babel-eslint/lib/analyze-scope.js create mode 100644 tools/node_modules/babel-eslint/lib/babylon-to-espree/attachComments.js create mode 100644 tools/node_modules/babel-eslint/lib/babylon-to-espree/convertComments.js create mode 100644 tools/node_modules/babel-eslint/lib/babylon-to-espree/convertTemplateType.js create mode 100644 tools/node_modules/babel-eslint/lib/babylon-to-espree/index.js create mode 100644 tools/node_modules/babel-eslint/lib/babylon-to-espree/toAST.js create mode 100644 tools/node_modules/babel-eslint/lib/babylon-to-espree/toToken.js create mode 100644 tools/node_modules/babel-eslint/lib/babylon-to-espree/toTokens.js create mode 100644 tools/node_modules/babel-eslint/lib/index.js create mode 100644 tools/node_modules/babel-eslint/lib/parse-with-patch.js create mode 100644 tools/node_modules/babel-eslint/lib/parse-with-scope.js create mode 100644 tools/node_modules/babel-eslint/lib/parse.js create mode 100644 tools/node_modules/babel-eslint/lib/patch-eslint-scope.js create mode 100644 tools/node_modules/babel-eslint/lib/visitor-keys.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/code-frame/README.md create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/code-frame/lib/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/code-frame/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/helper-function-name/README.md create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/helper-function-name/lib/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/helper-function-name/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/helper-get-function-arity/README.md create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/helper-get-function-arity/lib/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/helper-get-function-arity/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/template/README.md create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/template/lib/builder.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/template/lib/formatters.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/template/lib/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/template/lib/literal.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/template/lib/options.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/template/lib/parse.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/template/lib/populate.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/template/lib/string.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/template/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/README.md create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/cache.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/context.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/hub.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/ancestry.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/comments.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/context.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/conversion.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/evaluation.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/family.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/inference/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/inference/inferer-reference.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/inference/inferers.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/introspection.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/lib/hoister.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/lib/removal-hooks.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/lib/virtual-types.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/modification.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/removal.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/replacement.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/scope/binding.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/scope/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/scope/lib/renamer.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/visitors.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/traverse/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/README.md create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/asserts/assertNode.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/asserts/generated/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/builders/builder.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/builders/flow/createTypeAnnotationBasedOnTypeof.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/builders/flow/createUnionTypeAnnotation.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/builders/generated/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/builders/react/buildChildren.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/clone/clone.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/clone/cloneDeep.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/clone/cloneWithoutLoc.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/addComment.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/addComments.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/inheritInnerComments.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/inheritLeadingComments.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/inheritTrailingComments.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/inheritsComments.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/removeComments.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/constants/generated/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/constants/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/ensureBlock.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/gatherSequenceExpressions.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toBindingIdentifierName.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toBlock.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toComputedKey.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toExpression.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toIdentifier.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toKeyAlias.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toSequenceExpression.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toStatement.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/valueToNode.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/core.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/es2015.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/experimental.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/flow.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/jsx.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/misc.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/typescript.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/utils.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/appendToMemberExpression.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/flow/removeTypeDuplicates.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/inherits.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/prependToMemberExpression.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/removeProperties.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/removePropertiesDeep.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/retrievers/getBindingIdentifiers.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/retrievers/getOuterBindingIdentifiers.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/traverse/traverse.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/traverse/traverseFast.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/utils/inherit.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/utils/react/cleanJSXElementLiteralChild.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/utils/shallowEqual.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/buildMatchMemberExpression.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/generated/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/is.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isBinding.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isBlockScoped.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isImmutable.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isLet.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isNode.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isNodesEquivalent.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isReferenced.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isScope.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isSpecifierDefault.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isType.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isValidES3Identifier.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isValidIdentifier.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isVar.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/matchesPattern.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/react/isCompatTag.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/react/isReactComponent.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/validate.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/generateTypeHelpers.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/generators/generateAsserts.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/generators/generateBuilders.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/generators/generateConstants.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/generators/generateValidators.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/utils/formatBuilderName.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/utils/formatCode.js create mode 100644 tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/utils/lowerFirst.js create mode 100644 tools/node_modules/babel-eslint/node_modules/ansi-styles/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/ansi-styles/license create mode 100644 tools/node_modules/babel-eslint/node_modules/ansi-styles/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/ansi-styles/readme.md create mode 100644 tools/node_modules/babel-eslint/node_modules/babylon/LICENSE create mode 100644 tools/node_modules/babel-eslint/node_modules/babylon/README.md create mode 100755 tools/node_modules/babel-eslint/node_modules/babylon/bin/babylon.js create mode 100644 tools/node_modules/babel-eslint/node_modules/babylon/lib/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/babylon/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/chalk/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/chalk/license create mode 100644 tools/node_modules/babel-eslint/node_modules/chalk/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/chalk/readme.md create mode 100644 tools/node_modules/babel-eslint/node_modules/chalk/templates.js create mode 100644 tools/node_modules/babel-eslint/node_modules/chalk/types/index.d.ts create mode 100644 tools/node_modules/babel-eslint/node_modules/color-convert/LICENSE create mode 100644 tools/node_modules/babel-eslint/node_modules/color-convert/README.md create mode 100644 tools/node_modules/babel-eslint/node_modules/color-convert/conversions.js create mode 100644 tools/node_modules/babel-eslint/node_modules/color-convert/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/color-convert/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/color-convert/route.js create mode 100644 tools/node_modules/babel-eslint/node_modules/color-name/.eslintrc.json create mode 100644 tools/node_modules/babel-eslint/node_modules/color-name/LICENSE create mode 100644 tools/node_modules/babel-eslint/node_modules/color-name/README.md create mode 100644 tools/node_modules/babel-eslint/node_modules/color-name/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/color-name/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/debug/.coveralls.yml create mode 100644 tools/node_modules/babel-eslint/node_modules/debug/LICENSE create mode 100644 tools/node_modules/babel-eslint/node_modules/debug/Makefile create mode 100644 tools/node_modules/babel-eslint/node_modules/debug/README.md create mode 100644 tools/node_modules/babel-eslint/node_modules/debug/karma.conf.js create mode 100644 tools/node_modules/babel-eslint/node_modules/debug/node.js create mode 100644 tools/node_modules/babel-eslint/node_modules/debug/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/debug/src/browser.js create mode 100644 tools/node_modules/babel-eslint/node_modules/debug/src/debug.js create mode 100644 tools/node_modules/babel-eslint/node_modules/debug/src/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/debug/src/node.js create mode 100644 tools/node_modules/babel-eslint/node_modules/escape-string-regexp/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/escape-string-regexp/license create mode 100644 tools/node_modules/babel-eslint/node_modules/escape-string-regexp/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/escape-string-regexp/readme.md create mode 100644 tools/node_modules/babel-eslint/node_modules/eslint-scope/LICENSE create mode 100644 tools/node_modules/babel-eslint/node_modules/eslint-scope/README.md create mode 100644 tools/node_modules/babel-eslint/node_modules/eslint-scope/lib/definition.js create mode 100644 tools/node_modules/babel-eslint/node_modules/eslint-scope/lib/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/eslint-scope/lib/pattern-visitor.js create mode 100644 tools/node_modules/babel-eslint/node_modules/eslint-scope/lib/reference.js create mode 100644 tools/node_modules/babel-eslint/node_modules/eslint-scope/lib/referencer.js create mode 100644 tools/node_modules/babel-eslint/node_modules/eslint-scope/lib/scope-manager.js create mode 100644 tools/node_modules/babel-eslint/node_modules/eslint-scope/lib/scope.js create mode 100644 tools/node_modules/babel-eslint/node_modules/eslint-scope/lib/variable.js create mode 100644 tools/node_modules/babel-eslint/node_modules/eslint-scope/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/eslint-visitor-keys/LICENSE create mode 100644 tools/node_modules/babel-eslint/node_modules/eslint-visitor-keys/README.md create mode 100644 tools/node_modules/babel-eslint/node_modules/eslint-visitor-keys/lib/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/eslint-visitor-keys/lib/visitor-keys.json create mode 100644 tools/node_modules/babel-eslint/node_modules/eslint-visitor-keys/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/esrecurse/.babelrc create mode 100644 tools/node_modules/babel-eslint/node_modules/esrecurse/README.md create mode 100644 tools/node_modules/babel-eslint/node_modules/esrecurse/esrecurse.js create mode 100644 tools/node_modules/babel-eslint/node_modules/esrecurse/package-lock.json create mode 100755 tools/node_modules/babel-eslint/node_modules/esrecurse/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/estraverse/.babelrc create mode 100644 tools/node_modules/babel-eslint/node_modules/estraverse/LICENSE.BSD create mode 100644 tools/node_modules/babel-eslint/node_modules/estraverse/estraverse.js create mode 100644 tools/node_modules/babel-eslint/node_modules/estraverse/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/esutils/LICENSE.BSD create mode 100644 tools/node_modules/babel-eslint/node_modules/esutils/README.md create mode 100644 tools/node_modules/babel-eslint/node_modules/esutils/lib/ast.js create mode 100644 tools/node_modules/babel-eslint/node_modules/esutils/lib/code.js create mode 100644 tools/node_modules/babel-eslint/node_modules/esutils/lib/keyword.js create mode 100644 tools/node_modules/babel-eslint/node_modules/esutils/lib/utils.js create mode 100644 tools/node_modules/babel-eslint/node_modules/esutils/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/globals/globals.json create mode 100644 tools/node_modules/babel-eslint/node_modules/globals/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/globals/license create mode 100644 tools/node_modules/babel-eslint/node_modules/globals/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/globals/readme.md create mode 100644 tools/node_modules/babel-eslint/node_modules/has-flag/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/has-flag/license create mode 100644 tools/node_modules/babel-eslint/node_modules/has-flag/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/has-flag/readme.md create mode 100644 tools/node_modules/babel-eslint/node_modules/invariant/LICENSE create mode 100644 tools/node_modules/babel-eslint/node_modules/invariant/README.md create mode 100644 tools/node_modules/babel-eslint/node_modules/invariant/browser.js create mode 100644 tools/node_modules/babel-eslint/node_modules/invariant/invariant.js create mode 100644 tools/node_modules/babel-eslint/node_modules/invariant/invariant.js.flow create mode 100644 tools/node_modules/babel-eslint/node_modules/invariant/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/js-tokens/LICENSE create mode 100644 tools/node_modules/babel-eslint/node_modules/js-tokens/README.md create mode 100644 tools/node_modules/babel-eslint/node_modules/js-tokens/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/js-tokens/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/LICENSE create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/README.md create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_DataView.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_Hash.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_LazyWrapper.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_ListCache.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_LodashWrapper.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_Map.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_MapCache.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_Promise.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_Set.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_SetCache.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_Stack.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_Symbol.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_Uint8Array.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_WeakMap.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_addMapEntry.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_addSetEntry.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_apply.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_arrayAggregator.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_arrayEach.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_arrayEachRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_arrayEvery.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_arrayFilter.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_arrayIncludes.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_arrayIncludesWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_arrayLikeKeys.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_arrayMap.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_arrayPush.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_arrayReduce.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_arrayReduceRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_arraySample.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_arraySampleSize.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_arrayShuffle.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_arraySome.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_asciiSize.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_asciiToArray.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_asciiWords.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_assignMergeValue.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_assignValue.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_assocIndexOf.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseAggregator.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseAssign.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseAssignIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseAssignValue.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseAt.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseClamp.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseClone.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseConforms.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseConformsTo.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseCreate.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseDelay.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseDifference.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseEach.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseEachRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseEvery.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseExtremum.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseFill.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseFilter.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseFindIndex.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseFindKey.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseFlatten.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseFor.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseForOwn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseForOwnRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseForRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseFunctions.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseGet.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseGetAllKeys.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseGetTag.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseGt.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseHas.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseHasIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseInRange.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseIndexOf.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseIndexOfWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseIntersection.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseInverter.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseInvoke.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseIsArguments.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseIsArrayBuffer.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseIsDate.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseIsEqual.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseIsEqualDeep.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseIsMap.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseIsMatch.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseIsNaN.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseIsNative.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseIsRegExp.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseIsSet.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseIsTypedArray.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseIteratee.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseKeys.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseKeysIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseLodash.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseLt.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseMap.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseMatches.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseMatchesProperty.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseMean.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseMerge.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseMergeDeep.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseNth.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseOrderBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_basePick.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_basePickBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseProperty.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_basePropertyDeep.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_basePropertyOf.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_basePullAll.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_basePullAt.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseRandom.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseRange.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseReduce.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseRepeat.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseRest.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseSample.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseSampleSize.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseSet.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseSetData.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseSetToString.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseShuffle.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseSlice.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseSome.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseSortBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseSortedIndex.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseSortedIndexBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseSortedUniq.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseSum.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseTimes.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseToNumber.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseToPairs.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseToString.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseUnary.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseUniq.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseUnset.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseUpdate.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseValues.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseWhile.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseWrapperValue.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseXor.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_baseZipObject.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_cacheHas.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_castArrayLikeObject.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_castFunction.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_castPath.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_castRest.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_castSlice.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_charsEndIndex.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_charsStartIndex.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_cloneArrayBuffer.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_cloneBuffer.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_cloneDataView.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_cloneMap.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_cloneRegExp.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_cloneSet.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_cloneSymbol.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_cloneTypedArray.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_compareAscending.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_compareMultiple.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_composeArgs.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_composeArgsRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_copyArray.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_copyObject.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_copySymbols.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_copySymbolsIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_coreJsData.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_countHolders.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createAggregator.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createAssigner.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createBaseEach.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createBaseFor.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createBind.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createCaseFirst.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createCompounder.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createCtor.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createCurry.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createFind.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createFlow.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createHybrid.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createInverter.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createMathOperation.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createOver.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createPadding.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createPartial.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createRange.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createRecurry.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createRelationalOperation.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createRound.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createSet.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createToPairs.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_createWrap.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_customDefaultsAssignIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_customDefaultsMerge.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_customOmitClone.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_deburrLetter.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_defineProperty.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_equalArrays.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_equalByTag.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_equalObjects.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_escapeHtmlChar.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_escapeStringChar.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_flatRest.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_freeGlobal.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_getAllKeys.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_getAllKeysIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_getData.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_getFuncName.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_getHolder.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_getMapData.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_getMatchData.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_getNative.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_getPrototype.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_getRawTag.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_getSymbols.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_getSymbolsIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_getTag.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_getValue.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_getView.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_getWrapDetails.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_hasPath.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_hasUnicode.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_hasUnicodeWord.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_hashClear.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_hashDelete.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_hashGet.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_hashHas.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_hashSet.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_initCloneArray.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_initCloneByTag.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_initCloneObject.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_insertWrapDetails.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_isFlattenable.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_isIndex.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_isIterateeCall.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_isKey.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_isKeyable.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_isLaziable.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_isMaskable.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_isMasked.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_isPrototype.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_isStrictComparable.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_iteratorToArray.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_lazyClone.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_lazyReverse.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_lazyValue.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_listCacheClear.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_listCacheDelete.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_listCacheGet.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_listCacheHas.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_listCacheSet.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_mapCacheClear.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_mapCacheDelete.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_mapCacheGet.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_mapCacheHas.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_mapCacheSet.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_mapToArray.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_matchesStrictComparable.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_memoizeCapped.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_mergeData.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_metaMap.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_nativeCreate.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_nativeKeys.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_nativeKeysIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_nodeUtil.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_objectToString.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_overArg.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_overRest.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_parent.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_reEscape.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_reEvaluate.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_reInterpolate.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_realNames.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_reorder.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_replaceHolders.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_root.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_setCacheAdd.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_setCacheHas.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_setData.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_setToArray.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_setToPairs.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_setToString.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_setWrapToString.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_shortOut.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_shuffleSelf.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_stackClear.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_stackDelete.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_stackGet.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_stackHas.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_stackSet.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_strictIndexOf.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_strictLastIndexOf.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_stringSize.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_stringToArray.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_stringToPath.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_toKey.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_toSource.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_unescapeHtmlChar.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_unicodeSize.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_unicodeToArray.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_unicodeWords.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_updateWrapDetails.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/_wrapperClone.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/add.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/after.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/array.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/ary.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/assign.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/assignIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/assignInWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/assignWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/at.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/attempt.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/before.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/bind.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/bindAll.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/bindKey.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/camelCase.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/capitalize.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/castArray.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/ceil.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/chain.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/chunk.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/clamp.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/clone.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/cloneDeep.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/cloneDeepWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/cloneWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/collection.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/commit.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/compact.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/concat.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/cond.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/conforms.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/conformsTo.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/constant.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/core.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/core.min.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/countBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/create.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/curry.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/curryRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/date.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/debounce.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/deburr.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/defaultTo.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/defaults.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/defaultsDeep.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/defer.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/delay.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/difference.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/differenceBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/differenceWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/divide.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/drop.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/dropRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/dropRightWhile.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/dropWhile.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/each.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/eachRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/endsWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/entries.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/entriesIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/eq.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/escape.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/escapeRegExp.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/every.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/extend.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/extendWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fill.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/filter.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/find.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/findIndex.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/findKey.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/findLast.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/findLastIndex.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/findLastKey.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/first.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/flatMap.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/flatMapDeep.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/flatMapDepth.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/flatten.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/flattenDeep.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/flattenDepth.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/flip.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/floor.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/flow.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/flowRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/forEach.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/forEachRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/forIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/forInRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/forOwn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/forOwnRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/F.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/T.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/__.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/_baseConvert.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/_convertBrowser.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/_falseOptions.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/_mapping.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/_util.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/add.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/after.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/all.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/allPass.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/always.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/any.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/anyPass.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/apply.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/array.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/ary.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/assign.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/assignAll.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/assignAllWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/assignIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/assignInAll.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/assignInAllWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/assignInWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/assignWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/assoc.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/assocPath.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/at.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/attempt.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/before.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/bind.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/bindAll.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/bindKey.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/camelCase.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/capitalize.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/castArray.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/ceil.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/chain.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/chunk.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/clamp.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/clone.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/cloneDeep.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/cloneDeepWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/cloneWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/collection.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/commit.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/compact.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/complement.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/compose.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/concat.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/cond.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/conforms.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/conformsTo.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/constant.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/contains.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/convert.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/countBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/create.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/curry.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/curryN.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/curryRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/curryRightN.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/date.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/debounce.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/deburr.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/defaultTo.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/defaults.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/defaultsAll.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/defaultsDeep.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/defaultsDeepAll.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/defer.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/delay.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/difference.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/differenceBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/differenceWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/dissoc.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/dissocPath.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/divide.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/drop.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/dropLast.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/dropLastWhile.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/dropRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/dropRightWhile.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/dropWhile.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/each.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/eachRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/endsWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/entries.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/entriesIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/eq.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/equals.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/escape.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/escapeRegExp.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/every.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/extend.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/extendAll.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/extendAllWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/extendWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/fill.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/filter.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/find.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/findFrom.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/findIndex.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/findIndexFrom.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/findKey.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/findLast.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/findLastFrom.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/findLastIndex.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/findLastIndexFrom.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/findLastKey.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/first.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/flatMap.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/flatMapDeep.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/flatMapDepth.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/flatten.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/flattenDeep.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/flattenDepth.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/flip.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/floor.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/flow.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/flowRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/forEach.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/forEachRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/forIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/forInRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/forOwn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/forOwnRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/fromPairs.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/function.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/functions.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/functionsIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/get.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/getOr.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/groupBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/gt.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/gte.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/has.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/hasIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/head.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/identical.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/identity.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/inRange.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/includes.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/includesFrom.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/indexBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/indexOf.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/indexOfFrom.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/init.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/initial.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/intersection.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/intersectionBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/intersectionWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/invert.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/invertBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/invertObj.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/invoke.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/invokeArgs.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/invokeArgsMap.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/invokeMap.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isArguments.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isArray.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isArrayBuffer.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isArrayLike.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isArrayLikeObject.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isBoolean.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isBuffer.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isDate.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isElement.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isEmpty.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isEqual.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isEqualWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isError.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isFinite.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isFunction.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isInteger.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isLength.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isMap.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isMatch.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isMatchWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isNaN.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isNative.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isNil.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isNull.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isNumber.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isObject.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isObjectLike.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isPlainObject.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isRegExp.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isSafeInteger.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isSet.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isString.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isSymbol.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isTypedArray.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isUndefined.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isWeakMap.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/isWeakSet.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/iteratee.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/join.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/juxt.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/kebabCase.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/keyBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/keys.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/keysIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/lang.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/last.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/lastIndexOf.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/lastIndexOfFrom.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/lowerCase.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/lowerFirst.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/lt.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/lte.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/map.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/mapKeys.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/mapValues.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/matches.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/matchesProperty.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/math.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/max.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/maxBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/mean.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/meanBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/memoize.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/merge.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/mergeAll.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/mergeAllWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/mergeWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/method.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/methodOf.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/min.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/minBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/mixin.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/multiply.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/nAry.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/negate.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/next.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/noop.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/now.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/nth.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/nthArg.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/number.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/object.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/omit.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/omitAll.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/omitBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/once.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/orderBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/over.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/overArgs.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/overEvery.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/overSome.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/pad.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/padChars.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/padCharsEnd.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/padCharsStart.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/padEnd.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/padStart.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/parseInt.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/partial.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/partialRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/partition.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/path.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/pathEq.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/pathOr.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/paths.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/pick.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/pickAll.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/pickBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/pipe.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/placeholder.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/plant.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/pluck.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/prop.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/propEq.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/propOr.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/property.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/propertyOf.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/props.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/pull.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/pullAll.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/pullAllBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/pullAllWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/pullAt.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/random.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/range.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/rangeRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/rangeStep.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/rangeStepRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/rearg.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/reduce.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/reduceRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/reject.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/remove.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/repeat.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/replace.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/rest.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/restFrom.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/result.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/reverse.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/round.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/sample.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/sampleSize.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/seq.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/set.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/setWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/shuffle.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/size.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/slice.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/snakeCase.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/some.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/sortBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/sortedIndex.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/sortedIndexBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/sortedIndexOf.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/sortedLastIndex.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/sortedLastIndexBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/sortedLastIndexOf.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/sortedUniq.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/sortedUniqBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/split.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/spread.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/spreadFrom.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/startCase.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/startsWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/string.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/stubArray.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/stubFalse.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/stubObject.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/stubString.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/stubTrue.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/subtract.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/sum.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/sumBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/symmetricDifference.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/symmetricDifferenceBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/symmetricDifferenceWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/tail.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/take.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/takeLast.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/takeLastWhile.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/takeRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/takeRightWhile.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/takeWhile.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/tap.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/template.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/templateSettings.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/throttle.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/thru.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/times.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/toArray.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/toFinite.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/toInteger.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/toIterator.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/toJSON.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/toLength.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/toLower.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/toNumber.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/toPairs.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/toPairsIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/toPath.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/toPlainObject.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/toSafeInteger.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/toString.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/toUpper.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/transform.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/trim.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/trimChars.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/trimCharsEnd.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/trimCharsStart.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/trimEnd.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/trimStart.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/truncate.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/unapply.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/unary.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/unescape.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/union.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/unionBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/unionWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/uniq.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/uniqBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/uniqWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/uniqueId.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/unnest.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/unset.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/unzip.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/unzipWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/update.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/updateWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/upperCase.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/upperFirst.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/useWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/util.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/value.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/valueOf.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/values.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/valuesIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/where.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/whereEq.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/without.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/words.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/wrap.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/wrapperAt.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/wrapperChain.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/wrapperLodash.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/wrapperReverse.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/wrapperValue.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/xor.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/xorBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/xorWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/zip.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/zipAll.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/zipObj.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/zipObject.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/zipObjectDeep.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fp/zipWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/fromPairs.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/function.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/functions.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/functionsIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/get.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/groupBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/gt.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/gte.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/has.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/hasIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/head.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/identity.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/inRange.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/includes.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/indexOf.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/initial.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/intersection.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/intersectionBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/intersectionWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/invert.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/invertBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/invoke.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/invokeMap.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isArguments.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isArray.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isArrayBuffer.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isArrayLike.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isArrayLikeObject.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isBoolean.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isBuffer.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isDate.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isElement.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isEmpty.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isEqual.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isEqualWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isError.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isFinite.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isFunction.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isInteger.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isLength.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isMap.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isMatch.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isMatchWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isNaN.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isNative.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isNil.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isNull.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isNumber.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isObject.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isObjectLike.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isPlainObject.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isRegExp.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isSafeInteger.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isSet.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isString.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isSymbol.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isTypedArray.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isUndefined.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isWeakMap.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/isWeakSet.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/iteratee.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/join.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/kebabCase.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/keyBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/keys.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/keysIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/lang.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/last.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/lastIndexOf.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/lodash.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/lodash.min.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/lowerCase.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/lowerFirst.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/lt.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/lte.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/map.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/mapKeys.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/mapValues.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/matches.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/matchesProperty.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/math.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/max.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/maxBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/mean.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/meanBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/memoize.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/merge.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/mergeWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/method.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/methodOf.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/min.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/minBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/mixin.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/multiply.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/negate.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/next.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/noop.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/now.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/nth.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/nthArg.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/number.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/object.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/omit.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/omitBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/once.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/orderBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/over.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/overArgs.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/overEvery.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/overSome.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/pad.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/padEnd.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/padStart.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/parseInt.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/partial.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/partialRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/partition.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/pick.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/pickBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/plant.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/property.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/propertyOf.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/pull.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/pullAll.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/pullAllBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/pullAllWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/pullAt.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/random.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/range.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/rangeRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/rearg.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/reduce.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/reduceRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/reject.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/remove.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/repeat.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/replace.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/rest.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/result.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/reverse.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/round.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/sample.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/sampleSize.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/seq.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/set.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/setWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/shuffle.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/size.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/slice.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/snakeCase.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/some.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/sortBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/sortedIndex.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/sortedIndexBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/sortedIndexOf.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/sortedLastIndex.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/sortedLastIndexBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/sortedLastIndexOf.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/sortedUniq.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/sortedUniqBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/split.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/spread.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/startCase.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/startsWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/string.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/stubArray.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/stubFalse.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/stubObject.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/stubString.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/stubTrue.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/subtract.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/sum.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/sumBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/tail.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/take.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/takeRight.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/takeRightWhile.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/takeWhile.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/tap.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/template.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/templateSettings.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/throttle.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/thru.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/times.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/toArray.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/toFinite.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/toInteger.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/toIterator.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/toJSON.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/toLength.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/toLower.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/toNumber.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/toPairs.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/toPairsIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/toPath.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/toPlainObject.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/toSafeInteger.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/toString.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/toUpper.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/transform.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/trim.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/trimEnd.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/trimStart.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/truncate.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/unary.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/unescape.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/union.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/unionBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/unionWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/uniq.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/uniqBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/uniqWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/uniqueId.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/unset.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/unzip.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/unzipWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/update.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/updateWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/upperCase.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/upperFirst.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/util.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/value.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/valueOf.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/values.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/valuesIn.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/without.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/words.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/wrap.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/wrapperAt.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/wrapperChain.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/wrapperLodash.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/wrapperReverse.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/wrapperValue.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/xor.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/xorBy.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/xorWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/zip.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/zipObject.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/zipObjectDeep.js create mode 100644 tools/node_modules/babel-eslint/node_modules/lodash/zipWith.js create mode 100644 tools/node_modules/babel-eslint/node_modules/loose-envify/LICENSE create mode 100644 tools/node_modules/babel-eslint/node_modules/loose-envify/README.md create mode 100755 tools/node_modules/babel-eslint/node_modules/loose-envify/cli.js create mode 100644 tools/node_modules/babel-eslint/node_modules/loose-envify/custom.js create mode 100644 tools/node_modules/babel-eslint/node_modules/loose-envify/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/loose-envify/loose-envify.js create mode 100644 tools/node_modules/babel-eslint/node_modules/loose-envify/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/loose-envify/replace.js create mode 100644 tools/node_modules/babel-eslint/node_modules/ms/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/ms/license.md create mode 100644 tools/node_modules/babel-eslint/node_modules/ms/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/ms/readme.md create mode 100644 tools/node_modules/babel-eslint/node_modules/object-assign/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/object-assign/license create mode 100644 tools/node_modules/babel-eslint/node_modules/object-assign/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/object-assign/readme.md create mode 100644 tools/node_modules/babel-eslint/node_modules/supports-color/browser.js create mode 100644 tools/node_modules/babel-eslint/node_modules/supports-color/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/supports-color/license create mode 100644 tools/node_modules/babel-eslint/node_modules/supports-color/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/supports-color/readme.md create mode 100644 tools/node_modules/babel-eslint/node_modules/to-fast-properties/index.js create mode 100644 tools/node_modules/babel-eslint/node_modules/to-fast-properties/license create mode 100644 tools/node_modules/babel-eslint/node_modules/to-fast-properties/package.json create mode 100644 tools/node_modules/babel-eslint/node_modules/to-fast-properties/readme.md create mode 100644 tools/node_modules/babel-eslint/package.json create mode 100755 tools/update-babel-eslint.sh diff --git a/LICENSE b/LICENSE index c0578539494b70..4d4fd710946b24 100644 --- a/LICENSE +++ b/LICENSE @@ -1061,6 +1061,32 @@ The externally maintained libraries used by Node.js are: THE SOFTWARE. """ +- babel-eslint, located at tools/node_modules/babel-eslint, is licensed as follows: + """ + Copyright (c) 2014-2016 Sebastian McKenzie + + MIT License + + Permission is hereby granted, free of charge, to any person obtaining + a copy of this software and associated documentation files (the + "Software"), to deal in the Software without restriction, including + without limitation the rights to use, copy, modify, merge, publish, + distribute, sublicense, and/or sell copies of the Software, and to + permit persons to whom the Software is furnished to do so, subject to + the following conditions: + + The above copyright notice and this permission notice shall be + included in all copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, + EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE + LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION + OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION + WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + """ + - gtest, located at deps/gtest, is licensed as follows: """ Copyright 2008, Google Inc. diff --git a/tools/license-builder.sh b/tools/license-builder.sh index dcd10e270c8bbb..50e92b3821a3cb 100755 --- a/tools/license-builder.sh +++ b/tools/license-builder.sh @@ -77,6 +77,7 @@ addlicense "marked" "tools/doc/node_modules/marked" \ addlicense "cpplint.py" "tools/cpplint.py" \ "$(sed -e '/^$/,$d' -e 's/^#$//' -e 's/^# //' ${rootdir}/tools/cpplint.py | tail -n +3)" addlicense "ESLint" "tools/node_modules/eslint" "$(cat ${rootdir}/tools/node_modules/eslint/LICENSE)" +addlicense "babel-eslint" "tools/node_modules/babel-eslint" "$(cat ${rootdir}/tools/node_modules/babel-eslint/LICENSE)" addlicense "gtest" "deps/gtest" "$(cat ${rootdir}/deps/gtest/LICENSE)" # nghttp2 diff --git a/tools/node_modules/babel-eslint/LICENSE b/tools/node_modules/babel-eslint/LICENSE new file mode 100644 index 00000000000000..80194a854b944c --- /dev/null +++ b/tools/node_modules/babel-eslint/LICENSE @@ -0,0 +1,22 @@ +Copyright (c) 2014-2016 Sebastian McKenzie + +MIT License + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/tools/node_modules/babel-eslint/README.md b/tools/node_modules/babel-eslint/README.md new file mode 100644 index 00000000000000..23f13c3b1080bf --- /dev/null +++ b/tools/node_modules/babel-eslint/README.md @@ -0,0 +1,102 @@ +# babel-eslint [![npm](https://img.shields.io/npm/v/babel-eslint.svg)](https://www.npmjs.com/package/babel-eslint) [![travis](https://img.shields.io/travis/babel/babel-eslint/master.svg)](https://travis-ci.org/babel/babel-eslint) [![npm-downloads](https://img.shields.io/npm/dm/babel-eslint.svg)](https://www.npmjs.com/package/babel-eslint) + +**babel-eslint** allows you to lint **ALL** valid Babel code with the fantastic +[ESLint](https://github.com/eslint/eslint). + +### Why Use babel-eslint + +You only need to use babel-eslint if you are using types (Flow) or experimental features not supported in ESLint itself yet. Otherwise try the default parser (you don't have to use it just because you are using Babel). + +--- + +> If there is an issue, first check if it can be reproduced with the regular parser or with the latest versions of `eslint` and `babel-eslint`! + +For questions and support please visit the [`#discussion`](https://babeljs.slack.com/messages/discussion/) babel slack channel (sign up [here](https://github.com/babel/notes/issues/38)) or eslint [gitter](https://gitter.im/eslint/eslint)! + +> Note that the `ecmaFeatures` config property may still be required for ESLint to work properly with features not in ECMAScript 5 by default. Examples are `globalReturn` and `modules`). + +## Known Issues + +Flow: +> Check out [eslint-plugin-flowtype](https://github.com/gajus/eslint-plugin-flowtype): An `eslint` plugin that makes flow type annotations global variables and marks declarations as used. Solves the problem of false positives with `no-undef` and `no-unused-vars`. +- `no-undef` for global flow types: `ReactElement`, `ReactClass` [#130](https://github.com/babel/babel-eslint/issues/130#issuecomment-111215076) + - Workaround: define types as globals in `.eslintrc` or define types and import them `import type ReactElement from './types'` +- `no-unused-vars/no-undef` with Flow declarations (`declare module A {}`) [#132](https://github.com/babel/babel-eslint/issues/132#issuecomment-112815926) + +Modules/strict mode +- `no-unused-vars: [2, {vars: local}]` [#136](https://github.com/babel/babel-eslint/issues/136) + +Please check out [eslint-plugin-react](https://github.com/yannickcr/eslint-plugin-react) for React/JSX issues +- `no-unused-vars` with jsx + +Please check out [eslint-plugin-babel](https://github.com/babel/eslint-plugin-babel) for other issues + +## How does it work? + +ESLint allows custom parsers. This is great but some of the syntax nodes that Babel supports +aren't supported by ESLint. When using this plugin, ESLint is monkeypatched and your code is +transformed into code that ESLint can understand. All location info such as line numbers, +columns is also retained so you can track down errors with ease. + +Basically `babel-eslint` exports an [`index.js`](/index.js) that a linter can use. +It just needs to export a `parse` method that takes in a string of code and outputs an AST. + +## Usage + +### Supported ESLint versions + +ESLint | babel-eslint +------------ | ------------- +3.x | >= 6.x +2.x | >= 6.x +1.x | >= 5.x + +### Install + +Ensure that you have substituted the correct version lock for `eslint` and `babel-eslint` into this command: + +```sh +$ npm install eslint@3.x babel-eslint@7 --save-dev +# or +$ yarn add eslint@3.x babel-eslint@7 -D +``` + +### Setup + +**.eslintrc** + +```json +{ + "parser": "babel-eslint", + "rules": { + "strict": 0 + } +} +``` + +Check out the [ESLint docs](http://eslint.org/docs/rules/) for all possible rules. + +### Configuration + +`sourceType` can be set to `'module'`(default) or `'script'` if your code isn't using ECMAScript modules. +`allowImportExportEverywhere` can be set to true to allow import and export declarations to appear anywhere a statement is allowed if your build environment supports that. By default, import and export declarations can only appear at a program's top level. +`codeFrame` can be set to false to disable the code frame in the reporter. This is useful since some eslint formatters don't play well with it. + +**.eslintrc** + +```json +{ + "parser": "babel-eslint", + "parserOptions": { + "sourceType": "module", + "allowImportExportEverywhere": false, + "codeFrame": false + } +} +``` + +### Run + +```sh +$ eslint your-files-here +``` diff --git a/tools/node_modules/babel-eslint/lib/analyze-scope.js b/tools/node_modules/babel-eslint/lib/analyze-scope.js new file mode 100644 index 00000000000000..dd4cc3b35a5ae1 --- /dev/null +++ b/tools/node_modules/babel-eslint/lib/analyze-scope.js @@ -0,0 +1,338 @@ +"use strict"; + +const t = require("@babel/types"); +const escope = require("eslint-scope"); +const Definition = require("eslint-scope/lib/definition").Definition; +const OriginalPatternVisitor = require("eslint-scope/lib/pattern-visitor"); +const OriginalReferencer = require("eslint-scope/lib/referencer"); +const fallback = require("eslint-visitor-keys").getKeys; +const childVisitorKeys = require("./visitor-keys"); + +const flowFlippedAliasKeys = t.FLIPPED_ALIAS_KEYS.Flow.concat([ + "ArrayPattern", + "ClassDeclaration", + "ClassExpression", + "FunctionDeclaration", + "FunctionExpression", + "Identifier", + "ObjectPattern", + "RestElement", +]); +const visitorKeysMap = Object.keys(t.VISITOR_KEYS).reduce(function(acc, key) { + const value = t.VISITOR_KEYS[key]; + if (flowFlippedAliasKeys.indexOf(value) === -1) { + acc[key] = value; + } + return acc; +}, {}); + +const propertyTypes = { + // loops + callProperties: { type: "loop", values: ["value"] }, + indexers: { type: "loop", values: ["key", "value"] }, + properties: { type: "loop", values: ["argument", "value"] }, + types: { type: "loop" }, + params: { type: "loop" }, + // single property + argument: { type: "single" }, + elementType: { type: "single" }, + qualification: { type: "single" }, + rest: { type: "single" }, + returnType: { type: "single" }, + // others + typeAnnotation: { type: "typeAnnotation" }, + typeParameters: { type: "typeParameters" }, + id: { type: "id" }, +}; + +class PatternVisitor extends OriginalPatternVisitor { + ArrayPattern(node) { + node.elements.forEach(this.visit, this); + } + + ObjectPattern(node) { + node.properties.forEach(this.visit, this); + } +} + +class Referencer extends OriginalReferencer { + // inherits. + visitPattern(node, options, callback) { + if (!node) { + return; + } + + // Visit type annotations. + this._checkIdentifierOrVisit(node.typeAnnotation); + if (t.isAssignmentPattern(node)) { + this._checkIdentifierOrVisit(node.left.typeAnnotation); + } + + // Overwrite `super.visitPattern(node, options, callback)` in order to not visit `ArrayPattern#typeAnnotation` and `ObjectPattern#typeAnnotation`. + if (typeof options === "function") { + callback = options; + options = { processRightHandNodes: false }; + } + + const visitor = new PatternVisitor(this.options, node, callback); + visitor.visit(node); + + // Process the right hand nodes recursively. + if (options.processRightHandNodes) { + visitor.rightHandNodes.forEach(this.visit, this); + } + } + + // inherits. + visitClass(node) { + // Decorators. + this._visitArray(node.decorators); + + // Flow type parameters. + const typeParamScope = this._nestTypeParamScope(node); + + // Flow super types. + this._visitTypeAnnotation(node.implements); + this._visitTypeAnnotation( + node.superTypeParameters && node.superTypeParameters.params + ); + + // Basic. + super.visitClass(node); + + // Close the type parameter scope. + if (typeParamScope) { + this.close(node); + } + } + + // inherits. + visitFunction(node) { + const typeParamScope = this._nestTypeParamScope(node); + + // Flow return types. + this._checkIdentifierOrVisit(node.returnType); + + // Basic. + super.visitFunction(node); + + // Close the type parameter scope. + if (typeParamScope) { + this.close(node); + } + } + + // inherits. + visitProperty(node) { + if (node.value && node.value.type === "TypeCastExpression") { + this._visitTypeAnnotation(node.value); + } + this._visitArray(node.decorators); + super.visitProperty(node); + } + + InterfaceDeclaration(node) { + this._createScopeVariable(node, node.id); + + const typeParamScope = this._nestTypeParamScope(node); + + // TODO: Handle mixins + this._visitArray(node.extends); + this.visit(node.body); + + if (typeParamScope) { + this.close(node); + } + } + + TypeAlias(node) { + this._createScopeVariable(node, node.id); + + const typeParamScope = this._nestTypeParamScope(node); + + this.visit(node.right); + + if (typeParamScope) { + this.close(node); + } + } + + ClassProperty(node) { + this._visitClassProperty(node); + } + + ClassPrivateProperty(node) { + this._visitClassProperty(node); + } + + DeclareModule(node) { + this._visitDeclareX(node); + } + + DeclareFunction(node) { + this._visitDeclareX(node); + } + + DeclareVariable(node) { + this._visitDeclareX(node); + } + + DeclareClass(node) { + this._visitDeclareX(node); + } + + _visitClassProperty(node) { + this._visitTypeAnnotation(node.typeAnnotation); + this.visitProperty(node); + } + + _visitDeclareX(node) { + if (node.id) { + this._createScopeVariable(node, node.id); + } + + const typeParamScope = this._nestTypeParamScope(node); + if (typeParamScope) { + this.close(node); + } + } + + _createScopeVariable(node, name) { + this.currentScope().variableScope.__define( + name, + new Definition("Variable", name, node, null, null, null) + ); + } + + _nestTypeParamScope(node) { + if (!node.typeParameters) { + return null; + } + + const parentScope = this.scopeManager.__currentScope; + const scope = new escope.Scope( + this.scopeManager, + "type-parameters", + parentScope, + node, + false + ); + + this.scopeManager.__nestScope(scope); + for (let j = 0; j < node.typeParameters.params.length; j++) { + const name = node.typeParameters.params[j]; + scope.__define(name, new Definition("TypeParameter", name, name)); + if (name.typeAnnotation) { + this._checkIdentifierOrVisit(name); + } + } + scope.__define = function() { + return parentScope.__define.apply(parentScope, arguments); + }; + + return scope; + } + + _visitTypeAnnotation(node) { + if (!node) { + return; + } + if (Array.isArray(node)) { + node.forEach(this._visitTypeAnnotation, this); + return; + } + + // get property to check (params, id, etc...) + const visitorValues = visitorKeysMap[node.type]; + if (!visitorValues) { + return; + } + + // can have multiple properties + for (let i = 0; i < visitorValues.length; i++) { + const visitorValue = visitorValues[i]; + const propertyType = propertyTypes[visitorValue]; + const nodeProperty = node[visitorValue]; + // check if property or type is defined + if (propertyType == null || nodeProperty == null) { + continue; + } + if (propertyType.type === "loop") { + for (let j = 0; j < nodeProperty.length; j++) { + if (Array.isArray(propertyType.values)) { + for (let k = 0; k < propertyType.values.length; k++) { + const loopPropertyNode = nodeProperty[j][propertyType.values[k]]; + if (loopPropertyNode) { + this._checkIdentifierOrVisit(loopPropertyNode); + } + } + } else { + this._checkIdentifierOrVisit(nodeProperty[j]); + } + } + } else if (propertyType.type === "single") { + this._checkIdentifierOrVisit(nodeProperty); + } else if (propertyType.type === "typeAnnotation") { + this._visitTypeAnnotation(node.typeAnnotation); + } else if (propertyType.type === "typeParameters") { + for (let l = 0; l < node.typeParameters.params.length; l++) { + this._checkIdentifierOrVisit(node.typeParameters.params[l]); + } + } else if (propertyType.type === "id") { + if (node.id.type === "Identifier") { + this._checkIdentifierOrVisit(node.id); + } else { + this._visitTypeAnnotation(node.id); + } + } + } + } + + _checkIdentifierOrVisit(node) { + if (node && node.typeAnnotation) { + this._visitTypeAnnotation(node.typeAnnotation); + } else if (node && node.type === "Identifier") { + this.visit(node); + } else { + this._visitTypeAnnotation(node); + } + } + + _visitArray(nodeList) { + if (nodeList) { + for (const node of nodeList) { + this.visit(node); + } + } + } +} + +module.exports = function(ast, parserOptions) { + const options = { + ignoreEval: true, + optimistic: false, + directive: false, + nodejsScope: + ast.sourceType === "script" && + (parserOptions.ecmaFeatures && + parserOptions.ecmaFeatures.globalReturn) === true, + impliedStrict: false, + sourceType: ast.sourceType, + ecmaVersion: parserOptions.ecmaVersion || 2018, + fallback, + }; + + if (OriginalReferencer._babelEslintPatched) { + require("./patch-eslint-scope")(parserOptions); + return escope.analyze(ast, options); + } + + options.childVisitorKeys = childVisitorKeys; + + const scopeManager = new escope.ScopeManager(options); + const referencer = new Referencer(options, scopeManager); + + referencer.visit(ast); + + return scopeManager; +}; diff --git a/tools/node_modules/babel-eslint/lib/babylon-to-espree/attachComments.js b/tools/node_modules/babel-eslint/lib/babylon-to-espree/attachComments.js new file mode 100644 index 00000000000000..8c608a45ad9473 --- /dev/null +++ b/tools/node_modules/babel-eslint/lib/babylon-to-espree/attachComments.js @@ -0,0 +1,59 @@ +"use strict"; + +// comment fixes +module.exports = function(ast, comments, tokens) { + if (comments.length) { + var firstComment = comments[0]; + var lastComment = comments[comments.length - 1]; + // fixup program start + if (!tokens.length) { + // if no tokens, the program starts at the end of the last comment + ast.start = lastComment.end; + ast.loc.start.line = lastComment.loc.end.line; + ast.loc.start.column = lastComment.loc.end.column; + + if (ast.leadingComments === null && ast.innerComments.length) { + ast.leadingComments = ast.innerComments; + } + } else if (firstComment.start < tokens[0].start) { + // if there are comments before the first token, the program starts at the first token + var token = tokens[0]; + // ast.start = token.start; + // ast.loc.start.line = token.loc.start.line; + // ast.loc.start.column = token.loc.start.column; + + // estraverse do not put leading comments on first node when the comment + // appear before the first token + if (ast.body.length) { + var node = ast.body[0]; + node.leadingComments = []; + var firstTokenStart = token.start; + var len = comments.length; + for (var i = 0; i < len && comments[i].start < firstTokenStart; i++) { + node.leadingComments.push(comments[i]); + } + } + } + // fixup program end + if (tokens.length) { + var lastToken = tokens[tokens.length - 1]; + if (lastComment.end > lastToken.end) { + // If there is a comment after the last token, the program ends at the + // last token and not the comment + // ast.end = lastToken.end; + ast.range[1] = lastToken.end; + ast.loc.end.line = lastToken.loc.end.line; + ast.loc.end.column = lastToken.loc.end.column; + } + } + } else { + if (!tokens.length) { + ast.loc.start.line = 1; + ast.loc.end.line = 1; + } + } + if (ast.body && ast.body.length > 0) { + ast.loc.start.line = ast.body[0].loc.start.line; + ast.range[0] = ast.body[0].start; + } +}; diff --git a/tools/node_modules/babel-eslint/lib/babylon-to-espree/convertComments.js b/tools/node_modules/babel-eslint/lib/babylon-to-espree/convertComments.js new file mode 100644 index 00000000000000..17d7117372946d --- /dev/null +++ b/tools/node_modules/babel-eslint/lib/babylon-to-espree/convertComments.js @@ -0,0 +1,17 @@ +"use strict"; + +module.exports = function(comments) { + for (var i = 0; i < comments.length; i++) { + var comment = comments[i]; + if (comment.type === "CommentBlock") { + comment.type = "Block"; + } else if (comment.type === "CommentLine") { + comment.type = "Line"; + } + // sometimes comments don't get ranges computed, + // even with options.ranges === true + if (!comment.range) { + comment.range = [comment.start, comment.end]; + } + } +}; diff --git a/tools/node_modules/babel-eslint/lib/babylon-to-espree/convertTemplateType.js b/tools/node_modules/babel-eslint/lib/babylon-to-espree/convertTemplateType.js new file mode 100644 index 00000000000000..d8892f997260cb --- /dev/null +++ b/tools/node_modules/babel-eslint/lib/babylon-to-espree/convertTemplateType.js @@ -0,0 +1,99 @@ +"use strict"; + +module.exports = function(tokens, tt) { + var startingToken = 0; + var currentToken = 0; + var numBraces = 0; // track use of {} + var numBackQuotes = 0; // track number of nested templates + + function isBackQuote(token) { + return tokens[token].type === tt.backQuote; + } + + function isTemplateStarter(token) { + return ( + isBackQuote(token) || + // only can be a template starter when in a template already + (tokens[token].type === tt.braceR && numBackQuotes > 0) + ); + } + + function isTemplateEnder(token) { + return isBackQuote(token) || tokens[token].type === tt.dollarBraceL; + } + + // append the values between start and end + function createTemplateValue(start, end) { + var value = ""; + while (start <= end) { + if (tokens[start].value) { + value += tokens[start].value; + } else if (tokens[start].type !== tt.template) { + value += tokens[start].type.label; + } + start++; + } + return value; + } + + // create Template token + function replaceWithTemplateType(start, end) { + var templateToken = { + type: "Template", + value: createTemplateValue(start, end), + start: tokens[start].start, + end: tokens[end].end, + loc: { + start: tokens[start].loc.start, + end: tokens[end].loc.end, + }, + }; + + // put new token in place of old tokens + tokens.splice(start, end - start + 1, templateToken); + } + + function trackNumBraces(token) { + if (tokens[token].type === tt.braceL) { + numBraces++; + } else if (tokens[token].type === tt.braceR) { + numBraces--; + } + } + + while (startingToken < tokens.length) { + // template start: check if ` or } + if (isTemplateStarter(startingToken) && numBraces === 0) { + if (isBackQuote(startingToken)) { + numBackQuotes++; + } + + currentToken = startingToken + 1; + + // check if token after template start is "template" + if ( + currentToken >= tokens.length - 1 || + tokens[currentToken].type !== tt.template + ) { + break; + } + + // template end: find ` or ${ + while (!isTemplateEnder(currentToken)) { + if (currentToken >= tokens.length - 1) { + break; + } + currentToken++; + } + + if (isBackQuote(currentToken)) { + numBackQuotes--; + } + // template start and end found: create new token + replaceWithTemplateType(startingToken, currentToken); + } else if (numBackQuotes > 0) { + trackNumBraces(startingToken); + } + startingToken++; + } +}; diff --git a/tools/node_modules/babel-eslint/lib/babylon-to-espree/index.js b/tools/node_modules/babel-eslint/lib/babylon-to-espree/index.js new file mode 100644 index 00000000000000..ecd8eee6f1d8a8 --- /dev/null +++ b/tools/node_modules/babel-eslint/lib/babylon-to-espree/index.js @@ -0,0 +1,35 @@ +"use strict"; + +var attachComments = require("./attachComments"); +var convertComments = require("./convertComments"); +var toTokens = require("./toTokens"); +var toAST = require("./toAST"); + +module.exports = function(ast, traverse, tt, code) { + // remove EOF token, eslint doesn't use this for anything and it interferes + // with some rules see https://github.com/babel/babel-eslint/issues/2 + // todo: find a more elegant way to do this + ast.tokens.pop(); + + // convert tokens + ast.tokens = toTokens(ast.tokens, tt, code); + + // add comments + convertComments(ast.comments); + + // transform esprima and acorn divergent nodes + toAST(ast, traverse, code); + + // ast.program.tokens = ast.tokens; + // ast.program.comments = ast.comments; + // ast = ast.program; + + // remove File + ast.type = "Program"; + ast.sourceType = ast.program.sourceType; + ast.directives = ast.program.directives; + ast.body = ast.program.body; + delete ast.program; + + attachComments(ast, ast.comments, ast.tokens); +}; diff --git a/tools/node_modules/babel-eslint/lib/babylon-to-espree/toAST.js b/tools/node_modules/babel-eslint/lib/babylon-to-espree/toAST.js new file mode 100644 index 00000000000000..b3da41f0cb0663 --- /dev/null +++ b/tools/node_modules/babel-eslint/lib/babylon-to-espree/toAST.js @@ -0,0 +1,118 @@ +"use strict"; + +var t = require("@babel/types"); +var convertComments = require("./convertComments"); + +module.exports = function(ast, traverse, code) { + var state = { source: code }; + + // Monkey patch visitor keys in order to be able to traverse the estree nodes + t.VISITOR_KEYS.Property = t.VISITOR_KEYS.ObjectProperty; + t.VISITOR_KEYS.MethodDefinition = [ + "key", + "value", + "decorators", + "returnType", + "typeParameters", + ]; + + traverse(ast, astTransformVisitor, null, state); + + delete t.VISITOR_KEYS.Property; + delete t.VISITOR_KEYS.MethodDefinition; +}; + +var astTransformVisitor = { + noScope: true, + enter(path) { + var node = path.node; + + // private var to track original node type + node._babelType = node.type; + + if (node.innerComments) { + node.trailingComments = node.innerComments; + delete node.innerComments; + } + + if (node.trailingComments) { + convertComments(node.trailingComments); + } + + if (node.leadingComments) { + convertComments(node.leadingComments); + } + }, + exit(path) { + var node = path.node; + + if (path.isJSXText()) { + node.type = "Literal"; + } + + if ( + path.isRestElement() && + path.parent && + path.parent.type === "ObjectPattern" + ) { + node.type = "ExperimentalRestProperty"; + } + + if ( + path.isSpreadElement() && + path.parent && + path.parent.type === "ObjectExpression" + ) { + node.type = "ExperimentalSpreadProperty"; + } + + if (path.isTypeParameter()) { + node.type = "Identifier"; + node.typeAnnotation = node.bound; + delete node.bound; + } + + // flow: prevent "no-undef" + // for "Component" in: "let x: React.Component" + if (path.isQualifiedTypeIdentifier()) { + delete node.id; + } + // for "b" in: "var a: { b: Foo }" + if (path.isObjectTypeProperty()) { + delete node.key; + } + // for "indexer" in: "var a: {[indexer: string]: number}" + if (path.isObjectTypeIndexer()) { + delete node.id; + } + // for "param" in: "var a: { func(param: Foo): Bar };" + if (path.isFunctionTypeParam()) { + delete node.name; + } + + // modules + + if (path.isImportDeclaration()) { + delete node.isType; + } + + // template string range fixes + if (path.isTemplateLiteral()) { + for (var j = 0; j < node.quasis.length; j++) { + var q = node.quasis[j]; + q.range[0] -= 1; + if (q.tail) { + q.range[1] += 1; + } else { + q.range[1] += 2; + } + q.loc.start.column -= 1; + if (q.tail) { + q.loc.end.column += 1; + } else { + q.loc.end.column += 2; + } + } + } + }, +}; diff --git a/tools/node_modules/babel-eslint/lib/babylon-to-espree/toToken.js b/tools/node_modules/babel-eslint/lib/babylon-to-espree/toToken.js new file mode 100644 index 00000000000000..9c5a49ef11dda2 --- /dev/null +++ b/tools/node_modules/babel-eslint/lib/babylon-to-espree/toToken.js @@ -0,0 +1,80 @@ +"use strict"; + +module.exports = function(token, tt, source) { + var type = token.type; + token.range = [token.start, token.end]; + + if (type === tt.name) { + token.type = "Identifier"; + } else if ( + type === tt.semi || + type === tt.comma || + type === tt.parenL || + type === tt.parenR || + type === tt.braceL || + type === tt.braceR || + type === tt.slash || + type === tt.dot || + type === tt.bracketL || + type === tt.bracketR || + type === tt.ellipsis || + type === tt.arrow || + type === tt.star || + type === tt.incDec || + type === tt.colon || + type === tt.question || + type === tt.template || + type === tt.backQuote || + type === tt.dollarBraceL || + type === tt.at || + type === tt.logicalOR || + type === tt.logicalAND || + type === tt.bitwiseOR || + type === tt.bitwiseXOR || + type === tt.bitwiseAND || + type === tt.equality || + type === tt.relational || + type === tt.bitShift || + type === tt.plusMin || + type === tt.modulo || + type === tt.exponent || + type === tt.prefix || + type === tt.doubleColon || + type.isAssign + ) { + token.type = "Punctuator"; + if (!token.value) token.value = type.label; + } else if (type === tt.jsxTagStart) { + token.type = "Punctuator"; + token.value = "<"; + } else if (type === tt.jsxTagEnd) { + token.type = "Punctuator"; + token.value = ">"; + } else if (type === tt.jsxName) { + token.type = "JSXIdentifier"; + } else if (type === tt.jsxText) { + token.type = "JSXText"; + } else if (type.keyword === "null") { + token.type = "Null"; + } else if (type.keyword === "false" || type.keyword === "true") { + token.type = "Boolean"; + } else if (type.keyword) { + token.type = "Keyword"; + } else if (type === tt.num) { + token.type = "Numeric"; + token.value = source.slice(token.start, token.end); + } else if (type === tt.string) { + token.type = "String"; + token.value = source.slice(token.start, token.end); + } else if (type === tt.regexp) { + token.type = "RegularExpression"; + var value = token.value; + token.regex = { + pattern: value.pattern, + flags: value.flags, + }; + token.value = `/${value.pattern}/${value.flags}`; + } + + return token; +}; diff --git a/tools/node_modules/babel-eslint/lib/babylon-to-espree/toTokens.js b/tools/node_modules/babel-eslint/lib/babylon-to-espree/toTokens.js new file mode 100644 index 00000000000000..a863b871b0a869 --- /dev/null +++ b/tools/node_modules/babel-eslint/lib/babylon-to-espree/toTokens.js @@ -0,0 +1,19 @@ +"use strict"; + +var convertTemplateType = require("./convertTemplateType"); +var toToken = require("./toToken"); + +module.exports = function(tokens, tt, code) { + // transform tokens to type "Template" + convertTemplateType(tokens, tt); + + var transformedTokens = []; + for (var i = 0; i < tokens.length; i++) { + var token = tokens[i]; + if (token.type !== "CommentLine" && token.type !== "CommentBlock") { + transformedTokens.push(toToken(token, tt, code)); + } + } + + return transformedTokens; +}; diff --git a/tools/node_modules/babel-eslint/lib/index.js b/tools/node_modules/babel-eslint/lib/index.js new file mode 100644 index 00000000000000..c4655280afad73 --- /dev/null +++ b/tools/node_modules/babel-eslint/lib/index.js @@ -0,0 +1,22 @@ +"use strict"; + +exports.parse = function(code, options) { + return exports.parseForESLint(code, options).ast; +}; + +exports.parseForESLint = function(code, options) { + options = options || {}; + options.ecmaVersion = options.ecmaVersion || 2018; + options.sourceType = options.sourceType || "module"; + options.allowImportExportEverywhere = + options.allowImportExportEverywhere || false; + + if (options.eslintVisitorKeys && options.eslintScopeManager) { + return require("./parse-with-scope")(code, options); + } + return { ast: require("./parse-with-patch")(code, options) }; +}; + +exports.parseNoPatch = function(code, options) { + return require("./parse")(code, options); +}; diff --git a/tools/node_modules/babel-eslint/lib/parse-with-patch.js b/tools/node_modules/babel-eslint/lib/parse-with-patch.js new file mode 100644 index 00000000000000..ba1b95b5b107a6 --- /dev/null +++ b/tools/node_modules/babel-eslint/lib/parse-with-patch.js @@ -0,0 +1,9 @@ +"use strict"; + +var parse = require("./parse"); +var patchEscope = require("./patch-eslint-scope"); + +module.exports = function(code, options) { + patchEscope(options); + return parse(code, options); +}; diff --git a/tools/node_modules/babel-eslint/lib/parse-with-scope.js b/tools/node_modules/babel-eslint/lib/parse-with-scope.js new file mode 100644 index 00000000000000..36e3fce5b06712 --- /dev/null +++ b/tools/node_modules/babel-eslint/lib/parse-with-scope.js @@ -0,0 +1,12 @@ +"use strict"; + +const visitorKeys = require("./visitor-keys"); +const analyzeScope = require("./analyze-scope"); +const parse = require("./parse"); + +module.exports = function(code, options) { + const ast = parse(code, options); + const scopeManager = analyzeScope(ast, options); + + return { ast, scopeManager, visitorKeys }; +}; diff --git a/tools/node_modules/babel-eslint/lib/parse.js b/tools/node_modules/babel-eslint/lib/parse.js new file mode 100644 index 00000000000000..f29e6af155b57a --- /dev/null +++ b/tools/node_modules/babel-eslint/lib/parse.js @@ -0,0 +1,87 @@ +"use strict"; + +var babylonToEspree = require("./babylon-to-espree"); +var parse = require("babylon").parse; +var tt = require("babylon").tokTypes; +var traverse = require("@babel/traverse").default; +var codeFrameColumns = require("@babel/code-frame").codeFrameColumns; + +module.exports = function(code, options) { + var opts = { + codeFrame: options.hasOwnProperty("codeFrame") ? options.codeFrame : true, + sourceType: options.sourceType, + allowImportExportEverywhere: options.allowImportExportEverywhere, // consistent with espree + allowReturnOutsideFunction: true, + allowSuperOutsideMethod: true, + ranges: true, + tokens: true, + plugins: [ + "flow", + "jsx", + "estree", + "asyncFunctions", + "asyncGenerators", + "classConstructorCall", + "classProperties", + "decorators", + "doExpressions", + "exponentiationOperator", + "exportDefaultFrom", + "exportNamespaceFrom", + "functionBind", + "functionSent", + "objectRestSpread", + "trailingFunctionCommas", + "dynamicImport", + "numericSeparator", + "optionalChaining", + "importMeta", + "classPrivateProperties", + "bigInt", + "optionalCatchBinding", + "throwExpressions", + "pipelineOperator", + "nullishCoalescingOperator", + ], + }; + + var ast; + try { + ast = parse(code, opts); + } catch (err) { + if (err instanceof SyntaxError) { + err.lineNumber = err.loc.line; + err.column = err.loc.column; + + if (opts.codeFrame) { + err.lineNumber = err.loc.line; + err.column = err.loc.column + 1; + + // remove trailing "(LINE:COLUMN)" acorn message and add in esprima syntax error message start + err.message = + "Line " + + err.lineNumber + + ": " + + err.message.replace(/ \((\d+):(\d+)\)$/, "") + + // add codeframe + "\n\n" + + codeFrameColumns( + code, + { + start: { + line: err.lineNumber, + column: err.column, + }, + }, + { highlightCode: true } + ); + } + } + + throw err; + } + + babylonToEspree(ast, traverse, tt, code); + + return ast; +}; diff --git a/tools/node_modules/babel-eslint/lib/patch-eslint-scope.js b/tools/node_modules/babel-eslint/lib/patch-eslint-scope.js new file mode 100644 index 00000000000000..aec71fc6ca70f7 --- /dev/null +++ b/tools/node_modules/babel-eslint/lib/patch-eslint-scope.js @@ -0,0 +1,370 @@ +"use strict"; + +var Module = require("module"); +var path = require("path"); +var t = require("@babel/types"); + +function getModules() { + try { + // avoid importing a local copy of eslint, try to find a peer dependency + var eslintLoc = Module._resolveFilename("eslint", module.parent); + } catch (err) { + try { + // avoids breaking in jest where module.parent is undefined + eslintLoc = require.resolve("eslint"); + } catch (err) { + throw new ReferenceError("couldn't resolve eslint"); + } + } + + // get modules relative to what eslint will load + var eslintMod = new Module(eslintLoc); + eslintMod.filename = eslintLoc; + eslintMod.paths = Module._nodeModulePaths(path.dirname(eslintLoc)); + + try { + var escope = eslintMod.require("eslint-scope"); + var Definition = eslintMod.require("eslint-scope/lib/definition") + .Definition; + var referencer = eslintMod.require("eslint-scope/lib/referencer"); + } catch (err) { + escope = eslintMod.require("escope"); + Definition = eslintMod.require("escope/lib/definition").Definition; + referencer = eslintMod.require("escope/lib/referencer"); + } + + var estraverse = eslintMod.require("estraverse"); + + if (referencer.__esModule) referencer = referencer.default; + + return { + Definition, + escope, + estraverse, + referencer, + }; +} + +function monkeypatch(modules) { + var Definition = modules.Definition; + var escope = modules.escope; + var estraverse = modules.estraverse; + var referencer = modules.referencer; + + Object.assign(estraverse.VisitorKeys, t.VISITOR_KEYS); + estraverse.VisitorKeys.MethodDefinition.push("decorators"); + estraverse.VisitorKeys.Property.push("decorators"); + + // if there are decorators, then visit each + function visitDecorators(node) { + if (!node.decorators) { + return; + } + for (var i = 0; i < node.decorators.length; i++) { + if (node.decorators[i].expression) { + this.visit(node.decorators[i]); + } + } + } + + // iterate through part of t.VISITOR_KEYS + var flowFlippedAliasKeys = t.FLIPPED_ALIAS_KEYS.Flow.concat([ + "ArrayPattern", + "ClassDeclaration", + "ClassExpression", + "FunctionDeclaration", + "FunctionExpression", + "Identifier", + "ObjectPattern", + "RestElement", + ]); + var visitorKeysMap = Object.keys(t.VISITOR_KEYS).reduce(function(acc, key) { + var value = t.VISITOR_KEYS[key]; + if (flowFlippedAliasKeys.indexOf(value) === -1) { + acc[key] = value; + } + return acc; + }, {}); + + var propertyTypes = { + // loops + callProperties: { type: "loop", values: ["value"] }, + indexers: { type: "loop", values: ["key", "value"] }, + properties: { type: "loop", values: ["argument", "value"] }, + types: { type: "loop" }, + params: { type: "loop" }, + // single property + argument: { type: "single" }, + elementType: { type: "single" }, + qualification: { type: "single" }, + rest: { type: "single" }, + returnType: { type: "single" }, + // others + typeAnnotation: { type: "typeAnnotation" }, + typeParameters: { type: "typeParameters" }, + id: { type: "id" }, + }; + + function visitTypeAnnotation(node) { + // get property to check (params, id, etc...) + var visitorValues = visitorKeysMap[node.type]; + if (!visitorValues) { + return; + } + + // can have multiple properties + for (var i = 0; i < visitorValues.length; i++) { + var visitorValue = visitorValues[i]; + var propertyType = propertyTypes[visitorValue]; + var nodeProperty = node[visitorValue]; + // check if property or type is defined + if (propertyType == null || nodeProperty == null) { + continue; + } + if (propertyType.type === "loop") { + for (var j = 0; j < nodeProperty.length; j++) { + if (Array.isArray(propertyType.values)) { + for (var k = 0; k < propertyType.values.length; k++) { + var loopPropertyNode = nodeProperty[j][propertyType.values[k]]; + if (loopPropertyNode) { + checkIdentifierOrVisit.call(this, loopPropertyNode); + } + } + } else { + checkIdentifierOrVisit.call(this, nodeProperty[j]); + } + } + } else if (propertyType.type === "single") { + checkIdentifierOrVisit.call(this, nodeProperty); + } else if (propertyType.type === "typeAnnotation") { + visitTypeAnnotation.call(this, node.typeAnnotation); + } else if (propertyType.type === "typeParameters") { + for (var l = 0; l < node.typeParameters.params.length; l++) { + checkIdentifierOrVisit.call(this, node.typeParameters.params[l]); + } + } else if (propertyType.type === "id") { + if (node.id.type === "Identifier") { + checkIdentifierOrVisit.call(this, node.id); + } else { + visitTypeAnnotation.call(this, node.id); + } + } + } + } + + function checkIdentifierOrVisit(node) { + if (node.typeAnnotation) { + visitTypeAnnotation.call(this, node.typeAnnotation); + } else if (node.type === "Identifier") { + this.visit(node); + } else { + visitTypeAnnotation.call(this, node); + } + } + + function nestTypeParamScope(manager, node) { + var parentScope = manager.__currentScope; + var scope = new escope.Scope( + manager, + "type-parameters", + parentScope, + node, + false + ); + manager.__nestScope(scope); + for (var j = 0; j < node.typeParameters.params.length; j++) { + var name = node.typeParameters.params[j]; + scope.__define(name, new Definition("TypeParameter", name, name)); + if (name.typeAnnotation) { + checkIdentifierOrVisit.call(this, name); + } + } + scope.__define = function() { + return parentScope.__define.apply(parentScope, arguments); + }; + return scope; + } + + // visit decorators that are in: ClassDeclaration / ClassExpression + var visitClass = referencer.prototype.visitClass; + referencer.prototype.visitClass = function(node) { + visitDecorators.call(this, node); + var typeParamScope; + if (node.typeParameters) { + typeParamScope = nestTypeParamScope.call(this, this.scopeManager, node); + } + // visit flow type: ClassImplements + if (node.implements) { + for (var i = 0; i < node.implements.length; i++) { + checkIdentifierOrVisit.call(this, node.implements[i]); + } + } + if (node.superTypeParameters) { + for (var k = 0; k < node.superTypeParameters.params.length; k++) { + checkIdentifierOrVisit.call(this, node.superTypeParameters.params[k]); + } + } + visitClass.call(this, node); + if (typeParamScope) { + this.close(node); + } + }; + + // visit decorators that are in: Property / MethodDefinition + var visitProperty = referencer.prototype.visitProperty; + referencer.prototype.visitProperty = function(node) { + if (node.value && node.value.type === "TypeCastExpression") { + visitTypeAnnotation.call(this, node.value); + } + visitDecorators.call(this, node); + visitProperty.call(this, node); + }; + + function visitClassProperty(node) { + if (node.typeAnnotation) { + visitTypeAnnotation.call(this, node.typeAnnotation); + } + this.visitProperty(node); + } + + // visit ClassProperty as a Property. + referencer.prototype.ClassProperty = visitClassProperty; + + // visit ClassPrivateProperty as a Property. + referencer.prototype.ClassPrivateProperty = visitClassProperty; + + // visit flow type in FunctionDeclaration, FunctionExpression, ArrowFunctionExpression + var visitFunction = referencer.prototype.visitFunction; + referencer.prototype.visitFunction = function(node) { + var typeParamScope; + if (node.typeParameters) { + typeParamScope = nestTypeParamScope.call(this, this.scopeManager, node); + } + if (node.returnType) { + checkIdentifierOrVisit.call(this, node.returnType); + } + // only visit if function parameters have types + if (node.params) { + for (var i = 0; i < node.params.length; i++) { + var param = node.params[i]; + if (param.typeAnnotation) { + checkIdentifierOrVisit.call(this, param); + } else if (t.isAssignmentPattern(param)) { + if (param.left.typeAnnotation) { + checkIdentifierOrVisit.call(this, param.left); + } + } + } + } + // set ArrayPattern/ObjectPattern visitor keys back to their original. otherwise + // escope will traverse into them and include the identifiers within as declarations + estraverse.VisitorKeys.ObjectPattern = ["properties"]; + estraverse.VisitorKeys.ArrayPattern = ["elements"]; + visitFunction.call(this, node); + // set them back to normal... + estraverse.VisitorKeys.ObjectPattern = t.VISITOR_KEYS.ObjectPattern; + estraverse.VisitorKeys.ArrayPattern = t.VISITOR_KEYS.ArrayPattern; + if (typeParamScope) { + this.close(node); + } + }; + + // visit flow type in VariableDeclaration + var variableDeclaration = referencer.prototype.VariableDeclaration; + referencer.prototype.VariableDeclaration = function(node) { + if (node.declarations) { + for (var i = 0; i < node.declarations.length; i++) { + var id = node.declarations[i].id; + var typeAnnotation = id.typeAnnotation; + if (typeAnnotation) { + checkIdentifierOrVisit.call(this, typeAnnotation); + } + } + } + variableDeclaration.call(this, node); + }; + + function createScopeVariable(node, name) { + this.currentScope().variableScope.__define( + name, + new Definition("Variable", name, node, null, null, null) + ); + } + + referencer.prototype.InterfaceDeclaration = function(node) { + createScopeVariable.call(this, node, node.id); + var typeParamScope; + if (node.typeParameters) { + typeParamScope = nestTypeParamScope.call(this, this.scopeManager, node); + } + // TODO: Handle mixins + for (var i = 0; i < node.extends.length; i++) { + visitTypeAnnotation.call(this, node.extends[i]); + } + visitTypeAnnotation.call(this, node.body); + if (typeParamScope) { + this.close(node); + } + }; + + referencer.prototype.TypeAlias = function(node) { + createScopeVariable.call(this, node, node.id); + var typeParamScope; + if (node.typeParameters) { + typeParamScope = nestTypeParamScope.call(this, this.scopeManager, node); + } + if (node.right) { + visitTypeAnnotation.call(this, node.right); + } + if (typeParamScope) { + this.close(node); + } + }; + + referencer.prototype.DeclareModule = referencer.prototype.DeclareFunction = referencer.prototype.DeclareVariable = referencer.prototype.DeclareClass = function( + node + ) { + if (node.id) { + createScopeVariable.call(this, node, node.id); + } + + var typeParamScope; + if (node.typeParameters) { + typeParamScope = nestTypeParamScope.call(this, this.scopeManager, node); + } + if (typeParamScope) { + this.close(node); + } + }; + + referencer._babelEslintPatched = true; +} + +// To patch for each call. +var escope = null; +var escopeAnalyze = null; + +module.exports = function(parserOptions) { + // Patch `Referencer.prototype` once. + if (!escope) { + const modules = getModules(); + monkeypatch(modules); + + // Store to patch for each call. + escope = modules.escope; + escopeAnalyze = modules.escope.analyze; + } + + // Patch `escope.analyze` based on the current parserOptions. + escope.analyze = function(ast, opts) { + opts = opts || {}; + opts.ecmaVersion = parserOptions.ecmaVersion; + opts.sourceType = parserOptions.sourceType; + opts.nodejsScope = + ast.sourceType === "script" && + (parserOptions.ecmaFeatures && + parserOptions.ecmaFeatures.globalReturn) === true; + + return escopeAnalyze.call(this, ast, opts); + }; +}; diff --git a/tools/node_modules/babel-eslint/lib/visitor-keys.js b/tools/node_modules/babel-eslint/lib/visitor-keys.js new file mode 100644 index 00000000000000..921a0bb0165749 --- /dev/null +++ b/tools/node_modules/babel-eslint/lib/visitor-keys.js @@ -0,0 +1,15 @@ +"use strict"; + +const BABEL_VISITOR_KEYS = require("@babel/types").VISITOR_KEYS; +const ESLINT_VISITOR_KEYS = require("eslint-visitor-keys").KEYS; + +module.exports = Object.assign( + { + Literal: ESLINT_VISITOR_KEYS.Literal, + MethodDefinition: ["decorators"].concat( + ESLINT_VISITOR_KEYS.MethodDefinition + ), + Property: ["decorators"].concat(ESLINT_VISITOR_KEYS.Property), + }, + BABEL_VISITOR_KEYS +); diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/code-frame/README.md b/tools/node_modules/babel-eslint/node_modules/@babel/code-frame/README.md new file mode 100644 index 00000000000000..7ef4d3f9df7dff --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/code-frame/README.md @@ -0,0 +1,126 @@ +# @babel/code-frame + +> Generate errors that contain a code frame that point to source locations. + +## Install + +```sh +npm install --save-dev @babel/code-frame +``` + +## Usage + +```js +import { codeFrameColumns } from '@babel/code-frame'; + +const rawLines = `class Foo { + constructor() +}`; +const location = { start: { line: 2, column: 16 } }; + +const result = codeFrameColumns(rawLines, location, { /* options */ }); + +console.log(result); +``` + +``` + 1 | class Foo { +> 2 | constructor() + | ^ + 3 | } +``` + +If the column number is not known, you may omit it. + +You can also pass an `end` hash in `location`. + +```js +import { codeFrameColumns } from '@babel/code-frame'; + +const rawLines = `class Foo { + constructor() { + console.log("hello"); + } +}`; +const location = { start: { line: 2, column: 17 }, end: { line: 4, column: 3 } }; + +const result = codeFrameColumns(rawLines, location, { /* options */ }); + +console.log(result); +``` + +``` + 1 | class Foo { +> 2 | constructor() { + | ^ +> 3 | console.log("hello"); + | ^^^^^^^^^^^^^^^^^^^^^^^^^ +> 4 | } + | ^^^ + 5 | }; +``` + +## Options + +### `highlightCode` + +`boolean`, defaults to `false`. + +Toggles syntax highlighting the code as JavaScript for terminals. + +### `linesAbove` + +`number`, defaults to `2`. + +Adjust the number of lines to show above the error. + +### `linesBelow` + +`number`, defaults to `3`. + +Adjust the number of lines to show below the error. + +### `forceColor` + +`boolean`, defaults to `false`. + +Enable this to forcibly syntax highlight the code as JavaScript (for non-terminals); overrides `highlightCode`. + +## Upgrading from prior versions + +Prior to version 7, the only API exposed by this module was for a single line and optional column pointer. The old API will now log a deprecation warning. + +The new API takes a `location` object, similar to what is available in an AST. + +This is an example of the deprecated (but still available) API: + +```js +import codeFrame from '@babel/code-frame'; + +const rawLines = `class Foo { + constructor() +}`; +const lineNumber = 2; +const colNumber = 16; + +const result = codeFrame(rawLines, lineNumber, colNumber, { /* options */ }); + +console.log(result); +``` + +To get the same highlighting using the new API: + +```js +import { codeFrameColumns } from '@babel/code-frame'; + +const rawLines = `class Foo { + constructor() { + console.log("hello"); + } +}`; +const location = { start: { line: 2, column: 16 } }; + +const result = codeFrameColumns(rawLines, location, { /* options */ }); + +console.log(result); +``` diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/code-frame/lib/index.js b/tools/node_modules/babel-eslint/node_modules/@babel/code-frame/lib/index.js new file mode 100644 index 00000000000000..744f9595b34df7 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/code-frame/lib/index.js @@ -0,0 +1,232 @@ +"use strict"; + +exports.__esModule = true; +exports.codeFrameColumns = codeFrameColumns; +exports.default = _default; + +var _jsTokens = _interopRequireWildcard(require("js-tokens")); + +var _esutils = _interopRequireDefault(require("esutils")); + +var _chalk = _interopRequireDefault(require("chalk")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +var deprecationWarningShown = false; + +function getDefs(chalk) { + return { + keyword: chalk.cyan, + capitalized: chalk.yellow, + jsx_tag: chalk.yellow, + punctuator: chalk.yellow, + number: chalk.magenta, + string: chalk.green, + regex: chalk.magenta, + comment: chalk.grey, + invalid: chalk.white.bgRed.bold, + gutter: chalk.grey, + marker: chalk.red.bold + }; +} + +var NEWLINE = /\r\n|[\n\r\u2028\u2029]/; +var JSX_TAG = /^[a-z][\w-]*$/i; +var BRACKET = /^[()[\]{}]$/; + +function getTokenType(match) { + var _match$slice = match.slice(-2), + offset = _match$slice[0], + text = _match$slice[1]; + + var token = (0, _jsTokens.matchToToken)(match); + + if (token.type === "name") { + if (_esutils.default.keyword.isReservedWordES6(token.value)) { + return "keyword"; + } + + if (JSX_TAG.test(token.value) && (text[offset - 1] === "<" || text.substr(offset - 2, 2) == ""), maybeHighlight(defs.gutter, gutter), line, markerLine].join(""); + } else { + return " " + maybeHighlight(defs.gutter, gutter) + line; + } + }).join("\n"); + + if (highlighted) { + return chalk.reset(frame); + } else { + return frame; + } +} + +function _default(rawLines, lineNumber, colNumber, opts) { + if (opts === void 0) { + opts = {}; + } + + if (!deprecationWarningShown) { + deprecationWarningShown = true; + var deprecationError = new Error("Passing lineNumber and colNumber is deprecated to @babel/code-frame. Please use `codeFrameColumns`."); + deprecationError.name = "DeprecationWarning"; + + if (process.emitWarning) { + process.emitWarning(deprecationError); + } else { + console.warn(deprecationError); + } + } + + colNumber = Math.max(colNumber, 0); + var location = { + start: { + column: colNumber, + line: lineNumber + } + }; + return codeFrameColumns(rawLines, location, opts); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/code-frame/package.json b/tools/node_modules/babel-eslint/node_modules/@babel/code-frame/package.json new file mode 100644 index 00000000000000..ddf50f787c1126 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/code-frame/package.json @@ -0,0 +1,52 @@ +{ + "_from": "@babel/code-frame@7.0.0-beta.36", + "_id": "@babel/code-frame@7.0.0-beta.36", + "_inBundle": false, + "_integrity": "sha512-sW77BFwJ48YvQp3Gzz5xtAUiXuYOL2aMJKDwiaY3OcvdqBFurtYfOpSa4QrNyDxmOGRFSYzUpabU2m9QrlWE7w==", + "_location": "/babel-eslint/@babel/code-frame", + "_phantomChildren": {}, + "_requested": { + "type": "version", + "registry": true, + "raw": "@babel/code-frame@7.0.0-beta.36", + "name": "@babel/code-frame", + "escapedName": "@babel%2fcode-frame", + "scope": "@babel", + "rawSpec": "7.0.0-beta.36", + "saveSpec": null, + "fetchSpec": "7.0.0-beta.36" + }, + "_requiredBy": [ + "/babel-eslint", + "/babel-eslint/@babel/template", + "/babel-eslint/@babel/traverse" + ], + "_resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.0.0-beta.36.tgz", + "_shasum": "2349d7ec04b3a06945ae173280ef8579b63728e4", + "_spec": "@babel/code-frame@7.0.0-beta.36", + "_where": "/home/mzasso/git/nodejs/node/tools/babel-eslint-tmp/node_modules/babel-eslint", + "author": { + "name": "Sebastian McKenzie", + "email": "sebmck@gmail.com" + }, + "bundleDependencies": false, + "dependencies": { + "chalk": "^2.0.0", + "esutils": "^2.0.2", + "js-tokens": "^3.0.0" + }, + "deprecated": false, + "description": "Generate errors that contain a code frame that point to source locations.", + "devDependencies": { + "strip-ansi": "^4.0.0" + }, + "homepage": "https://babeljs.io/", + "license": "MIT", + "main": "lib/index.js", + "name": "@babel/code-frame", + "repository": { + "type": "git", + "url": "https://github.com/babel/babel/tree/master/packages/babel-code-frame" + }, + "version": "7.0.0-beta.36" +} diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/helper-function-name/README.md b/tools/node_modules/babel-eslint/node_modules/@babel/helper-function-name/README.md new file mode 100644 index 00000000000000..97b5b4ded9f727 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/helper-function-name/README.md @@ -0,0 +1,5 @@ +# @babel/helper-function-name + +## Usage + +TODO diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/helper-function-name/lib/index.js b/tools/node_modules/babel-eslint/node_modules/@babel/helper-function-name/lib/index.js new file mode 100644 index 00000000000000..ecf17ff49db079 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/helper-function-name/lib/index.js @@ -0,0 +1,129 @@ +"use strict"; + +exports.__esModule = true; +exports.default = _default; + +var _helperGetFunctionArity = _interopRequireDefault(require("@babel/helper-get-function-arity")); + +var _template2 = _interopRequireDefault(require("@babel/template")); + +var t = _interopRequireWildcard(require("@babel/types")); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +var buildPropertyMethodAssignmentWrapper = (0, _template2.default)("\n (function (FUNCTION_KEY) {\n function FUNCTION_ID() {\n return FUNCTION_KEY.apply(this, arguments);\n }\n\n FUNCTION_ID.toString = function () {\n return FUNCTION_KEY.toString();\n }\n\n return FUNCTION_ID;\n })(FUNCTION)\n"); +var buildGeneratorPropertyMethodAssignmentWrapper = (0, _template2.default)("\n (function (FUNCTION_KEY) {\n function* FUNCTION_ID() {\n return yield* FUNCTION_KEY.apply(this, arguments);\n }\n\n FUNCTION_ID.toString = function () {\n return FUNCTION_KEY.toString();\n };\n\n return FUNCTION_ID;\n })(FUNCTION)\n"); +var visitor = { + "ReferencedIdentifier|BindingIdentifier": function ReferencedIdentifierBindingIdentifier(path, state) { + if (path.node.name !== state.name) return; + var localDeclar = path.scope.getBindingIdentifier(state.name); + if (localDeclar !== state.outerDeclar) return; + state.selfReference = true; + path.stop(); + } +}; + +function wrap(state, method, id, scope) { + if (state.selfReference) { + if (scope.hasBinding(id.name) && !scope.hasGlobal(id.name)) { + scope.rename(id.name); + } else { + if (!t.isFunction(method)) return; + var build = buildPropertyMethodAssignmentWrapper; + + if (method.generator) { + build = buildGeneratorPropertyMethodAssignmentWrapper; + } + + var _template = build({ + FUNCTION: method, + FUNCTION_ID: id, + FUNCTION_KEY: scope.generateUidIdentifier(id.name) + }).expression; + var params = _template.callee.body.body[0].params; + + for (var i = 0, len = (0, _helperGetFunctionArity.default)(method); i < len; i++) { + params.push(scope.generateUidIdentifier("x")); + } + + return _template; + } + } + + method.id = id; + scope.getProgramParent().references[id.name] = true; +} + +function visit(node, name, scope) { + var state = { + selfAssignment: false, + selfReference: false, + outerDeclar: scope.getBindingIdentifier(name), + references: [], + name: name + }; + var binding = scope.getOwnBinding(name); + + if (binding) { + if (binding.kind === "param") { + state.selfReference = true; + } else {} + } else if (state.outerDeclar || scope.hasGlobal(name)) { + scope.traverse(node, visitor, state); + } + + return state; +} + +function _default(_ref, localBinding) { + var node = _ref.node, + parent = _ref.parent, + scope = _ref.scope, + id = _ref.id; + + if (localBinding === void 0) { + localBinding = false; + } + + if (node.id) return; + + if ((t.isObjectProperty(parent) || t.isObjectMethod(parent, { + kind: "method" + })) && (!parent.computed || t.isLiteral(parent.key))) { + id = parent.key; + } else if (t.isVariableDeclarator(parent)) { + id = parent.id; + + if (t.isIdentifier(id) && !localBinding) { + var binding = scope.parent.getBinding(id.name); + + if (binding && binding.constant && scope.getBinding(id.name) === binding) { + node.id = id; + node.id[t.NOT_LOCAL_BINDING] = true; + return; + } + } + } else if (t.isAssignmentExpression(parent)) { + id = parent.left; + } else if (!id) { + return; + } + + var name; + + if (id && t.isLiteral(id)) { + name = id.value; + } else if (id && t.isIdentifier(id)) { + name = id.name; + } else { + return; + } + + name = t.toBindingIdentifierName(name); + id = t.identifier(name); + id[t.NOT_LOCAL_BINDING] = true; + var state = visit(node, name, scope); + return wrap(state, node, id, scope) || node; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/helper-function-name/package.json b/tools/node_modules/babel-eslint/node_modules/@babel/helper-function-name/package.json new file mode 100644 index 00000000000000..1a940d0e5f9fa1 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/helper-function-name/package.json @@ -0,0 +1,42 @@ +{ + "_from": "@babel/helper-function-name@7.0.0-beta.36", + "_id": "@babel/helper-function-name@7.0.0-beta.36", + "_inBundle": false, + "_integrity": "sha512-/SGPOyifPf20iTrMN+WdlY2MbKa7/o4j7B/4IAsdOusASp2icT+Wcdjf4tjJHaXNX8Pe9bpgVxLNxhRvcf8E5w==", + "_location": "/babel-eslint/@babel/helper-function-name", + "_phantomChildren": {}, + "_requested": { + "type": "version", + "registry": true, + "raw": "@babel/helper-function-name@7.0.0-beta.36", + "name": "@babel/helper-function-name", + "escapedName": "@babel%2fhelper-function-name", + "scope": "@babel", + "rawSpec": "7.0.0-beta.36", + "saveSpec": null, + "fetchSpec": "7.0.0-beta.36" + }, + "_requiredBy": [ + "/babel-eslint/@babel/traverse" + ], + "_resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.0.0-beta.36.tgz", + "_shasum": "366e3bc35147721b69009f803907c4d53212e88d", + "_spec": "@babel/helper-function-name@7.0.0-beta.36", + "_where": "/home/mzasso/git/nodejs/node/tools/babel-eslint-tmp/node_modules/babel-eslint/node_modules/@babel/traverse", + "bundleDependencies": false, + "dependencies": { + "@babel/helper-get-function-arity": "7.0.0-beta.36", + "@babel/template": "7.0.0-beta.36", + "@babel/types": "7.0.0-beta.36" + }, + "deprecated": false, + "description": "Helper function to change the property 'name' of every function", + "license": "MIT", + "main": "lib/index.js", + "name": "@babel/helper-function-name", + "repository": { + "type": "git", + "url": "https://github.com/babel/babel/tree/master/packages/babel-helper-function-name" + }, + "version": "7.0.0-beta.36" +} diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/helper-get-function-arity/README.md b/tools/node_modules/babel-eslint/node_modules/@babel/helper-get-function-arity/README.md new file mode 100644 index 00000000000000..d341c9ce350093 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/helper-get-function-arity/README.md @@ -0,0 +1,21 @@ +# @babel/helper-get-function-arity + +Function that returns the number of arguments that a function takes. +* Examples of what is considered an argument can be found at [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function/length) + +## Usage + +```javascript +import getFunctionArity from "@babel/helper-get-function-arity"; + +function wrap(state, method, id, scope) { + // ... + if (!t.isFunction(method)) { + return false; + } + + const argumentsLength = getFunctionArity(method); + + // ... +} +``` diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/helper-get-function-arity/lib/index.js b/tools/node_modules/babel-eslint/node_modules/@babel/helper-get-function-arity/lib/index.js new file mode 100644 index 00000000000000..a04262cff435ad --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/helper-get-function-arity/lib/index.js @@ -0,0 +1,22 @@ +"use strict"; + +exports.__esModule = true; +exports.default = _default; + +var t = _interopRequireWildcard(require("@babel/types")); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +function _default(node) { + var params = node.params; + + for (var i = 0; i < params.length; i++) { + var param = params[i]; + + if (t.isAssignmentPattern(param) || t.isRestElement(param)) { + return i; + } + } + + return params.length; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/helper-get-function-arity/package.json b/tools/node_modules/babel-eslint/node_modules/@babel/helper-get-function-arity/package.json new file mode 100644 index 00000000000000..a9b83dbcb53520 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/helper-get-function-arity/package.json @@ -0,0 +1,40 @@ +{ + "_from": "@babel/helper-get-function-arity@7.0.0-beta.36", + "_id": "@babel/helper-get-function-arity@7.0.0-beta.36", + "_inBundle": false, + "_integrity": "sha512-vPPcx2vsSoDbcyWr9S3nd0FM3B4hEXnt0p1oKpwa08GwK0fSRxa98MyaRGf8suk8frdQlG1P3mDrz5p/Rr3pbA==", + "_location": "/babel-eslint/@babel/helper-get-function-arity", + "_phantomChildren": {}, + "_requested": { + "type": "version", + "registry": true, + "raw": "@babel/helper-get-function-arity@7.0.0-beta.36", + "name": "@babel/helper-get-function-arity", + "escapedName": "@babel%2fhelper-get-function-arity", + "scope": "@babel", + "rawSpec": "7.0.0-beta.36", + "saveSpec": null, + "fetchSpec": "7.0.0-beta.36" + }, + "_requiredBy": [ + "/babel-eslint/@babel/helper-function-name" + ], + "_resolved": "https://registry.npmjs.org/@babel/helper-get-function-arity/-/helper-get-function-arity-7.0.0-beta.36.tgz", + "_shasum": "f5383bac9a96b274828b10d98900e84ee43e32b8", + "_spec": "@babel/helper-get-function-arity@7.0.0-beta.36", + "_where": "/home/mzasso/git/nodejs/node/tools/babel-eslint-tmp/node_modules/babel-eslint/node_modules/@babel/helper-function-name", + "bundleDependencies": false, + "dependencies": { + "@babel/types": "7.0.0-beta.36" + }, + "deprecated": false, + "description": "Helper function to get function arity", + "license": "MIT", + "main": "lib/index.js", + "name": "@babel/helper-get-function-arity", + "repository": { + "type": "git", + "url": "https://github.com/babel/babel/tree/master/packages/babel-helper-get-function-arity" + }, + "version": "7.0.0-beta.36" +} diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/template/README.md b/tools/node_modules/babel-eslint/node_modules/@babel/template/README.md new file mode 100644 index 00000000000000..0219286c3f3cff --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/template/README.md @@ -0,0 +1,172 @@ +# @babel/template + +> Generate an AST from a string template or template literal. + +In computer science, this is known as an implementation of quasiquotes. + +## Install + +```sh +npm install --save-dev @babel/template +``` + +## String Usage + +```js +import template from "@babel/template"; +import generate from "@babel/generator"; +import * as t from "@babel/types"; + +const buildRequire = template(` + var IMPORT_NAME = require(SOURCE); +`); + +const ast = buildRequire({ + IMPORT_NAME: t.identifier("myModule"), + SOURCE: t.stringLiteral("my-module") +}); + +console.log(generate(ast).code); +``` + +```js +const myModule = require("my-module"); +``` + +### `.ast` + +If no placeholders are in use and you just want a simple way to parse a +string into an AST, you can use the `.ast` version of the template. + +```js +const ast = template.ast(` + var myModule = require("my-module"); +`); +``` +which will parse and return the AST directly. + + +## Template Literal Usage + +```js +import template from "@babel/template"; +import generate from "@babel/generator"; +import * as t from "@babel/types"; + +const fn = template` + var IMPORT_NAME = require('${"my-module"}'); +`); + +const ast = fn({ + IMPORT_NAME: t.identifier("myModule"); +}); + +console.log(generate(ast).code); +``` + +Note that placeholders can be passed directly as part of the template literal +in order to make things as readable as possible, or they can be passed into +the template function. + +### `.ast` + +If no placeholders are in use and you just want a simple way to parse a +string into an AST, you can use the `.ast` version of the template. + +```js +const name = "my-module"; +const mod = "myModule"; + +const ast = template.ast` + var ${mod} = require("${name}"); +`; +``` +which will parse and return the AST directly. Note that unlike the string-based +version mentioned earlier, since this is a template literal, it is still +valid to perform replacements using template literal replacements. + + +## AST results + +The `@babel/template` API exposes a few flexible APIs to make it as easy as +possible to create ASTs with an expected structure. Each of these also has +the `.ast` property mentioned above. + +### `template` + +`template` returns either a single statement, or an array of +statements, depending on the parsed result. + +### `template.smart` + +This is the same as the default `template` API, returning either a single +node, or an array of nodes, depending on the parsed result. + +### `template.statement` + +`template.statement("foo;")()` returns a single statement node, and throw +an exception if the result is anything but a single statement. + +### `template.statements` + +`template.statements("foo;foo;")()` returns an array of statement nodes. + +### `template.expression` + +`template.expression("foo")()` returns the expression node. + +### `template.program` + +`template.program("foo;")()` returns the `Program` node for the template. + + +## API + +### `template(code, [opts])` + +#### code + +Type: `string` + +#### options + +`@babel/template` accepts all of the options from [babylon](https://github.com/babel/babel/tree/master/packages/babylon), and specifies +some defaults of its own: + +* `allowReturnOutsideFunction` is set to `true` by default. +* `allowSuperOutsideMethod` is set to `true` by default. +* `sourceType` is set to `module` by default. + +##### placeholderWhitelist + +Type: `Set` +Default: `undefined` + +A set of placeholder names to automatically accept. Items in this list do +not need to match the given placeholder pattern. + +##### placeholderPattern + +Type: `RegExp | false` +Default: `/^[_$A-Z0-9]+$/` + +A pattern to search for when looking for Identifier and StringLiteral +nodes that should be considered placeholders. +'false' will disable placeholder searching entirely, leaving only the +'placeholderWhitelist' value to find placeholders. + +##### preserveComments + +Type: `boolean` +Default: `false` + +Set this to `true` to preserve any comments from the `code` parameter. + +#### Return value + +By default `@babel/template` returns a `function` which is invoked with an +optional object of replacements. See the usage section for an example. + +When using `.ast`, the AST will be returned directly. + +[babylon]: https://github.com/babel/babylon#options diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/builder.js b/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/builder.js new file mode 100644 index 00000000000000..a5d2951d9bc698 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/builder.js @@ -0,0 +1,89 @@ +"use strict"; + +exports.__esModule = true; +exports.default = createTemplateBuilder; + +var _options = require("./options"); + +var _string = _interopRequireDefault(require("./string")); + +var _literal = _interopRequireDefault(require("./literal")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +var NO_PLACEHOLDER = (0, _options.validate)({ + placeholderPattern: false +}); + +function createTemplateBuilder(formatter, defaultOpts) { + var templateFnCache = new WeakMap(); + var templateAstCache = new WeakMap(); + var cachedOpts = defaultOpts || (0, _options.validate)(null); + return Object.assign(function (tpl) { + for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { + args[_key - 1] = arguments[_key]; + } + + if (typeof tpl === "string") { + if (args.length > 1) throw new Error("Unexpected extra params."); + return extendedTrace((0, _string.default)(formatter, tpl, (0, _options.merge)(cachedOpts, (0, _options.validate)(args[0])))); + } else if (Array.isArray(tpl)) { + var builder = templateFnCache.get(tpl); + + if (!builder) { + builder = (0, _literal.default)(formatter, tpl, cachedOpts); + templateFnCache.set(tpl, builder); + } + + return extendedTrace(builder(args)); + } else if (typeof tpl === "object" && tpl) { + if (args.length > 0) throw new Error("Unexpected extra params."); + return createTemplateBuilder(formatter, (0, _options.merge)(cachedOpts, (0, _options.validate)(tpl))); + } + + throw new Error("Unexpected template param " + typeof tpl); + }, { + ast: function ast(tpl) { + for (var _len2 = arguments.length, args = new Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) { + args[_key2 - 1] = arguments[_key2]; + } + + if (typeof tpl === "string") { + if (args.length > 1) throw new Error("Unexpected extra params."); + return (0, _string.default)(formatter, tpl, (0, _options.merge)((0, _options.merge)(cachedOpts, (0, _options.validate)(args[0])), NO_PLACEHOLDER))(); + } else if (Array.isArray(tpl)) { + var builder = templateAstCache.get(tpl); + + if (!builder) { + builder = (0, _literal.default)(formatter, tpl, (0, _options.merge)(cachedOpts, NO_PLACEHOLDER)); + templateAstCache.set(tpl, builder); + } + + return builder(args)(); + } + + throw new Error("Unexpected template param " + typeof tpl); + } + }); +} + +function extendedTrace(fn) { + var rootStack = ""; + + try { + throw new Error(); + } catch (error) { + if (error.stack) { + rootStack = error.stack.split("\n").slice(3).join("\n"); + } + } + + return function (arg) { + try { + return fn(arg); + } catch (err) { + err.stack += "\n =============\n" + rootStack; + throw err; + } + }; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/formatters.js b/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/formatters.js new file mode 100644 index 00000000000000..cd61283be57844 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/formatters.js @@ -0,0 +1,73 @@ +"use strict"; + +exports.__esModule = true; +exports.program = exports.expression = exports.statement = exports.statements = exports.smart = void 0; + +function makeStatementFormatter(fn) { + return { + code: function code(str) { + return "/* @babel/template */;\n" + str; + }, + validate: function validate() {}, + unwrap: function unwrap(ast) { + return fn(ast.program.body.slice(1)); + } + }; +} + +var smart = makeStatementFormatter(function (body) { + if (body.length > 1) { + return body; + } else { + return body[0]; + } +}); +exports.smart = smart; +var statements = makeStatementFormatter(function (body) { + return body; +}); +exports.statements = statements; +var statement = makeStatementFormatter(function (body) { + if (body.length === 0) { + throw new Error("Found nothing to return."); + } + + if (body.length > 1) { + throw new Error("Found multiple statements but wanted one"); + } + + return body[0]; +}); +exports.statement = statement; +var expression = { + code: function code(str) { + return "(\n" + str + "\n)"; + }, + validate: function validate(ast) { + var program = ast.program; + + if (program.body.length > 1) { + throw new Error("Found multiple statements but wanted one"); + } + + var expression = program.body[0].expression; + + if (expression.start === 0) { + throw new Error("Parse result included parens."); + } + }, + unwrap: function unwrap(ast) { + return ast.program.body[0].expression; + } +}; +exports.expression = expression; +var program = { + code: function code(str) { + return str; + }, + validate: function validate() {}, + unwrap: function unwrap(ast) { + return ast.program; + } +}; +exports.program = program; \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/index.js b/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/index.js new file mode 100644 index 00000000000000..30ec5c1eeb0213 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/index.js @@ -0,0 +1,34 @@ +"use strict"; + +exports.__esModule = true; +exports.default = exports.program = exports.expression = exports.statements = exports.statement = exports.smart = void 0; + +var formatters = _interopRequireWildcard(require("./formatters")); + +var _builder = _interopRequireDefault(require("./builder")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +var smart = (0, _builder.default)(formatters.smart); +exports.smart = smart; +var statement = (0, _builder.default)(formatters.statement); +exports.statement = statement; +var statements = (0, _builder.default)(formatters.statements); +exports.statements = statements; +var expression = (0, _builder.default)(formatters.expression); +exports.expression = expression; +var program = (0, _builder.default)(formatters.program); +exports.program = program; + +var _default = Object.assign(smart.bind(undefined), { + smart: smart, + statement: statement, + statements: statements, + expression: expression, + program: program, + ast: smart.ast +}); + +exports.default = _default; \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/literal.js b/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/literal.js new file mode 100644 index 00000000000000..4a31fc24804c67 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/literal.js @@ -0,0 +1,81 @@ +"use strict"; + +exports.__esModule = true; +exports.default = literalTemplate; + +var _options = require("./options"); + +var _parse = _interopRequireDefault(require("./parse")); + +var _populate = _interopRequireDefault(require("./populate")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function literalTemplate(formatter, tpl, opts) { + var _buildLiteralData = buildLiteralData(formatter, tpl, opts), + metadata = _buildLiteralData.metadata, + names = _buildLiteralData.names; + + return function (arg) { + var defaultReplacements = arg.reduce(function (acc, replacement, i) { + acc[names[i]] = replacement; + return acc; + }, {}); + return function (arg) { + var replacements = (0, _options.normalizeReplacements)(arg); + + if (replacements) { + Object.keys(replacements).forEach(function (key) { + if (Object.prototype.hasOwnProperty.call(defaultReplacements, key)) { + throw new Error("Unexpected replacement overlap."); + } + }); + } + + return formatter.unwrap((0, _populate.default)(metadata, replacements ? Object.assign(replacements, defaultReplacements) : defaultReplacements)); + }; + }; +} + +function buildLiteralData(formatter, tpl, opts) { + var names; + var nameSet; + var metadata; + var prefix = ""; + + do { + prefix += "$"; + var result = buildTemplateCode(tpl, prefix); + names = result.names; + nameSet = new Set(names); + metadata = (0, _parse.default)(formatter, formatter.code(result.code), { + parser: opts.parser, + placeholderWhitelist: new Set(result.names.concat(opts.placeholderWhitelist ? Array.from(opts.placeholderWhitelist) : [])), + placeholderPattern: opts.placeholderPattern, + preserveComments: opts.preserveComments + }); + } while (metadata.placeholders.some(function (placeholder) { + return placeholder.isDuplicate && nameSet.has(placeholder.name); + })); + + return { + metadata: metadata, + names: names + }; +} + +function buildTemplateCode(tpl, prefix) { + var names = []; + var code = tpl[0]; + + for (var i = 1; i < tpl.length; i++) { + var value = "" + prefix + (i - 1); + names.push(value); + code += value + tpl[i]; + } + + return { + names: names, + code: code + }; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/options.js b/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/options.js new file mode 100644 index 00000000000000..01522f28fc45ee --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/options.js @@ -0,0 +1,67 @@ +"use strict"; + +exports.__esModule = true; +exports.merge = merge; +exports.validate = validate; +exports.normalizeReplacements = normalizeReplacements; + +function _objectWithoutProperties(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]; } if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; } + +function merge(a, b) { + var _b$placeholderWhiteli = b.placeholderWhitelist, + placeholderWhitelist = _b$placeholderWhiteli === void 0 ? a.placeholderWhitelist : _b$placeholderWhiteli, + _b$placeholderPattern = b.placeholderPattern, + placeholderPattern = _b$placeholderPattern === void 0 ? a.placeholderPattern : _b$placeholderPattern, + _b$preserveComments = b.preserveComments, + preserveComments = _b$preserveComments === void 0 ? a.preserveComments : _b$preserveComments; + return { + parser: Object.assign({}, a.parser, b.parser), + placeholderWhitelist: placeholderWhitelist, + placeholderPattern: placeholderPattern, + preserveComments: preserveComments + }; +} + +function validate(opts) { + if (opts != null && typeof opts !== "object") { + throw new Error("Unknown template options."); + } + + var _ref = opts || {}, + placeholderWhitelist = _ref.placeholderWhitelist, + placeholderPattern = _ref.placeholderPattern, + preserveComments = _ref.preserveComments, + parser = _objectWithoutProperties(_ref, ["placeholderWhitelist", "placeholderPattern", "preserveComments"]); + + if (placeholderWhitelist != null && !(placeholderWhitelist instanceof Set)) { + throw new Error("'.placeholderWhitelist' must be a Set, null, or undefined"); + } + + if (placeholderPattern != null && !(placeholderPattern instanceof RegExp) && placeholderPattern !== false) { + throw new Error("'.placeholderPattern' must be a RegExp, false, null, or undefined"); + } + + if (preserveComments != null && typeof preserveComments !== "boolean") { + throw new Error("'.preserveComments' must be a boolean, null, or undefined"); + } + + return { + parser: parser, + placeholderWhitelist: placeholderWhitelist || undefined, + placeholderPattern: placeholderPattern == null ? undefined : placeholderPattern, + preserveComments: preserveComments == null ? false : preserveComments + }; +} + +function normalizeReplacements(replacements) { + if (Array.isArray(replacements)) { + return replacements.reduce(function (acc, replacement, i) { + acc["$" + i] = replacement; + return acc; + }, {}); + } else if (typeof replacements === "object" || replacements == null) { + return replacements || undefined; + } + + throw new Error("Template replacements must be an array, object, null, or undefined"); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/parse.js b/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/parse.js new file mode 100644 index 00000000000000..70f31e7322ff38 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/parse.js @@ -0,0 +1,130 @@ +"use strict"; + +exports.__esModule = true; +exports.default = parseAndBuildMetadata; + +var t = _interopRequireWildcard(require("@babel/types")); + +var _babylon = require("babylon"); + +var _codeFrame = require("@babel/code-frame"); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +var PATTERN = /^[_$A-Z0-9]+$/; + +function parseAndBuildMetadata(formatter, code, opts) { + var ast = parseWithCodeFrame(code, opts.parser); + var placeholderWhitelist = opts.placeholderWhitelist, + _opts$placeholderPatt = opts.placeholderPattern, + placeholderPattern = _opts$placeholderPatt === void 0 ? PATTERN : _opts$placeholderPatt, + preserveComments = opts.preserveComments; + t.removePropertiesDeep(ast, { + preserveComments: preserveComments + }); + formatter.validate(ast); + var placeholders = []; + var placeholderNames = new Set(); + t.traverse(ast, placeholderVisitorHandler, { + placeholders: placeholders, + placeholderNames: placeholderNames, + placeholderWhitelist: placeholderWhitelist, + placeholderPattern: placeholderPattern + }); + return { + ast: ast, + placeholders: placeholders, + placeholderNames: placeholderNames + }; +} + +function placeholderVisitorHandler(node, ancestors, state) { + var name; + + if (t.isIdentifier(node)) { + name = node.name; + } else if (t.isStringLiteral(node)) { + name = node.value; + } else { + return; + } + + if ((!state.placeholderPattern || !state.placeholderPattern.test(name)) && (!state.placeholderWhitelist || !state.placeholderWhitelist.has(name))) { + return; + } + + ancestors = ancestors.slice(); + var _ancestors = ancestors[ancestors.length - 1], + parent = _ancestors.node, + key = _ancestors.key; + var type; + + if (t.isStringLiteral(node)) { + type = "string"; + } else if (t.isNewExpression(parent) && key === "arguments" || t.isCallExpression(parent) && key === "arguments" || t.isFunction(parent) && key === "params") { + type = "param"; + } else if (t.isExpressionStatement(parent)) { + type = "statement"; + ancestors = ancestors.slice(0, -1); + } else { + type = "other"; + } + + state.placeholders.push({ + name: name, + type: type, + resolve: function resolve(ast) { + return resolveAncestors(ast, ancestors); + }, + isDuplicate: state.placeholderNames.has(name) + }); + state.placeholderNames.add(name); +} + +function resolveAncestors(ast, ancestors) { + var parent = ast; + + for (var i = 0; i < ancestors.length - 1; i++) { + var _ancestors$i = ancestors[i], + _key = _ancestors$i.key, + _index = _ancestors$i.index; + + if (_index === undefined) { + parent = parent[_key]; + } else { + parent = parent[_key][_index]; + } + } + + var _ancestors2 = ancestors[ancestors.length - 1], + key = _ancestors2.key, + index = _ancestors2.index; + return { + parent: parent, + key: key, + index: index + }; +} + +function parseWithCodeFrame(code, parserOpts) { + parserOpts = Object.assign({ + allowReturnOutsideFunction: true, + allowSuperOutsideMethod: true, + sourceType: "module" + }, parserOpts); + + try { + return (0, _babylon.parse)(code, parserOpts); + } catch (err) { + var loc = err.loc; + + if (loc) { + err.loc = null; + err.message += "\n" + (0, _codeFrame.codeFrameColumns)(code, { + start: loc + }); + } + + throw err; + } +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/populate.js b/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/populate.js new file mode 100644 index 00000000000000..1a358f7ba03cce --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/populate.js @@ -0,0 +1,120 @@ +"use strict"; + +exports.__esModule = true; +exports.default = populatePlaceholders; + +var t = _interopRequireWildcard(require("@babel/types")); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +function populatePlaceholders(metadata, replacements) { + var ast = t.cloneDeep(metadata.ast); + + if (replacements) { + metadata.placeholders.forEach(function (placeholder) { + if (!Object.prototype.hasOwnProperty.call(replacements, placeholder.name)) { + throw new Error("No substitution given for \"" + placeholder.name + "\""); + } + }); + Object.keys(replacements).forEach(function (key) { + if (!metadata.placeholderNames.has(key)) { + throw new Error("Unknown substitution \"" + key + "\" given"); + } + }); + } + + metadata.placeholders.slice().reverse().forEach(function (placeholder) { + try { + applyReplacement(placeholder, ast, replacements && replacements[placeholder.name] || null); + } catch (e) { + e.message = "babel-template placeholder \"" + placeholder.name + "\": " + e.message; + throw e; + } + }); + return ast; +} + +function applyReplacement(placeholder, ast, replacement) { + if (placeholder.isDuplicate) { + if (Array.isArray(replacement)) { + replacement = replacement.map(function (node) { + return t.cloneDeep(node); + }); + } else if (typeof replacement === "object") { + replacement = t.cloneDeep(replacement); + } + } + + var _placeholder$resolve = placeholder.resolve(ast), + parent = _placeholder$resolve.parent, + key = _placeholder$resolve.key, + index = _placeholder$resolve.index; + + if (placeholder.type === "string") { + if (typeof replacement === "string") { + replacement = t.stringLiteral(replacement); + } + + if (!replacement || !t.isStringLiteral(replacement)) { + throw new Error("Expected string substitution"); + } + } else if (placeholder.type === "statement") { + if (index === undefined) { + if (!replacement) { + replacement = t.emptyStatement(); + } else if (Array.isArray(replacement)) { + replacement = t.blockStatement(replacement); + } else if (typeof replacement === "string") { + replacement = t.expressionStatement(t.identifier(replacement)); + } else if (!t.isStatement(replacement)) { + replacement = t.expressionStatement(replacement); + } + } else { + if (replacement && !Array.isArray(replacement)) { + if (typeof replacement === "string") { + replacement = t.identifier(replacement); + } + + if (!t.isStatement(replacement)) { + replacement = t.expressionStatement(replacement); + } + } + } + } else if (placeholder.type === "param") { + if (typeof replacement === "string") { + replacement = t.identifier(replacement); + } + + if (index === undefined) throw new Error("Assertion failure."); + } else { + if (typeof replacement === "string") { + replacement = t.identifier(replacement); + } + + if (Array.isArray(replacement)) { + throw new Error("Cannot replace single expression with an array."); + } + } + + if (index === undefined) { + t.validate(parent, key, replacement); + parent[key] = replacement; + } else { + var items = parent[key].slice(); + + if (placeholder.type === "statement" || placeholder.type === "param") { + if (replacement == null) { + items.splice(index, 1); + } else if (Array.isArray(replacement)) { + items.splice.apply(items, [index, 1].concat(replacement)); + } else { + items[index] = replacement; + } + } else { + items[index] = replacement; + } + + t.validate(parent, key, items); + parent[key] = items; + } +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/string.js b/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/string.js new file mode 100644 index 00000000000000..3e8f198d8dbe23 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/template/lib/string.js @@ -0,0 +1,22 @@ +"use strict"; + +exports.__esModule = true; +exports.default = stringTemplate; + +var _options = require("./options"); + +var _parse = _interopRequireDefault(require("./parse")); + +var _populate = _interopRequireDefault(require("./populate")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function stringTemplate(formatter, code, opts) { + code = formatter.code(code); + var metadata; + return function (arg) { + var replacements = (0, _options.normalizeReplacements)(arg); + if (!metadata) metadata = (0, _parse.default)(formatter, code, opts); + return formatter.unwrap((0, _populate.default)(metadata, replacements)); + }; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/template/package.json b/tools/node_modules/babel-eslint/node_modules/@babel/template/package.json new file mode 100644 index 00000000000000..e0f4a71a6243aa --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/template/package.json @@ -0,0 +1,48 @@ +{ + "_from": "@babel/template@7.0.0-beta.36", + "_id": "@babel/template@7.0.0-beta.36", + "_inBundle": false, + "_integrity": "sha512-mUBi90WRyZ9iVvlWLEdeo8gn/tROyJdjKNC4W5xJTSZL+9MS89rTJSqiaJKXIkxk/YRDL/g/8snrG/O0xl33uA==", + "_location": "/babel-eslint/@babel/template", + "_phantomChildren": {}, + "_requested": { + "type": "version", + "registry": true, + "raw": "@babel/template@7.0.0-beta.36", + "name": "@babel/template", + "escapedName": "@babel%2ftemplate", + "scope": "@babel", + "rawSpec": "7.0.0-beta.36", + "saveSpec": null, + "fetchSpec": "7.0.0-beta.36" + }, + "_requiredBy": [ + "/babel-eslint/@babel/helper-function-name" + ], + "_resolved": "https://registry.npmjs.org/@babel/template/-/template-7.0.0-beta.36.tgz", + "_shasum": "02e903de5d68bd7899bce3c5b5447e59529abb00", + "_spec": "@babel/template@7.0.0-beta.36", + "_where": "/home/mzasso/git/nodejs/node/tools/babel-eslint-tmp/node_modules/babel-eslint/node_modules/@babel/helper-function-name", + "author": { + "name": "Sebastian McKenzie", + "email": "sebmck@gmail.com" + }, + "bundleDependencies": false, + "dependencies": { + "@babel/code-frame": "7.0.0-beta.36", + "@babel/types": "7.0.0-beta.36", + "babylon": "7.0.0-beta.36", + "lodash": "^4.2.0" + }, + "deprecated": false, + "description": "Generate an AST from a string template.", + "homepage": "https://babeljs.io/", + "license": "MIT", + "main": "lib/index.js", + "name": "@babel/template", + "repository": { + "type": "git", + "url": "https://github.com/babel/babel/tree/master/packages/babel-template" + }, + "version": "7.0.0-beta.36" +} diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/README.md b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/README.md new file mode 100644 index 00000000000000..a25ffe70a59b05 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/README.md @@ -0,0 +1,33 @@ +# @babel/traverse + +> @babel/traverse maintains the overall tree state, and is responsible for replacing, removing, and adding nodes. + +## Install + +```sh +$ npm install --save @babel/traverse +``` + +## Usage + +We can use it alongside Babylon to traverse and update nodes: + +```js +import * as babylon from "babylon"; +import traverse from "@babel/traverse"; + +const code = `function square(n) { + return n * n; +}`; + +const ast = babylon.parse(code); + +traverse(ast, { + enter(path) { + if (path.isIdentifier({ name: "n" })) { + path.node.name = "x"; + } + } +}); +``` +[:book: **Read the full docs here**](https://github.com/thejameskyle/babel-handbook/blob/master/translations/en/plugin-handbook.md#babel-traverse) diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/cache.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/cache.js new file mode 100644 index 00000000000000..f274059252720e --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/cache.js @@ -0,0 +1,24 @@ +"use strict"; + +exports.__esModule = true; +exports.clear = clear; +exports.clearPath = clearPath; +exports.clearScope = clearScope; +exports.scope = exports.path = void 0; +var path = new WeakMap(); +exports.path = path; +var scope = new WeakMap(); +exports.scope = scope; + +function clear() { + clearPath(); + clearScope(); +} + +function clearPath() { + exports.path = path = new WeakMap(); +} + +function clearScope() { + exports.scope = scope = new WeakMap(); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/context.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/context.js new file mode 100644 index 00000000000000..28e3d17a67c3e6 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/context.js @@ -0,0 +1,187 @@ +"use strict"; + +exports.__esModule = true; +exports.default = void 0; + +var _path4 = _interopRequireDefault(require("./path")); + +var t = _interopRequireWildcard(require("@babel/types")); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +var testing = process.env.NODE_ENV === "test"; + +var TraversalContext = function () { + function TraversalContext(scope, opts, state, parentPath) { + this.parentPath = void 0; + this.scope = void 0; + this.state = void 0; + this.opts = void 0; + this.queue = null; + this.parentPath = parentPath; + this.scope = scope; + this.state = state; + this.opts = opts; + } + + var _proto = TraversalContext.prototype; + + _proto.shouldVisit = function shouldVisit(node) { + var opts = this.opts; + if (opts.enter || opts.exit) return true; + if (opts[node.type]) return true; + var keys = t.VISITOR_KEYS[node.type]; + if (!keys || !keys.length) return false; + + 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; + if (node[_key]) return true; + } + + return false; + }; + + _proto.create = function create(node, obj, key, listKey) { + return _path4.default.get({ + parentPath: this.parentPath, + parent: node, + container: obj, + key: key, + listKey: listKey + }); + }; + + _proto.maybeQueue = function maybeQueue(path, notPriority) { + if (this.trap) { + throw new Error("Infinite cycle detected"); + } + + if (this.queue) { + if (notPriority) { + this.queue.push(path); + } else { + this.priorityQueue.push(path); + } + } + }; + + _proto.visitMultiple = function visitMultiple(container, parent, listKey) { + if (container.length === 0) return false; + var queue = []; + + for (var key = 0; key < container.length; key++) { + var node = container[key]; + + if (node && this.shouldVisit(node)) { + queue.push(this.create(parent, container, key, listKey)); + } + } + + return this.visitQueue(queue); + }; + + _proto.visitSingle = function visitSingle(node, key) { + if (this.shouldVisit(node[key])) { + return this.visitQueue([this.create(node, node, key)]); + } else { + return false; + } + }; + + _proto.visitQueue = function visitQueue(queue) { + this.queue = queue; + this.priorityQueue = []; + var visited = []; + var stop = false; + + for (var _iterator2 = queue, _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 _path2 = _ref2; + + _path2.resync(); + + if (_path2.contexts.length === 0 || _path2.contexts[_path2.contexts.length - 1] !== this) { + _path2.pushContext(this); + } + + if (_path2.key === null) continue; + + if (testing && queue.length >= 10000) { + this.trap = true; + } + + if (visited.indexOf(_path2.node) >= 0) continue; + visited.push(_path2.node); + + if (_path2.visit()) { + stop = true; + break; + } + + if (this.priorityQueue.length) { + stop = this.visitQueue(this.priorityQueue); + this.priorityQueue = []; + this.queue = queue; + if (stop) break; + } + } + + for (var _iterator3 = queue, _isArray3 = Array.isArray(_iterator3), _i3 = 0, _iterator3 = _isArray3 ? _iterator3 : _iterator3[Symbol.iterator]();;) { + var _ref3; + + if (_isArray3) { + if (_i3 >= _iterator3.length) break; + _ref3 = _iterator3[_i3++]; + } else { + _i3 = _iterator3.next(); + if (_i3.done) break; + _ref3 = _i3.value; + } + + var _path3 = _ref3; + + _path3.popContext(); + } + + this.queue = null; + return stop; + }; + + _proto.visit = function visit(node, key) { + var nodes = node[key]; + if (!nodes) return false; + + if (Array.isArray(nodes)) { + return this.visitMultiple(nodes, node, key); + } else { + return this.visitSingle(node, key); + } + }; + + return TraversalContext; +}(); + +exports.default = TraversalContext; \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/hub.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/hub.js new file mode 100644 index 00000000000000..d10c2aa86c51ad --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/hub.js @@ -0,0 +1,10 @@ +"use strict"; + +exports.__esModule = true; +exports.default = void 0; + +var Hub = function Hub(file) { + this.file = file; +}; + +exports.default = Hub; \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/index.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/index.js new file mode 100644 index 00000000000000..5e95ffe5a1337e --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/index.js @@ -0,0 +1,112 @@ +"use strict"; + +exports.__esModule = true; +exports.default = traverse; +exports.visitors = exports.Hub = exports.Scope = exports.NodePath = void 0; + +var _context = _interopRequireDefault(require("./context")); + +var visitors = _interopRequireWildcard(require("./visitors")); + +exports.visitors = visitors; + +var _includes = _interopRequireDefault(require("lodash/includes")); + +var t = _interopRequireWildcard(require("@babel/types")); + +var cache = _interopRequireWildcard(require("./cache")); + +var _path = _interopRequireDefault(require("./path")); + +exports.NodePath = _path.default; + +var _scope = _interopRequireDefault(require("./scope")); + +exports.Scope = _scope.default; + +var _hub = _interopRequireDefault(require("./hub")); + +exports.Hub = _hub.default; + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function traverse(parent, opts, scope, state, parentPath) { + if (!parent) return; + if (!opts) opts = {}; + + if (!opts.noScope && !scope) { + if (parent.type !== "Program" && parent.type !== "File") { + throw new Error("You must pass a scope and parentPath unless traversing a Program/File. " + ("Instead of that you tried to traverse a " + parent.type + " node without ") + "passing scope and parentPath."); + } + } + + visitors.explode(opts); + traverse.node(parent, opts, scope, state, parentPath); +} + +traverse.visitors = visitors; +traverse.verify = visitors.verify; +traverse.explode = visitors.explode; + +traverse.cheap = function (node, enter) { + return t.traverseFast(node, enter); +}; + +traverse.node = function (node, opts, scope, state, parentPath, skipKeys) { + var keys = t.VISITOR_KEYS[node.type]; + if (!keys) return; + var context = new _context.default(scope, opts, state, parentPath); + + 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; + if (skipKeys && skipKeys[_key]) continue; + if (context.visit(node, _key)) return; + } +}; + +traverse.clearNode = function (node, opts) { + t.removeProperties(node, opts); + cache.path.delete(node); +}; + +traverse.removeProperties = function (tree, opts) { + t.traverseFast(tree, traverse.clearNode, opts); + return tree; +}; + +function hasBlacklistedType(path, state) { + if (path.node.type === state.type) { + state.has = true; + path.stop(); + } +} + +traverse.hasType = function (tree, type, blacklistTypes) { + if ((0, _includes.default)(blacklistTypes, tree.type)) return false; + if (tree.type === type) return true; + var state = { + has: false, + type: type + }; + traverse(tree, { + noScope: true, + blacklist: blacklistTypes, + enter: hasBlacklistedType + }, null, state); + return state.has; +}; + +traverse.cache = cache; \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/ancestry.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/ancestry.js new file mode 100644 index 00000000000000..489628f7791050 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/ancestry.js @@ -0,0 +1,192 @@ +"use strict"; + +exports.__esModule = true; +exports.findParent = findParent; +exports.find = find; +exports.getFunctionParent = getFunctionParent; +exports.getStatementParent = getStatementParent; +exports.getEarliestCommonAncestorFrom = getEarliestCommonAncestorFrom; +exports.getDeepestCommonAncestorFrom = getDeepestCommonAncestorFrom; +exports.getAncestry = getAncestry; +exports.isAncestor = isAncestor; +exports.isDescendant = isDescendant; +exports.inType = inType; + +var t = _interopRequireWildcard(require("@babel/types")); + +var _index = _interopRequireDefault(require("./index")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +function findParent(callback) { + var path = this; + + while (path = path.parentPath) { + if (callback(path)) return path; + } + + return null; +} + +function find(callback) { + var path = this; + + do { + if (callback(path)) return path; + } while (path = path.parentPath); + + return null; +} + +function getFunctionParent() { + return this.findParent(function (p) { + return p.isFunction(); + }); +} + +function getStatementParent() { + var path = this; + + do { + if (!path.parentPath || Array.isArray(path.container) && path.isStatement()) { + break; + } else { + path = path.parentPath; + } + } while (path); + + if (path && (path.isProgram() || path.isFile())) { + throw new Error("File/Program node, we can't possibly find a statement parent to this"); + } + + return path; +} + +function getEarliestCommonAncestorFrom(paths) { + return this.getDeepestCommonAncestorFrom(paths, function (deepest, i, ancestries) { + var earliest; + var keys = t.VISITOR_KEYS[deepest.type]; + var _arr = ancestries; + + for (var _i = 0; _i < _arr.length; _i++) { + var ancestry = _arr[_i]; + var path = ancestry[i + 1]; + + if (!earliest) { + earliest = path; + continue; + } + + if (path.listKey && earliest.listKey === path.listKey) { + if (path.key < earliest.key) { + earliest = path; + continue; + } + } + + var earliestKeyIndex = keys.indexOf(earliest.parentKey); + var currentKeyIndex = keys.indexOf(path.parentKey); + + if (earliestKeyIndex > currentKeyIndex) { + earliest = path; + } + } + + return earliest; + }); +} + +function getDeepestCommonAncestorFrom(paths, filter) { + var _this = this; + + if (!paths.length) { + return this; + } + + if (paths.length === 1) { + return paths[0]; + } + + var minDepth = Infinity; + var lastCommonIndex, lastCommon; + var ancestries = paths.map(function (path) { + var ancestry = []; + + do { + ancestry.unshift(path); + } while ((path = path.parentPath) && path !== _this); + + if (ancestry.length < minDepth) { + minDepth = ancestry.length; + } + + return ancestry; + }); + var first = ancestries[0]; + + depthLoop: for (var i = 0; i < minDepth; i++) { + var shouldMatch = first[i]; + var _arr2 = ancestries; + + for (var _i2 = 0; _i2 < _arr2.length; _i2++) { + var ancestry = _arr2[_i2]; + + if (ancestry[i] !== shouldMatch) { + break depthLoop; + } + } + + lastCommonIndex = i; + lastCommon = shouldMatch; + } + + if (lastCommon) { + if (filter) { + return filter(lastCommon, lastCommonIndex, ancestries); + } else { + return lastCommon; + } + } else { + throw new Error("Couldn't find intersection"); + } +} + +function getAncestry() { + var path = this; + var paths = []; + + do { + paths.push(path); + } while (path = path.parentPath); + + return paths; +} + +function isAncestor(maybeDescendant) { + return maybeDescendant.isDescendant(this); +} + +function isDescendant(maybeAncestor) { + return !!this.findParent(function (parent) { + return parent === maybeAncestor; + }); +} + +function inType() { + var path = this; + + while (path) { + var _arr3 = arguments; + + for (var _i3 = 0; _i3 < _arr3.length; _i3++) { + var type = _arr3[_i3]; + if (path.node.type === type) return true; + } + + path = path.parentPath; + } + + return false; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/comments.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/comments.js new file mode 100644 index 00000000000000..5a1d7e25c0e410 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/comments.js @@ -0,0 +1,37 @@ +"use strict"; + +exports.__esModule = true; +exports.shareCommentsWithSiblings = shareCommentsWithSiblings; +exports.addComment = addComment; +exports.addComments = addComments; + +var t = _interopRequireWildcard(require("@babel/types")); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +function shareCommentsWithSiblings() { + if (typeof this.key === "string") return; + var node = this.node; + if (!node) return; + var trailing = node.trailingComments; + var leading = node.leadingComments; + if (!trailing && !leading) return; + var prev = this.getSibling(this.key - 1); + var next = this.getSibling(this.key + 1); + var hasPrev = Boolean(prev.node); + var hasNext = Boolean(next.node); + + if (hasPrev && hasNext) {} else if (hasPrev) { + prev.addComments("trailing", trailing); + } else if (hasNext) { + next.addComments("leading", leading); + } +} + +function addComment(type, content, line) { + t.addComment(this.node, type, content, line); +} + +function addComments(type, comments) { + t.addComments(this.node, type, comments); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/context.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/context.js new file mode 100644 index 00000000000000..8413e8727aeb25 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/context.js @@ -0,0 +1,273 @@ +"use strict"; + +exports.__esModule = true; +exports.call = call; +exports._call = _call; +exports.isBlacklisted = isBlacklisted; +exports.visit = visit; +exports.skip = skip; +exports.skipKey = skipKey; +exports.stop = stop; +exports.setScope = setScope; +exports.setContext = setContext; +exports.resync = resync; +exports._resyncParent = _resyncParent; +exports._resyncKey = _resyncKey; +exports._resyncList = _resyncList; +exports._resyncRemoved = _resyncRemoved; +exports.popContext = popContext; +exports.pushContext = pushContext; +exports.setup = setup; +exports.setKey = setKey; +exports.requeue = requeue; +exports._getQueueContexts = _getQueueContexts; + +var _index = _interopRequireDefault(require("../index")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function call(key) { + var opts = this.opts; + this.debug(key); + + if (this.node) { + if (this._call(opts[key])) return true; + } + + if (this.node) { + return this._call(opts[this.node.type] && opts[this.node.type][key]); + } + + return false; +} + +function _call(fns) { + if (!fns) return false; + + for (var _iterator = fns, _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 _fn = _ref; + if (!_fn) continue; + var node = this.node; + if (!node) return true; + + var ret = _fn.call(this.state, this, this.state); + + if (ret && typeof ret === "object" && typeof ret.then === "function") { + throw new Error("You appear to be using an plugin with an async traversay visitors, " + "which your current version of Babel does not support." + "If you're using a published plugin, you may need to upgrade " + "your @babel/core version."); + } + + if (ret) { + throw new Error("Unexpected return value from visitor method " + _fn); + } + + if (this.node !== node) return true; + if (this.shouldStop || this.shouldSkip || this.removed) return true; + } + + return false; +} + +function isBlacklisted() { + var blacklist = this.opts.blacklist; + return blacklist && blacklist.indexOf(this.node.type) > -1; +} + +function visit() { + if (!this.node) { + return false; + } + + if (this.isBlacklisted()) { + return false; + } + + if (this.opts.shouldSkip && this.opts.shouldSkip(this)) { + return false; + } + + if (this.call("enter") || this.shouldSkip) { + this.debug("Skip..."); + return this.shouldStop; + } + + this.debug("Recursing into..."); + + _index.default.node(this.node, this.opts, this.scope, this.state, this, this.skipKeys); + + this.call("exit"); + return this.shouldStop; +} + +function skip() { + this.shouldSkip = true; +} + +function skipKey(key) { + this.skipKeys[key] = true; +} + +function stop() { + this.shouldStop = true; + this.shouldSkip = true; +} + +function setScope() { + if (this.opts && this.opts.noScope) return; + var path = this.parentPath; + var target; + + while (path && !target) { + if (path.opts && path.opts.noScope) return; + target = path.scope; + path = path.parentPath; + } + + this.scope = this.getScope(target); + if (this.scope) this.scope.init(); +} + +function setContext(context) { + this.shouldSkip = false; + this.shouldStop = false; + this.removed = false; + this.skipKeys = {}; + + if (context) { + this.context = context; + this.state = context.state; + this.opts = context.opts; + } + + this.setScope(); + return this; +} + +function resync() { + if (this.removed) return; + + this._resyncParent(); + + this._resyncList(); + + this._resyncKey(); +} + +function _resyncParent() { + if (this.parentPath) { + this.parent = this.parentPath.node; + } +} + +function _resyncKey() { + if (!this.container) return; + if (this.node === this.container[this.key]) return; + + if (Array.isArray(this.container)) { + for (var i = 0; i < this.container.length; i++) { + if (this.container[i] === this.node) { + return this.setKey(i); + } + } + } else { + for (var key in this.container) { + if (this.container[key] === this.node) { + return this.setKey(key); + } + } + } + + this.key = null; +} + +function _resyncList() { + if (!this.parent || !this.inList) return; + var newContainer = this.parent[this.listKey]; + if (this.container === newContainer) return; + this.container = newContainer || null; +} + +function _resyncRemoved() { + if (this.key == null || !this.container || this.container[this.key] !== this.node) { + this._markRemoved(); + } +} + +function popContext() { + this.contexts.pop(); + + if (this.contexts.length > 0) { + this.setContext(this.contexts[this.contexts.length - 1]); + } else { + this.setContext(undefined); + } +} + +function pushContext(context) { + this.contexts.push(context); + this.setContext(context); +} + +function setup(parentPath, container, listKey, key) { + this.inList = !!listKey; + this.listKey = listKey; + this.parentKey = listKey || key; + this.container = container; + this.parentPath = parentPath || this.parentPath; + this.setKey(key); +} + +function setKey(key) { + this.key = key; + this.node = this.container[this.key]; + this.type = this.node && this.node.type; +} + +function requeue(pathToQueue) { + if (pathToQueue === void 0) { + pathToQueue = this; + } + + if (pathToQueue.removed) return; + var contexts = this.contexts; + + for (var _iterator2 = contexts, _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 _context = _ref2; + + _context.maybeQueue(pathToQueue); + } +} + +function _getQueueContexts() { + var path = this; + var contexts = this.contexts; + + while (!contexts.length) { + path = path.parentPath; + if (!path) break; + contexts = path.contexts; + } + + return contexts; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/conversion.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/conversion.js new file mode 100644 index 00000000000000..28b52ebf2ff653 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/conversion.js @@ -0,0 +1,446 @@ +"use strict"; + +exports.__esModule = true; +exports.toComputedKey = toComputedKey; +exports.ensureBlock = ensureBlock; +exports.arrowFunctionToShadowed = arrowFunctionToShadowed; +exports.unwrapFunctionEnvironment = unwrapFunctionEnvironment; +exports.arrowFunctionToExpression = arrowFunctionToExpression; + +var t = _interopRequireWildcard(require("@babel/types")); + +var _helperFunctionName = _interopRequireDefault(require("@babel/helper-function-name")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +function toComputedKey() { + var node = this.node; + var key; + + if (this.isMemberExpression()) { + key = node.property; + } else if (this.isProperty() || this.isMethod()) { + key = node.key; + } else { + throw new ReferenceError("todo"); + } + + if (!node.computed) { + if (t.isIdentifier(key)) key = t.stringLiteral(key.name); + } + + return key; +} + +function ensureBlock() { + var body = this.get("body"); + var bodyNode = body.node; + + if (Array.isArray(body)) { + throw new Error("Can't convert array path to a block statement"); + } + + if (!bodyNode) { + throw new Error("Can't convert node without a body"); + } + + if (body.isBlockStatement()) { + return bodyNode; + } + + var statements = []; + var stringPath = "body"; + var key; + var listKey; + + if (body.isStatement()) { + listKey = "body"; + key = 0; + statements.push(body.node); + } else { + stringPath += ".body.0"; + + if (this.isFunction()) { + key = "argument"; + statements.push(t.returnStatement(body.node)); + } else { + key = "expression"; + statements.push(t.expressionStatement(body.node)); + } + } + + this.node.body = t.blockStatement(statements); + var parentPath = this.get(stringPath); + body.setup(parentPath, listKey ? parentPath.node[listKey] : parentPath.node, listKey, key); + return this.node; +} + +function arrowFunctionToShadowed() { + if (!this.isArrowFunctionExpression()) return; + this.arrowFunctionToExpression(); +} + +function unwrapFunctionEnvironment() { + if (!this.isArrowFunctionExpression() && !this.isFunctionExpression() && !this.isFunctionDeclaration()) { + throw this.buildCodeFrameError("Can only unwrap the environment of a function."); + } + + hoistFunctionEnvironment(this); +} + +function arrowFunctionToExpression(_temp) { + var _ref = _temp === void 0 ? {} : _temp, + _ref$allowInsertArrow = _ref.allowInsertArrow, + allowInsertArrow = _ref$allowInsertArrow === void 0 ? true : _ref$allowInsertArrow, + _ref$specCompliant = _ref.specCompliant, + specCompliant = _ref$specCompliant === void 0 ? false : _ref$specCompliant; + + if (!this.isArrowFunctionExpression()) { + throw this.buildCodeFrameError("Cannot convert non-arrow function to a function expression."); + } + + var thisBinding = hoistFunctionEnvironment(this, specCompliant, allowInsertArrow); + this.ensureBlock(); + this.node.type = "FunctionExpression"; + + if (specCompliant) { + var checkBinding = thisBinding ? null : this.parentPath.scope.generateUidIdentifier("arrowCheckId"); + + if (checkBinding) { + this.parentPath.scope.push({ + id: checkBinding, + init: t.objectExpression([]) + }); + } + + this.get("body").unshiftContainer("body", t.expressionStatement(t.callExpression(this.hub.file.addHelper("newArrowCheck"), [t.thisExpression(), checkBinding ? t.identifier(checkBinding.name) : t.identifier(thisBinding)]))); + this.replaceWith(t.callExpression(t.memberExpression((0, _helperFunctionName.default)(this, true) || this.node, t.identifier("bind")), [checkBinding ? t.identifier(checkBinding.name) : t.thisExpression()])); + } +} + +function hoistFunctionEnvironment(fnPath, specCompliant, allowInsertArrow) { + if (specCompliant === void 0) { + specCompliant = false; + } + + if (allowInsertArrow === void 0) { + allowInsertArrow = true; + } + + var thisEnvFn = fnPath.findParent(function (p) { + return p.isFunction() && !p.isArrowFunctionExpression() || p.isProgram() || p.isClassProperty({ + static: false + }); + }); + var inConstructor = thisEnvFn && thisEnvFn.node.kind === "constructor"; + + if (thisEnvFn.isClassProperty()) { + throw fnPath.buildCodeFrameError("Unable to transform arrow inside class property"); + } + + var _getScopeInformation = getScopeInformation(fnPath), + thisPaths = _getScopeInformation.thisPaths, + argumentsPaths = _getScopeInformation.argumentsPaths, + newTargetPaths = _getScopeInformation.newTargetPaths, + superProps = _getScopeInformation.superProps, + superCalls = _getScopeInformation.superCalls; + + if (inConstructor && superCalls.length > 0) { + if (!allowInsertArrow) { + throw superCalls[0].buildCodeFrameError("Unable to handle nested super() usage in arrow"); + } + + var allSuperCalls = []; + thisEnvFn.traverse({ + Function: function Function(child) { + if (child.isArrowFunctionExpression()) return; + child.skip(); + }, + ClassProperty: function ClassProperty(child) { + if (child.node.static) return; + child.skip(); + }, + CallExpression: function CallExpression(child) { + if (!child.get("callee").isSuper()) return; + allSuperCalls.push(child); + } + }); + var superBinding = getSuperBinding(thisEnvFn); + allSuperCalls.forEach(function (superCall) { + return superCall.get("callee").replaceWith(t.identifier(superBinding)); + }); + } + + var thisBinding; + + if (thisPaths.length > 0 || specCompliant) { + thisBinding = getThisBinding(thisEnvFn, inConstructor); + + if (!specCompliant || inConstructor && hasSuperClass(thisEnvFn)) { + thisPaths.forEach(function (thisChild) { + thisChild.replaceWith(thisChild.isJSX() ? t.jsxIdentifier(thisBinding) : t.identifier(thisBinding)); + }); + if (specCompliant) thisBinding = null; + } + } + + if (argumentsPaths.length > 0) { + var argumentsBinding = getBinding(thisEnvFn, "arguments", function () { + return t.identifier("arguments"); + }); + argumentsPaths.forEach(function (argumentsChild) { + argumentsChild.replaceWith(t.identifier(argumentsBinding)); + }); + } + + if (newTargetPaths.length > 0) { + var newTargetBinding = getBinding(thisEnvFn, "newtarget", function () { + return t.metaProperty(t.identifier("new"), t.identifier("target")); + }); + newTargetPaths.forEach(function (argumentsChild) { + argumentsChild.replaceWith(t.identifier(newTargetBinding)); + }); + } + + if (superProps.length > 0) { + if (!allowInsertArrow) { + throw superProps[0].buildCodeFrameError("Unable to handle nested super.prop usage"); + } + + var flatSuperProps = superProps.reduce(function (acc, superProp) { + return acc.concat(standardizeSuperProperty(superProp)); + }, []); + flatSuperProps.forEach(function (superProp) { + var key = superProp.node.computed ? "" : superProp.get("property").node.name; + + if (superProp.parentPath.isCallExpression({ + callee: superProp.node + })) { + var _superBinding = getSuperPropCallBinding(thisEnvFn, key); + + if (superProp.node.computed) { + var prop = superProp.get("property").node; + superProp.replaceWith(t.identifier(_superBinding)); + superProp.parentPath.node.arguments.unshift(prop); + } else { + superProp.replaceWith(t.identifier(_superBinding)); + } + } else { + var isAssignment = superProp.parentPath.isAssignmentExpression({ + left: superProp.node + }); + + var _superBinding2 = getSuperPropBinding(thisEnvFn, isAssignment, key); + + var args = []; + + if (superProp.node.computed) { + args.push(superProp.get("property").node); + } + + if (isAssignment) { + var value = superProp.parentPath.node.right; + args.push(value); + superProp.parentPath.replaceWith(t.callExpression(t.identifier(_superBinding2), args)); + } else { + superProp.replaceWith(t.callExpression(t.identifier(_superBinding2), args)); + } + } + }); + } + + return thisBinding; +} + +function standardizeSuperProperty(superProp) { + if (superProp.parentPath.isAssignmentExpression() && superProp.parentPath.node.operator !== "=") { + var assignmentPath = superProp.parentPath; + var op = assignmentPath.node.operator.slice(0, -1); + var value = assignmentPath.node.right; + assignmentPath.node.operator = "="; + + if (superProp.node.computed) { + var tmp = superProp.scope.generateDeclaredUidIdentifier("tmp"); + assignmentPath.get("left").replaceWith(t.memberExpression(superProp.node.object, t.assignmentExpression("=", tmp, superProp.node.property), true)); + assignmentPath.get("right").replaceWith(t.binaryExpression(op, t.memberExpression(superProp.node.object, t.identifier(tmp.name), true), value)); + } else { + assignmentPath.get("left").replaceWith(t.memberExpression(superProp.node.object, superProp.node.property)); + assignmentPath.get("right").replaceWith(t.binaryExpression(op, t.memberExpression(superProp.node.object, t.identifier(superProp.node.property.name)), value)); + } + + return [assignmentPath.get("left"), assignmentPath.get("right").get("left")]; + } else if (superProp.parentPath.isUpdateExpression()) { + var updateExpr = superProp.parentPath; + + var _tmp = superProp.scope.generateDeclaredUidIdentifier("tmp"); + + var computedKey = superProp.node.computed ? superProp.scope.generateDeclaredUidIdentifier("prop") : null; + var parts = [t.assignmentExpression("=", _tmp, t.memberExpression(superProp.node.object, computedKey ? t.assignmentExpression("=", computedKey, superProp.node.property) : superProp.node.property, superProp.node.computed)), t.assignmentExpression("=", t.memberExpression(superProp.node.object, computedKey ? t.identifier(computedKey.name) : superProp.node.property, superProp.node.computed), t.binaryExpression("+", t.identifier(_tmp.name), t.numericLiteral(1)))]; + + if (!superProp.parentPath.node.prefix) { + parts.push(t.identifier(_tmp.name)); + } + + updateExpr.replaceWith(t.sequenceExpression(parts)); + var left = updateExpr.get("expressions.0.right"); + var right = updateExpr.get("expressions.1.left"); + return [left, right]; + } + + return [superProp]; +} + +function hasSuperClass(thisEnvFn) { + return thisEnvFn.isClassMethod() && !!thisEnvFn.parentPath.parentPath.node.superClass; +} + +function getThisBinding(thisEnvFn, inConstructor) { + return getBinding(thisEnvFn, "this", function (thisBinding) { + if (!inConstructor || !hasSuperClass(thisEnvFn)) return t.thisExpression(); + var supers = new WeakSet(); + thisEnvFn.traverse({ + Function: function Function(child) { + if (child.isArrowFunctionExpression()) return; + child.skip(); + }, + ClassProperty: function ClassProperty(child) { + if (child.node.static) return; + child.skip(); + }, + CallExpression: function CallExpression(child) { + if (!child.get("callee").isSuper()) return; + if (supers.has(child.node)) return; + supers.add(child.node); + child.replaceWith(t.assignmentExpression("=", t.identifier(thisBinding), child.node)); + } + }); + }); +} + +function getSuperBinding(thisEnvFn) { + return getBinding(thisEnvFn, "supercall", function () { + var argsBinding = thisEnvFn.scope.generateUidIdentifier("args"); + return t.arrowFunctionExpression([t.restElement(argsBinding)], t.callExpression(t.super(), [t.spreadElement(t.identifier(argsBinding.name))])); + }); +} + +function getSuperPropCallBinding(thisEnvFn, propName) { + return getBinding(thisEnvFn, "superprop_call:" + (propName || ""), function () { + var argsBinding = thisEnvFn.scope.generateUidIdentifier("args"); + var argsList = [t.restElement(argsBinding)]; + var fnBody; + + if (propName) { + fnBody = t.callExpression(t.memberExpression(t.super(), t.identifier(propName)), [t.spreadElement(t.identifier(argsBinding.name))]); + } else { + var method = thisEnvFn.scope.generateUidIdentifier("prop"); + argsList.unshift(method); + fnBody = t.callExpression(t.memberExpression(t.super(), t.identifier(method.name), true), [t.spreadElement(t.identifier(argsBinding.name))]); + } + + return t.arrowFunctionExpression(argsList, fnBody); + }); +} + +function getSuperPropBinding(thisEnvFn, isAssignment, propName) { + var op = isAssignment ? "set" : "get"; + return getBinding(thisEnvFn, "superprop_" + op + ":" + (propName || ""), function () { + var argsList = []; + var fnBody; + + if (propName) { + fnBody = t.memberExpression(t.super(), t.identifier(propName)); + } else { + var method = thisEnvFn.scope.generateUidIdentifier("prop"); + argsList.unshift(method); + fnBody = t.memberExpression(t.super(), t.identifier(method.name), true); + } + + if (isAssignment) { + var valueIdent = thisEnvFn.scope.generateUidIdentifier("value"); + argsList.push(valueIdent); + fnBody = t.assignmentExpression("=", fnBody, t.identifier(valueIdent.name)); + } + + return t.arrowFunctionExpression(argsList, fnBody); + }); +} + +function getBinding(thisEnvFn, key, init) { + var cacheKey = "binding:" + key; + var data = thisEnvFn.getData(cacheKey); + + if (!data) { + var id = thisEnvFn.scope.generateUidIdentifier(key); + data = id.name; + thisEnvFn.setData(cacheKey, data); + thisEnvFn.scope.push({ + id: id, + init: init(data) + }); + } + + return data; +} + +function getScopeInformation(fnPath) { + var thisPaths = []; + var argumentsPaths = []; + var newTargetPaths = []; + var superProps = []; + var superCalls = []; + fnPath.traverse({ + ClassProperty: function ClassProperty(child) { + if (child.node.static) return; + child.skip(); + }, + Function: function Function(child) { + if (child.isArrowFunctionExpression()) return; + child.skip(); + }, + ThisExpression: function ThisExpression(child) { + thisPaths.push(child); + }, + JSXIdentifier: function JSXIdentifier(child) { + if (child.node.name !== "this") return; + + if (!child.parentPath.isJSXMemberExpression({ + object: child.node + }) && !child.parentPath.isJSXOpeningElement({ + name: child.node + })) { + return; + } + + thisPaths.push(child); + }, + CallExpression: function CallExpression(child) { + if (child.get("callee").isSuper()) superCalls.push(child); + }, + MemberExpression: function MemberExpression(child) { + if (child.get("object").isSuper()) superProps.push(child); + }, + ReferencedIdentifier: function ReferencedIdentifier(child) { + if (child.node.name !== "arguments") return; + argumentsPaths.push(child); + }, + MetaProperty: function MetaProperty(child) { + if (!child.get("meta").isIdentifier({ + name: "new" + })) return; + if (!child.get("property").isIdentifier({ + name: "target" + })) return; + newTargetPaths.push(child); + } + }); + return { + thisPaths: thisPaths, + argumentsPaths: argumentsPaths, + newTargetPaths: newTargetPaths, + superProps: superProps, + superCalls: superCalls + }; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/evaluation.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/evaluation.js new file mode 100644 index 00000000000000..ed62dfbc87b6db --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/evaluation.js @@ -0,0 +1,451 @@ +"use strict"; + +exports.__esModule = true; +exports.evaluateTruthy = evaluateTruthy; +exports.evaluate = evaluate; +var VALID_CALLEES = ["String", "Number", "Math"]; +var INVALID_METHODS = ["random"]; + +function evaluateTruthy() { + var res = this.evaluate(); + if (res.confident) return !!res.value; +} + +function deopt(path, state) { + if (!state.confident) return; + state.deoptPath = path; + state.confident = false; +} + +function evaluateCached(path, state) { + var node = path.node; + var seen = state.seen; + + if (seen.has(node)) { + var existing = seen.get(node); + + if (existing.resolved) { + return existing.value; + } else { + deopt(path, state); + return; + } + } else { + var item = { + resolved: false + }; + seen.set(node, item); + + var val = _evaluate(path, state); + + if (state.confident) { + item.resolved = true; + item.value = val; + } + + return val; + } +} + +function _evaluate(path, state) { + if (!state.confident) return; + var node = path.node; + + if (path.isSequenceExpression()) { + var exprs = path.get("expressions"); + return evaluateCached(exprs[exprs.length - 1], state); + } + + if (path.isStringLiteral() || path.isNumericLiteral() || path.isBooleanLiteral()) { + return node.value; + } + + if (path.isNullLiteral()) { + return null; + } + + if (path.isTemplateLiteral()) { + return evaluateQuasis(path, node.quasis, state); + } + + if (path.isTaggedTemplateExpression() && path.get("tag").isMemberExpression()) { + var object = path.get("tag.object"); + var name = object.node.name; + var property = path.get("tag.property"); + + if (object.isIdentifier() && name === "String" && !path.scope.getBinding(name, true) && property.isIdentifier && property.node.name === "raw") { + return evaluateQuasis(path, node.quasi.quasis, state, true); + } + } + + if (path.isConditionalExpression()) { + var testResult = evaluateCached(path.get("test"), state); + if (!state.confident) return; + + if (testResult) { + return evaluateCached(path.get("consequent"), state); + } else { + return evaluateCached(path.get("alternate"), state); + } + } + + if (path.isExpressionWrapper()) { + return evaluateCached(path.get("expression"), state); + } + + if (path.isMemberExpression() && !path.parentPath.isCallExpression({ + callee: node + })) { + var _property = path.get("property"); + + var _object = path.get("object"); + + if (_object.isLiteral() && _property.isIdentifier()) { + var value = _object.node.value; + var type = typeof value; + + if (type === "number" || type === "string") { + return value[_property.node.name]; + } + } + } + + if (path.isReferencedIdentifier()) { + var binding = path.scope.getBinding(node.name); + + if (binding && binding.constantViolations.length > 0) { + return deopt(binding.path, state); + } + + if (binding && path.node.start < binding.path.node.end) { + return deopt(binding.path, state); + } + + if (binding && binding.hasValue) { + return binding.value; + } else { + if (node.name === "undefined") { + return binding ? deopt(binding.path, state) : undefined; + } else if (node.name === "Infinity") { + return binding ? deopt(binding.path, state) : Infinity; + } else if (node.name === "NaN") { + return binding ? deopt(binding.path, state) : NaN; + } + + var resolved = path.resolve(); + + if (resolved === path) { + return deopt(path, state); + } else { + return evaluateCached(resolved, state); + } + } + } + + if (path.isUnaryExpression({ + prefix: true + })) { + if (node.operator === "void") { + return undefined; + } + + var argument = path.get("argument"); + + if (node.operator === "typeof" && (argument.isFunction() || argument.isClass())) { + return "function"; + } + + var arg = evaluateCached(argument, state); + if (!state.confident) return; + + switch (node.operator) { + case "!": + return !arg; + + case "+": + return +arg; + + case "-": + return -arg; + + case "~": + return ~arg; + + case "typeof": + return typeof arg; + } + } + + if (path.isArrayExpression()) { + var arr = []; + var elems = path.get("elements"); + + for (var _iterator = elems, _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 _elem = _ref; + + var elemValue = _elem.evaluate(); + + if (elemValue.confident) { + arr.push(elemValue.value); + } else { + return deopt(_elem, state); + } + } + + return arr; + } + + if (path.isObjectExpression()) { + var obj = {}; + var props = path.get("properties"); + + for (var _iterator2 = props, _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 _prop = _ref2; + + if (_prop.isObjectMethod() || _prop.isSpreadElement()) { + return deopt(_prop, state); + } + + var keyPath = _prop.get("key"); + + var key = keyPath; + + if (_prop.node.computed) { + key = key.evaluate(); + + if (!key.confident) { + return deopt(keyPath, state); + } + + key = key.value; + } else if (key.isIdentifier()) { + key = key.node.name; + } else { + key = key.node.value; + } + + var valuePath = _prop.get("value"); + + var _value2 = valuePath.evaluate(); + + if (!_value2.confident) { + return deopt(valuePath, state); + } + + _value2 = _value2.value; + obj[key] = _value2; + } + + return obj; + } + + if (path.isLogicalExpression()) { + var wasConfident = state.confident; + var left = evaluateCached(path.get("left"), state); + var leftConfident = state.confident; + state.confident = wasConfident; + var right = evaluateCached(path.get("right"), state); + var rightConfident = state.confident; + state.confident = leftConfident && rightConfident; + + switch (node.operator) { + case "||": + if (left && leftConfident) { + state.confident = true; + return left; + } + + if (!state.confident) return; + return left || right; + + case "&&": + if (!left && leftConfident || !right && rightConfident) { + state.confident = true; + } + + if (!state.confident) return; + return left && right; + } + } + + if (path.isBinaryExpression()) { + var _left = evaluateCached(path.get("left"), state); + + if (!state.confident) return; + + var _right = evaluateCached(path.get("right"), state); + + if (!state.confident) return; + + switch (node.operator) { + case "-": + return _left - _right; + + case "+": + return _left + _right; + + case "/": + return _left / _right; + + case "*": + return _left * _right; + + case "%": + return _left % _right; + + case "**": + return Math.pow(_left, _right); + + case "<": + return _left < _right; + + case ">": + return _left > _right; + + case "<=": + return _left <= _right; + + case ">=": + return _left >= _right; + + case "==": + return _left == _right; + + case "!=": + return _left != _right; + + case "===": + return _left === _right; + + case "!==": + return _left !== _right; + + case "|": + return _left | _right; + + case "&": + return _left & _right; + + case "^": + return _left ^ _right; + + case "<<": + return _left << _right; + + case ">>": + return _left >> _right; + + case ">>>": + return _left >>> _right; + } + } + + if (path.isCallExpression()) { + var callee = path.get("callee"); + var context; + var func; + + if (callee.isIdentifier() && !path.scope.getBinding(callee.node.name, true) && VALID_CALLEES.indexOf(callee.node.name) >= 0) { + func = global[node.callee.name]; + } + + if (callee.isMemberExpression()) { + var _object2 = callee.get("object"); + + var _property2 = callee.get("property"); + + if (_object2.isIdentifier() && _property2.isIdentifier() && VALID_CALLEES.indexOf(_object2.node.name) >= 0 && INVALID_METHODS.indexOf(_property2.node.name) < 0) { + context = global[_object2.node.name]; + func = context[_property2.node.name]; + } + + if (_object2.isLiteral() && _property2.isIdentifier()) { + var _type = typeof _object2.node.value; + + if (_type === "string" || _type === "number") { + context = _object2.node.value; + func = context[_property2.node.name]; + } + } + } + + if (func) { + var args = path.get("arguments").map(function (arg) { + return evaluateCached(arg, state); + }); + if (!state.confident) return; + return func.apply(context, args); + } + } + + deopt(path, state); +} + +function evaluateQuasis(path, quasis, state, raw) { + if (raw === void 0) { + raw = false; + } + + var str = ""; + var i = 0; + var exprs = path.get("expressions"); + + for (var _iterator3 = quasis, _isArray3 = Array.isArray(_iterator3), _i3 = 0, _iterator3 = _isArray3 ? _iterator3 : _iterator3[Symbol.iterator]();;) { + var _ref3; + + if (_isArray3) { + if (_i3 >= _iterator3.length) break; + _ref3 = _iterator3[_i3++]; + } else { + _i3 = _iterator3.next(); + if (_i3.done) break; + _ref3 = _i3.value; + } + + var _elem2 = _ref3; + if (!state.confident) break; + str += raw ? _elem2.value.raw : _elem2.value.cooked; + var expr = exprs[i++]; + if (expr) str += String(evaluateCached(expr, state)); + } + + if (!state.confident) return; + return str; +} + +function evaluate() { + var state = { + confident: true, + deoptPath: null, + seen: new Map() + }; + var value = evaluateCached(this, state); + if (!state.confident) value = undefined; + return { + confident: state.confident, + deopt: state.deoptPath, + value: value + }; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/family.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/family.js new file mode 100644 index 00000000000000..da8010d7979fae --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/family.js @@ -0,0 +1,244 @@ +"use strict"; + +exports.__esModule = true; +exports.getOpposite = getOpposite; +exports.getCompletionRecords = getCompletionRecords; +exports.getSibling = getSibling; +exports.getPrevSibling = getPrevSibling; +exports.getNextSibling = getNextSibling; +exports.getAllNextSiblings = getAllNextSiblings; +exports.getAllPrevSiblings = getAllPrevSiblings; +exports.get = get; +exports._getKey = _getKey; +exports._getPattern = _getPattern; +exports.getBindingIdentifiers = getBindingIdentifiers; +exports.getOuterBindingIdentifiers = getOuterBindingIdentifiers; +exports.getBindingIdentifierPaths = getBindingIdentifierPaths; +exports.getOuterBindingIdentifierPaths = getOuterBindingIdentifierPaths; + +var _index = _interopRequireDefault(require("./index")); + +var t = _interopRequireWildcard(require("@babel/types")); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function getOpposite() { + if (this.key === "left") { + return this.getSibling("right"); + } else if (this.key === "right") { + return this.getSibling("left"); + } +} + +function addCompletionRecords(path, paths) { + if (path) return paths.concat(path.getCompletionRecords()); + return paths; +} + +function getCompletionRecords() { + var paths = []; + + if (this.isIfStatement()) { + paths = addCompletionRecords(this.get("consequent"), paths); + paths = addCompletionRecords(this.get("alternate"), paths); + } else if (this.isDoExpression() || this.isFor() || this.isWhile()) { + paths = addCompletionRecords(this.get("body"), paths); + } else if (this.isProgram() || this.isBlockStatement()) { + paths = addCompletionRecords(this.get("body").pop(), paths); + } else if (this.isFunction()) { + return this.get("body").getCompletionRecords(); + } else if (this.isTryStatement()) { + paths = addCompletionRecords(this.get("block"), paths); + paths = addCompletionRecords(this.get("handler"), paths); + paths = addCompletionRecords(this.get("finalizer"), paths); + } else if (this.isCatchClause()) { + paths = addCompletionRecords(this.get("body"), paths); + } else { + paths.push(this); + } + + return paths; +} + +function getSibling(key) { + return _index.default.get({ + parentPath: this.parentPath, + parent: this.parent, + container: this.container, + listKey: this.listKey, + key: key + }); +} + +function getPrevSibling() { + return this.getSibling(this.key - 1); +} + +function getNextSibling() { + return this.getSibling(this.key + 1); +} + +function getAllNextSiblings() { + var _key = this.key; + var sibling = this.getSibling(++_key); + var siblings = []; + + while (sibling.node) { + siblings.push(sibling); + sibling = this.getSibling(++_key); + } + + return siblings; +} + +function getAllPrevSiblings() { + var _key = this.key; + var sibling = this.getSibling(--_key); + var siblings = []; + + while (sibling.node) { + siblings.push(sibling); + sibling = this.getSibling(--_key); + } + + return siblings; +} + +function get(key, context) { + if (context === true) context = this.context; + var parts = key.split("."); + + if (parts.length === 1) { + return this._getKey(key, context); + } else { + return this._getPattern(parts, context); + } +} + +function _getKey(key, context) { + var _this = this; + + var node = this.node; + var container = node[key]; + + if (Array.isArray(container)) { + return container.map(function (_, i) { + return _index.default.get({ + listKey: key, + parentPath: _this, + parent: node, + container: container, + key: i + }).setContext(context); + }); + } else { + return _index.default.get({ + parentPath: this, + parent: node, + container: node, + key: key + }).setContext(context); + } +} + +function _getPattern(parts, context) { + var path = this; + var _arr = parts; + + for (var _i = 0; _i < _arr.length; _i++) { + var part = _arr[_i]; + + if (part === ".") { + path = path.parentPath; + } else { + if (Array.isArray(path)) { + path = path[part]; + } else { + path = path.get(part, context); + } + } + } + + return path; +} + +function getBindingIdentifiers(duplicates) { + return t.getBindingIdentifiers(this.node, duplicates); +} + +function getOuterBindingIdentifiers(duplicates) { + return t.getOuterBindingIdentifiers(this.node, duplicates); +} + +function getBindingIdentifierPaths(duplicates, outerOnly) { + if (duplicates === void 0) { + duplicates = false; + } + + if (outerOnly === void 0) { + outerOnly = false; + } + + var path = this; + var search = [].concat(path); + var ids = Object.create(null); + + while (search.length) { + var id = search.shift(); + if (!id) continue; + if (!id.node) continue; + var keys = t.getBindingIdentifiers.keys[id.node.type]; + + if (id.isIdentifier()) { + if (duplicates) { + var _ids = ids[id.node.name] = ids[id.node.name] || []; + + _ids.push(id); + } else { + ids[id.node.name] = id; + } + + continue; + } + + if (id.isExportDeclaration()) { + var declaration = id.get("declaration"); + + if (declaration.isDeclaration()) { + search.push(declaration); + } + + continue; + } + + if (outerOnly) { + if (id.isFunctionDeclaration()) { + search.push(id.get("id")); + continue; + } + + if (id.isFunctionExpression()) { + continue; + } + } + + if (keys) { + for (var i = 0; i < keys.length; i++) { + var key = keys[i]; + var child = id.get(key); + + if (Array.isArray(child) || child.node) { + search = search.concat(child); + } + } + } + } + + return ids; +} + +function getOuterBindingIdentifierPaths(duplicates) { + return this.getBindingIdentifierPaths(duplicates, true); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/index.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/index.js new file mode 100644 index 00000000000000..716eae7ebfc379 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/index.js @@ -0,0 +1,228 @@ +"use strict"; + +exports.__esModule = true; +exports.default = void 0; + +var virtualTypes = _interopRequireWildcard(require("./lib/virtual-types")); + +var _debug2 = _interopRequireDefault(require("debug")); + +var _invariant = _interopRequireDefault(require("invariant")); + +var _index = _interopRequireDefault(require("../index")); + +var _scope = _interopRequireDefault(require("../scope")); + +var t = _interopRequireWildcard(require("@babel/types")); + +var _cache = require("../cache"); + +var NodePath_ancestry = _interopRequireWildcard(require("./ancestry")); + +var NodePath_inference = _interopRequireWildcard(require("./inference")); + +var NodePath_replacement = _interopRequireWildcard(require("./replacement")); + +var NodePath_evaluation = _interopRequireWildcard(require("./evaluation")); + +var NodePath_conversion = _interopRequireWildcard(require("./conversion")); + +var NodePath_introspection = _interopRequireWildcard(require("./introspection")); + +var NodePath_context = _interopRequireWildcard(require("./context")); + +var NodePath_removal = _interopRequireWildcard(require("./removal")); + +var NodePath_modification = _interopRequireWildcard(require("./modification")); + +var NodePath_family = _interopRequireWildcard(require("./family")); + +var NodePath_comments = _interopRequireWildcard(require("./comments")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +var _debug = (0, _debug2.default)("babel"); + +var NodePath = function () { + function NodePath(hub, parent) { + this.parent = void 0; + this.hub = void 0; + this.contexts = void 0; + this.data = void 0; + this.shouldSkip = void 0; + this.shouldStop = void 0; + this.removed = void 0; + this.state = void 0; + this.opts = void 0; + this.skipKeys = void 0; + this.parentPath = void 0; + this.context = void 0; + this.container = void 0; + this.listKey = void 0; + this.inList = void 0; + this.parentKey = void 0; + this.key = void 0; + this.node = void 0; + this.scope = void 0; + this.type = void 0; + this.typeAnnotation = void 0; + this.parent = parent; + this.hub = hub; + this.contexts = []; + this.data = {}; + this.shouldSkip = false; + this.shouldStop = false; + this.removed = false; + this.state = null; + this.opts = null; + this.skipKeys = null; + this.parentPath = null; + this.context = null; + this.container = null; + this.listKey = null; + this.inList = false; + this.parentKey = null; + this.key = null; + this.node = null; + this.scope = null; + this.type = null; + this.typeAnnotation = null; + } + + NodePath.get = function get(_ref) { + var hub = _ref.hub, + parentPath = _ref.parentPath, + parent = _ref.parent, + container = _ref.container, + listKey = _ref.listKey, + key = _ref.key; + + if (!hub && parentPath) { + hub = parentPath.hub; + } + + (0, _invariant.default)(parent, "To get a node path the parent needs to exist"); + var targetNode = container[key]; + var paths = _cache.path.get(parent) || []; + + if (!_cache.path.has(parent)) { + _cache.path.set(parent, paths); + } + + var path; + + for (var i = 0; i < paths.length; i++) { + var pathCheck = paths[i]; + + if (pathCheck.node === targetNode) { + path = pathCheck; + break; + } + } + + if (!path) { + path = new NodePath(hub, parent); + paths.push(path); + } + + path.setup(parentPath, container, listKey, key); + return path; + }; + + var _proto = NodePath.prototype; + + _proto.getScope = function getScope(scope) { + return this.isScope() ? new _scope.default(this) : scope; + }; + + _proto.setData = function setData(key, val) { + return this.data[key] = val; + }; + + _proto.getData = function getData(key, def) { + var val = this.data[key]; + if (!val && def) val = this.data[key] = def; + return val; + }; + + _proto.buildCodeFrameError = function buildCodeFrameError(msg, Error) { + if (Error === void 0) { + Error = SyntaxError; + } + + return this.hub.file.buildCodeFrameError(this.node, msg, Error); + }; + + _proto.traverse = function traverse(visitor, state) { + (0, _index.default)(this.node, visitor, this.scope, state, this); + }; + + _proto.set = function set(key, node) { + t.validate(this.node, key, node); + this.node[key] = node; + }; + + _proto.getPathLocation = function getPathLocation() { + var parts = []; + var path = this; + + do { + var key = path.key; + if (path.inList) key = path.listKey + "[" + key + "]"; + parts.unshift(key); + } while (path = path.parentPath); + + return parts.join("."); + }; + + _proto.debug = function debug(message) { + if (!_debug.enabled) return; + + _debug(this.getPathLocation() + " " + this.type + ": " + message); + }; + + return NodePath; +}(); + +exports.default = NodePath; +Object.assign(NodePath.prototype, NodePath_ancestry, NodePath_inference, NodePath_replacement, NodePath_evaluation, NodePath_conversion, NodePath_introspection, NodePath_context, NodePath_removal, NodePath_modification, NodePath_family, NodePath_comments); + +var _loop = function _loop(type) { + var typeKey = "is" + type; + + NodePath.prototype[typeKey] = function (opts) { + return t[typeKey](this.node, opts); + }; + + NodePath.prototype["assert" + type] = function (opts) { + if (!this[typeKey](opts)) { + throw new TypeError("Expected node path of type " + type); + } + }; +}; + +var _arr = t.TYPES; + +for (var _i = 0; _i < _arr.length; _i++) { + var type = _arr[_i]; + + _loop(type); +} + +var _loop2 = function _loop2(type) { + if (type[0] === "_") return "continue"; + if (t.TYPES.indexOf(type) < 0) t.TYPES.push(type); + var virtualType = virtualTypes[type]; + + NodePath.prototype["is" + type] = function (opts) { + return virtualType.checkPath(this, opts); + }; +}; + +for (var type in virtualTypes) { + var _ret = _loop2(type); + + if (_ret === "continue") continue; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/inference/index.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/inference/index.js new file mode 100644 index 00000000000000..30d125c20c7f33 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/inference/index.js @@ -0,0 +1,126 @@ +"use strict"; + +exports.__esModule = true; +exports.getTypeAnnotation = getTypeAnnotation; +exports._getTypeAnnotation = _getTypeAnnotation; +exports.isBaseType = isBaseType; +exports.couldBeBaseType = couldBeBaseType; +exports.baseTypeStrictlyMatches = baseTypeStrictlyMatches; +exports.isGenericType = isGenericType; + +var inferers = _interopRequireWildcard(require("./inferers")); + +var t = _interopRequireWildcard(require("@babel/types")); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +function getTypeAnnotation() { + if (this.typeAnnotation) return this.typeAnnotation; + var type = this._getTypeAnnotation() || t.anyTypeAnnotation(); + if (t.isTypeAnnotation(type)) type = type.typeAnnotation; + return this.typeAnnotation = type; +} + +function _getTypeAnnotation() { + var node = this.node; + + if (!node) { + if (this.key === "init" && this.parentPath.isVariableDeclarator()) { + var declar = this.parentPath.parentPath; + var declarParent = declar.parentPath; + + if (declar.key === "left" && declarParent.isForInStatement()) { + return t.stringTypeAnnotation(); + } + + if (declar.key === "left" && declarParent.isForOfStatement()) { + return t.anyTypeAnnotation(); + } + + return t.voidTypeAnnotation(); + } else { + return; + } + } + + if (node.typeAnnotation) { + return node.typeAnnotation; + } + + var inferer = inferers[node.type]; + + if (inferer) { + return inferer.call(this, node); + } + + inferer = inferers[this.parentPath.type]; + + if (inferer && inferer.validParent) { + return this.parentPath.getTypeAnnotation(); + } +} + +function isBaseType(baseName, soft) { + return _isBaseType(baseName, this.getTypeAnnotation(), soft); +} + +function _isBaseType(baseName, type, soft) { + if (baseName === "string") { + return t.isStringTypeAnnotation(type); + } else if (baseName === "number") { + return t.isNumberTypeAnnotation(type); + } else if (baseName === "boolean") { + return t.isBooleanTypeAnnotation(type); + } else if (baseName === "any") { + return t.isAnyTypeAnnotation(type); + } else if (baseName === "mixed") { + return t.isMixedTypeAnnotation(type); + } else if (baseName === "empty") { + return t.isEmptyTypeAnnotation(type); + } else if (baseName === "void") { + return t.isVoidTypeAnnotation(type); + } else { + if (soft) { + return false; + } else { + throw new Error("Unknown base type " + baseName); + } + } +} + +function couldBeBaseType(name) { + var type = this.getTypeAnnotation(); + if (t.isAnyTypeAnnotation(type)) return true; + + if (t.isUnionTypeAnnotation(type)) { + var _arr = type.types; + + for (var _i = 0; _i < _arr.length; _i++) { + var type2 = _arr[_i]; + + if (t.isAnyTypeAnnotation(type2) || _isBaseType(name, type2, true)) { + return true; + } + } + + return false; + } else { + return _isBaseType(name, type, true); + } +} + +function baseTypeStrictlyMatches(right) { + var left = this.getTypeAnnotation(); + right = right.getTypeAnnotation(); + + if (!t.isAnyTypeAnnotation(left) && t.isFlowBaseAnnotation(left)) { + return right.type === left.type; + } +} + +function isGenericType(genericName) { + var type = this.getTypeAnnotation(); + return t.isGenericTypeAnnotation(type) && t.isIdentifier(type.id, { + name: genericName + }); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/inference/inferer-reference.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/inference/inferer-reference.js new file mode 100644 index 00000000000000..219c32f8936c72 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/inference/inferer-reference.js @@ -0,0 +1,175 @@ +"use strict"; + +exports.__esModule = true; +exports.default = _default; + +var t = _interopRequireWildcard(require("@babel/types")); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +function _default(node) { + if (!this.isReferenced()) return; + var binding = this.scope.getBinding(node.name); + + if (binding) { + if (binding.identifier.typeAnnotation) { + return binding.identifier.typeAnnotation; + } else { + return getTypeAnnotationBindingConstantViolations(binding, this, node.name); + } + } + + if (node.name === "undefined") { + return t.voidTypeAnnotation(); + } else if (node.name === "NaN" || node.name === "Infinity") { + return t.numberTypeAnnotation(); + } else if (node.name === "arguments") {} +} + +function getTypeAnnotationBindingConstantViolations(binding, path, name) { + var types = []; + var functionConstantViolations = []; + var constantViolations = getConstantViolationsBefore(binding, path, functionConstantViolations); + var testType = getConditionalAnnotation(binding, path, name); + + if (testType) { + var testConstantViolations = getConstantViolationsBefore(binding, testType.ifStatement); + constantViolations = constantViolations.filter(function (path) { + return testConstantViolations.indexOf(path) < 0; + }); + types.push(testType.typeAnnotation); + } + + if (constantViolations.length) { + constantViolations = constantViolations.concat(functionConstantViolations); + var _arr = constantViolations; + + for (var _i = 0; _i < _arr.length; _i++) { + var violation = _arr[_i]; + types.push(violation.getTypeAnnotation()); + } + } + + if (types.length) { + return t.createUnionTypeAnnotation(types); + } +} + +function getConstantViolationsBefore(binding, path, functions) { + var violations = binding.constantViolations.slice(); + violations.unshift(binding.path); + return violations.filter(function (violation) { + violation = violation.resolve(); + + var status = violation._guessExecutionStatusRelativeTo(path); + + if (functions && status === "function") functions.push(violation); + return status === "before"; + }); +} + +function inferAnnotationFromBinaryExpression(name, path) { + var operator = path.node.operator; + var right = path.get("right").resolve(); + var left = path.get("left").resolve(); + var target; + + if (left.isIdentifier({ + name: name + })) { + target = right; + } else if (right.isIdentifier({ + name: name + })) { + target = left; + } + + if (target) { + if (operator === "===") { + return target.getTypeAnnotation(); + } + + if (t.BOOLEAN_NUMBER_BINARY_OPERATORS.indexOf(operator) >= 0) { + return t.numberTypeAnnotation(); + } + + return; + } + + if (operator !== "===" && operator !== "==") return; + var typeofPath; + var typePath; + + if (left.isUnaryExpression({ + operator: "typeof" + })) { + typeofPath = left; + typePath = right; + } else if (right.isUnaryExpression({ + operator: "typeof" + })) { + typeofPath = right; + typePath = left; + } + + if (!typeofPath) return; + if (!typeofPath.get("argument").isIdentifier({ + name: name + })) return; + typePath = typePath.resolve(); + if (!typePath.isLiteral()) return; + var typeValue = typePath.node.value; + if (typeof typeValue !== "string") return; + return t.createTypeAnnotationBasedOnTypeof(typeValue); +} + +function getParentConditionalPath(binding, path, name) { + var parentPath; + + while (parentPath = path.parentPath) { + if (parentPath.isIfStatement() || parentPath.isConditionalExpression()) { + if (path.key === "test") { + return; + } + + return parentPath; + } + + if (parentPath.isFunction()) { + if (parentPath.parentPath.scope.getBinding(name) !== binding) return; + } + + path = parentPath; + } +} + +function getConditionalAnnotation(binding, path, name) { + var ifStatement = getParentConditionalPath(binding, path, name); + if (!ifStatement) return; + var test = ifStatement.get("test"); + var paths = [test]; + var types = []; + + for (var i = 0; i < paths.length; i++) { + var _path = paths[i]; + + if (_path.isLogicalExpression()) { + if (_path.node.operator === "&&") { + paths.push(_path.get("left")); + paths.push(_path.get("right")); + } + } else if (_path.isBinaryExpression()) { + var type = inferAnnotationFromBinaryExpression(name, _path); + if (type) types.push(type); + } + } + + if (types.length) { + return { + typeAnnotation: t.createUnionTypeAnnotation(types), + ifStatement: ifStatement + }; + } + + return getConditionalAnnotation(ifStatement, name); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/inference/inferers.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/inference/inferers.js new file mode 100644 index 00000000000000..d31295b940abae --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/inference/inferers.js @@ -0,0 +1,207 @@ +"use strict"; + +exports.__esModule = true; +exports.VariableDeclarator = VariableDeclarator; +exports.TypeCastExpression = TypeCastExpression; +exports.NewExpression = NewExpression; +exports.TemplateLiteral = TemplateLiteral; +exports.UnaryExpression = UnaryExpression; +exports.BinaryExpression = BinaryExpression; +exports.LogicalExpression = LogicalExpression; +exports.ConditionalExpression = ConditionalExpression; +exports.SequenceExpression = SequenceExpression; +exports.AssignmentExpression = AssignmentExpression; +exports.UpdateExpression = UpdateExpression; +exports.StringLiteral = StringLiteral; +exports.NumericLiteral = NumericLiteral; +exports.BooleanLiteral = BooleanLiteral; +exports.NullLiteral = NullLiteral; +exports.RegExpLiteral = RegExpLiteral; +exports.ObjectExpression = ObjectExpression; +exports.ArrayExpression = ArrayExpression; +exports.RestElement = RestElement; +exports.ClassDeclaration = exports.ClassExpression = exports.FunctionDeclaration = exports.ArrowFunctionExpression = exports.FunctionExpression = Func; +exports.CallExpression = CallExpression; +exports.TaggedTemplateExpression = TaggedTemplateExpression; +exports.Identifier = void 0; + +var t = _interopRequireWildcard(require("@babel/types")); + +var _infererReference = _interopRequireDefault(require("./inferer-reference")); + +exports.Identifier = _infererReference.default; + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +function VariableDeclarator() { + var id = this.get("id"); + if (!id.isIdentifier()) return; + var init = this.get("init"); + var type = init.getTypeAnnotation(); + + if (type && type.type === "AnyTypeAnnotation") { + if (init.isCallExpression() && init.get("callee").isIdentifier({ + name: "Array" + }) && !init.scope.hasBinding("Array", true)) { + type = ArrayExpression(); + } + } + + return type; +} + +function TypeCastExpression(node) { + return node.typeAnnotation; +} + +TypeCastExpression.validParent = true; + +function NewExpression(node) { + if (this.get("callee").isIdentifier()) { + return t.genericTypeAnnotation(node.callee); + } +} + +function TemplateLiteral() { + return t.stringTypeAnnotation(); +} + +function UnaryExpression(node) { + var operator = node.operator; + + if (operator === "void") { + return t.voidTypeAnnotation(); + } else if (t.NUMBER_UNARY_OPERATORS.indexOf(operator) >= 0) { + return t.numberTypeAnnotation(); + } else if (t.STRING_UNARY_OPERATORS.indexOf(operator) >= 0) { + return t.stringTypeAnnotation(); + } else if (t.BOOLEAN_UNARY_OPERATORS.indexOf(operator) >= 0) { + return t.booleanTypeAnnotation(); + } +} + +function BinaryExpression(node) { + var operator = node.operator; + + if (t.NUMBER_BINARY_OPERATORS.indexOf(operator) >= 0) { + return t.numberTypeAnnotation(); + } else if (t.BOOLEAN_BINARY_OPERATORS.indexOf(operator) >= 0) { + return t.booleanTypeAnnotation(); + } else if (operator === "+") { + var right = this.get("right"); + var left = this.get("left"); + + if (left.isBaseType("number") && right.isBaseType("number")) { + return t.numberTypeAnnotation(); + } else if (left.isBaseType("string") || right.isBaseType("string")) { + return t.stringTypeAnnotation(); + } + + return t.unionTypeAnnotation([t.stringTypeAnnotation(), t.numberTypeAnnotation()]); + } +} + +function LogicalExpression() { + return t.createUnionTypeAnnotation([this.get("left").getTypeAnnotation(), this.get("right").getTypeAnnotation()]); +} + +function ConditionalExpression() { + return t.createUnionTypeAnnotation([this.get("consequent").getTypeAnnotation(), this.get("alternate").getTypeAnnotation()]); +} + +function SequenceExpression() { + return this.get("expressions").pop().getTypeAnnotation(); +} + +function AssignmentExpression() { + return this.get("right").getTypeAnnotation(); +} + +function UpdateExpression(node) { + var operator = node.operator; + + if (operator === "++" || operator === "--") { + return t.numberTypeAnnotation(); + } +} + +function StringLiteral() { + return t.stringTypeAnnotation(); +} + +function NumericLiteral() { + return t.numberTypeAnnotation(); +} + +function BooleanLiteral() { + return t.booleanTypeAnnotation(); +} + +function NullLiteral() { + return t.nullLiteralTypeAnnotation(); +} + +function RegExpLiteral() { + return t.genericTypeAnnotation(t.identifier("RegExp")); +} + +function ObjectExpression() { + return t.genericTypeAnnotation(t.identifier("Object")); +} + +function ArrayExpression() { + return t.genericTypeAnnotation(t.identifier("Array")); +} + +function RestElement() { + return ArrayExpression(); +} + +RestElement.validParent = true; + +function Func() { + return t.genericTypeAnnotation(t.identifier("Function")); +} + +var isArrayFrom = t.buildMatchMemberExpression("Array.from"); +var isObjectKeys = t.buildMatchMemberExpression("Object.keys"); +var isObjectValues = t.buildMatchMemberExpression("Object.values"); +var isObjectEntries = t.buildMatchMemberExpression("Object.entries"); + +function CallExpression() { + var callee = this.node.callee; + + if (isObjectKeys(callee)) { + return t.arrayTypeAnnotation(t.stringTypeAnnotation()); + } else if (isArrayFrom(callee) || isObjectValues(callee)) { + return t.arrayTypeAnnotation(t.anyTypeAnnotation()); + } else if (isObjectEntries(callee)) { + return t.arrayTypeAnnotation(t.tupleTypeAnnotation([t.stringTypeAnnotation(), t.anyTypeAnnotation()])); + } + + return resolveCall(this.get("callee")); +} + +function TaggedTemplateExpression() { + return resolveCall(this.get("tag")); +} + +function resolveCall(callee) { + callee = callee.resolve(); + + if (callee.isFunction()) { + if (callee.is("async")) { + if (callee.is("generator")) { + return t.genericTypeAnnotation(t.identifier("AsyncIterator")); + } else { + return t.genericTypeAnnotation(t.identifier("Promise")); + } + } else { + if (callee.node.returnType) { + return callee.node.returnType; + } else {} + } + } +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/introspection.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/introspection.js new file mode 100644 index 00000000000000..2ee6fb91a6f81c --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/introspection.js @@ -0,0 +1,361 @@ +"use strict"; + +exports.__esModule = true; +exports.matchesPattern = matchesPattern; +exports.has = has; +exports.isStatic = isStatic; +exports.isnt = isnt; +exports.equals = equals; +exports.isNodeType = isNodeType; +exports.canHaveVariableDeclarationOrExpression = canHaveVariableDeclarationOrExpression; +exports.canSwapBetweenExpressionAndStatement = canSwapBetweenExpressionAndStatement; +exports.isCompletionRecord = isCompletionRecord; +exports.isStatementOrBlock = isStatementOrBlock; +exports.referencesImport = referencesImport; +exports.getSource = getSource; +exports.willIMaybeExecuteBefore = willIMaybeExecuteBefore; +exports._guessExecutionStatusRelativeTo = _guessExecutionStatusRelativeTo; +exports._guessExecutionStatusRelativeToDifferentFunctions = _guessExecutionStatusRelativeToDifferentFunctions; +exports.resolve = resolve; +exports._resolve = _resolve; +exports.isConstantExpression = isConstantExpression; +exports.is = void 0; + +var _includes = _interopRequireDefault(require("lodash/includes")); + +var t = _interopRequireWildcard(require("@babel/types")); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function matchesPattern(pattern, allowPartial) { + return t.matchesPattern(this.node, pattern, allowPartial); +} + +function has(key) { + var val = this.node && this.node[key]; + + if (val && Array.isArray(val)) { + return !!val.length; + } else { + return !!val; + } +} + +function isStatic() { + return this.scope.isStatic(this.node); +} + +var is = has; +exports.is = is; + +function isnt(key) { + return !this.has(key); +} + +function equals(key, value) { + return this.node[key] === value; +} + +function isNodeType(type) { + return t.isType(this.type, type); +} + +function canHaveVariableDeclarationOrExpression() { + return (this.key === "init" || this.key === "left") && this.parentPath.isFor(); +} + +function canSwapBetweenExpressionAndStatement(replacement) { + if (this.key !== "body" || !this.parentPath.isArrowFunctionExpression()) { + return false; + } + + if (this.isExpression()) { + return t.isBlockStatement(replacement); + } else if (this.isBlockStatement()) { + return t.isExpression(replacement); + } + + return false; +} + +function isCompletionRecord(allowInsideFunction) { + var path = this; + var first = true; + + do { + var container = path.container; + + if (path.isFunction() && !first) { + return !!allowInsideFunction; + } + + first = false; + + if (Array.isArray(container) && path.key !== container.length - 1) { + return false; + } + } while ((path = path.parentPath) && !path.isProgram()); + + return true; +} + +function isStatementOrBlock() { + if (this.parentPath.isLabeledStatement() || t.isBlockStatement(this.container)) { + return false; + } else { + return (0, _includes.default)(t.STATEMENT_OR_BLOCK_KEYS, this.key); + } +} + +function referencesImport(moduleSource, importName) { + if (!this.isReferencedIdentifier()) return false; + var binding = this.scope.getBinding(this.node.name); + if (!binding || binding.kind !== "module") return false; + var path = binding.path; + var parent = path.parentPath; + if (!parent.isImportDeclaration()) return false; + + if (parent.node.source.value === moduleSource) { + if (!importName) return true; + } else { + return false; + } + + if (path.isImportDefaultSpecifier() && importName === "default") { + return true; + } + + if (path.isImportNamespaceSpecifier() && importName === "*") { + return true; + } + + if (path.isImportSpecifier() && path.node.imported.name === importName) { + return true; + } + + return false; +} + +function getSource() { + var node = this.node; + + if (node.end) { + return this.hub.file.code.slice(node.start, node.end); + } else { + return ""; + } +} + +function willIMaybeExecuteBefore(target) { + return this._guessExecutionStatusRelativeTo(target) !== "after"; +} + +function _guessExecutionStatusRelativeTo(target) { + var targetFuncParent = target.scope.getFunctionParent() || target.scope.getProgramParent(); + var selfFuncParent = this.scope.getFunctionParent() || target.scope.getProgramParent(); + + if (targetFuncParent.node !== selfFuncParent.node) { + var status = this._guessExecutionStatusRelativeToDifferentFunctions(targetFuncParent); + + if (status) { + return status; + } else { + target = targetFuncParent.path; + } + } + + var targetPaths = target.getAncestry(); + if (targetPaths.indexOf(this) >= 0) return "after"; + var selfPaths = this.getAncestry(); + var commonPath; + var targetIndex; + var selfIndex; + + for (selfIndex = 0; selfIndex < selfPaths.length; selfIndex++) { + var selfPath = selfPaths[selfIndex]; + targetIndex = targetPaths.indexOf(selfPath); + + if (targetIndex >= 0) { + commonPath = selfPath; + break; + } + } + + if (!commonPath) { + return "before"; + } + + var targetRelationship = targetPaths[targetIndex - 1]; + var selfRelationship = selfPaths[selfIndex - 1]; + + if (!targetRelationship || !selfRelationship) { + return "before"; + } + + if (targetRelationship.listKey && targetRelationship.container === selfRelationship.container) { + return targetRelationship.key > selfRelationship.key ? "before" : "after"; + } + + var keys = t.VISITOR_KEYS[commonPath.type]; + var targetKeyPosition = keys.indexOf(targetRelationship.key); + var selfKeyPosition = keys.indexOf(selfRelationship.key); + return targetKeyPosition > selfKeyPosition ? "before" : "after"; +} + +function _guessExecutionStatusRelativeToDifferentFunctions(targetFuncParent) { + var targetFuncPath = targetFuncParent.path; + if (!targetFuncPath.isFunctionDeclaration()) return; + var binding = targetFuncPath.scope.getBinding(targetFuncPath.node.id.name); + if (!binding.references) return "before"; + var referencePaths = binding.referencePaths; + + for (var _iterator = referencePaths, _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 _path2 = _ref; + + if (_path2.key !== "callee" || !_path2.parentPath.isCallExpression()) { + return; + } + } + + var allStatus; + + for (var _iterator2 = referencePaths, _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 _path3 = _ref2; + var childOfFunction = !!_path3.find(function (path) { + return path.node === targetFuncPath.node; + }); + if (childOfFunction) continue; + + var status = this._guessExecutionStatusRelativeTo(_path3); + + if (allStatus) { + if (allStatus !== status) return; + } else { + allStatus = status; + } + } + + return allStatus; +} + +function resolve(dangerous, resolved) { + return this._resolve(dangerous, resolved) || this; +} + +function _resolve(dangerous, resolved) { + if (resolved && resolved.indexOf(this) >= 0) return; + resolved = resolved || []; + resolved.push(this); + + if (this.isVariableDeclarator()) { + if (this.get("id").isIdentifier()) { + return this.get("init").resolve(dangerous, resolved); + } else {} + } else if (this.isReferencedIdentifier()) { + var binding = this.scope.getBinding(this.node.name); + if (!binding) return; + if (!binding.constant) return; + if (binding.kind === "module") return; + + if (binding.path !== this) { + var ret = binding.path.resolve(dangerous, resolved); + if (this.find(function (parent) { + return parent.node === ret.node; + })) return; + return ret; + } + } else if (this.isTypeCastExpression()) { + return this.get("expression").resolve(dangerous, resolved); + } else if (dangerous && this.isMemberExpression()) { + var targetKey = this.toComputedKey(); + if (!t.isLiteral(targetKey)) return; + var targetName = targetKey.value; + var target = this.get("object").resolve(dangerous, resolved); + + if (target.isObjectExpression()) { + var props = target.get("properties"); + var _arr = props; + + for (var _i3 = 0; _i3 < _arr.length; _i3++) { + var prop = _arr[_i3]; + if (!prop.isProperty()) continue; + var key = prop.get("key"); + var match = prop.isnt("computed") && key.isIdentifier({ + name: targetName + }); + match = match || key.isLiteral({ + value: targetName + }); + if (match) return prop.get("value").resolve(dangerous, resolved); + } + } else if (target.isArrayExpression() && !isNaN(+targetName)) { + var elems = target.get("elements"); + var elem = elems[targetName]; + if (elem) return elem.resolve(dangerous, resolved); + } + } +} + +function isConstantExpression() { + if (this.isIdentifier()) { + var binding = this.scope.getBinding(this.node.name); + + if (!binding) { + return false; + } + + return binding.constant && binding.path.get("init").isConstantExpression(); + } + + if (this.isLiteral()) { + if (this.isRegExpLiteral()) { + return false; + } + + if (this.isTemplateLiteral()) { + return this.get("expressions").every(function (expression) { + return expression.isConstantExpression(); + }); + } + + return true; + } + + if (this.isUnaryExpression()) { + if (this.get("operator").node !== "void") { + return false; + } + + return this.get("argument").isConstantExpression(); + } + + if (this.isBinaryExpression()) { + return this.get("left").isConstantExpression() && this.get("right").isConstantExpression(); + } + + return false; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/lib/hoister.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/lib/hoister.js new file mode 100644 index 00000000000000..ffec4e640347c6 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/lib/hoister.js @@ -0,0 +1,182 @@ +"use strict"; + +exports.__esModule = true; +exports.default = void 0; + +var t = _interopRequireWildcard(require("@babel/types")); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +var referenceVisitor = { + ReferencedIdentifier: function ReferencedIdentifier(path, state) { + if (path.isJSXIdentifier() && t.react.isCompatTag(path.node.name) && !path.parentPath.isJSXMemberExpression()) { + return; + } + + if (path.node.name === "this") { + var scope = path.scope; + + do { + if (scope.path.isFunction() && !scope.path.isArrowFunctionExpression()) { + break; + } + } while (scope = scope.parent); + + if (scope) state.breakOnScopePaths.push(scope.path); + } + + var binding = path.scope.getBinding(path.node.name); + if (!binding) return; + if (binding !== state.scope.getBinding(path.node.name)) return; + state.bindings[path.node.name] = binding; + } +}; + +var PathHoister = function () { + function PathHoister(path, scope) { + this.breakOnScopePaths = []; + this.bindings = {}; + this.scopes = []; + this.scope = scope; + this.path = path; + this.attachAfter = false; + } + + var _proto = PathHoister.prototype; + + _proto.isCompatibleScope = function isCompatibleScope(scope) { + for (var key in this.bindings) { + var binding = this.bindings[key]; + + if (!scope.bindingIdentifierEquals(key, binding.identifier)) { + return false; + } + } + + return true; + }; + + _proto.getCompatibleScopes = function getCompatibleScopes() { + var scope = this.path.scope; + + do { + if (this.isCompatibleScope(scope)) { + this.scopes.push(scope); + } else { + break; + } + + if (this.breakOnScopePaths.indexOf(scope.path) >= 0) { + break; + } + } while (scope = scope.parent); + }; + + _proto.getAttachmentPath = function getAttachmentPath() { + var path = this._getAttachmentPath(); + + if (!path) return; + var targetScope = path.scope; + + if (targetScope.path === path) { + targetScope = path.scope.parent; + } + + if (targetScope.path.isProgram() || targetScope.path.isFunction()) { + for (var name in this.bindings) { + if (!targetScope.hasOwnBinding(name)) continue; + var binding = this.bindings[name]; + + if (binding.kind === "param" || binding.path.parentKey === "params") { + continue; + } + + var bindingParentPath = this.getAttachmentParentForPath(binding.path); + + if (bindingParentPath.key >= path.key) { + this.attachAfter = true; + path = binding.path; + var _arr = binding.constantViolations; + + for (var _i = 0; _i < _arr.length; _i++) { + var violationPath = _arr[_i]; + + if (this.getAttachmentParentForPath(violationPath).key > path.key) { + path = violationPath; + } + } + } + } + } + + return path; + }; + + _proto._getAttachmentPath = function _getAttachmentPath() { + var scopes = this.scopes; + var scope = scopes.pop(); + if (!scope) return; + + if (scope.path.isFunction()) { + if (this.hasOwnParamBindings(scope)) { + if (this.scope === scope) return; + var bodies = scope.path.get("body").get("body"); + + for (var i = 0; i < bodies.length; i++) { + if (bodies[i].node._blockHoist) continue; + return bodies[i]; + } + } else { + return this.getNextScopeAttachmentParent(); + } + } else if (scope.path.isProgram()) { + return this.getNextScopeAttachmentParent(); + } + }; + + _proto.getNextScopeAttachmentParent = function getNextScopeAttachmentParent() { + var scope = this.scopes.pop(); + if (scope) return this.getAttachmentParentForPath(scope.path); + }; + + _proto.getAttachmentParentForPath = function getAttachmentParentForPath(path) { + do { + if (!path.parentPath || Array.isArray(path.container) && path.isStatement()) { + return path; + } + } while (path = path.parentPath); + }; + + _proto.hasOwnParamBindings = function hasOwnParamBindings(scope) { + for (var name in this.bindings) { + if (!scope.hasOwnBinding(name)) continue; + var binding = this.bindings[name]; + if (binding.kind === "param" && binding.constant) return true; + } + + return false; + }; + + _proto.run = function run() { + this.path.traverse(referenceVisitor, this); + this.getCompatibleScopes(); + var attachTo = this.getAttachmentPath(); + if (!attachTo) return; + if (attachTo.getFunctionParent() === this.path.getFunctionParent()) return; + var uid = attachTo.scope.generateUidIdentifier("ref"); + var declarator = t.variableDeclarator(uid, this.path.node); + var insertFn = this.attachAfter ? "insertAfter" : "insertBefore"; + attachTo[insertFn]([attachTo.isVariableDeclarator() ? declarator : t.variableDeclaration("var", [declarator])]); + var parent = this.path.parentPath; + + if (parent.isJSXElement() && this.path.container === parent.node.children) { + uid = t.JSXExpressionContainer(uid); + } + + this.path.replaceWith(uid); + }; + + return PathHoister; +}(); + +exports.default = PathHoister; \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/lib/removal-hooks.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/lib/removal-hooks.js new file mode 100644 index 00000000000000..79d5682f455225 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/lib/removal-hooks.js @@ -0,0 +1,36 @@ +"use strict"; + +exports.__esModule = true; +exports.hooks = void 0; +var hooks = [function (self, parent) { + var removeParent = self.key === "test" && (parent.isWhile() || parent.isSwitchCase()) || self.key === "declaration" && parent.isExportDeclaration() || self.key === "body" && parent.isLabeledStatement() || self.listKey === "declarations" && parent.isVariableDeclaration() && parent.node.declarations.length === 1 || self.key === "expression" && parent.isExpressionStatement(); + + if (removeParent) { + parent.remove(); + return true; + } +}, function (self, parent) { + if (parent.isSequenceExpression() && parent.node.expressions.length === 1) { + parent.replaceWith(parent.node.expressions[0]); + return true; + } +}, function (self, parent) { + if (parent.isBinary()) { + if (self.key === "left") { + parent.replaceWith(parent.node.right); + } else { + parent.replaceWith(parent.node.left); + } + + return true; + } +}, function (self, parent) { + if (parent.isIfStatement() && (self.key === "consequent" || self.key === "alternate") || self.key === "body" && (parent.isLoop() || parent.isArrowFunctionExpression())) { + self.replaceWith({ + type: "BlockStatement", + body: [] + }); + return true; + } +}]; +exports.hooks = hooks; \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/lib/virtual-types.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/lib/virtual-types.js new file mode 100644 index 00000000000000..4320201b9c0519 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/lib/virtual-types.js @@ -0,0 +1,172 @@ +"use strict"; + +exports.__esModule = true; +exports.ForAwaitStatement = exports.NumericLiteralTypeAnnotation = exports.ExistentialTypeParam = exports.SpreadProperty = exports.RestProperty = exports.Flow = exports.Pure = exports.Generated = exports.User = exports.Var = exports.BlockScoped = exports.Referenced = exports.Scope = exports.Expression = exports.Statement = exports.BindingIdentifier = exports.ReferencedMemberExpression = exports.ReferencedIdentifier = void 0; + +var t = _interopRequireWildcard(require("@babel/types")); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +var ReferencedIdentifier = { + types: ["Identifier", "JSXIdentifier"], + checkPath: function checkPath(_ref, opts) { + var node = _ref.node, + parent = _ref.parent; + + if (!t.isIdentifier(node, opts) && !t.isJSXMemberExpression(parent, opts)) { + if (t.isJSXIdentifier(node, opts)) { + if (t.react.isCompatTag(node.name)) return false; + } else { + return false; + } + } + + return t.isReferenced(node, parent); + } +}; +exports.ReferencedIdentifier = ReferencedIdentifier; +var ReferencedMemberExpression = { + types: ["MemberExpression"], + checkPath: function checkPath(_ref2) { + var node = _ref2.node, + parent = _ref2.parent; + return t.isMemberExpression(node) && t.isReferenced(node, parent); + } +}; +exports.ReferencedMemberExpression = ReferencedMemberExpression; +var BindingIdentifier = { + types: ["Identifier"], + checkPath: function checkPath(_ref3) { + var node = _ref3.node, + parent = _ref3.parent; + return t.isIdentifier(node) && t.isBinding(node, parent); + } +}; +exports.BindingIdentifier = BindingIdentifier; +var Statement = { + types: ["Statement"], + checkPath: function checkPath(_ref4) { + var node = _ref4.node, + parent = _ref4.parent; + + if (t.isStatement(node)) { + if (t.isVariableDeclaration(node)) { + if (t.isForXStatement(parent, { + left: node + })) return false; + if (t.isForStatement(parent, { + init: node + })) return false; + } + + return true; + } else { + return false; + } + } +}; +exports.Statement = Statement; +var Expression = { + types: ["Expression"], + checkPath: function checkPath(path) { + if (path.isIdentifier()) { + return path.isReferencedIdentifier(); + } else { + return t.isExpression(path.node); + } + } +}; +exports.Expression = Expression; +var Scope = { + types: ["Scopable"], + checkPath: function checkPath(path) { + return t.isScope(path.node, path.parent); + } +}; +exports.Scope = Scope; +var Referenced = { + checkPath: function checkPath(path) { + return t.isReferenced(path.node, path.parent); + } +}; +exports.Referenced = Referenced; +var BlockScoped = { + checkPath: function checkPath(path) { + return t.isBlockScoped(path.node); + } +}; +exports.BlockScoped = BlockScoped; +var Var = { + types: ["VariableDeclaration"], + checkPath: function checkPath(path) { + return t.isVar(path.node); + } +}; +exports.Var = Var; +var User = { + checkPath: function checkPath(path) { + return path.node && !!path.node.loc; + } +}; +exports.User = User; +var Generated = { + checkPath: function checkPath(path) { + return !path.isUser(); + } +}; +exports.Generated = Generated; +var Pure = { + checkPath: function checkPath(path, opts) { + return path.scope.isPure(path.node, opts); + } +}; +exports.Pure = Pure; +var Flow = { + types: ["Flow", "ImportDeclaration", "ExportDeclaration", "ImportSpecifier"], + checkPath: function checkPath(_ref5) { + var node = _ref5.node; + + if (t.isFlow(node)) { + return true; + } else if (t.isImportDeclaration(node)) { + return node.importKind === "type" || node.importKind === "typeof"; + } else if (t.isExportDeclaration(node)) { + return node.exportKind === "type"; + } else if (t.isImportSpecifier(node)) { + return node.importKind === "type" || node.importKind === "typeof"; + } else { + return false; + } + } +}; +exports.Flow = Flow; +var RestProperty = { + types: ["RestElement"], + checkPath: function checkPath(path) { + return path.parentPath && path.parentPath.isObjectPattern(); + } +}; +exports.RestProperty = RestProperty; +var SpreadProperty = { + types: ["RestElement"], + checkPath: function checkPath(path) { + return path.parentPath && path.parentPath.isObjectExpression(); + } +}; +exports.SpreadProperty = SpreadProperty; +var ExistentialTypeParam = { + types: ["ExistsTypeAnnotation"] +}; +exports.ExistentialTypeParam = ExistentialTypeParam; +var NumericLiteralTypeAnnotation = { + types: ["NumberLiteralTypeAnnotation"] +}; +exports.NumericLiteralTypeAnnotation = NumericLiteralTypeAnnotation; +var ForAwaitStatement = { + types: ["ForOfStatement"], + checkPath: function checkPath(_ref6) { + var node = _ref6.node; + return node.await === true; + } +}; +exports.ForAwaitStatement = ForAwaitStatement; \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/modification.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/modification.js new file mode 100644 index 00000000000000..5f09e17c6b266b --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/modification.js @@ -0,0 +1,216 @@ +"use strict"; + +exports.__esModule = true; +exports.insertBefore = insertBefore; +exports._containerInsert = _containerInsert; +exports._containerInsertBefore = _containerInsertBefore; +exports._containerInsertAfter = _containerInsertAfter; +exports.insertAfter = insertAfter; +exports.updateSiblingKeys = updateSiblingKeys; +exports._verifyNodeList = _verifyNodeList; +exports.unshiftContainer = unshiftContainer; +exports.pushContainer = pushContainer; +exports.hoist = hoist; + +var _cache = require("../cache"); + +var _hoister = _interopRequireDefault(require("./lib/hoister")); + +var _index = _interopRequireDefault(require("./index")); + +var t = _interopRequireWildcard(require("@babel/types")); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function insertBefore(nodes) { + this._assertUnremoved(); + + nodes = this._verifyNodeList(nodes); + + if (this.parentPath.isExpressionStatement() || this.parentPath.isLabeledStatement() || this.parentPath.isExportDeclaration()) { + return this.parentPath.insertBefore(nodes); + } else if (this.isNodeType("Expression") && this.listKey !== "params" && this.listKey !== "arguments" || this.parentPath.isForStatement() && this.key === "init") { + if (this.node) nodes.push(this.node); + return this.replaceExpressionWithStatements(nodes); + } else if (Array.isArray(this.container)) { + return this._containerInsertBefore(nodes); + } else if (this.isStatementOrBlock()) { + var shouldInsertCurrentNode = this.node && (!this.isExpressionStatement() || this.node.expression != null); + this.replaceWith(t.blockStatement(shouldInsertCurrentNode ? [this.node] : [])); + return this.unshiftContainer("body", nodes); + } else { + throw new Error("We don't know what to do with this node type. " + "We were previously a Statement but we can't fit in here?"); + } +} + +function _containerInsert(from, nodes) { + var _container; + + this.updateSiblingKeys(from, nodes.length); + var paths = []; + + (_container = this.container).splice.apply(_container, [from, 0].concat(nodes)); + + for (var i = 0; i < nodes.length; i++) { + var to = from + i; + var path = this.getSibling("" + to); + paths.push(path); + + if (this.context && this.context.queue) { + path.pushContext(this.context); + } + } + + var contexts = this._getQueueContexts(); + + for (var _i = 0; _i < paths.length; _i++) { + var _path = paths[_i]; + + _path.setScope(); + + _path.debug("Inserted."); + + for (var _iterator = contexts, _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 _context = _ref; + + _context.maybeQueue(_path, true); + } + } + + return paths; +} + +function _containerInsertBefore(nodes) { + return this._containerInsert(this.key, nodes); +} + +function _containerInsertAfter(nodes) { + return this._containerInsert(this.key + 1, nodes); +} + +function insertAfter(nodes) { + this._assertUnremoved(); + + nodes = this._verifyNodeList(nodes); + + if (this.parentPath.isExpressionStatement() || this.parentPath.isLabeledStatement() || this.parentPath.isExportDeclaration()) { + return this.parentPath.insertAfter(nodes); + } else if (this.isNodeType("Expression") || this.parentPath.isForStatement() && this.key === "init") { + if (this.node) { + var temp = this.scope.generateDeclaredUidIdentifier(); + nodes.unshift(t.expressionStatement(t.assignmentExpression("=", temp, this.node))); + nodes.push(t.expressionStatement(temp)); + } + + return this.replaceExpressionWithStatements(nodes); + } else if (Array.isArray(this.container)) { + return this._containerInsertAfter(nodes); + } else if (this.isStatementOrBlock()) { + var shouldInsertCurrentNode = this.node && (!this.isExpressionStatement() || this.node.expression != null); + this.replaceWith(t.blockStatement(shouldInsertCurrentNode ? [this.node] : [])); + return this.pushContainer("body", nodes); + } else { + throw new Error("We don't know what to do with this node type. " + "We were previously a Statement but we can't fit in here?"); + } +} + +function updateSiblingKeys(fromIndex, incrementBy) { + if (!this.parent) return; + + var paths = _cache.path.get(this.parent); + + for (var i = 0; i < paths.length; i++) { + var path = paths[i]; + + if (path.key >= fromIndex) { + path.key += incrementBy; + } + } +} + +function _verifyNodeList(nodes) { + if (!nodes) { + return []; + } + + if (nodes.constructor !== Array) { + nodes = [nodes]; + } + + for (var i = 0; i < nodes.length; i++) { + var node = nodes[i]; + var msg = void 0; + + if (!node) { + msg = "has falsy node"; + } else if (typeof node !== "object") { + msg = "contains a non-object node"; + } else if (!node.type) { + msg = "without a type"; + } else if (node instanceof _index.default) { + msg = "has a NodePath when it expected a raw object"; + } + + if (msg) { + var type = Array.isArray(node) ? "array" : typeof node; + throw new Error("Node list " + msg + " with the index of " + i + " and type of " + type); + } + } + + return nodes; +} + +function unshiftContainer(listKey, nodes) { + this._assertUnremoved(); + + nodes = this._verifyNodeList(nodes); + + var path = _index.default.get({ + parentPath: this, + parent: this.node, + container: this.node[listKey], + listKey: listKey, + key: 0 + }); + + return path.insertBefore(nodes); +} + +function pushContainer(listKey, nodes) { + this._assertUnremoved(); + + nodes = this._verifyNodeList(nodes); + var container = this.node[listKey]; + + var path = _index.default.get({ + parentPath: this, + parent: this.node, + container: container, + listKey: listKey, + key: container.length + }); + + return path.replaceWithMultiple(nodes); +} + +function hoist(scope) { + if (scope === void 0) { + scope = this.scope; + } + + var hoister = new _hoister.default(this, scope); + return hoister.run(); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/removal.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/removal.js new file mode 100644 index 00000000000000..cca923f6625b28 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/removal.js @@ -0,0 +1,58 @@ +"use strict"; + +exports.__esModule = true; +exports.remove = remove; +exports._callRemovalHooks = _callRemovalHooks; +exports._remove = _remove; +exports._markRemoved = _markRemoved; +exports._assertUnremoved = _assertUnremoved; + +var _removalHooks = require("./lib/removal-hooks"); + +function remove() { + this._assertUnremoved(); + + this.resync(); + + if (this._callRemovalHooks()) { + this._markRemoved(); + + return; + } + + this.shareCommentsWithSiblings(); + + this._remove(); + + this._markRemoved(); +} + +function _callRemovalHooks() { + var _arr = _removalHooks.hooks; + + for (var _i = 0; _i < _arr.length; _i++) { + var fn = _arr[_i]; + if (fn(this, this.parentPath)) return true; + } +} + +function _remove() { + if (Array.isArray(this.container)) { + this.container.splice(this.key, 1); + this.updateSiblingKeys(this.key, -1); + } else { + this._replaceWith(null); + } +} + +function _markRemoved() { + this.shouldSkip = true; + this.removed = true; + this.node = null; +} + +function _assertUnremoved() { + if (this.removed) { + throw this.buildCodeFrameError("NodePath has been removed so is read-only."); + } +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/replacement.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/replacement.js new file mode 100644 index 00000000000000..01558373bd1afc --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/path/replacement.js @@ -0,0 +1,251 @@ +"use strict"; + +exports.__esModule = true; +exports.replaceWithMultiple = replaceWithMultiple; +exports.replaceWithSourceString = replaceWithSourceString; +exports.replaceWith = replaceWith; +exports._replaceWith = _replaceWith; +exports.replaceExpressionWithStatements = replaceExpressionWithStatements; +exports.replaceInline = replaceInline; + +var _codeFrame = require("@babel/code-frame"); + +var _index = _interopRequireDefault(require("../index")); + +var _index2 = _interopRequireDefault(require("./index")); + +var _babylon = require("babylon"); + +var t = _interopRequireWildcard(require("@babel/types")); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +var hoistVariablesVisitor = { + Function: function Function(path) { + path.skip(); + }, + VariableDeclaration: function VariableDeclaration(path) { + if (path.node.kind !== "var") return; + var bindings = path.getBindingIdentifiers(); + + for (var key in bindings) { + path.scope.push({ + id: bindings[key] + }); + } + + var exprs = []; + var _arr = path.node.declarations; + + for (var _i = 0; _i < _arr.length; _i++) { + var declar = _arr[_i]; + + if (declar.init) { + exprs.push(t.expressionStatement(t.assignmentExpression("=", declar.id, declar.init))); + } + } + + path.replaceWithMultiple(exprs); + } +}; + +function replaceWithMultiple(nodes) { + this.resync(); + nodes = this._verifyNodeList(nodes); + t.inheritLeadingComments(nodes[0], this.node); + t.inheritTrailingComments(nodes[nodes.length - 1], this.node); + this.node = this.container[this.key] = null; + var paths = this.insertAfter(nodes); + + if (this.node) { + this.requeue(); + } else { + this.remove(); + } + + return paths; +} + +function replaceWithSourceString(replacement) { + this.resync(); + + try { + replacement = "(" + replacement + ")"; + replacement = (0, _babylon.parse)(replacement); + } catch (err) { + var loc = err.loc; + + if (loc) { + err.loc = null; + err.message += " - make sure this is an expression.\n" + (0, _codeFrame.codeFrameColumns)(replacement, { + start: { + line: loc.line, + column: loc.column + 1 + } + }); + } + + throw err; + } + + replacement = replacement.program.body[0].expression; + + _index.default.removeProperties(replacement); + + return this.replaceWith(replacement); +} + +function replaceWith(replacement) { + this.resync(); + + if (this.removed) { + throw new Error("You can't replace this node, we've already removed it"); + } + + if (replacement instanceof _index2.default) { + replacement = replacement.node; + } + + if (!replacement) { + throw new Error("You passed `path.replaceWith()` a falsy node, use `path.remove()` instead"); + } + + if (this.node === replacement) { + return [this]; + } + + if (this.isProgram() && !t.isProgram(replacement)) { + throw new Error("You can only replace a Program root node with another Program node"); + } + + if (Array.isArray(replacement)) { + throw new Error("Don't use `path.replaceWith()` with an array of nodes, use `path.replaceWithMultiple()`"); + } + + if (typeof replacement === "string") { + throw new Error("Don't use `path.replaceWith()` with a source string, use `path.replaceWithSourceString()`"); + } + + var nodePath = ""; + + if (this.isNodeType("Statement") && t.isExpression(replacement)) { + if (!this.canHaveVariableDeclarationOrExpression() && !this.canSwapBetweenExpressionAndStatement(replacement) && !this.parentPath.isExportDefaultDeclaration()) { + replacement = t.expressionStatement(replacement); + nodePath = "expression"; + } + } + + if (this.isNodeType("Expression") && t.isStatement(replacement)) { + if (!this.canHaveVariableDeclarationOrExpression() && !this.canSwapBetweenExpressionAndStatement(replacement)) { + return this.replaceExpressionWithStatements([replacement]); + } + } + + var oldNode = this.node; + + if (oldNode) { + t.inheritsComments(replacement, oldNode); + t.removeComments(oldNode); + } + + this._replaceWith(replacement); + + this.type = replacement.type; + this.setScope(); + this.requeue(); + return [nodePath ? this.get(nodePath) : this]; +} + +function _replaceWith(node) { + if (!this.container) { + throw new ReferenceError("Container is falsy"); + } + + if (this.inList) { + t.validate(this.parent, this.key, [node]); + } else { + t.validate(this.parent, this.key, node); + } + + this.debug("Replace with " + (node && node.type)); + this.node = this.container[this.key] = node; +} + +function replaceExpressionWithStatements(nodes) { + this.resync(); + var toSequenceExpression = t.toSequenceExpression(nodes, this.scope); + + if (toSequenceExpression) { + return this.replaceWith(toSequenceExpression)[0].get("expressions"); + } + + var container = t.arrowFunctionExpression([], t.blockStatement(nodes)); + this.replaceWith(t.callExpression(container, [])); + this.traverse(hoistVariablesVisitor); + var completionRecords = this.get("callee").getCompletionRecords(); + + for (var _iterator = completionRecords, _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 _path = _ref; + if (!_path.isExpressionStatement()) continue; + + var loop = _path.findParent(function (path) { + return path.isLoop(); + }); + + if (loop) { + var uid = loop.getData("expressionReplacementReturnUid"); + + if (!uid) { + var _callee = this.get("callee"); + + uid = _callee.scope.generateDeclaredUidIdentifier("ret"); + + _callee.get("body").pushContainer("body", t.returnStatement(uid)); + + loop.setData("expressionReplacementReturnUid", uid); + } else { + uid = t.identifier(uid.name); + } + + _path.get("expression").replaceWith(t.assignmentExpression("=", uid, _path.node.expression)); + } else { + _path.replaceWith(t.returnStatement(_path.node.expression)); + } + } + + var callee = this.get("callee"); + callee.arrowFunctionToExpression(); + return callee.get("body.body"); +} + +function replaceInline(nodes) { + this.resync(); + + if (Array.isArray(nodes)) { + if (Array.isArray(this.container)) { + nodes = this._verifyNodeList(nodes); + + var paths = this._containerInsertAfter(nodes); + + this.remove(); + return paths; + } else { + return this.replaceWithMultiple(nodes); + } + } else { + return this.replaceWith(nodes); + } +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/scope/binding.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/scope/binding.js new file mode 100644 index 00000000000000..7f8c3a2f85f46f --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/scope/binding.js @@ -0,0 +1,79 @@ +"use strict"; + +exports.__esModule = true; +exports.default = void 0; + +var Binding = function () { + function Binding(_ref) { + var identifier = _ref.identifier, + scope = _ref.scope, + path = _ref.path, + kind = _ref.kind; + this.constantViolations = void 0; + this.constant = void 0; + this.referencePaths = void 0; + this.referenced = void 0; + this.references = void 0; + this.hasDeoptedValue = void 0; + this.hasValue = void 0; + this.value = void 0; + 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; +}(); + +exports.default = Binding; \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/scope/index.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/scope/index.js new file mode 100644 index 00000000000000..70b656b7abaaa7 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/scope/index.js @@ -0,0 +1,970 @@ +"use strict"; + +exports.__esModule = true; +exports.default = void 0; + +var _includes = _interopRequireDefault(require("lodash/includes")); + +var _repeat = _interopRequireDefault(require("lodash/repeat")); + +var _renamer = _interopRequireDefault(require("./lib/renamer")); + +var _index = _interopRequireDefault(require("../index")); + +var _defaults = _interopRequireDefault(require("lodash/defaults")); + +var _binding2 = _interopRequireDefault(require("./binding")); + +var _globals = _interopRequireDefault(require("globals")); + +var t = _interopRequireWildcard(require("@babel/types")); + +var _cache = require("../cache"); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +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 gatherNodeParts(node, parts) { + if (t.isModuleDeclaration(node)) { + if (node.source) { + gatherNodeParts(node.source, parts); + } else if (node.specifiers && node.specifiers.length) { + var _arr = node.specifiers; + + for (var _i = 0; _i < _arr.length; _i++) { + var specifier = _arr[_i]; + gatherNodeParts(specifier, parts); + } + } else if (node.declaration) { + gatherNodeParts(node.declaration, parts); + } + } else if (t.isModuleSpecifier(node)) { + gatherNodeParts(node.local, parts); + } else if (t.isMemberExpression(node)) { + gatherNodeParts(node.object, parts); + gatherNodeParts(node.property, parts); + } else if (t.isIdentifier(node)) { + parts.push(node.name); + } else if (t.isLiteral(node)) { + parts.push(node.value); + } else if (t.isCallExpression(node)) { + gatherNodeParts(node.callee, parts); + } else if (t.isObjectExpression(node) || t.isObjectPattern(node)) { + var _arr2 = node.properties; + + for (var _i2 = 0; _i2 < _arr2.length; _i2++) { + var prop = _arr2[_i2]; + gatherNodeParts(prop.key || prop.argument, parts); + } + } +} + +var collectorVisitor = { + For: function For(path) { + var _arr3 = t.FOR_INIT_KEYS; + + for (var _i3 = 0; _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 (t.isClassDeclaration(declar) || t.isFunctionDeclaration(declar)) { + var _id = declar.id; + if (!_id) return; + var binding = scope.getBinding(_id.name); + if (binding) binding.reference(path); + } else if (t.isVariableDeclaration(declar)) { + var _arr4 = declar.declarations; + + for (var _i4 = 0; _i4 < _arr4.length; _i4++) { + var decl = _arr4[_i4]; + var ids = t.getBindingIdentifiers(decl); + + for (var name in ids) { + 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"); + var _arr5 = paths; + + for (var _i5 = 0; _i5 < _arr5.length; _i5++) { + var bodyPath = _arr5[_i5]; + + if (bodyPath.isFunctionDeclaration()) { + path.scope.getBlockParent().registerDeclaration(bodyPath); + } + } + } +}; +var uid = 0; + +var Scope = function () { + function Scope(path) { + var node = path.node; + + var cached = _cache.scope.get(node); + + if (cached && cached.path === path) { + return cached; + } + + _cache.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) { + (0, _index.default)(node, opts, this, state, this.path); + }; + + _proto.generateDeclaredUidIdentifier = function generateDeclaredUidIdentifier(name) { + if (name === void 0) { + name = "temp"; + } + + var id = this.generateUidIdentifier(name); + this.push({ + id: id + }); + return id; + }; + + _proto.generateUidIdentifier = function generateUidIdentifier(name) { + if (name === void 0) { + name = "temp"; + } + + return t.identifier(this.generateUid(name)); + }; + + _proto.generateUid = function generateUid(name) { + if (name === void 0) { + name = "temp"; + } + + name = t.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.generateUidIdentifierBasedOnNode = function generateUidIdentifierBasedOnNode(parent, defaultName) { + var node = parent; + + if (t.isAssignmentExpression(parent)) { + node = parent.left; + } else if (t.isVariableDeclarator(parent)) { + node = parent.id; + } else if (t.isObjectProperty(node) || t.isObjectMethod(node)) { + node = node.key; + } + + var parts = []; + gatherNodeParts(node, parts); + var id = parts.join("$"); + id = id.replace(/^_/, "") || defaultName || "ref"; + return this.generateUidIdentifier(id.slice(0, 20)); + }; + + _proto.isStatic = function isStatic(node) { + if (t.isThisExpression(node) || t.isSuper(node)) { + return true; + } + + if (t.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 _id2 = this.generateUidIdentifierBasedOnNode(node); + + if (!dontPush) this.push({ + id: _id2 + }); + return _id2; + } + }; + + _proto.checkBlockScopedCollisions = function checkBlockScopedCollisions(local, kind, name, id) { + if (kind === "param") return; + if (local.kind === "local") return; + if (kind === "hoisted" && local.kind === "let") 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.file.buildCodeFrameError(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.default(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 = (0, _repeat.default)("-", 60); + console.log(sep); + var scope = this; + + do { + console.log("#", scope.block.type); + + for (var name in scope.bindings) { + 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) { + var file = this.hub.file; + + if (t.isIdentifier(node)) { + var binding = this.getBinding(node.name); + + if (binding && binding.constant && binding.path.isGenericType("Array")) { + return node; + } + } + + if (t.isArrayExpression(node)) { + return node; + } + + if (t.isIdentifier(node, { + name: "arguments" + })) { + return t.callExpression(t.memberExpression(t.memberExpression(t.memberExpression(t.identifier("Array"), t.identifier("prototype")), t.identifier("slice")), t.identifier("call")), [node]); + } + + var helperName = "toArray"; + var args = [node]; + + if (i === true) { + helperName = "toConsumableArray"; + } else if (i) { + args.push(t.numericLiteral(i)); + helperName = "slicedToArray"; + } + + return t.callExpression(file.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.isFlow()) return; + + 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"); + var _arr6 = declarations; + + for (var _i6 = 0; _i6 < _arr6.length; _i6++) { + var declar = _arr6[_i6]; + this.registerBinding(path.node.kind, declar); + } + } else if (path.isClassDeclaration()) { + this.registerBinding("let", path); + } else if (path.isImportDeclaration()) { + var specifiers = path.get("specifiers"); + var _arr7 = specifiers; + + for (var _i7 = 0; _i7 < _arr7.length; _i7++) { + var specifier = _arr7[_i7]; + 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() { + if (this.hasBinding("undefined")) { + return t.unaryExpression("void", t.numericLiteral(0), true); + } else { + return t.identifier("undefined"); + } + }; + + _proto.registerConstantViolation = function registerConstantViolation(path) { + var ids = path.getBindingIdentifiers(); + + for (var name in ids) { + 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), _i8 = 0, _iterator = _isArray ? _iterator : _iterator[Symbol.iterator]();;) { + var _ref; + + if (_isArray) { + if (_i8 >= _iterator.length) break; + _ref = _iterator[_i8++]; + } else { + _i8 = _iterator.next(); + if (_i8.done) break; + _ref = _i8.value; + } + + var _declar2 = _ref; + this.registerBinding(kind, _declar2); + } + + return; + } + + var parent = this.getProgramParent(); + var ids = path.getBindingIdentifiers(true); + + for (var name in ids) { + var _arr8 = ids[name]; + + for (var _i9 = 0; _i9 < _arr8.length; _i9++) { + var _id3 = _arr8[_i9]; + var local = this.getOwnBinding(name); + + if (local) { + if (local.identifier === _id3) continue; + this.checkBlockScopedCollisions(local, kind, name, _id3); + } + + parent.references[name] = true; + + if (local) { + this.registerConstantViolation(bindingPath); + } else { + this.bindings[name] = new _binding2.default({ + identifier: _id3, + 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 (t.isIdentifier(node)) { + var binding = this.getBinding(node.name); + if (!binding) return false; + if (constantsOnly) return binding.constant; + return true; + } else if (t.isClass(node)) { + if (node.superClass && !this.isPure(node.superClass, constantsOnly)) { + return false; + } + + return this.isPure(node.body, constantsOnly); + } else if (t.isClassBody(node)) { + for (var _iterator2 = node.body, _isArray2 = Array.isArray(_iterator2), _i10 = 0, _iterator2 = _isArray2 ? _iterator2 : _iterator2[Symbol.iterator]();;) { + var _ref2; + + if (_isArray2) { + if (_i10 >= _iterator2.length) break; + _ref2 = _iterator2[_i10++]; + } else { + _i10 = _iterator2.next(); + if (_i10.done) break; + _ref2 = _i10.value; + } + + var _method = _ref2; + if (!this.isPure(_method, constantsOnly)) return false; + } + + return true; + } else if (t.isBinary(node)) { + return this.isPure(node.left, constantsOnly) && this.isPure(node.right, constantsOnly); + } else if (t.isArrayExpression(node)) { + var _arr9 = node.elements; + + for (var _i11 = 0; _i11 < _arr9.length; _i11++) { + var elem = _arr9[_i11]; + if (!this.isPure(elem, constantsOnly)) return false; + } + + return true; + } else if (t.isObjectExpression(node)) { + var _arr10 = node.properties; + + for (var _i12 = 0; _i12 < _arr10.length; _i12++) { + var prop = _arr10[_i12]; + if (!this.isPure(prop, constantsOnly)) return false; + } + + return true; + } else if (t.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 (t.isClassProperty(node) || t.isObjectProperty(node)) { + if (node.computed && !this.isPure(node.key, constantsOnly)) return false; + return this.isPure(node.value, constantsOnly); + } else if (t.isUnaryExpression(node)) { + return this.isPure(node.argument, constantsOnly); + } else if (t.isTaggedTemplateExpression(node)) { + return t.matchesPattern(node.tag, "String.raw") && !this.hasBinding("String", true) && this.isPure(node.quasi, constantsOnly); + } else if (t.isTemplateLiteral(node)) { + var _arr11 = node.expressions; + + for (var _i13 = 0; _i13 < _arr11.length; _i13++) { + var expression = _arr11[_i13]; + if (!this.isPure(expression, constantsOnly)) return false; + } + + return true; + } else { + return t.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()) { + var _arr12 = t.FOR_INIT_KEYS; + + for (var _i14 = 0; _i14 < _arr12.length; _i14++) { + var key = _arr12[_i14]; + 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[t.NOT_LOCAL_BINDING]) { + this.registerBinding("local", path.get("id"), path); + } + } + + if (path.isClassExpression() && path.has("id")) { + if (!path.get("id").node[t.NOT_LOCAL_BINDING]) { + this.registerBinding("local", path); + } + } + + if (path.isFunction()) { + var params = path.get("params"); + + for (var _iterator3 = params, _isArray3 = Array.isArray(_iterator3), _i15 = 0, _iterator3 = _isArray3 ? _iterator3 : _iterator3[Symbol.iterator]();;) { + var _ref3; + + if (_isArray3) { + if (_i15 >= _iterator3.length) break; + _ref3 = _iterator3[_i15++]; + } else { + _i15 = _iterator3.next(); + if (_i15.done) break; + _ref3 = _i15.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), _i16 = 0, _iterator4 = _isArray4 ? _iterator4 : _iterator4[Symbol.iterator]();;) { + var _ref4; + + if (_isArray4) { + if (_i16 >= _iterator4.length) break; + _ref4 = _iterator4[_i16++]; + } else { + _i16 = _iterator4.next(); + if (_i16.done) break; + _ref4 = _i16.value; + } + + var _path3 = _ref4; + + var ids = _path3.getBindingIdentifiers(); + + var programParent = void 0; + + for (var name in ids) { + if (_path3.scope.getBinding(name)) continue; + programParent = programParent || _path3.scope.getProgramParent(); + programParent.addGlobal(ids[name]); + } + + _path3.scope.registerConstantViolation(_path3); + } + + for (var _iterator5 = state.references, _isArray5 = Array.isArray(_iterator5), _i17 = 0, _iterator5 = _isArray5 ? _iterator5 : _iterator5[Symbol.iterator]();;) { + var _ref5; + + if (_isArray5) { + if (_i17 >= _iterator5.length) break; + _ref5 = _iterator5[_i17++]; + } else { + _i17 = _iterator5.next(); + if (_i17.done) break; + _ref5 = _i17.value; + } + + var _ref7 = _ref5; + + var binding = _ref7.scope.getBinding(_ref7.node.name); + + if (binding) { + binding.reference(_ref7); + } else { + _ref7.scope.getProgramParent().addGlobal(_ref7.node); + } + } + + for (var _iterator6 = state.constantViolations, _isArray6 = Array.isArray(_iterator6), _i18 = 0, _iterator6 = _isArray6 ? _iterator6 : _iterator6[Symbol.iterator]();;) { + var _ref6; + + if (_isArray6) { + if (_i18 >= _iterator6.length) break; + _ref6 = _iterator6[_i18++]; + } else { + _i18 = _iterator6.next(); + if (_i18.done) break; + _ref6 = _i18.value; + } + + var _path4 = _ref6; + + _path4.scope.registerConstantViolation(_path4); + } + }; + + _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 = t.variableDeclaration(kind, []); + declar._blockHoist = blockHoist; + + var _path$unshiftContaine = path.unshiftContainer("body", [declar]); + + declarPath = _path$unshiftContaine[0]; + if (!unique) path.setData(dataKey, declarPath); + } + + var declarator = t.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 { + (0, _defaults.default)(ids, scope.bindings); + scope = scope.parent; + } while (scope); + + return ids; + }; + + _proto.getAllBindingsOfKind = function getAllBindingsOfKind() { + var ids = Object.create(null); + var _arr13 = arguments; + + for (var _i19 = 0; _i19 < _arr13.length; _i19++) { + var kind = _arr13[_i19]; + var scope = this; + + do { + for (var name in scope.bindings) { + 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; + + do { + var binding = scope.getOwnBinding(name); + if (binding) return binding; + } 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 && (0, _includes.default)(Scope.globals, name)) return true; + if (!noGlobals && (0, _includes.default)(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; +}(); + +exports.default = Scope; +Scope.globals = Object.keys(_globals.default.builtin); +Scope.contextVariables = ["arguments", "undefined", "Infinity", "NaN"]; \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/scope/lib/renamer.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/scope/lib/renamer.js new file mode 100644 index 00000000000000..4d5816663d0de0 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/scope/lib/renamer.js @@ -0,0 +1,131 @@ +"use strict"; + +exports.__esModule = true; +exports.default = void 0; + +var _binding = _interopRequireDefault(require("../binding")); + +var t = _interopRequireWildcard(require("@babel/types")); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +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.oldName = void 0; + this.newName = void 0; + this.binding = void 0; + this.newName = newName; + this.oldName = oldName; + this.binding = binding; + } + + var _proto = Renamer.prototype; + + _proto.maybeConvertFromExportDeclaration = function maybeConvertFromExportDeclaration(parentDeclar) { + var exportDeclar = parentDeclar.parentPath.isExportDeclaration() && parentDeclar.parentPath; + if (!exportDeclar) return; + var isDefault = exportDeclar.isExportDefaultDeclaration(); + + if (isDefault && (parentDeclar.isFunctionDeclaration() || parentDeclar.isClassDeclaration()) && !parentDeclar.node.id) { + parentDeclar.node.id = parentDeclar.scope.generateUidIdentifier("default"); + } + + var bindingIdentifiers = parentDeclar.getOuterBindingIdentifiers(); + var specifiers = []; + + for (var name in bindingIdentifiers) { + var localName = name === this.oldName ? this.newName : name; + var exportedName = isDefault ? "default" : name; + specifiers.push(t.exportSpecifier(t.identifier(localName), t.identifier(exportedName))); + } + + if (specifiers.length) { + var aliasDeclar = t.exportNamedDeclaration(null, specifiers); + + if (parentDeclar.isFunctionDeclaration()) { + aliasDeclar._blockHoist = 3; + } + + exportDeclar.insertAfter(aliasDeclar); + exportDeclar.replaceWith(parentDeclar.node); + } + }; + + _proto.maybeConvertFromClassFunctionDeclaration = function maybeConvertFromClassFunctionDeclaration(path) { + return; + if (!path.isFunctionDeclaration() && !path.isClassDeclaration()) return; + if (this.binding.kind !== "hoisted") return; + path.node.id = t.identifier(this.oldName); + path.node._blockHoist = 3; + path.replaceWith(t.variableDeclaration("let", [t.variableDeclarator(t.identifier(this.newName), t.toExpression(path.node))])); + }; + + _proto.maybeConvertFromClassFunctionExpression = function maybeConvertFromClassFunctionExpression(path) { + return; + if (!path.isFunctionExpression() && !path.isClassExpression()) return; + if (this.binding.kind !== "local") return; + path.node.id = t.identifier(this.oldName); + this.binding.scope.parent.push({ + id: t.identifier(this.newName) + }); + path.replaceWith(t.assignmentExpression("=", t.identifier(this.newName), path.node)); + }; + + _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(); + }); + + if (parentDeclar) { + 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; +}(); + +exports.default = Renamer; \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/visitors.js b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/visitors.js new file mode 100644 index 00000000000000..ae53c474bbea3c --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/lib/visitors.js @@ -0,0 +1,292 @@ +"use strict"; + +exports.__esModule = true; +exports.explode = explode; +exports.verify = verify; +exports.merge = merge; + +var virtualTypes = _interopRequireWildcard(require("./path/lib/virtual-types")); + +var t = _interopRequireWildcard(require("@babel/types")); + +var _clone = _interopRequireDefault(require("lodash/clone")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +function explode(visitor) { + if (visitor._exploded) return visitor; + visitor._exploded = true; + + for (var nodeType in visitor) { + if (shouldIgnoreKey(nodeType)) continue; + var parts = nodeType.split("|"); + if (parts.length === 1) continue; + var fns = visitor[nodeType]; + delete visitor[nodeType]; + + for (var _iterator = parts, _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 _part = _ref; + visitor[_part] = fns; + } + } + + verify(visitor); + delete visitor.__esModule; + ensureEntranceObjects(visitor); + ensureCallbackArrays(visitor); + + var _arr = Object.keys(visitor); + + for (var _i2 = 0; _i2 < _arr.length; _i2++) { + var _nodeType = _arr[_i2]; + if (shouldIgnoreKey(_nodeType)) continue; + var wrapper = virtualTypes[_nodeType]; + if (!wrapper) continue; + var _fns = visitor[_nodeType]; + + for (var type in _fns) { + _fns[type] = wrapCheck(wrapper, _fns[type]); + } + + delete visitor[_nodeType]; + + if (wrapper.types) { + var _arr2 = wrapper.types; + + for (var _i4 = 0; _i4 < _arr2.length; _i4++) { + var _type = _arr2[_i4]; + + if (visitor[_type]) { + mergePair(visitor[_type], _fns); + } else { + visitor[_type] = _fns; + } + } + } else { + mergePair(visitor, _fns); + } + } + + for (var _nodeType2 in visitor) { + if (shouldIgnoreKey(_nodeType2)) continue; + var _fns2 = visitor[_nodeType2]; + var aliases = t.FLIPPED_ALIAS_KEYS[_nodeType2]; + var deprecratedKey = t.DEPRECATED_KEYS[_nodeType2]; + + if (deprecratedKey) { + console.trace("Visitor defined for " + _nodeType2 + " but it has been renamed to " + deprecratedKey); + aliases = [deprecratedKey]; + } + + if (!aliases) continue; + delete visitor[_nodeType2]; + + for (var _iterator2 = aliases, _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 _alias = _ref2; + var existing = visitor[_alias]; + + if (existing) { + mergePair(existing, _fns2); + } else { + visitor[_alias] = (0, _clone.default)(_fns2); + } + } + } + + for (var _nodeType3 in visitor) { + if (shouldIgnoreKey(_nodeType3)) continue; + ensureCallbackArrays(visitor[_nodeType3]); + } + + return visitor; +} + +function verify(visitor) { + if (visitor._verified) return; + + if (typeof visitor === "function") { + throw new Error("You passed `traverse()` a function when it expected a visitor object, " + "are you sure you didn't mean `{ enter: Function }`?"); + } + + for (var nodeType in visitor) { + if (nodeType === "enter" || nodeType === "exit") { + validateVisitorMethods(nodeType, visitor[nodeType]); + } + + if (shouldIgnoreKey(nodeType)) continue; + + if (t.TYPES.indexOf(nodeType) < 0) { + throw new Error("You gave us a visitor for the node type " + nodeType + " but it's not a valid type"); + } + + var visitors = visitor[nodeType]; + + if (typeof visitors === "object") { + for (var visitorKey in visitors) { + if (visitorKey === "enter" || visitorKey === "exit") { + validateVisitorMethods(nodeType + "." + visitorKey, visitors[visitorKey]); + } else { + throw new Error("You passed `traverse()` a visitor object with the property " + (nodeType + " that has the invalid property " + visitorKey)); + } + } + } + } + + visitor._verified = true; +} + +function validateVisitorMethods(path, val) { + var fns = [].concat(val); + + for (var _iterator3 = fns, _isArray3 = Array.isArray(_iterator3), _i5 = 0, _iterator3 = _isArray3 ? _iterator3 : _iterator3[Symbol.iterator]();;) { + var _ref3; + + if (_isArray3) { + if (_i5 >= _iterator3.length) break; + _ref3 = _iterator3[_i5++]; + } else { + _i5 = _iterator3.next(); + if (_i5.done) break; + _ref3 = _i5.value; + } + + var _fn = _ref3; + + if (typeof _fn !== "function") { + throw new TypeError("Non-function found defined in " + path + " with type " + typeof _fn); + } + } +} + +function merge(visitors, states, wrapper) { + if (states === void 0) { + states = []; + } + + var rootVisitor = {}; + + for (var i = 0; i < visitors.length; i++) { + var visitor = visitors[i]; + var state = states[i]; + explode(visitor); + + for (var type in visitor) { + var visitorType = visitor[type]; + + if (state || wrapper) { + visitorType = wrapWithStateOrWrapper(visitorType, state, wrapper); + } + + var nodeVisitor = rootVisitor[type] = rootVisitor[type] || {}; + mergePair(nodeVisitor, visitorType); + } + } + + return rootVisitor; +} + +function wrapWithStateOrWrapper(oldVisitor, state, wrapper) { + var newVisitor = {}; + + var _loop = function _loop(key) { + var fns = oldVisitor[key]; + if (!Array.isArray(fns)) return "continue"; + fns = fns.map(function (fn) { + var newFn = fn; + + if (state) { + newFn = function newFn(path) { + return fn.call(state, path, state); + }; + } + + if (wrapper) { + newFn = wrapper(state.key, key, newFn); + } + + return newFn; + }); + newVisitor[key] = fns; + }; + + for (var key in oldVisitor) { + var _ret = _loop(key); + + if (_ret === "continue") continue; + } + + return newVisitor; +} + +function ensureEntranceObjects(obj) { + for (var key in obj) { + if (shouldIgnoreKey(key)) continue; + var fns = obj[key]; + + if (typeof fns === "function") { + obj[key] = { + enter: fns + }; + } + } +} + +function ensureCallbackArrays(obj) { + if (obj.enter && !Array.isArray(obj.enter)) obj.enter = [obj.enter]; + if (obj.exit && !Array.isArray(obj.exit)) obj.exit = [obj.exit]; +} + +function wrapCheck(wrapper, fn) { + var newFn = function newFn(path) { + if (wrapper.checkPath(path)) { + return fn.apply(this, arguments); + } + }; + + newFn.toString = function () { + return fn.toString(); + }; + + return newFn; +} + +function shouldIgnoreKey(key) { + if (key[0] === "_") return true; + if (key === "enter" || key === "exit" || key === "shouldSkip") return true; + + if (key === "blacklist" || key === "noScope" || key === "skipKeys") { + return true; + } + + return false; +} + +function mergePair(dest, src) { + for (var key in src) { + dest[key] = [].concat(dest[key] || [], src[key]); + } +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/traverse/package.json b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/package.json new file mode 100644 index 00000000000000..7ef7d42c27e95b --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/traverse/package.json @@ -0,0 +1,56 @@ +{ + "_from": "@babel/traverse@7.0.0-beta.36", + "_id": "@babel/traverse@7.0.0-beta.36", + "_inBundle": false, + "_integrity": "sha512-OTUb6iSKVR/98dGThRJ1BiyfwbuX10BVnkz89IpaerjTPRhDfMBfLsqmzxz5MiywUOW4M0Clta0o7rSxkfcuzw==", + "_location": "/babel-eslint/@babel/traverse", + "_phantomChildren": {}, + "_requested": { + "type": "version", + "registry": true, + "raw": "@babel/traverse@7.0.0-beta.36", + "name": "@babel/traverse", + "escapedName": "@babel%2ftraverse", + "scope": "@babel", + "rawSpec": "7.0.0-beta.36", + "saveSpec": null, + "fetchSpec": "7.0.0-beta.36" + }, + "_requiredBy": [ + "/babel-eslint" + ], + "_resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.0.0-beta.36.tgz", + "_shasum": "1dc6f8750e89b6b979de5fe44aa993b1a2192261", + "_spec": "@babel/traverse@7.0.0-beta.36", + "_where": "/home/mzasso/git/nodejs/node/tools/babel-eslint-tmp/node_modules/babel-eslint", + "author": { + "name": "Sebastian McKenzie", + "email": "sebmck@gmail.com" + }, + "bundleDependencies": false, + "dependencies": { + "@babel/code-frame": "7.0.0-beta.36", + "@babel/helper-function-name": "7.0.0-beta.36", + "@babel/types": "7.0.0-beta.36", + "babylon": "7.0.0-beta.36", + "debug": "^3.0.1", + "globals": "^11.1.0", + "invariant": "^2.2.0", + "lodash": "^4.2.0" + }, + "deprecated": false, + "description": "The Babel Traverse module maintains the overall tree state, and is responsible for replacing, removing, and adding nodes", + "devDependencies": { + "@babel/generator": "7.0.0-beta.36", + "@babel/helper-plugin-test-runner": "7.0.0-beta.36" + }, + "homepage": "https://babeljs.io/", + "license": "MIT", + "main": "lib/index.js", + "name": "@babel/traverse", + "repository": { + "type": "git", + "url": "https://github.com/babel/babel/tree/master/packages/babel-traverse" + }, + "version": "7.0.0-beta.36" +} diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/README.md b/tools/node_modules/babel-eslint/node_modules/@babel/types/README.md new file mode 100644 index 00000000000000..5e8d650c86c425 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/README.md @@ -0,0 +1,2835 @@ +# @babel/types + +> This module contains methods for building ASTs manually and for checking the types of AST nodes. + +## Install + +```sh +npm install --save-dev @babel/types +``` + +## API + + + +### anyTypeAnnotation +```javascript +t.anyTypeAnnotation() +``` + +See also `t.isAnyTypeAnnotation(node, opts)` and `t.assertAnyTypeAnnotation(node, opts)`. + +Aliases: `Flow`, `FlowBaseAnnotation` + + +--- + +### arrayExpression +```javascript +t.arrayExpression(elements) +``` + +See also `t.isArrayExpression(node, opts)` and `t.assertArrayExpression(node, opts)`. + +Aliases: `Expression` + + - `elements`: `Array` (default: `[]`) + +--- + +### arrayPattern +```javascript +t.arrayPattern(elements) +``` + +See also `t.isArrayPattern(node, opts)` and `t.assertArrayPattern(node, opts)`. + +Aliases: `Pattern`, `PatternLike`, `LVal` + + - `elements`: `Array` (required) + - `decorators`: `Array` (default: `null`) + - `typeAnnotation`: `TypeAnnotation | TSTypeAnnotation | Noop` (default: `null`) + +--- + +### arrayTypeAnnotation +```javascript +t.arrayTypeAnnotation(elementType) +``` + +See also `t.isArrayTypeAnnotation(node, opts)` and `t.assertArrayTypeAnnotation(node, opts)`. + +Aliases: `Flow` + + - `elementType` (required) + +--- + +### arrowFunctionExpression +```javascript +t.arrowFunctionExpression(params, body, async) +``` + +See also `t.isArrowFunctionExpression(node, opts)` and `t.assertArrowFunctionExpression(node, opts)`. + +Aliases: `Scopable`, `Function`, `BlockParent`, `FunctionParent`, `Expression`, `Pureish` + + - `params`: `Array` (required) + - `body`: `BlockStatement | Expression` (required) + - `async`: `boolean` (default: `false`) + - `expression`: `boolean` (default: `null`) + - `generator`: `boolean` (default: `false`) + - `returnType`: `TypeAnnotation | TSTypeAnnotation | Noop` (default: `null`) + - `typeParameters`: `TypeParameterDeclaration | TSTypeParameterDeclaration | Noop` (default: `null`) + +--- + +### assignmentExpression +```javascript +t.assignmentExpression(operator, left, right) +``` + +See also `t.isAssignmentExpression(node, opts)` and `t.assertAssignmentExpression(node, opts)`. + +Aliases: `Expression` + + - `operator`: `string` (required) + - `left`: `LVal` (required) + - `right`: `Expression` (required) + +--- + +### assignmentPattern +```javascript +t.assignmentPattern(left, right) +``` + +See also `t.isAssignmentPattern(node, opts)` and `t.assertAssignmentPattern(node, opts)`. + +Aliases: `Pattern`, `PatternLike`, `LVal` + + - `left`: `Identifier | ObjectPattern | ArrayPattern` (required) + - `right`: `Expression` (required) + - `decorators`: `Array` (default: `null`) + - `typeAnnotation`: `TypeAnnotation | TSTypeAnnotation | Noop` (default: `null`) + +--- + +### awaitExpression +```javascript +t.awaitExpression(argument) +``` + +See also `t.isAwaitExpression(node, opts)` and `t.assertAwaitExpression(node, opts)`. + +Aliases: `Expression`, `Terminatorless` + + - `argument`: `Expression` (required) + +--- + +### binaryExpression +```javascript +t.binaryExpression(operator, left, right) +``` + +See also `t.isBinaryExpression(node, opts)` and `t.assertBinaryExpression(node, opts)`. + +Aliases: `Binary`, `Expression` + + - `operator`: `'+' | '-' | '/' | '%' | '*' | '**' | '&' | '|' | '>>' | '>>>' | '<<' | '^' | '==' | '===' | '!=' | '!==' | 'in' | 'instanceof' | '>' | '<' | '>=' | '<='` (required) + - `left`: `Expression` (required) + - `right`: `Expression` (required) + +--- + +### bindExpression +```javascript +t.bindExpression(object, callee) +``` + +See also `t.isBindExpression(node, opts)` and `t.assertBindExpression(node, opts)`. + +Aliases: `Expression` + + - `object` (required) + - `callee` (required) + +--- + +### blockStatement +```javascript +t.blockStatement(body, directives) +``` + +See also `t.isBlockStatement(node, opts)` and `t.assertBlockStatement(node, opts)`. + +Aliases: `Scopable`, `BlockParent`, `Block`, `Statement` + + - `body`: `Array` (required) + - `directives`: `Array` (default: `[]`) + +--- + +### booleanLiteral +```javascript +t.booleanLiteral(value) +``` + +See also `t.isBooleanLiteral(node, opts)` and `t.assertBooleanLiteral(node, opts)`. + +Aliases: `Expression`, `Pureish`, `Literal`, `Immutable` + + - `value`: `boolean` (required) + +--- + +### booleanLiteralTypeAnnotation +```javascript +t.booleanLiteralTypeAnnotation() +``` + +See also `t.isBooleanLiteralTypeAnnotation(node, opts)` and `t.assertBooleanLiteralTypeAnnotation(node, opts)`. + +Aliases: `Flow` + + +--- + +### booleanTypeAnnotation +```javascript +t.booleanTypeAnnotation() +``` + +See also `t.isBooleanTypeAnnotation(node, opts)` and `t.assertBooleanTypeAnnotation(node, opts)`. + +Aliases: `Flow`, `FlowBaseAnnotation` + + +--- + +### breakStatement +```javascript +t.breakStatement(label) +``` + +See also `t.isBreakStatement(node, opts)` and `t.assertBreakStatement(node, opts)`. + +Aliases: `Statement`, `Terminatorless`, `CompletionStatement` + + - `label`: `Identifier` (default: `null`) + +--- + +### callExpression +```javascript +t.callExpression(callee, arguments) +``` + +See also `t.isCallExpression(node, opts)` and `t.assertCallExpression(node, opts)`. + +Aliases: `Expression` + + - `callee`: `Expression` (required) + - `arguments`: `Array` (required) + - `optional`: `true | false` (default: `null`) + - `typeParameters`: `TypeParameterInstantiation | TSTypeParameterInstantiation` (default: `null`) + +--- + +### catchClause +```javascript +t.catchClause(param, body) +``` + +See also `t.isCatchClause(node, opts)` and `t.assertCatchClause(node, opts)`. + +Aliases: `Scopable`, `BlockParent` + + - `param`: `Identifier` (default: `null`) + - `body`: `BlockStatement` (required) + +--- + +### classBody +```javascript +t.classBody(body) +``` + +See also `t.isClassBody(node, opts)` and `t.assertClassBody(node, opts)`. + + - `body`: `Array` (required) + +--- + +### classDeclaration +```javascript +t.classDeclaration(id, superClass, body, decorators) +``` + +See also `t.isClassDeclaration(node, opts)` and `t.assertClassDeclaration(node, opts)`. + +Aliases: `Scopable`, `Class`, `Statement`, `Declaration`, `Pureish` + + - `id`: `Identifier` (default: `null`) + - `superClass`: `Expression` (default: `null`) + - `body`: `ClassBody` (required) + - `decorators`: `Array` (default: `null`) + - `abstract`: `boolean` (default: `null`) + - `declare`: `boolean` (default: `null`) + - `implements`: `Array` (default: `null`) + - `mixins` (default: `null`) + - `superTypeParameters`: `TypeParameterInstantiation | TSTypeParameterInstantiation` (default: `null`) + - `typeParameters`: `TypeParameterDeclaration | TSTypeParameterDeclaration | Noop` (default: `null`) + +--- + +### classExpression +```javascript +t.classExpression(id, superClass, body, decorators) +``` + +See also `t.isClassExpression(node, opts)` and `t.assertClassExpression(node, opts)`. + +Aliases: `Scopable`, `Class`, `Expression`, `Pureish` + + - `id`: `Identifier` (default: `null`) + - `superClass`: `Expression` (default: `null`) + - `body`: `ClassBody` (required) + - `decorators`: `Array` (default: `null`) + - `implements`: `Array` (default: `null`) + - `mixins` (default: `null`) + - `superTypeParameters`: `TypeParameterInstantiation | TSTypeParameterInstantiation` (default: `null`) + - `typeParameters`: `TypeParameterDeclaration | TSTypeParameterDeclaration | Noop` (default: `null`) + +--- + +### classImplements +```javascript +t.classImplements(id, typeParameters) +``` + +See also `t.isClassImplements(node, opts)` and `t.assertClassImplements(node, opts)`. + +Aliases: `Flow` + + - `id` (required) + - `typeParameters` (required) + +--- + +### classMethod +```javascript +t.classMethod(kind, key, params, body, computed, static) +``` + +See also `t.isClassMethod(node, opts)` and `t.assertClassMethod(node, opts)`. + +Aliases: `Function`, `Scopable`, `BlockParent`, `FunctionParent`, `Method` + + - `kind`: `"get" | "set" | "method" | "constructor"` (default: `'method'`) + - `key`: if computed then `Expression` else `Identifier | Literal` (required) + - `params`: `Array` (required) + - `body`: `BlockStatement` (required) + - `computed`: `boolean` (default: `false`) + - `static`: `boolean` (default: `null`) + - `abstract`: `boolean` (default: `null`) + - `access`: `"public" | "private" | "protected"` (default: `null`) + - `accessibility`: `"public" | "private" | "protected"` (default: `null`) + - `async`: `boolean` (default: `false`) + - `decorators`: `Array` (default: `null`) + - `generator`: `boolean` (default: `false`) + - `optional`: `boolean` (default: `null`) + - `returnType`: `TypeAnnotation | TSTypeAnnotation | Noop` (default: `null`) + - `typeParameters`: `TypeParameterDeclaration | TSTypeParameterDeclaration | Noop` (default: `null`) + +--- + +### classProperty +```javascript +t.classProperty(key, value, typeAnnotation, decorators, computed) +``` + +See also `t.isClassProperty(node, opts)` and `t.assertClassProperty(node, opts)`. + +Aliases: `Property` + + - `key` (required) + - `value`: `Expression` (default: `null`) + - `typeAnnotation`: `TypeAnnotation | TSTypeAnnotation | Noop` (default: `null`) + - `decorators`: `Array` (default: `null`) + - `computed`: `boolean` (default: `false`) + - `abstract`: `boolean` (default: `null`) + - `accessibility`: `"public" | "private" | "protected"` (default: `null`) + - `optional`: `boolean` (default: `null`) + - `readonly`: `boolean` (default: `null`) + - `static`: `boolean` (default: `null`) + +--- + +### conditionalExpression +```javascript +t.conditionalExpression(test, consequent, alternate) +``` + +See also `t.isConditionalExpression(node, opts)` and `t.assertConditionalExpression(node, opts)`. + +Aliases: `Expression`, `Conditional` + + - `test`: `Expression` (required) + - `consequent`: `Expression` (required) + - `alternate`: `Expression` (required) + +--- + +### continueStatement +```javascript +t.continueStatement(label) +``` + +See also `t.isContinueStatement(node, opts)` and `t.assertContinueStatement(node, opts)`. + +Aliases: `Statement`, `Terminatorless`, `CompletionStatement` + + - `label`: `Identifier` (default: `null`) + +--- + +### debuggerStatement +```javascript +t.debuggerStatement() +``` + +See also `t.isDebuggerStatement(node, opts)` and `t.assertDebuggerStatement(node, opts)`. + +Aliases: `Statement` + + +--- + +### declareClass +```javascript +t.declareClass(id, typeParameters, extends, body) +``` + +See also `t.isDeclareClass(node, opts)` and `t.assertDeclareClass(node, opts)`. + +Aliases: `Flow`, `FlowDeclaration`, `Statement`, `Declaration` + + - `id` (required) + - `typeParameters` (required) + - `extends` (required) + - `body` (required) + +--- + +### declareExportAllDeclaration +```javascript +t.declareExportAllDeclaration(source) +``` + +See also `t.isDeclareExportAllDeclaration(node, opts)` and `t.assertDeclareExportAllDeclaration(node, opts)`. + +Aliases: `Flow`, `FlowDeclaration`, `Statement`, `Declaration` + + - `source` (required) + +--- + +### declareExportDeclaration +```javascript +t.declareExportDeclaration(declaration, specifiers, source) +``` + +See also `t.isDeclareExportDeclaration(node, opts)` and `t.assertDeclareExportDeclaration(node, opts)`. + +Aliases: `Flow`, `FlowDeclaration`, `Statement`, `Declaration` + + - `declaration` (required) + - `specifiers` (required) + - `source` (required) + +--- + +### declareFunction +```javascript +t.declareFunction(id) +``` + +See also `t.isDeclareFunction(node, opts)` and `t.assertDeclareFunction(node, opts)`. + +Aliases: `Flow`, `FlowDeclaration`, `Statement`, `Declaration` + + - `id` (required) + +--- + +### declareInterface +```javascript +t.declareInterface(id, typeParameters, extends, body) +``` + +See also `t.isDeclareInterface(node, opts)` and `t.assertDeclareInterface(node, opts)`. + +Aliases: `Flow`, `FlowDeclaration`, `Statement`, `Declaration` + + - `id` (required) + - `typeParameters` (required) + - `extends` (required) + - `body` (required) + +--- + +### declareModule +```javascript +t.declareModule(id, body) +``` + +See also `t.isDeclareModule(node, opts)` and `t.assertDeclareModule(node, opts)`. + +Aliases: `Flow`, `FlowDeclaration`, `Statement`, `Declaration` + + - `id` (required) + - `body` (required) + +--- + +### declareModuleExports +```javascript +t.declareModuleExports(typeAnnotation) +``` + +See also `t.isDeclareModuleExports(node, opts)` and `t.assertDeclareModuleExports(node, opts)`. + +Aliases: `Flow`, `FlowDeclaration`, `Statement`, `Declaration` + + - `typeAnnotation` (required) + +--- + +### declareOpaqueType +```javascript +t.declareOpaqueType(id, typeParameters, supertype) +``` + +See also `t.isDeclareOpaqueType(node, opts)` and `t.assertDeclareOpaqueType(node, opts)`. + +Aliases: `Flow`, `FlowDeclaration`, `Statement`, `Declaration` + + - `id` (required) + - `typeParameters` (required) + - `supertype` (required) + +--- + +### declareTypeAlias +```javascript +t.declareTypeAlias(id, typeParameters, right) +``` + +See also `t.isDeclareTypeAlias(node, opts)` and `t.assertDeclareTypeAlias(node, opts)`. + +Aliases: `Flow`, `FlowDeclaration`, `Statement`, `Declaration` + + - `id` (required) + - `typeParameters` (required) + - `right` (required) + +--- + +### declareVariable +```javascript +t.declareVariable(id) +``` + +See also `t.isDeclareVariable(node, opts)` and `t.assertDeclareVariable(node, opts)`. + +Aliases: `Flow`, `FlowDeclaration`, `Statement`, `Declaration` + + - `id` (required) + +--- + +### declaredPredicate +```javascript +t.declaredPredicate(value) +``` + +See also `t.isDeclaredPredicate(node, opts)` and `t.assertDeclaredPredicate(node, opts)`. + +Aliases: `Flow`, `FlowPredicate` + + - `value` (required) + +--- + +### decorator +```javascript +t.decorator(expression) +``` + +See also `t.isDecorator(node, opts)` and `t.assertDecorator(node, opts)`. + + - `expression`: `Expression` (required) + +--- + +### directive +```javascript +t.directive(value) +``` + +See also `t.isDirective(node, opts)` and `t.assertDirective(node, opts)`. + + - `value`: `DirectiveLiteral` (required) + +--- + +### directiveLiteral +```javascript +t.directiveLiteral(value) +``` + +See also `t.isDirectiveLiteral(node, opts)` and `t.assertDirectiveLiteral(node, opts)`. + + - `value`: `string` (required) + +--- + +### doExpression +```javascript +t.doExpression(body) +``` + +See also `t.isDoExpression(node, opts)` and `t.assertDoExpression(node, opts)`. + +Aliases: `Expression` + + - `body`: `BlockStatement` (required) + +--- + +### doWhileStatement +```javascript +t.doWhileStatement(test, body) +``` + +See also `t.isDoWhileStatement(node, opts)` and `t.assertDoWhileStatement(node, opts)`. + +Aliases: `Statement`, `BlockParent`, `Loop`, `While`, `Scopable` + + - `test`: `Expression` (required) + - `body`: `Statement` (required) + +--- + +### emptyStatement +```javascript +t.emptyStatement() +``` + +See also `t.isEmptyStatement(node, opts)` and `t.assertEmptyStatement(node, opts)`. + +Aliases: `Statement` + + +--- + +### emptyTypeAnnotation +```javascript +t.emptyTypeAnnotation() +``` + +See also `t.isEmptyTypeAnnotation(node, opts)` and `t.assertEmptyTypeAnnotation(node, opts)`. + +Aliases: `Flow`, `FlowBaseAnnotation` + + +--- + +### existsTypeAnnotation +```javascript +t.existsTypeAnnotation() +``` + +See also `t.isExistsTypeAnnotation(node, opts)` and `t.assertExistsTypeAnnotation(node, opts)`. + +Aliases: `Flow` + + +--- + +### exportAllDeclaration +```javascript +t.exportAllDeclaration(source) +``` + +See also `t.isExportAllDeclaration(node, opts)` and `t.assertExportAllDeclaration(node, opts)`. + +Aliases: `Statement`, `Declaration`, `ModuleDeclaration`, `ExportDeclaration` + + - `source`: `StringLiteral` (required) + +--- + +### exportDefaultDeclaration +```javascript +t.exportDefaultDeclaration(declaration) +``` + +See also `t.isExportDefaultDeclaration(node, opts)` and `t.assertExportDefaultDeclaration(node, opts)`. + +Aliases: `Statement`, `Declaration`, `ModuleDeclaration`, `ExportDeclaration` + + - `declaration`: `FunctionDeclaration | TSDeclareFunction | ClassDeclaration | Expression` (required) + +--- + +### exportDefaultSpecifier +```javascript +t.exportDefaultSpecifier(exported) +``` + +See also `t.isExportDefaultSpecifier(node, opts)` and `t.assertExportDefaultSpecifier(node, opts)`. + +Aliases: `ModuleSpecifier` + + - `exported`: `Identifier` (required) + +--- + +### exportNamedDeclaration +```javascript +t.exportNamedDeclaration(declaration, specifiers, source) +``` + +See also `t.isExportNamedDeclaration(node, opts)` and `t.assertExportNamedDeclaration(node, opts)`. + +Aliases: `Statement`, `Declaration`, `ModuleDeclaration`, `ExportDeclaration` + + - `declaration`: `Declaration` (default: `null`) + - `specifiers`: `Array` (required) + - `source`: `StringLiteral` (default: `null`) + +--- + +### exportNamespaceSpecifier +```javascript +t.exportNamespaceSpecifier(exported) +``` + +See also `t.isExportNamespaceSpecifier(node, opts)` and `t.assertExportNamespaceSpecifier(node, opts)`. + +Aliases: `ModuleSpecifier` + + - `exported`: `Identifier` (required) + +--- + +### exportSpecifier +```javascript +t.exportSpecifier(local, exported) +``` + +See also `t.isExportSpecifier(node, opts)` and `t.assertExportSpecifier(node, opts)`. + +Aliases: `ModuleSpecifier` + + - `local`: `Identifier` (required) + - `exported`: `Identifier` (required) + +--- + +### expressionStatement +```javascript +t.expressionStatement(expression) +``` + +See also `t.isExpressionStatement(node, opts)` and `t.assertExpressionStatement(node, opts)`. + +Aliases: `Statement`, `ExpressionWrapper` + + - `expression`: `Expression` (required) + +--- + +### file +```javascript +t.file(program, comments, tokens) +``` + +See also `t.isFile(node, opts)` and `t.assertFile(node, opts)`. + + - `program`: `Program` (required) + - `comments` (required) + - `tokens` (required) + +--- + +### forInStatement +```javascript +t.forInStatement(left, right, body) +``` + +See also `t.isForInStatement(node, opts)` and `t.assertForInStatement(node, opts)`. + +Aliases: `Scopable`, `Statement`, `For`, `BlockParent`, `Loop`, `ForXStatement` + + - `left`: `VariableDeclaration | LVal` (required) + - `right`: `Expression` (required) + - `body`: `Statement` (required) + +--- + +### forOfStatement +```javascript +t.forOfStatement(left, right, body) +``` + +See also `t.isForOfStatement(node, opts)` and `t.assertForOfStatement(node, opts)`. + +Aliases: `Scopable`, `Statement`, `For`, `BlockParent`, `Loop`, `ForXStatement` + + - `left`: `VariableDeclaration | LVal` (required) + - `right`: `Expression` (required) + - `body`: `Statement` (required) + - `await`: `boolean` (default: `false`) + +--- + +### forStatement +```javascript +t.forStatement(init, test, update, body) +``` + +See also `t.isForStatement(node, opts)` and `t.assertForStatement(node, opts)`. + +Aliases: `Scopable`, `Statement`, `For`, `BlockParent`, `Loop` + + - `init`: `VariableDeclaration | Expression` (default: `null`) + - `test`: `Expression` (default: `null`) + - `update`: `Expression` (default: `null`) + - `body`: `Statement` (required) + +--- + +### functionDeclaration +```javascript +t.functionDeclaration(id, params, body, generator, async) +``` + +See also `t.isFunctionDeclaration(node, opts)` and `t.assertFunctionDeclaration(node, opts)`. + +Aliases: `Scopable`, `Function`, `BlockParent`, `FunctionParent`, `Statement`, `Pureish`, `Declaration` + + - `id`: `Identifier` (default: `null`) + - `params`: `Array` (required) + - `body`: `BlockStatement` (required) + - `generator`: `boolean` (default: `false`) + - `async`: `boolean` (default: `false`) + - `declare`: `boolean` (default: `null`) + - `returnType`: `TypeAnnotation | TSTypeAnnotation | Noop` (default: `null`) + - `typeParameters`: `TypeParameterDeclaration | TSTypeParameterDeclaration | Noop` (default: `null`) + +--- + +### functionExpression +```javascript +t.functionExpression(id, params, body, generator, async) +``` + +See also `t.isFunctionExpression(node, opts)` and `t.assertFunctionExpression(node, opts)`. + +Aliases: `Scopable`, `Function`, `BlockParent`, `FunctionParent`, `Expression`, `Pureish` + + - `id`: `Identifier` (default: `null`) + - `params`: `Array` (required) + - `body`: `BlockStatement` (required) + - `generator`: `boolean` (default: `false`) + - `async`: `boolean` (default: `false`) + - `returnType`: `TypeAnnotation | TSTypeAnnotation | Noop` (default: `null`) + - `typeParameters`: `TypeParameterDeclaration | TSTypeParameterDeclaration | Noop` (default: `null`) + +--- + +### functionTypeAnnotation +```javascript +t.functionTypeAnnotation(typeParameters, params, rest, returnType) +``` + +See also `t.isFunctionTypeAnnotation(node, opts)` and `t.assertFunctionTypeAnnotation(node, opts)`. + +Aliases: `Flow` + + - `typeParameters` (required) + - `params` (required) + - `rest` (required) + - `returnType` (required) + +--- + +### functionTypeParam +```javascript +t.functionTypeParam(name, typeAnnotation) +``` + +See also `t.isFunctionTypeParam(node, opts)` and `t.assertFunctionTypeParam(node, opts)`. + +Aliases: `Flow` + + - `name` (required) + - `typeAnnotation` (required) + +--- + +### genericTypeAnnotation +```javascript +t.genericTypeAnnotation(id, typeParameters) +``` + +See also `t.isGenericTypeAnnotation(node, opts)` and `t.assertGenericTypeAnnotation(node, opts)`. + +Aliases: `Flow` + + - `id` (required) + - `typeParameters` (required) + +--- + +### identifier +```javascript +t.identifier(name) +``` + +See also `t.isIdentifier(node, opts)` and `t.assertIdentifier(node, opts)`. + +Aliases: `Expression`, `PatternLike`, `LVal`, `TSEntityName` + + - `name`: `string` (required) + - `decorators`: `Array` (default: `null`) + - `optional`: `boolean` (default: `null`) + - `typeAnnotation`: `TypeAnnotation | TSTypeAnnotation | Noop` (default: `null`) + +--- + +### ifStatement +```javascript +t.ifStatement(test, consequent, alternate) +``` + +See also `t.isIfStatement(node, opts)` and `t.assertIfStatement(node, opts)`. + +Aliases: `Statement`, `Conditional` + + - `test`: `Expression` (required) + - `consequent`: `Statement` (required) + - `alternate`: `Statement` (default: `null`) + +--- + +### import +```javascript +t.import() +``` + +See also `t.isImport(node, opts)` and `t.assertImport(node, opts)`. + +Aliases: `Expression` + + +--- + +### importDeclaration +```javascript +t.importDeclaration(specifiers, source) +``` + +See also `t.isImportDeclaration(node, opts)` and `t.assertImportDeclaration(node, opts)`. + +Aliases: `Statement`, `Declaration`, `ModuleDeclaration` + + - `specifiers`: `Array` (required) + - `source`: `StringLiteral` (required) + +--- + +### importDefaultSpecifier +```javascript +t.importDefaultSpecifier(local) +``` + +See also `t.isImportDefaultSpecifier(node, opts)` and `t.assertImportDefaultSpecifier(node, opts)`. + +Aliases: `ModuleSpecifier` + + - `local`: `Identifier` (required) + +--- + +### importNamespaceSpecifier +```javascript +t.importNamespaceSpecifier(local) +``` + +See also `t.isImportNamespaceSpecifier(node, opts)` and `t.assertImportNamespaceSpecifier(node, opts)`. + +Aliases: `ModuleSpecifier` + + - `local`: `Identifier` (required) + +--- + +### importSpecifier +```javascript +t.importSpecifier(local, imported) +``` + +See also `t.isImportSpecifier(node, opts)` and `t.assertImportSpecifier(node, opts)`. + +Aliases: `ModuleSpecifier` + + - `local`: `Identifier` (required) + - `imported`: `Identifier` (required) + - `importKind`: `null | 'type' | 'typeof'` (default: `null`) + +--- + +### inferredPredicate +```javascript +t.inferredPredicate() +``` + +See also `t.isInferredPredicate(node, opts)` and `t.assertInferredPredicate(node, opts)`. + +Aliases: `Flow`, `FlowPredicate` + + +--- + +### interfaceDeclaration +```javascript +t.interfaceDeclaration(id, typeParameters, extends, body) +``` + +See also `t.isInterfaceDeclaration(node, opts)` and `t.assertInterfaceDeclaration(node, opts)`. + +Aliases: `Flow`, `FlowDeclaration`, `Statement`, `Declaration` + + - `id` (required) + - `typeParameters` (required) + - `extends` (required) + - `body` (required) + +--- + +### interfaceExtends +```javascript +t.interfaceExtends(id, typeParameters) +``` + +See also `t.isInterfaceExtends(node, opts)` and `t.assertInterfaceExtends(node, opts)`. + +Aliases: `Flow` + + - `id` (required) + - `typeParameters` (required) + +--- + +### intersectionTypeAnnotation +```javascript +t.intersectionTypeAnnotation(types) +``` + +See also `t.isIntersectionTypeAnnotation(node, opts)` and `t.assertIntersectionTypeAnnotation(node, opts)`. + +Aliases: `Flow` + + - `types` (required) + +--- + +### jSXAttribute +```javascript +t.jSXAttribute(name, value) +``` + +See also `t.isJSXAttribute(node, opts)` and `t.assertJSXAttribute(node, opts)`. + +Aliases: `JSX`, `Immutable` + + - `name`: `JSXIdentifier | JSXNamespacedName` (required) + - `value`: `JSXElement | JSXFragment | StringLiteral | JSXExpressionContainer` (default: `null`) + +--- + +### jSXClosingElement +```javascript +t.jSXClosingElement(name) +``` + +See also `t.isJSXClosingElement(node, opts)` and `t.assertJSXClosingElement(node, opts)`. + +Aliases: `JSX`, `Immutable` + + - `name`: `JSXIdentifier | JSXMemberExpression` (required) + +--- + +### jSXClosingFragment +```javascript +t.jSXClosingFragment() +``` + +See also `t.isJSXClosingFragment(node, opts)` and `t.assertJSXClosingFragment(node, opts)`. + +Aliases: `JSX`, `Immutable` + + +--- + +### jSXElement +```javascript +t.jSXElement(openingElement, closingElement, children, selfClosing) +``` + +See also `t.isJSXElement(node, opts)` and `t.assertJSXElement(node, opts)`. + +Aliases: `JSX`, `Immutable`, `Expression` + + - `openingElement`: `JSXOpeningElement` (required) + - `closingElement`: `JSXClosingElement` (default: `null`) + - `children`: `Array` (required) + - `selfClosing` (required) + +--- + +### jSXEmptyExpression +```javascript +t.jSXEmptyExpression() +``` + +See also `t.isJSXEmptyExpression(node, opts)` and `t.assertJSXEmptyExpression(node, opts)`. + +Aliases: `JSX` + + +--- + +### jSXExpressionContainer +```javascript +t.jSXExpressionContainer(expression) +``` + +See also `t.isJSXExpressionContainer(node, opts)` and `t.assertJSXExpressionContainer(node, opts)`. + +Aliases: `JSX`, `Immutable` + + - `expression`: `Expression` (required) + +--- + +### jSXFragment +```javascript +t.jSXFragment(openingFragment, closingFragment, children) +``` + +See also `t.isJSXFragment(node, opts)` and `t.assertJSXFragment(node, opts)`. + +Aliases: `JSX`, `Immutable`, `Expression` + + - `openingFragment`: `JSXOpeningFragment` (required) + - `closingFragment`: `JSXClosingFragment` (required) + - `children`: `Array` (required) + +--- + +### jSXIdentifier +```javascript +t.jSXIdentifier(name) +``` + +See also `t.isJSXIdentifier(node, opts)` and `t.assertJSXIdentifier(node, opts)`. + +Aliases: `JSX` + + - `name`: `string` (required) + +--- + +### jSXMemberExpression +```javascript +t.jSXMemberExpression(object, property) +``` + +See also `t.isJSXMemberExpression(node, opts)` and `t.assertJSXMemberExpression(node, opts)`. + +Aliases: `JSX` + + - `object`: `JSXMemberExpression | JSXIdentifier` (required) + - `property`: `JSXIdentifier` (required) + +--- + +### jSXNamespacedName +```javascript +t.jSXNamespacedName(namespace, name) +``` + +See also `t.isJSXNamespacedName(node, opts)` and `t.assertJSXNamespacedName(node, opts)`. + +Aliases: `JSX` + + - `namespace`: `JSXIdentifier` (required) + - `name`: `JSXIdentifier` (required) + +--- + +### jSXOpeningElement +```javascript +t.jSXOpeningElement(name, attributes, selfClosing) +``` + +See also `t.isJSXOpeningElement(node, opts)` and `t.assertJSXOpeningElement(node, opts)`. + +Aliases: `JSX`, `Immutable` + + - `name`: `JSXIdentifier | JSXMemberExpression` (required) + - `attributes`: `Array` (required) + - `selfClosing`: `boolean` (default: `false`) + +--- + +### jSXOpeningFragment +```javascript +t.jSXOpeningFragment() +``` + +See also `t.isJSXOpeningFragment(node, opts)` and `t.assertJSXOpeningFragment(node, opts)`. + +Aliases: `JSX`, `Immutable` + + +--- + +### jSXSpreadAttribute +```javascript +t.jSXSpreadAttribute(argument) +``` + +See also `t.isJSXSpreadAttribute(node, opts)` and `t.assertJSXSpreadAttribute(node, opts)`. + +Aliases: `JSX` + + - `argument`: `Expression` (required) + +--- + +### jSXSpreadChild +```javascript +t.jSXSpreadChild(expression) +``` + +See also `t.isJSXSpreadChild(node, opts)` and `t.assertJSXSpreadChild(node, opts)`. + +Aliases: `JSX`, `Immutable` + + - `expression`: `Expression` (required) + +--- + +### jSXText +```javascript +t.jSXText(value) +``` + +See also `t.isJSXText(node, opts)` and `t.assertJSXText(node, opts)`. + +Aliases: `JSX`, `Immutable` + + - `value`: `string` (required) + +--- + +### labeledStatement +```javascript +t.labeledStatement(label, body) +``` + +See also `t.isLabeledStatement(node, opts)` and `t.assertLabeledStatement(node, opts)`. + +Aliases: `Statement` + + - `label`: `Identifier` (required) + - `body`: `Statement` (required) + +--- + +### logicalExpression +```javascript +t.logicalExpression(operator, left, right) +``` + +See also `t.isLogicalExpression(node, opts)` and `t.assertLogicalExpression(node, opts)`. + +Aliases: `Binary`, `Expression` + + - `operator`: `'||' | '&&' | '??'` (required) + - `left`: `Expression` (required) + - `right`: `Expression` (required) + +--- + +### memberExpression +```javascript +t.memberExpression(object, property, computed, optional) +``` + +See also `t.isMemberExpression(node, opts)` and `t.assertMemberExpression(node, opts)`. + +Aliases: `Expression`, `LVal` + + - `object`: `Expression` (required) + - `property`: if computed then `Expression` else `Identifier` (required) + - `computed`: `boolean` (default: `false`) + - `optional`: `true | false` (default: `null`) + +--- + +### metaProperty +```javascript +t.metaProperty(meta, property) +``` + +See also `t.isMetaProperty(node, opts)` and `t.assertMetaProperty(node, opts)`. + +Aliases: `Expression` + + - `meta`: `Identifier` (required) + - `property`: `Identifier` (required) + +--- + +### mixedTypeAnnotation +```javascript +t.mixedTypeAnnotation() +``` + +See also `t.isMixedTypeAnnotation(node, opts)` and `t.assertMixedTypeAnnotation(node, opts)`. + +Aliases: `Flow`, `FlowBaseAnnotation` + + +--- + +### newExpression +```javascript +t.newExpression(callee, arguments) +``` + +See also `t.isNewExpression(node, opts)` and `t.assertNewExpression(node, opts)`. + +Aliases: `Expression` + + - `callee`: `Expression` (required) + - `arguments`: `Array` (required) + - `optional`: `true | false` (default: `null`) + - `typeParameters`: `TypeParameterInstantiation | TSTypeParameterInstantiation` (default: `null`) + +--- + +### noop +```javascript +t.noop() +``` + +See also `t.isNoop(node, opts)` and `t.assertNoop(node, opts)`. + + +--- + +### nullLiteral +```javascript +t.nullLiteral() +``` + +See also `t.isNullLiteral(node, opts)` and `t.assertNullLiteral(node, opts)`. + +Aliases: `Expression`, `Pureish`, `Literal`, `Immutable` + + +--- + +### nullLiteralTypeAnnotation +```javascript +t.nullLiteralTypeAnnotation() +``` + +See also `t.isNullLiteralTypeAnnotation(node, opts)` and `t.assertNullLiteralTypeAnnotation(node, opts)`. + +Aliases: `Flow`, `FlowBaseAnnotation` + + +--- + +### nullableTypeAnnotation +```javascript +t.nullableTypeAnnotation(typeAnnotation) +``` + +See also `t.isNullableTypeAnnotation(node, opts)` and `t.assertNullableTypeAnnotation(node, opts)`. + +Aliases: `Flow` + + - `typeAnnotation` (required) + +--- + +### numberLiteralTypeAnnotation +```javascript +t.numberLiteralTypeAnnotation() +``` + +See also `t.isNumberLiteralTypeAnnotation(node, opts)` and `t.assertNumberLiteralTypeAnnotation(node, opts)`. + +Aliases: `Flow` + + +--- + +### numberTypeAnnotation +```javascript +t.numberTypeAnnotation() +``` + +See also `t.isNumberTypeAnnotation(node, opts)` and `t.assertNumberTypeAnnotation(node, opts)`. + +Aliases: `Flow`, `FlowBaseAnnotation` + + +--- + +### numericLiteral +```javascript +t.numericLiteral(value) +``` + +See also `t.isNumericLiteral(node, opts)` and `t.assertNumericLiteral(node, opts)`. + +Aliases: `Expression`, `Pureish`, `Literal`, `Immutable` + + - `value`: `number` (required) + +--- + +### objectExpression +```javascript +t.objectExpression(properties) +``` + +See also `t.isObjectExpression(node, opts)` and `t.assertObjectExpression(node, opts)`. + +Aliases: `Expression` + + - `properties`: `Array` (required) + +--- + +### objectMethod +```javascript +t.objectMethod(kind, key, params, body, computed) +``` + +See also `t.isObjectMethod(node, opts)` and `t.assertObjectMethod(node, opts)`. + +Aliases: `UserWhitespacable`, `Function`, `Scopable`, `BlockParent`, `FunctionParent`, `Method`, `ObjectMember` + + - `kind`: `"method" | "get" | "set"` (default: `'method'`) + - `key`: if computed then `Expression` else `Identifier | Literal` (required) + - `params`: `Array` (required) + - `body`: `BlockStatement` (required) + - `computed`: `boolean` (default: `false`) + - `async`: `boolean` (default: `false`) + - `decorators`: `Array` (default: `null`) + - `generator`: `boolean` (default: `false`) + - `returnType`: `TypeAnnotation | TSTypeAnnotation | Noop` (default: `null`) + - `typeParameters`: `TypeParameterDeclaration | TSTypeParameterDeclaration | Noop` (default: `null`) + +--- + +### objectPattern +```javascript +t.objectPattern(properties) +``` + +See also `t.isObjectPattern(node, opts)` and `t.assertObjectPattern(node, opts)`. + +Aliases: `Pattern`, `PatternLike`, `LVal` + + - `properties`: `Array` (required) + - `decorators`: `Array` (default: `null`) + - `typeAnnotation`: `TypeAnnotation | TSTypeAnnotation | Noop` (default: `null`) + +--- + +### objectProperty +```javascript +t.objectProperty(key, value, computed, shorthand, decorators) +``` + +See also `t.isObjectProperty(node, opts)` and `t.assertObjectProperty(node, opts)`. + +Aliases: `UserWhitespacable`, `Property`, `ObjectMember` + + - `key`: if computed then `Expression` else `Identifier | Literal` (required) + - `value`: `Expression | PatternLike` (required) + - `computed`: `boolean` (default: `false`) + - `shorthand`: `boolean` (default: `false`) + - `decorators`: `Array` (default: `null`) + +--- + +### objectTypeAnnotation +```javascript +t.objectTypeAnnotation(properties, indexers, callProperties) +``` + +See also `t.isObjectTypeAnnotation(node, opts)` and `t.assertObjectTypeAnnotation(node, opts)`. + +Aliases: `Flow` + + - `properties` (required) + - `indexers` (required) + - `callProperties` (required) + +--- + +### objectTypeCallProperty +```javascript +t.objectTypeCallProperty(value) +``` + +See also `t.isObjectTypeCallProperty(node, opts)` and `t.assertObjectTypeCallProperty(node, opts)`. + +Aliases: `Flow`, `UserWhitespacable` + + - `value` (required) + +--- + +### objectTypeIndexer +```javascript +t.objectTypeIndexer(id, key, value) +``` + +See also `t.isObjectTypeIndexer(node, opts)` and `t.assertObjectTypeIndexer(node, opts)`. + +Aliases: `Flow`, `UserWhitespacable` + + - `id` (required) + - `key` (required) + - `value` (required) + +--- + +### objectTypeProperty +```javascript +t.objectTypeProperty(key, value) +``` + +See also `t.isObjectTypeProperty(node, opts)` and `t.assertObjectTypeProperty(node, opts)`. + +Aliases: `Flow`, `UserWhitespacable` + + - `key` (required) + - `value` (required) + +--- + +### objectTypeSpreadProperty +```javascript +t.objectTypeSpreadProperty(argument) +``` + +See also `t.isObjectTypeSpreadProperty(node, opts)` and `t.assertObjectTypeSpreadProperty(node, opts)`. + +Aliases: `Flow`, `UserWhitespacable` + + - `argument` (required) + +--- + +### opaqueType +```javascript +t.opaqueType(id, typeParameters, supertype, impltype) +``` + +See also `t.isOpaqueType(node, opts)` and `t.assertOpaqueType(node, opts)`. + +Aliases: `Flow`, `FlowDeclaration`, `Statement`, `Declaration` + + - `id` (required) + - `typeParameters` (required) + - `supertype` (required) + - `impltype` (required) + +--- + +### parenthesizedExpression +```javascript +t.parenthesizedExpression(expression) +``` + +See also `t.isParenthesizedExpression(node, opts)` and `t.assertParenthesizedExpression(node, opts)`. + +Aliases: `Expression`, `ExpressionWrapper` + + - `expression`: `Expression` (required) + +--- + +### program +```javascript +t.program(body, directives, sourceType) +``` + +See also `t.isProgram(node, opts)` and `t.assertProgram(node, opts)`. + +Aliases: `Scopable`, `BlockParent`, `Block` + + - `body`: `Array` (required) + - `directives`: `Array` (default: `[]`) + - `sourceType`: `'script' | 'module'` (default: `'script'`) + - `sourceFile`: `string` (default: `null`) + +--- + +### qualifiedTypeIdentifier +```javascript +t.qualifiedTypeIdentifier(id, qualification) +``` + +See also `t.isQualifiedTypeIdentifier(node, opts)` and `t.assertQualifiedTypeIdentifier(node, opts)`. + +Aliases: `Flow` + + - `id` (required) + - `qualification` (required) + +--- + +### regExpLiteral +```javascript +t.regExpLiteral(pattern, flags) +``` + +See also `t.isRegExpLiteral(node, opts)` and `t.assertRegExpLiteral(node, opts)`. + +Aliases: `Expression`, `Literal` + + - `pattern`: `string` (required) + - `flags`: `string` (default: `''`) + +--- + +### restElement +```javascript +t.restElement(argument) +``` + +See also `t.isRestElement(node, opts)` and `t.assertRestElement(node, opts)`. + +Aliases: `LVal`, `PatternLike` + + - `argument`: `LVal` (required) + - `decorators`: `Array` (default: `null`) + - `typeAnnotation`: `TypeAnnotation | TSTypeAnnotation | Noop` (default: `null`) + +--- + +### returnStatement +```javascript +t.returnStatement(argument) +``` + +See also `t.isReturnStatement(node, opts)` and `t.assertReturnStatement(node, opts)`. + +Aliases: `Statement`, `Terminatorless`, `CompletionStatement` + + - `argument`: `Expression` (default: `null`) + +--- + +### sequenceExpression +```javascript +t.sequenceExpression(expressions) +``` + +See also `t.isSequenceExpression(node, opts)` and `t.assertSequenceExpression(node, opts)`. + +Aliases: `Expression` + + - `expressions`: `Array` (required) + +--- + +### spreadElement +```javascript +t.spreadElement(argument) +``` + +See also `t.isSpreadElement(node, opts)` and `t.assertSpreadElement(node, opts)`. + +Aliases: `UnaryLike` + + - `argument`: `Expression` (required) + +--- + +### stringLiteral +```javascript +t.stringLiteral(value) +``` + +See also `t.isStringLiteral(node, opts)` and `t.assertStringLiteral(node, opts)`. + +Aliases: `Expression`, `Pureish`, `Literal`, `Immutable` + + - `value`: `string` (required) + +--- + +### stringLiteralTypeAnnotation +```javascript +t.stringLiteralTypeAnnotation() +``` + +See also `t.isStringLiteralTypeAnnotation(node, opts)` and `t.assertStringLiteralTypeAnnotation(node, opts)`. + +Aliases: `Flow` + + +--- + +### stringTypeAnnotation +```javascript +t.stringTypeAnnotation() +``` + +See also `t.isStringTypeAnnotation(node, opts)` and `t.assertStringTypeAnnotation(node, opts)`. + +Aliases: `Flow`, `FlowBaseAnnotation` + + +--- + +### super +```javascript +t.super() +``` + +See also `t.isSuper(node, opts)` and `t.assertSuper(node, opts)`. + +Aliases: `Expression` + + +--- + +### switchCase +```javascript +t.switchCase(test, consequent) +``` + +See also `t.isSwitchCase(node, opts)` and `t.assertSwitchCase(node, opts)`. + + - `test`: `Expression` (default: `null`) + - `consequent`: `Array` (required) + +--- + +### switchStatement +```javascript +t.switchStatement(discriminant, cases) +``` + +See also `t.isSwitchStatement(node, opts)` and `t.assertSwitchStatement(node, opts)`. + +Aliases: `Statement`, `BlockParent`, `Scopable` + + - `discriminant`: `Expression` (required) + - `cases`: `Array` (required) + +--- + +### tSAnyKeyword +```javascript +t.tSAnyKeyword() +``` + +See also `t.isTSAnyKeyword(node, opts)` and `t.assertTSAnyKeyword(node, opts)`. + +Aliases: `TSType` + + +--- + +### tSArrayType +```javascript +t.tSArrayType(elementType) +``` + +See also `t.isTSArrayType(node, opts)` and `t.assertTSArrayType(node, opts)`. + +Aliases: `TSType` + + - `elementType`: `TSType` (required) + +--- + +### tSAsExpression +```javascript +t.tSAsExpression(expression, typeAnnotation) +``` + +See also `t.isTSAsExpression(node, opts)` and `t.assertTSAsExpression(node, opts)`. + +Aliases: `Expression` + + - `expression`: `Expression` (required) + - `typeAnnotation`: `TSType` (required) + +--- + +### tSBooleanKeyword +```javascript +t.tSBooleanKeyword() +``` + +See also `t.isTSBooleanKeyword(node, opts)` and `t.assertTSBooleanKeyword(node, opts)`. + +Aliases: `TSType` + + +--- + +### tSCallSignatureDeclaration +```javascript +t.tSCallSignatureDeclaration(typeParameters, parameters, typeAnnotation) +``` + +See also `t.isTSCallSignatureDeclaration(node, opts)` and `t.assertTSCallSignatureDeclaration(node, opts)`. + +Aliases: `TSTypeElement` + + - `typeParameters`: `TSTypeParameterDeclaration` (default: `null`) + - `parameters`: `Array` (default: `null`) + - `typeAnnotation`: `TSTypeAnnotation` (default: `null`) + +--- + +### tSConstructSignatureDeclaration +```javascript +t.tSConstructSignatureDeclaration(typeParameters, parameters, typeAnnotation) +``` + +See also `t.isTSConstructSignatureDeclaration(node, opts)` and `t.assertTSConstructSignatureDeclaration(node, opts)`. + +Aliases: `TSTypeElement` + + - `typeParameters`: `TSTypeParameterDeclaration` (default: `null`) + - `parameters`: `Array` (default: `null`) + - `typeAnnotation`: `TSTypeAnnotation` (default: `null`) + +--- + +### tSConstructorType +```javascript +t.tSConstructorType(typeParameters, typeAnnotation) +``` + +See also `t.isTSConstructorType(node, opts)` and `t.assertTSConstructorType(node, opts)`. + +Aliases: `TSType` + + - `typeParameters`: `TSTypeParameterDeclaration` (default: `null`) + - `typeAnnotation`: `TSTypeAnnotation` (default: `null`) + - `parameters`: `Array` (default: `null`) + +--- + +### tSDeclareFunction +```javascript +t.tSDeclareFunction(id, typeParameters, params, returnType) +``` + +See also `t.isTSDeclareFunction(node, opts)` and `t.assertTSDeclareFunction(node, opts)`. + +Aliases: `Statement`, `Declaration` + + - `id`: `Identifier` (default: `null`) + - `typeParameters`: `TSTypeParameterDeclaration | Noop` (default: `null`) + - `params`: `Array` (required) + - `returnType`: `TSTypeAnnotation | Noop` (default: `null`) + - `async`: `boolean` (default: `false`) + - `declare`: `boolean` (default: `null`) + - `generator`: `boolean` (default: `false`) + +--- + +### tSDeclareMethod +```javascript +t.tSDeclareMethod(decorators, key, typeParameters, params, returnType) +``` + +See also `t.isTSDeclareMethod(node, opts)` and `t.assertTSDeclareMethod(node, opts)`. + + - `decorators`: `Array` (default: `null`) + - `key` (required) + - `typeParameters`: `TSTypeParameterDeclaration | Noop` (default: `null`) + - `params`: `Array` (required) + - `returnType`: `TSTypeAnnotation | Noop` (default: `null`) + - `abstract`: `boolean` (default: `null`) + - `access`: `"public" | "private" | "protected"` (default: `null`) + - `accessibility`: `"public" | "private" | "protected"` (default: `null`) + - `async`: `boolean` (default: `false`) + - `computed`: `boolean` (default: `false`) + - `generator`: `boolean` (default: `false`) + - `kind`: `"get" | "set" | "method" | "constructor"` (default: `'method'`) + - `optional`: `boolean` (default: `null`) + - `static`: `boolean` (default: `null`) + +--- + +### tSEnumDeclaration +```javascript +t.tSEnumDeclaration(id, members) +``` + +See also `t.isTSEnumDeclaration(node, opts)` and `t.assertTSEnumDeclaration(node, opts)`. + +Aliases: `Statement`, `Declaration` + + - `id`: `Identifier` (required) + - `members`: `Array` (required) + - `const`: `boolean` (default: `null`) + - `declare`: `boolean` (default: `null`) + - `initializer`: `Expression` (default: `null`) + +--- + +### tSEnumMember +```javascript +t.tSEnumMember(id, initializer) +``` + +See also `t.isTSEnumMember(node, opts)` and `t.assertTSEnumMember(node, opts)`. + + - `id`: `Identifier | StringLiteral` (required) + - `initializer`: `Expression` (default: `null`) + +--- + +### tSExportAssignment +```javascript +t.tSExportAssignment(expression) +``` + +See also `t.isTSExportAssignment(node, opts)` and `t.assertTSExportAssignment(node, opts)`. + +Aliases: `Statement` + + - `expression`: `Expression` (required) + +--- + +### tSExpressionWithTypeArguments +```javascript +t.tSExpressionWithTypeArguments(expression, typeParameters) +``` + +See also `t.isTSExpressionWithTypeArguments(node, opts)` and `t.assertTSExpressionWithTypeArguments(node, opts)`. + +Aliases: `TSType` + + - `expression`: `TSEntityName` (required) + - `typeParameters`: `TSTypeParameterInstantiation` (default: `null`) + +--- + +### tSExternalModuleReference +```javascript +t.tSExternalModuleReference(expression) +``` + +See also `t.isTSExternalModuleReference(node, opts)` and `t.assertTSExternalModuleReference(node, opts)`. + + - `expression`: `StringLiteral` (required) + +--- + +### tSFunctionType +```javascript +t.tSFunctionType(typeParameters, typeAnnotation) +``` + +See also `t.isTSFunctionType(node, opts)` and `t.assertTSFunctionType(node, opts)`. + +Aliases: `TSType` + + - `typeParameters`: `TSTypeParameterDeclaration` (default: `null`) + - `typeAnnotation`: `TSTypeAnnotation` (default: `null`) + - `parameters`: `Array` (default: `null`) + +--- + +### tSImportEqualsDeclaration +```javascript +t.tSImportEqualsDeclaration(id, moduleReference) +``` + +See also `t.isTSImportEqualsDeclaration(node, opts)` and `t.assertTSImportEqualsDeclaration(node, opts)`. + +Aliases: `Statement` + + - `id`: `Identifier` (required) + - `moduleReference`: `TSEntityName | TSExternalModuleReference` (required) + - `isExport`: `boolean` (default: `null`) + +--- + +### tSIndexSignature +```javascript +t.tSIndexSignature(parameters, typeAnnotation) +``` + +See also `t.isTSIndexSignature(node, opts)` and `t.assertTSIndexSignature(node, opts)`. + +Aliases: `TSTypeElement` + + - `parameters`: `Array` (required) + - `typeAnnotation`: `TSTypeAnnotation` (default: `null`) + - `readonly`: `boolean` (default: `null`) + +--- + +### tSIndexedAccessType +```javascript +t.tSIndexedAccessType(objectType, indexType) +``` + +See also `t.isTSIndexedAccessType(node, opts)` and `t.assertTSIndexedAccessType(node, opts)`. + +Aliases: `TSType` + + - `objectType`: `TSType` (required) + - `indexType`: `TSType` (required) + +--- + +### tSInterfaceBody +```javascript +t.tSInterfaceBody(body) +``` + +See also `t.isTSInterfaceBody(node, opts)` and `t.assertTSInterfaceBody(node, opts)`. + + - `body`: `Array` (required) + +--- + +### tSInterfaceDeclaration +```javascript +t.tSInterfaceDeclaration(id, typeParameters, extends, body) +``` + +See also `t.isTSInterfaceDeclaration(node, opts)` and `t.assertTSInterfaceDeclaration(node, opts)`. + +Aliases: `Statement`, `Declaration` + + - `id`: `Identifier` (required) + - `typeParameters`: `TSTypeParameterDeclaration` (default: `null`) + - `extends`: `Array` (default: `null`) + - `body`: `TSInterfaceBody` (required) + - `declare`: `boolean` (default: `null`) + +--- + +### tSIntersectionType +```javascript +t.tSIntersectionType(types) +``` + +See also `t.isTSIntersectionType(node, opts)` and `t.assertTSIntersectionType(node, opts)`. + +Aliases: `TSType` + + - `types`: `Array` (required) + +--- + +### tSLiteralType +```javascript +t.tSLiteralType(literal) +``` + +See also `t.isTSLiteralType(node, opts)` and `t.assertTSLiteralType(node, opts)`. + +Aliases: `TSType` + + - `literal`: `NumericLiteral | StringLiteral | BooleanLiteral` (required) + +--- + +### tSMappedType +```javascript +t.tSMappedType(typeParameter, typeAnnotation) +``` + +See also `t.isTSMappedType(node, opts)` and `t.assertTSMappedType(node, opts)`. + +Aliases: `TSType` + + - `typeParameter`: `TSTypeParameter` (required) + - `typeAnnotation`: `TSType` (default: `null`) + - `optional`: `boolean` (default: `null`) + - `readonly`: `boolean` (default: `null`) + +--- + +### tSMethodSignature +```javascript +t.tSMethodSignature(key, typeParameters, parameters, typeAnnotation) +``` + +See also `t.isTSMethodSignature(node, opts)` and `t.assertTSMethodSignature(node, opts)`. + +Aliases: `TSTypeElement` + + - `key`: `Expression` (required) + - `typeParameters`: `TSTypeParameterDeclaration` (default: `null`) + - `parameters`: `Array` (default: `null`) + - `typeAnnotation`: `TSTypeAnnotation` (default: `null`) + - `computed`: `boolean` (default: `null`) + - `optional`: `boolean` (default: `null`) + +--- + +### tSModuleBlock +```javascript +t.tSModuleBlock(body) +``` + +See also `t.isTSModuleBlock(node, opts)` and `t.assertTSModuleBlock(node, opts)`. + + - `body`: `Array` (required) + +--- + +### tSModuleDeclaration +```javascript +t.tSModuleDeclaration(id, body) +``` + +See also `t.isTSModuleDeclaration(node, opts)` and `t.assertTSModuleDeclaration(node, opts)`. + +Aliases: `Statement`, `Declaration` + + - `id`: `Identifier | StringLiteral` (required) + - `body`: `TSModuleBlock | TSModuleDeclaration` (required) + - `declare`: `boolean` (default: `null`) + - `global`: `boolean` (default: `null`) + +--- + +### tSNamespaceExportDeclaration +```javascript +t.tSNamespaceExportDeclaration(id) +``` + +See also `t.isTSNamespaceExportDeclaration(node, opts)` and `t.assertTSNamespaceExportDeclaration(node, opts)`. + +Aliases: `Statement` + + - `id`: `Identifier` (required) + +--- + +### tSNeverKeyword +```javascript +t.tSNeverKeyword() +``` + +See also `t.isTSNeverKeyword(node, opts)` and `t.assertTSNeverKeyword(node, opts)`. + +Aliases: `TSType` + + +--- + +### tSNonNullExpression +```javascript +t.tSNonNullExpression(expression) +``` + +See also `t.isTSNonNullExpression(node, opts)` and `t.assertTSNonNullExpression(node, opts)`. + +Aliases: `Expression` + + - `expression`: `Expression` (required) + +--- + +### tSNullKeyword +```javascript +t.tSNullKeyword() +``` + +See also `t.isTSNullKeyword(node, opts)` and `t.assertTSNullKeyword(node, opts)`. + +Aliases: `TSType` + + +--- + +### tSNumberKeyword +```javascript +t.tSNumberKeyword() +``` + +See also `t.isTSNumberKeyword(node, opts)` and `t.assertTSNumberKeyword(node, opts)`. + +Aliases: `TSType` + + +--- + +### tSObjectKeyword +```javascript +t.tSObjectKeyword() +``` + +See also `t.isTSObjectKeyword(node, opts)` and `t.assertTSObjectKeyword(node, opts)`. + +Aliases: `TSType` + + +--- + +### tSParameterProperty +```javascript +t.tSParameterProperty(parameter) +``` + +See also `t.isTSParameterProperty(node, opts)` and `t.assertTSParameterProperty(node, opts)`. + +Aliases: `LVal` + + - `parameter`: `Identifier | AssignmentPattern` (required) + - `accessibility`: `'public' | 'private' | 'protected'` (default: `null`) + - `readonly`: `boolean` (default: `null`) + +--- + +### tSParenthesizedType +```javascript +t.tSParenthesizedType(typeAnnotation) +``` + +See also `t.isTSParenthesizedType(node, opts)` and `t.assertTSParenthesizedType(node, opts)`. + +Aliases: `TSType` + + - `typeAnnotation`: `TSType` (required) + +--- + +### tSPropertySignature +```javascript +t.tSPropertySignature(key, typeAnnotation, initializer) +``` + +See also `t.isTSPropertySignature(node, opts)` and `t.assertTSPropertySignature(node, opts)`. + +Aliases: `TSTypeElement` + + - `key`: `Expression` (required) + - `typeAnnotation`: `TSTypeAnnotation` (default: `null`) + - `initializer`: `Expression` (default: `null`) + - `computed`: `boolean` (default: `null`) + - `optional`: `boolean` (default: `null`) + - `readonly`: `boolean` (default: `null`) + +--- + +### tSQualifiedName +```javascript +t.tSQualifiedName(left, right) +``` + +See also `t.isTSQualifiedName(node, opts)` and `t.assertTSQualifiedName(node, opts)`. + +Aliases: `TSEntityName` + + - `left`: `TSEntityName` (required) + - `right`: `Identifier` (required) + +--- + +### tSStringKeyword +```javascript +t.tSStringKeyword() +``` + +See also `t.isTSStringKeyword(node, opts)` and `t.assertTSStringKeyword(node, opts)`. + +Aliases: `TSType` + + +--- + +### tSSymbolKeyword +```javascript +t.tSSymbolKeyword() +``` + +See also `t.isTSSymbolKeyword(node, opts)` and `t.assertTSSymbolKeyword(node, opts)`. + +Aliases: `TSType` + + +--- + +### tSThisType +```javascript +t.tSThisType() +``` + +See also `t.isTSThisType(node, opts)` and `t.assertTSThisType(node, opts)`. + +Aliases: `TSType` + + +--- + +### tSTupleType +```javascript +t.tSTupleType(elementTypes) +``` + +See also `t.isTSTupleType(node, opts)` and `t.assertTSTupleType(node, opts)`. + +Aliases: `TSType` + + - `elementTypes`: `Array` (required) + +--- + +### tSTypeAliasDeclaration +```javascript +t.tSTypeAliasDeclaration(id, typeParameters, typeAnnotation) +``` + +See also `t.isTSTypeAliasDeclaration(node, opts)` and `t.assertTSTypeAliasDeclaration(node, opts)`. + +Aliases: `Statement`, `Declaration` + + - `id`: `Identifier` (required) + - `typeParameters`: `TSTypeParameterDeclaration` (default: `null`) + - `typeAnnotation`: `TSType` (required) + - `declare`: `boolean` (default: `null`) + +--- + +### tSTypeAnnotation +```javascript +t.tSTypeAnnotation(typeAnnotation) +``` + +See also `t.isTSTypeAnnotation(node, opts)` and `t.assertTSTypeAnnotation(node, opts)`. + + - `typeAnnotation`: `TSType` (required) + +--- + +### tSTypeAssertion +```javascript +t.tSTypeAssertion(typeAnnotation, expression) +``` + +See also `t.isTSTypeAssertion(node, opts)` and `t.assertTSTypeAssertion(node, opts)`. + +Aliases: `Expression` + + - `typeAnnotation`: `TSType` (required) + - `expression`: `Expression` (required) + +--- + +### tSTypeLiteral +```javascript +t.tSTypeLiteral(members) +``` + +See also `t.isTSTypeLiteral(node, opts)` and `t.assertTSTypeLiteral(node, opts)`. + +Aliases: `TSType` + + - `members`: `Array` (required) + +--- + +### tSTypeOperator +```javascript +t.tSTypeOperator(typeAnnotation) +``` + +See also `t.isTSTypeOperator(node, opts)` and `t.assertTSTypeOperator(node, opts)`. + +Aliases: `TSType` + + - `typeAnnotation`: `TSType` (required) + - `operator`: `string` (default: `null`) + +--- + +### tSTypeParameter +```javascript +t.tSTypeParameter(constraint, default) +``` + +See also `t.isTSTypeParameter(node, opts)` and `t.assertTSTypeParameter(node, opts)`. + + - `constraint`: `TSType` (default: `null`) + - `default`: `TSType` (default: `null`) + - `name`: `string` (default: `null`) + +--- + +### tSTypeParameterDeclaration +```javascript +t.tSTypeParameterDeclaration(params) +``` + +See also `t.isTSTypeParameterDeclaration(node, opts)` and `t.assertTSTypeParameterDeclaration(node, opts)`. + + - `params`: `Array` (required) + +--- + +### tSTypeParameterInstantiation +```javascript +t.tSTypeParameterInstantiation(params) +``` + +See also `t.isTSTypeParameterInstantiation(node, opts)` and `t.assertTSTypeParameterInstantiation(node, opts)`. + + - `params`: `Array` (required) + +--- + +### tSTypePredicate +```javascript +t.tSTypePredicate(parameterName, typeAnnotation) +``` + +See also `t.isTSTypePredicate(node, opts)` and `t.assertTSTypePredicate(node, opts)`. + +Aliases: `TSType` + + - `parameterName`: `Identifier | TSThisType` (required) + - `typeAnnotation`: `TSTypeAnnotation` (required) + +--- + +### tSTypeQuery +```javascript +t.tSTypeQuery(exprName) +``` + +See also `t.isTSTypeQuery(node, opts)` and `t.assertTSTypeQuery(node, opts)`. + +Aliases: `TSType` + + - `exprName`: `TSEntityName` (required) + +--- + +### tSTypeReference +```javascript +t.tSTypeReference(typeName, typeParameters) +``` + +See also `t.isTSTypeReference(node, opts)` and `t.assertTSTypeReference(node, opts)`. + +Aliases: `TSType` + + - `typeName`: `TSEntityName` (required) + - `typeParameters`: `TSTypeParameterInstantiation` (default: `null`) + +--- + +### tSUndefinedKeyword +```javascript +t.tSUndefinedKeyword() +``` + +See also `t.isTSUndefinedKeyword(node, opts)` and `t.assertTSUndefinedKeyword(node, opts)`. + +Aliases: `TSType` + + +--- + +### tSUnionType +```javascript +t.tSUnionType(types) +``` + +See also `t.isTSUnionType(node, opts)` and `t.assertTSUnionType(node, opts)`. + +Aliases: `TSType` + + - `types`: `Array` (required) + +--- + +### tSVoidKeyword +```javascript +t.tSVoidKeyword() +``` + +See also `t.isTSVoidKeyword(node, opts)` and `t.assertTSVoidKeyword(node, opts)`. + +Aliases: `TSType` + + +--- + +### taggedTemplateExpression +```javascript +t.taggedTemplateExpression(tag, quasi) +``` + +See also `t.isTaggedTemplateExpression(node, opts)` and `t.assertTaggedTemplateExpression(node, opts)`. + +Aliases: `Expression` + + - `tag`: `Expression` (required) + - `quasi`: `TemplateLiteral` (required) + +--- + +### templateElement +```javascript +t.templateElement(value, tail) +``` + +See also `t.isTemplateElement(node, opts)` and `t.assertTemplateElement(node, opts)`. + + - `value` (required) + - `tail`: `boolean` (default: `false`) + +--- + +### templateLiteral +```javascript +t.templateLiteral(quasis, expressions) +``` + +See also `t.isTemplateLiteral(node, opts)` and `t.assertTemplateLiteral(node, opts)`. + +Aliases: `Expression`, `Literal` + + - `quasis`: `Array` (required) + - `expressions`: `Array` (required) + +--- + +### thisExpression +```javascript +t.thisExpression() +``` + +See also `t.isThisExpression(node, opts)` and `t.assertThisExpression(node, opts)`. + +Aliases: `Expression` + + +--- + +### thisTypeAnnotation +```javascript +t.thisTypeAnnotation() +``` + +See also `t.isThisTypeAnnotation(node, opts)` and `t.assertThisTypeAnnotation(node, opts)`. + +Aliases: `Flow`, `FlowBaseAnnotation` + + +--- + +### throwStatement +```javascript +t.throwStatement(argument) +``` + +See also `t.isThrowStatement(node, opts)` and `t.assertThrowStatement(node, opts)`. + +Aliases: `Statement`, `Terminatorless`, `CompletionStatement` + + - `argument`: `Expression` (required) + +--- + +### tryStatement +```javascript +t.tryStatement(block, handler, finalizer) +``` + +See also `t.isTryStatement(node, opts)` and `t.assertTryStatement(node, opts)`. + +Aliases: `Statement` + + - `block`: `BlockStatement` (required) + - `handler`: `CatchClause` (default: `null`) + - `finalizer`: `BlockStatement` (default: `null`) + +--- + +### tupleTypeAnnotation +```javascript +t.tupleTypeAnnotation(types) +``` + +See also `t.isTupleTypeAnnotation(node, opts)` and `t.assertTupleTypeAnnotation(node, opts)`. + +Aliases: `Flow` + + - `types` (required) + +--- + +### typeAlias +```javascript +t.typeAlias(id, typeParameters, right) +``` + +See also `t.isTypeAlias(node, opts)` and `t.assertTypeAlias(node, opts)`. + +Aliases: `Flow`, `FlowDeclaration`, `Statement`, `Declaration` + + - `id` (required) + - `typeParameters` (required) + - `right` (required) + +--- + +### typeAnnotation +```javascript +t.typeAnnotation(typeAnnotation) +``` + +See also `t.isTypeAnnotation(node, opts)` and `t.assertTypeAnnotation(node, opts)`. + +Aliases: `Flow` + + - `typeAnnotation`: `Flow` (required) + +--- + +### typeCastExpression +```javascript +t.typeCastExpression(expression, typeAnnotation) +``` + +See also `t.isTypeCastExpression(node, opts)` and `t.assertTypeCastExpression(node, opts)`. + +Aliases: `Flow`, `ExpressionWrapper`, `Expression` + + - `expression` (required) + - `typeAnnotation` (required) + +--- + +### typeParameter +```javascript +t.typeParameter(bound, default) +``` + +See also `t.isTypeParameter(node, opts)` and `t.assertTypeParameter(node, opts)`. + +Aliases: `Flow` + + - `bound`: `TypeAnnotation` (default: `null`) + - `default`: `Flow` (default: `null`) + - `name`: `string` (default: `null`) + +--- + +### typeParameterDeclaration +```javascript +t.typeParameterDeclaration(params) +``` + +See also `t.isTypeParameterDeclaration(node, opts)` and `t.assertTypeParameterDeclaration(node, opts)`. + +Aliases: `Flow` + + - `params`: `Array` (required) + +--- + +### typeParameterInstantiation +```javascript +t.typeParameterInstantiation(params) +``` + +See also `t.isTypeParameterInstantiation(node, opts)` and `t.assertTypeParameterInstantiation(node, opts)`. + +Aliases: `Flow` + + - `params`: `Array` (required) + +--- + +### typeofTypeAnnotation +```javascript +t.typeofTypeAnnotation(argument) +``` + +See also `t.isTypeofTypeAnnotation(node, opts)` and `t.assertTypeofTypeAnnotation(node, opts)`. + +Aliases: `Flow` + + - `argument` (required) + +--- + +### unaryExpression +```javascript +t.unaryExpression(operator, argument, prefix) +``` + +See also `t.isUnaryExpression(node, opts)` and `t.assertUnaryExpression(node, opts)`. + +Aliases: `UnaryLike`, `Expression` + + - `operator`: `'void' | 'throw' | 'delete' | '!' | '+' | '-' | '~' | 'typeof'` (required) + - `argument`: `Expression` (required) + - `prefix`: `boolean` (default: `true`) + +--- + +### unionTypeAnnotation +```javascript +t.unionTypeAnnotation(types) +``` + +See also `t.isUnionTypeAnnotation(node, opts)` and `t.assertUnionTypeAnnotation(node, opts)`. + +Aliases: `Flow` + + - `types` (required) + +--- + +### updateExpression +```javascript +t.updateExpression(operator, argument, prefix) +``` + +See also `t.isUpdateExpression(node, opts)` and `t.assertUpdateExpression(node, opts)`. + +Aliases: `Expression` + + - `operator`: `'++' | '--'` (required) + - `argument`: `Expression` (required) + - `prefix`: `boolean` (default: `false`) + +--- + +### variableDeclaration +```javascript +t.variableDeclaration(kind, declarations) +``` + +See also `t.isVariableDeclaration(node, opts)` and `t.assertVariableDeclaration(node, opts)`. + +Aliases: `Statement`, `Declaration` + + - `kind`: `"var" | "let" | "const"` (required) + - `declarations`: `Array` (required) + - `declare`: `boolean` (default: `null`) + +--- + +### variableDeclarator +```javascript +t.variableDeclarator(id, init) +``` + +See also `t.isVariableDeclarator(node, opts)` and `t.assertVariableDeclarator(node, opts)`. + + - `id`: `LVal` (required) + - `init`: `Expression` (default: `null`) + +--- + +### voidTypeAnnotation +```javascript +t.voidTypeAnnotation() +``` + +See also `t.isVoidTypeAnnotation(node, opts)` and `t.assertVoidTypeAnnotation(node, opts)`. + +Aliases: `Flow`, `FlowBaseAnnotation` + + +--- + +### whileStatement +```javascript +t.whileStatement(test, body) +``` + +See also `t.isWhileStatement(node, opts)` and `t.assertWhileStatement(node, opts)`. + +Aliases: `Statement`, `BlockParent`, `Loop`, `While`, `Scopable` + + - `test`: `Expression` (required) + - `body`: `BlockStatement | Statement` (required) + +--- + +### withStatement +```javascript +t.withStatement(object, body) +``` + +See also `t.isWithStatement(node, opts)` and `t.assertWithStatement(node, opts)`. + +Aliases: `Statement` + + - `object`: `Expression` (required) + - `body`: `BlockStatement | Statement` (required) + +--- + +### yieldExpression +```javascript +t.yieldExpression(argument, delegate) +``` + +See also `t.isYieldExpression(node, opts)` and `t.assertYieldExpression(node, opts)`. + +Aliases: `Expression`, `Terminatorless` + + - `argument`: `Expression` (default: `null`) + - `delegate`: `boolean` (default: `false`) + +--- + + + + diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/asserts/assertNode.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/asserts/assertNode.js new file mode 100644 index 00000000000000..783ee0dbccfae8 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/asserts/assertNode.js @@ -0,0 +1,15 @@ +"use strict"; + +exports.__esModule = true; +exports.default = assertNode; + +var _isNode = _interopRequireDefault(require("../validators/isNode")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function assertNode(node) { + if (!(0, _isNode.default)(node)) { + var type = node && node.type || JSON.stringify(node); + throw new TypeError("Not a valid node of type \"" + type + "\""); + } +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/asserts/generated/index.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/asserts/generated/index.js new file mode 100644 index 00000000000000..8c2b91eed30430 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/asserts/generated/index.js @@ -0,0 +1,2215 @@ +"use strict"; + +exports.__esModule = true; +exports.assertArrayExpression = assertArrayExpression; +exports.assertAssignmentExpression = assertAssignmentExpression; +exports.assertBinaryExpression = assertBinaryExpression; +exports.assertDirective = assertDirective; +exports.assertDirectiveLiteral = assertDirectiveLiteral; +exports.assertBlockStatement = assertBlockStatement; +exports.assertBreakStatement = assertBreakStatement; +exports.assertCallExpression = assertCallExpression; +exports.assertCatchClause = assertCatchClause; +exports.assertConditionalExpression = assertConditionalExpression; +exports.assertContinueStatement = assertContinueStatement; +exports.assertDebuggerStatement = assertDebuggerStatement; +exports.assertDoWhileStatement = assertDoWhileStatement; +exports.assertEmptyStatement = assertEmptyStatement; +exports.assertExpressionStatement = assertExpressionStatement; +exports.assertFile = assertFile; +exports.assertForInStatement = assertForInStatement; +exports.assertForStatement = assertForStatement; +exports.assertFunctionDeclaration = assertFunctionDeclaration; +exports.assertFunctionExpression = assertFunctionExpression; +exports.assertIdentifier = assertIdentifier; +exports.assertIfStatement = assertIfStatement; +exports.assertLabeledStatement = assertLabeledStatement; +exports.assertStringLiteral = assertStringLiteral; +exports.assertNumericLiteral = assertNumericLiteral; +exports.assertNullLiteral = assertNullLiteral; +exports.assertBooleanLiteral = assertBooleanLiteral; +exports.assertRegExpLiteral = assertRegExpLiteral; +exports.assertLogicalExpression = assertLogicalExpression; +exports.assertMemberExpression = assertMemberExpression; +exports.assertNewExpression = assertNewExpression; +exports.assertProgram = assertProgram; +exports.assertObjectExpression = assertObjectExpression; +exports.assertObjectMethod = assertObjectMethod; +exports.assertObjectProperty = assertObjectProperty; +exports.assertRestElement = assertRestElement; +exports.assertReturnStatement = assertReturnStatement; +exports.assertSequenceExpression = assertSequenceExpression; +exports.assertSwitchCase = assertSwitchCase; +exports.assertSwitchStatement = assertSwitchStatement; +exports.assertThisExpression = assertThisExpression; +exports.assertThrowStatement = assertThrowStatement; +exports.assertTryStatement = assertTryStatement; +exports.assertUnaryExpression = assertUnaryExpression; +exports.assertUpdateExpression = assertUpdateExpression; +exports.assertVariableDeclaration = assertVariableDeclaration; +exports.assertVariableDeclarator = assertVariableDeclarator; +exports.assertWhileStatement = assertWhileStatement; +exports.assertWithStatement = assertWithStatement; +exports.assertAssignmentPattern = assertAssignmentPattern; +exports.assertArrayPattern = assertArrayPattern; +exports.assertArrowFunctionExpression = assertArrowFunctionExpression; +exports.assertClassBody = assertClassBody; +exports.assertClassDeclaration = assertClassDeclaration; +exports.assertClassExpression = assertClassExpression; +exports.assertExportAllDeclaration = assertExportAllDeclaration; +exports.assertExportDefaultDeclaration = assertExportDefaultDeclaration; +exports.assertExportNamedDeclaration = assertExportNamedDeclaration; +exports.assertExportSpecifier = assertExportSpecifier; +exports.assertForOfStatement = assertForOfStatement; +exports.assertImportDeclaration = assertImportDeclaration; +exports.assertImportDefaultSpecifier = assertImportDefaultSpecifier; +exports.assertImportNamespaceSpecifier = assertImportNamespaceSpecifier; +exports.assertImportSpecifier = assertImportSpecifier; +exports.assertMetaProperty = assertMetaProperty; +exports.assertClassMethod = assertClassMethod; +exports.assertObjectPattern = assertObjectPattern; +exports.assertSpreadElement = assertSpreadElement; +exports.assertSuper = assertSuper; +exports.assertTaggedTemplateExpression = assertTaggedTemplateExpression; +exports.assertTemplateElement = assertTemplateElement; +exports.assertTemplateLiteral = assertTemplateLiteral; +exports.assertYieldExpression = assertYieldExpression; +exports.assertAnyTypeAnnotation = assertAnyTypeAnnotation; +exports.assertArrayTypeAnnotation = assertArrayTypeAnnotation; +exports.assertBooleanTypeAnnotation = assertBooleanTypeAnnotation; +exports.assertBooleanLiteralTypeAnnotation = assertBooleanLiteralTypeAnnotation; +exports.assertNullLiteralTypeAnnotation = assertNullLiteralTypeAnnotation; +exports.assertClassImplements = assertClassImplements; +exports.assertDeclareClass = assertDeclareClass; +exports.assertDeclareFunction = assertDeclareFunction; +exports.assertDeclareInterface = assertDeclareInterface; +exports.assertDeclareModule = assertDeclareModule; +exports.assertDeclareModuleExports = assertDeclareModuleExports; +exports.assertDeclareTypeAlias = assertDeclareTypeAlias; +exports.assertDeclareOpaqueType = assertDeclareOpaqueType; +exports.assertDeclareVariable = assertDeclareVariable; +exports.assertDeclareExportDeclaration = assertDeclareExportDeclaration; +exports.assertDeclareExportAllDeclaration = assertDeclareExportAllDeclaration; +exports.assertDeclaredPredicate = assertDeclaredPredicate; +exports.assertExistsTypeAnnotation = assertExistsTypeAnnotation; +exports.assertFunctionTypeAnnotation = assertFunctionTypeAnnotation; +exports.assertFunctionTypeParam = assertFunctionTypeParam; +exports.assertGenericTypeAnnotation = assertGenericTypeAnnotation; +exports.assertInferredPredicate = assertInferredPredicate; +exports.assertInterfaceExtends = assertInterfaceExtends; +exports.assertInterfaceDeclaration = assertInterfaceDeclaration; +exports.assertIntersectionTypeAnnotation = assertIntersectionTypeAnnotation; +exports.assertMixedTypeAnnotation = assertMixedTypeAnnotation; +exports.assertEmptyTypeAnnotation = assertEmptyTypeAnnotation; +exports.assertNullableTypeAnnotation = assertNullableTypeAnnotation; +exports.assertNumberLiteralTypeAnnotation = assertNumberLiteralTypeAnnotation; +exports.assertNumberTypeAnnotation = assertNumberTypeAnnotation; +exports.assertObjectTypeAnnotation = assertObjectTypeAnnotation; +exports.assertObjectTypeCallProperty = assertObjectTypeCallProperty; +exports.assertObjectTypeIndexer = assertObjectTypeIndexer; +exports.assertObjectTypeProperty = assertObjectTypeProperty; +exports.assertObjectTypeSpreadProperty = assertObjectTypeSpreadProperty; +exports.assertOpaqueType = assertOpaqueType; +exports.assertQualifiedTypeIdentifier = assertQualifiedTypeIdentifier; +exports.assertStringLiteralTypeAnnotation = assertStringLiteralTypeAnnotation; +exports.assertStringTypeAnnotation = assertStringTypeAnnotation; +exports.assertThisTypeAnnotation = assertThisTypeAnnotation; +exports.assertTupleTypeAnnotation = assertTupleTypeAnnotation; +exports.assertTypeofTypeAnnotation = assertTypeofTypeAnnotation; +exports.assertTypeAlias = assertTypeAlias; +exports.assertTypeAnnotation = assertTypeAnnotation; +exports.assertTypeCastExpression = assertTypeCastExpression; +exports.assertTypeParameter = assertTypeParameter; +exports.assertTypeParameterDeclaration = assertTypeParameterDeclaration; +exports.assertTypeParameterInstantiation = assertTypeParameterInstantiation; +exports.assertUnionTypeAnnotation = assertUnionTypeAnnotation; +exports.assertVoidTypeAnnotation = assertVoidTypeAnnotation; +exports.assertJSXAttribute = assertJSXAttribute; +exports.assertJSXClosingElement = assertJSXClosingElement; +exports.assertJSXElement = assertJSXElement; +exports.assertJSXEmptyExpression = assertJSXEmptyExpression; +exports.assertJSXExpressionContainer = assertJSXExpressionContainer; +exports.assertJSXSpreadChild = assertJSXSpreadChild; +exports.assertJSXIdentifier = assertJSXIdentifier; +exports.assertJSXMemberExpression = assertJSXMemberExpression; +exports.assertJSXNamespacedName = assertJSXNamespacedName; +exports.assertJSXOpeningElement = assertJSXOpeningElement; +exports.assertJSXSpreadAttribute = assertJSXSpreadAttribute; +exports.assertJSXText = assertJSXText; +exports.assertJSXFragment = assertJSXFragment; +exports.assertJSXOpeningFragment = assertJSXOpeningFragment; +exports.assertJSXClosingFragment = assertJSXClosingFragment; +exports.assertNoop = assertNoop; +exports.assertParenthesizedExpression = assertParenthesizedExpression; +exports.assertAwaitExpression = assertAwaitExpression; +exports.assertBindExpression = assertBindExpression; +exports.assertClassProperty = assertClassProperty; +exports.assertImport = assertImport; +exports.assertDecorator = assertDecorator; +exports.assertDoExpression = assertDoExpression; +exports.assertExportDefaultSpecifier = assertExportDefaultSpecifier; +exports.assertExportNamespaceSpecifier = assertExportNamespaceSpecifier; +exports.assertTSParameterProperty = assertTSParameterProperty; +exports.assertTSDeclareFunction = assertTSDeclareFunction; +exports.assertTSDeclareMethod = assertTSDeclareMethod; +exports.assertTSQualifiedName = assertTSQualifiedName; +exports.assertTSCallSignatureDeclaration = assertTSCallSignatureDeclaration; +exports.assertTSConstructSignatureDeclaration = assertTSConstructSignatureDeclaration; +exports.assertTSPropertySignature = assertTSPropertySignature; +exports.assertTSMethodSignature = assertTSMethodSignature; +exports.assertTSIndexSignature = assertTSIndexSignature; +exports.assertTSAnyKeyword = assertTSAnyKeyword; +exports.assertTSNumberKeyword = assertTSNumberKeyword; +exports.assertTSObjectKeyword = assertTSObjectKeyword; +exports.assertTSBooleanKeyword = assertTSBooleanKeyword; +exports.assertTSStringKeyword = assertTSStringKeyword; +exports.assertTSSymbolKeyword = assertTSSymbolKeyword; +exports.assertTSVoidKeyword = assertTSVoidKeyword; +exports.assertTSUndefinedKeyword = assertTSUndefinedKeyword; +exports.assertTSNullKeyword = assertTSNullKeyword; +exports.assertTSNeverKeyword = assertTSNeverKeyword; +exports.assertTSThisType = assertTSThisType; +exports.assertTSFunctionType = assertTSFunctionType; +exports.assertTSConstructorType = assertTSConstructorType; +exports.assertTSTypeReference = assertTSTypeReference; +exports.assertTSTypePredicate = assertTSTypePredicate; +exports.assertTSTypeQuery = assertTSTypeQuery; +exports.assertTSTypeLiteral = assertTSTypeLiteral; +exports.assertTSArrayType = assertTSArrayType; +exports.assertTSTupleType = assertTSTupleType; +exports.assertTSUnionType = assertTSUnionType; +exports.assertTSIntersectionType = assertTSIntersectionType; +exports.assertTSParenthesizedType = assertTSParenthesizedType; +exports.assertTSTypeOperator = assertTSTypeOperator; +exports.assertTSIndexedAccessType = assertTSIndexedAccessType; +exports.assertTSMappedType = assertTSMappedType; +exports.assertTSLiteralType = assertTSLiteralType; +exports.assertTSExpressionWithTypeArguments = assertTSExpressionWithTypeArguments; +exports.assertTSInterfaceDeclaration = assertTSInterfaceDeclaration; +exports.assertTSInterfaceBody = assertTSInterfaceBody; +exports.assertTSTypeAliasDeclaration = assertTSTypeAliasDeclaration; +exports.assertTSAsExpression = assertTSAsExpression; +exports.assertTSTypeAssertion = assertTSTypeAssertion; +exports.assertTSEnumDeclaration = assertTSEnumDeclaration; +exports.assertTSEnumMember = assertTSEnumMember; +exports.assertTSModuleDeclaration = assertTSModuleDeclaration; +exports.assertTSModuleBlock = assertTSModuleBlock; +exports.assertTSImportEqualsDeclaration = assertTSImportEqualsDeclaration; +exports.assertTSExternalModuleReference = assertTSExternalModuleReference; +exports.assertTSNonNullExpression = assertTSNonNullExpression; +exports.assertTSExportAssignment = assertTSExportAssignment; +exports.assertTSNamespaceExportDeclaration = assertTSNamespaceExportDeclaration; +exports.assertTSTypeAnnotation = assertTSTypeAnnotation; +exports.assertTSTypeParameterInstantiation = assertTSTypeParameterInstantiation; +exports.assertTSTypeParameterDeclaration = assertTSTypeParameterDeclaration; +exports.assertTSTypeParameter = assertTSTypeParameter; +exports.assertExpression = assertExpression; +exports.assertBinary = assertBinary; +exports.assertScopable = assertScopable; +exports.assertBlockParent = assertBlockParent; +exports.assertBlock = assertBlock; +exports.assertStatement = assertStatement; +exports.assertTerminatorless = assertTerminatorless; +exports.assertCompletionStatement = assertCompletionStatement; +exports.assertConditional = assertConditional; +exports.assertLoop = assertLoop; +exports.assertWhile = assertWhile; +exports.assertExpressionWrapper = assertExpressionWrapper; +exports.assertFor = assertFor; +exports.assertForXStatement = assertForXStatement; +exports.assertFunction = assertFunction; +exports.assertFunctionParent = assertFunctionParent; +exports.assertPureish = assertPureish; +exports.assertDeclaration = assertDeclaration; +exports.assertPatternLike = assertPatternLike; +exports.assertLVal = assertLVal; +exports.assertTSEntityName = assertTSEntityName; +exports.assertLiteral = assertLiteral; +exports.assertImmutable = assertImmutable; +exports.assertUserWhitespacable = assertUserWhitespacable; +exports.assertMethod = assertMethod; +exports.assertObjectMember = assertObjectMember; +exports.assertProperty = assertProperty; +exports.assertUnaryLike = assertUnaryLike; +exports.assertPattern = assertPattern; +exports.assertClass = assertClass; +exports.assertModuleDeclaration = assertModuleDeclaration; +exports.assertExportDeclaration = assertExportDeclaration; +exports.assertModuleSpecifier = assertModuleSpecifier; +exports.assertFlow = assertFlow; +exports.assertFlowBaseAnnotation = assertFlowBaseAnnotation; +exports.assertFlowDeclaration = assertFlowDeclaration; +exports.assertFlowPredicate = assertFlowPredicate; +exports.assertJSX = assertJSX; +exports.assertTSTypeElement = assertTSTypeElement; +exports.assertTSType = assertTSType; +exports.assertNumberLiteral = assertNumberLiteral; +exports.assertRegexLiteral = assertRegexLiteral; +exports.assertRestProperty = assertRestProperty; +exports.assertSpreadProperty = assertSpreadProperty; + +var _is = _interopRequireDefault(require("../../validators/is")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function assert(type, node, opts) { + if (!(0, _is.default)(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 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 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 assertClassDeclaration(node, opts) { + if (opts === void 0) { + opts = {}; + } + + assert("ClassDeclaration", node, opts); +} + +function assertClassExpression(node, opts) { + if (opts === void 0) { + opts = {}; + } + + assert("ClassExpression", 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 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 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 assertVoidTypeAnnotation(node, opts) { + if (opts === void 0) { + opts = {}; + } + + assert("VoidTypeAnnotation", 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 assertParenthesizedExpression(node, opts) { + if (opts === void 0) { + opts = {}; + } + + assert("ParenthesizedExpression", 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 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 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 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 assertTSBooleanKeyword(node, opts) { + if (opts === void 0) { + opts = {}; + } + + assert("TSBooleanKeyword", 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 assertTSVoidKeyword(node, opts) { + if (opts === void 0) { + opts = {}; + } + + assert("TSVoidKeyword", node, opts); +} + +function assertTSUndefinedKeyword(node, opts) { + if (opts === void 0) { + opts = {}; + } + + assert("TSUndefinedKeyword", node, opts); +} + +function assertTSNullKeyword(node, opts) { + if (opts === void 0) { + opts = {}; + } + + assert("TSNullKeyword", node, opts); +} + +function assertTSNeverKeyword(node, opts) { + if (opts === void 0) { + opts = {}; + } + + assert("TSNeverKeyword", 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 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 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 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 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 assertJSX(node, opts) { + if (opts === void 0) { + opts = {}; + } + + assert("JSX", 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); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/builders/builder.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/builders/builder.js new file mode 100644 index 00000000000000..4adf87032d41f1 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/builders/builder.js @@ -0,0 +1,44 @@ +"use strict"; + +exports.__esModule = true; +exports.default = builder; + +var _clone = _interopRequireDefault(require("lodash/clone")); + +var _definitions = require("../definitions"); + +var _validate = _interopRequireDefault(require("../validators/validate")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +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 = _definitions.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 = _definitions.NODE_FIELDS[type][key]; + var arg; + if (i < countArgs) arg = args[i]; + if (arg === undefined) arg = (0, _clone.default)(field.default); + node[key] = arg; + i++; + }); + + for (var key in node) { + (0, _validate.default)(node, key, node[key]); + } + + return node; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/builders/flow/createTypeAnnotationBasedOnTypeof.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/builders/flow/createTypeAnnotationBasedOnTypeof.js new file mode 100644 index 00000000000000..bff3b99b3f62e5 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/builders/flow/createTypeAnnotationBasedOnTypeof.js @@ -0,0 +1,26 @@ +"use strict"; + +exports.__esModule = true; +exports.default = createTypeAnnotationBasedOnTypeof; + +var _generated = require("../generated"); + +function createTypeAnnotationBasedOnTypeof(type) { + if (type === "string") { + return (0, _generated.stringTypeAnnotation)(); + } else if (type === "number") { + return (0, _generated.numberTypeAnnotation)(); + } else if (type === "undefined") { + return (0, _generated.voidTypeAnnotation)(); + } else if (type === "boolean") { + return (0, _generated.booleanTypeAnnotation)(); + } else if (type === "function") { + return (0, _generated.genericTypeAnnotation)((0, _generated.identifier)("Function")); + } else if (type === "object") { + return (0, _generated.genericTypeAnnotation)((0, _generated.identifier)("Object")); + } else if (type === "symbol") { + return (0, _generated.genericTypeAnnotation)((0, _generated.identifier)("Symbol")); + } else { + throw new Error("Invalid typeof value"); + } +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/builders/flow/createUnionTypeAnnotation.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/builders/flow/createUnionTypeAnnotation.js new file mode 100644 index 00000000000000..932e45972962ce --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/builders/flow/createUnionTypeAnnotation.js @@ -0,0 +1,20 @@ +"use strict"; + +exports.__esModule = true; +exports.default = createUnionTypeAnnotation; + +var _generated = require("../generated"); + +var _removeTypeDuplicates = _interopRequireDefault(require("../../modifications/flow/removeTypeDuplicates")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function createUnionTypeAnnotation(types) { + var flattened = (0, _removeTypeDuplicates.default)(types); + + if (flattened.length === 1) { + return flattened[0]; + } else { + return (0, _generated.unionTypeAnnotation)(flattened); + } +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/builders/generated/index.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/builders/generated/index.js new file mode 100644 index 00000000000000..632b628f8dd6bb --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/builders/generated/index.js @@ -0,0 +1,1869 @@ +"use strict"; + +exports.__esModule = true; +exports.arrayExpression = exports.ArrayExpression = ArrayExpression; +exports.assignmentExpression = exports.AssignmentExpression = AssignmentExpression; +exports.binaryExpression = exports.BinaryExpression = BinaryExpression; +exports.directive = exports.Directive = Directive; +exports.directiveLiteral = exports.DirectiveLiteral = DirectiveLiteral; +exports.blockStatement = exports.BlockStatement = BlockStatement; +exports.breakStatement = exports.BreakStatement = BreakStatement; +exports.callExpression = exports.CallExpression = CallExpression; +exports.catchClause = exports.CatchClause = CatchClause; +exports.conditionalExpression = exports.ConditionalExpression = ConditionalExpression; +exports.continueStatement = exports.ContinueStatement = ContinueStatement; +exports.debuggerStatement = exports.DebuggerStatement = DebuggerStatement; +exports.doWhileStatement = exports.DoWhileStatement = DoWhileStatement; +exports.emptyStatement = exports.EmptyStatement = EmptyStatement; +exports.expressionStatement = exports.ExpressionStatement = ExpressionStatement; +exports.file = exports.File = File; +exports.forInStatement = exports.ForInStatement = ForInStatement; +exports.forStatement = exports.ForStatement = ForStatement; +exports.functionDeclaration = exports.FunctionDeclaration = FunctionDeclaration; +exports.functionExpression = exports.FunctionExpression = FunctionExpression; +exports.identifier = exports.Identifier = Identifier; +exports.ifStatement = exports.IfStatement = IfStatement; +exports.labeledStatement = exports.LabeledStatement = LabeledStatement; +exports.stringLiteral = exports.StringLiteral = StringLiteral; +exports.numericLiteral = exports.NumericLiteral = NumericLiteral; +exports.nullLiteral = exports.NullLiteral = NullLiteral; +exports.booleanLiteral = exports.BooleanLiteral = BooleanLiteral; +exports.regExpLiteral = exports.RegExpLiteral = RegExpLiteral; +exports.logicalExpression = exports.LogicalExpression = LogicalExpression; +exports.memberExpression = exports.MemberExpression = MemberExpression; +exports.newExpression = exports.NewExpression = NewExpression; +exports.program = exports.Program = Program; +exports.objectExpression = exports.ObjectExpression = ObjectExpression; +exports.objectMethod = exports.ObjectMethod = ObjectMethod; +exports.objectProperty = exports.ObjectProperty = ObjectProperty; +exports.restElement = exports.RestElement = RestElement; +exports.returnStatement = exports.ReturnStatement = ReturnStatement; +exports.sequenceExpression = exports.SequenceExpression = SequenceExpression; +exports.switchCase = exports.SwitchCase = SwitchCase; +exports.switchStatement = exports.SwitchStatement = SwitchStatement; +exports.thisExpression = exports.ThisExpression = ThisExpression; +exports.throwStatement = exports.ThrowStatement = ThrowStatement; +exports.tryStatement = exports.TryStatement = TryStatement; +exports.unaryExpression = exports.UnaryExpression = UnaryExpression; +exports.updateExpression = exports.UpdateExpression = UpdateExpression; +exports.variableDeclaration = exports.VariableDeclaration = VariableDeclaration; +exports.variableDeclarator = exports.VariableDeclarator = VariableDeclarator; +exports.whileStatement = exports.WhileStatement = WhileStatement; +exports.withStatement = exports.WithStatement = WithStatement; +exports.assignmentPattern = exports.AssignmentPattern = AssignmentPattern; +exports.arrayPattern = exports.ArrayPattern = ArrayPattern; +exports.arrowFunctionExpression = exports.ArrowFunctionExpression = ArrowFunctionExpression; +exports.classBody = exports.ClassBody = ClassBody; +exports.classDeclaration = exports.ClassDeclaration = ClassDeclaration; +exports.classExpression = exports.ClassExpression = ClassExpression; +exports.exportAllDeclaration = exports.ExportAllDeclaration = ExportAllDeclaration; +exports.exportDefaultDeclaration = exports.ExportDefaultDeclaration = ExportDefaultDeclaration; +exports.exportNamedDeclaration = exports.ExportNamedDeclaration = ExportNamedDeclaration; +exports.exportSpecifier = exports.ExportSpecifier = ExportSpecifier; +exports.forOfStatement = exports.ForOfStatement = ForOfStatement; +exports.importDeclaration = exports.ImportDeclaration = ImportDeclaration; +exports.importDefaultSpecifier = exports.ImportDefaultSpecifier = ImportDefaultSpecifier; +exports.importNamespaceSpecifier = exports.ImportNamespaceSpecifier = ImportNamespaceSpecifier; +exports.importSpecifier = exports.ImportSpecifier = ImportSpecifier; +exports.metaProperty = exports.MetaProperty = MetaProperty; +exports.classMethod = exports.ClassMethod = ClassMethod; +exports.objectPattern = exports.ObjectPattern = ObjectPattern; +exports.spreadElement = exports.SpreadElement = SpreadElement; +exports.super = exports.Super = Super; +exports.taggedTemplateExpression = exports.TaggedTemplateExpression = TaggedTemplateExpression; +exports.templateElement = exports.TemplateElement = TemplateElement; +exports.templateLiteral = exports.TemplateLiteral = TemplateLiteral; +exports.yieldExpression = exports.YieldExpression = YieldExpression; +exports.anyTypeAnnotation = exports.AnyTypeAnnotation = AnyTypeAnnotation; +exports.arrayTypeAnnotation = exports.ArrayTypeAnnotation = ArrayTypeAnnotation; +exports.booleanTypeAnnotation = exports.BooleanTypeAnnotation = BooleanTypeAnnotation; +exports.booleanLiteralTypeAnnotation = exports.BooleanLiteralTypeAnnotation = BooleanLiteralTypeAnnotation; +exports.nullLiteralTypeAnnotation = exports.NullLiteralTypeAnnotation = NullLiteralTypeAnnotation; +exports.classImplements = exports.ClassImplements = ClassImplements; +exports.declareClass = exports.DeclareClass = DeclareClass; +exports.declareFunction = exports.DeclareFunction = DeclareFunction; +exports.declareInterface = exports.DeclareInterface = DeclareInterface; +exports.declareModule = exports.DeclareModule = DeclareModule; +exports.declareModuleExports = exports.DeclareModuleExports = DeclareModuleExports; +exports.declareTypeAlias = exports.DeclareTypeAlias = DeclareTypeAlias; +exports.declareOpaqueType = exports.DeclareOpaqueType = DeclareOpaqueType; +exports.declareVariable = exports.DeclareVariable = DeclareVariable; +exports.declareExportDeclaration = exports.DeclareExportDeclaration = DeclareExportDeclaration; +exports.declareExportAllDeclaration = exports.DeclareExportAllDeclaration = DeclareExportAllDeclaration; +exports.declaredPredicate = exports.DeclaredPredicate = DeclaredPredicate; +exports.existsTypeAnnotation = exports.ExistsTypeAnnotation = ExistsTypeAnnotation; +exports.functionTypeAnnotation = exports.FunctionTypeAnnotation = FunctionTypeAnnotation; +exports.functionTypeParam = exports.FunctionTypeParam = FunctionTypeParam; +exports.genericTypeAnnotation = exports.GenericTypeAnnotation = GenericTypeAnnotation; +exports.inferredPredicate = exports.InferredPredicate = InferredPredicate; +exports.interfaceExtends = exports.InterfaceExtends = InterfaceExtends; +exports.interfaceDeclaration = exports.InterfaceDeclaration = InterfaceDeclaration; +exports.intersectionTypeAnnotation = exports.IntersectionTypeAnnotation = IntersectionTypeAnnotation; +exports.mixedTypeAnnotation = exports.MixedTypeAnnotation = MixedTypeAnnotation; +exports.emptyTypeAnnotation = exports.EmptyTypeAnnotation = EmptyTypeAnnotation; +exports.nullableTypeAnnotation = exports.NullableTypeAnnotation = NullableTypeAnnotation; +exports.numberLiteralTypeAnnotation = exports.NumberLiteralTypeAnnotation = NumberLiteralTypeAnnotation; +exports.numberTypeAnnotation = exports.NumberTypeAnnotation = NumberTypeAnnotation; +exports.objectTypeAnnotation = exports.ObjectTypeAnnotation = ObjectTypeAnnotation; +exports.objectTypeCallProperty = exports.ObjectTypeCallProperty = ObjectTypeCallProperty; +exports.objectTypeIndexer = exports.ObjectTypeIndexer = ObjectTypeIndexer; +exports.objectTypeProperty = exports.ObjectTypeProperty = ObjectTypeProperty; +exports.objectTypeSpreadProperty = exports.ObjectTypeSpreadProperty = ObjectTypeSpreadProperty; +exports.opaqueType = exports.OpaqueType = OpaqueType; +exports.qualifiedTypeIdentifier = exports.QualifiedTypeIdentifier = QualifiedTypeIdentifier; +exports.stringLiteralTypeAnnotation = exports.StringLiteralTypeAnnotation = StringLiteralTypeAnnotation; +exports.stringTypeAnnotation = exports.StringTypeAnnotation = StringTypeAnnotation; +exports.thisTypeAnnotation = exports.ThisTypeAnnotation = ThisTypeAnnotation; +exports.tupleTypeAnnotation = exports.TupleTypeAnnotation = TupleTypeAnnotation; +exports.typeofTypeAnnotation = exports.TypeofTypeAnnotation = TypeofTypeAnnotation; +exports.typeAlias = exports.TypeAlias = TypeAlias; +exports.typeAnnotation = exports.TypeAnnotation = TypeAnnotation; +exports.typeCastExpression = exports.TypeCastExpression = TypeCastExpression; +exports.typeParameter = exports.TypeParameter = TypeParameter; +exports.typeParameterDeclaration = exports.TypeParameterDeclaration = TypeParameterDeclaration; +exports.typeParameterInstantiation = exports.TypeParameterInstantiation = TypeParameterInstantiation; +exports.unionTypeAnnotation = exports.UnionTypeAnnotation = UnionTypeAnnotation; +exports.voidTypeAnnotation = exports.VoidTypeAnnotation = VoidTypeAnnotation; +exports.jSXAttribute = exports.jsxAttribute = exports.JSXAttribute = JSXAttribute; +exports.jSXClosingElement = exports.jsxClosingElement = exports.JSXClosingElement = JSXClosingElement; +exports.jSXElement = exports.jsxElement = exports.JSXElement = JSXElement; +exports.jSXEmptyExpression = exports.jsxEmptyExpression = exports.JSXEmptyExpression = JSXEmptyExpression; +exports.jSXExpressionContainer = exports.jsxExpressionContainer = exports.JSXExpressionContainer = JSXExpressionContainer; +exports.jSXSpreadChild = exports.jsxSpreadChild = exports.JSXSpreadChild = JSXSpreadChild; +exports.jSXIdentifier = exports.jsxIdentifier = exports.JSXIdentifier = JSXIdentifier; +exports.jSXMemberExpression = exports.jsxMemberExpression = exports.JSXMemberExpression = JSXMemberExpression; +exports.jSXNamespacedName = exports.jsxNamespacedName = exports.JSXNamespacedName = JSXNamespacedName; +exports.jSXOpeningElement = exports.jsxOpeningElement = exports.JSXOpeningElement = JSXOpeningElement; +exports.jSXSpreadAttribute = exports.jsxSpreadAttribute = exports.JSXSpreadAttribute = JSXSpreadAttribute; +exports.jSXText = exports.jsxText = exports.JSXText = JSXText; +exports.jSXFragment = exports.jsxFragment = exports.JSXFragment = JSXFragment; +exports.jSXOpeningFragment = exports.jsxOpeningFragment = exports.JSXOpeningFragment = JSXOpeningFragment; +exports.jSXClosingFragment = exports.jsxClosingFragment = exports.JSXClosingFragment = JSXClosingFragment; +exports.noop = exports.Noop = Noop; +exports.parenthesizedExpression = exports.ParenthesizedExpression = ParenthesizedExpression; +exports.awaitExpression = exports.AwaitExpression = AwaitExpression; +exports.bindExpression = exports.BindExpression = BindExpression; +exports.classProperty = exports.ClassProperty = ClassProperty; +exports.import = exports.Import = Import; +exports.decorator = exports.Decorator = Decorator; +exports.doExpression = exports.DoExpression = DoExpression; +exports.exportDefaultSpecifier = exports.ExportDefaultSpecifier = ExportDefaultSpecifier; +exports.exportNamespaceSpecifier = exports.ExportNamespaceSpecifier = ExportNamespaceSpecifier; +exports.tSParameterProperty = exports.tsParameterProperty = exports.TSParameterProperty = TSParameterProperty; +exports.tSDeclareFunction = exports.tsDeclareFunction = exports.TSDeclareFunction = TSDeclareFunction; +exports.tSDeclareMethod = exports.tsDeclareMethod = exports.TSDeclareMethod = TSDeclareMethod; +exports.tSQualifiedName = exports.tsQualifiedName = exports.TSQualifiedName = TSQualifiedName; +exports.tSCallSignatureDeclaration = exports.tsCallSignatureDeclaration = exports.TSCallSignatureDeclaration = TSCallSignatureDeclaration; +exports.tSConstructSignatureDeclaration = exports.tsConstructSignatureDeclaration = exports.TSConstructSignatureDeclaration = TSConstructSignatureDeclaration; +exports.tSPropertySignature = exports.tsPropertySignature = exports.TSPropertySignature = TSPropertySignature; +exports.tSMethodSignature = exports.tsMethodSignature = exports.TSMethodSignature = TSMethodSignature; +exports.tSIndexSignature = exports.tsIndexSignature = exports.TSIndexSignature = TSIndexSignature; +exports.tSAnyKeyword = exports.tsAnyKeyword = exports.TSAnyKeyword = TSAnyKeyword; +exports.tSNumberKeyword = exports.tsNumberKeyword = exports.TSNumberKeyword = TSNumberKeyword; +exports.tSObjectKeyword = exports.tsObjectKeyword = exports.TSObjectKeyword = TSObjectKeyword; +exports.tSBooleanKeyword = exports.tsBooleanKeyword = exports.TSBooleanKeyword = TSBooleanKeyword; +exports.tSStringKeyword = exports.tsStringKeyword = exports.TSStringKeyword = TSStringKeyword; +exports.tSSymbolKeyword = exports.tsSymbolKeyword = exports.TSSymbolKeyword = TSSymbolKeyword; +exports.tSVoidKeyword = exports.tsVoidKeyword = exports.TSVoidKeyword = TSVoidKeyword; +exports.tSUndefinedKeyword = exports.tsUndefinedKeyword = exports.TSUndefinedKeyword = TSUndefinedKeyword; +exports.tSNullKeyword = exports.tsNullKeyword = exports.TSNullKeyword = TSNullKeyword; +exports.tSNeverKeyword = exports.tsNeverKeyword = exports.TSNeverKeyword = TSNeverKeyword; +exports.tSThisType = exports.tsThisType = exports.TSThisType = TSThisType; +exports.tSFunctionType = exports.tsFunctionType = exports.TSFunctionType = TSFunctionType; +exports.tSConstructorType = exports.tsConstructorType = exports.TSConstructorType = TSConstructorType; +exports.tSTypeReference = exports.tsTypeReference = exports.TSTypeReference = TSTypeReference; +exports.tSTypePredicate = exports.tsTypePredicate = exports.TSTypePredicate = TSTypePredicate; +exports.tSTypeQuery = exports.tsTypeQuery = exports.TSTypeQuery = TSTypeQuery; +exports.tSTypeLiteral = exports.tsTypeLiteral = exports.TSTypeLiteral = TSTypeLiteral; +exports.tSArrayType = exports.tsArrayType = exports.TSArrayType = TSArrayType; +exports.tSTupleType = exports.tsTupleType = exports.TSTupleType = TSTupleType; +exports.tSUnionType = exports.tsUnionType = exports.TSUnionType = TSUnionType; +exports.tSIntersectionType = exports.tsIntersectionType = exports.TSIntersectionType = TSIntersectionType; +exports.tSParenthesizedType = exports.tsParenthesizedType = exports.TSParenthesizedType = TSParenthesizedType; +exports.tSTypeOperator = exports.tsTypeOperator = exports.TSTypeOperator = TSTypeOperator; +exports.tSIndexedAccessType = exports.tsIndexedAccessType = exports.TSIndexedAccessType = TSIndexedAccessType; +exports.tSMappedType = exports.tsMappedType = exports.TSMappedType = TSMappedType; +exports.tSLiteralType = exports.tsLiteralType = exports.TSLiteralType = TSLiteralType; +exports.tSExpressionWithTypeArguments = exports.tsExpressionWithTypeArguments = exports.TSExpressionWithTypeArguments = TSExpressionWithTypeArguments; +exports.tSInterfaceDeclaration = exports.tsInterfaceDeclaration = exports.TSInterfaceDeclaration = TSInterfaceDeclaration; +exports.tSInterfaceBody = exports.tsInterfaceBody = exports.TSInterfaceBody = TSInterfaceBody; +exports.tSTypeAliasDeclaration = exports.tsTypeAliasDeclaration = exports.TSTypeAliasDeclaration = TSTypeAliasDeclaration; +exports.tSAsExpression = exports.tsAsExpression = exports.TSAsExpression = TSAsExpression; +exports.tSTypeAssertion = exports.tsTypeAssertion = exports.TSTypeAssertion = TSTypeAssertion; +exports.tSEnumDeclaration = exports.tsEnumDeclaration = exports.TSEnumDeclaration = TSEnumDeclaration; +exports.tSEnumMember = exports.tsEnumMember = exports.TSEnumMember = TSEnumMember; +exports.tSModuleDeclaration = exports.tsModuleDeclaration = exports.TSModuleDeclaration = TSModuleDeclaration; +exports.tSModuleBlock = exports.tsModuleBlock = exports.TSModuleBlock = TSModuleBlock; +exports.tSImportEqualsDeclaration = exports.tsImportEqualsDeclaration = exports.TSImportEqualsDeclaration = TSImportEqualsDeclaration; +exports.tSExternalModuleReference = exports.tsExternalModuleReference = exports.TSExternalModuleReference = TSExternalModuleReference; +exports.tSNonNullExpression = exports.tsNonNullExpression = exports.TSNonNullExpression = TSNonNullExpression; +exports.tSExportAssignment = exports.tsExportAssignment = exports.TSExportAssignment = TSExportAssignment; +exports.tSNamespaceExportDeclaration = exports.tsNamespaceExportDeclaration = exports.TSNamespaceExportDeclaration = TSNamespaceExportDeclaration; +exports.tSTypeAnnotation = exports.tsTypeAnnotation = exports.TSTypeAnnotation = TSTypeAnnotation; +exports.tSTypeParameterInstantiation = exports.tsTypeParameterInstantiation = exports.TSTypeParameterInstantiation = TSTypeParameterInstantiation; +exports.tSTypeParameterDeclaration = exports.tsTypeParameterDeclaration = exports.TSTypeParameterDeclaration = TSTypeParameterDeclaration; +exports.tSTypeParameter = exports.tsTypeParameter = exports.TSTypeParameter = TSTypeParameter; +exports.numberLiteral = exports.NumberLiteral = NumberLiteral; +exports.regexLiteral = exports.RegexLiteral = RegexLiteral; +exports.restProperty = exports.RestProperty = RestProperty; +exports.spreadProperty = exports.SpreadProperty = SpreadProperty; + +var _builder = _interopRequireDefault(require("../builder")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function ArrayExpression() { + for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) { + args[_key] = arguments[_key]; + } + + return _builder.default.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.default.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.default.apply(void 0, ["BinaryExpression"].concat(args)); +} + +function Directive() { + for (var _len4 = arguments.length, args = new Array(_len4), _key4 = 0; _key4 < _len4; _key4++) { + args[_key4] = arguments[_key4]; + } + + return _builder.default.apply(void 0, ["Directive"].concat(args)); +} + +function DirectiveLiteral() { + for (var _len5 = arguments.length, args = new Array(_len5), _key5 = 0; _key5 < _len5; _key5++) { + args[_key5] = arguments[_key5]; + } + + return _builder.default.apply(void 0, ["DirectiveLiteral"].concat(args)); +} + +function BlockStatement() { + for (var _len6 = arguments.length, args = new Array(_len6), _key6 = 0; _key6 < _len6; _key6++) { + args[_key6] = arguments[_key6]; + } + + return _builder.default.apply(void 0, ["BlockStatement"].concat(args)); +} + +function BreakStatement() { + for (var _len7 = arguments.length, args = new Array(_len7), _key7 = 0; _key7 < _len7; _key7++) { + args[_key7] = arguments[_key7]; + } + + return _builder.default.apply(void 0, ["BreakStatement"].concat(args)); +} + +function CallExpression() { + for (var _len8 = arguments.length, args = new Array(_len8), _key8 = 0; _key8 < _len8; _key8++) { + args[_key8] = arguments[_key8]; + } + + return _builder.default.apply(void 0, ["CallExpression"].concat(args)); +} + +function CatchClause() { + for (var _len9 = arguments.length, args = new Array(_len9), _key9 = 0; _key9 < _len9; _key9++) { + args[_key9] = arguments[_key9]; + } + + return _builder.default.apply(void 0, ["CatchClause"].concat(args)); +} + +function ConditionalExpression() { + for (var _len10 = arguments.length, args = new Array(_len10), _key10 = 0; _key10 < _len10; _key10++) { + args[_key10] = arguments[_key10]; + } + + return _builder.default.apply(void 0, ["ConditionalExpression"].concat(args)); +} + +function ContinueStatement() { + for (var _len11 = arguments.length, args = new Array(_len11), _key11 = 0; _key11 < _len11; _key11++) { + args[_key11] = arguments[_key11]; + } + + return _builder.default.apply(void 0, ["ContinueStatement"].concat(args)); +} + +function DebuggerStatement() { + for (var _len12 = arguments.length, args = new Array(_len12), _key12 = 0; _key12 < _len12; _key12++) { + args[_key12] = arguments[_key12]; + } + + return _builder.default.apply(void 0, ["DebuggerStatement"].concat(args)); +} + +function DoWhileStatement() { + for (var _len13 = arguments.length, args = new Array(_len13), _key13 = 0; _key13 < _len13; _key13++) { + args[_key13] = arguments[_key13]; + } + + return _builder.default.apply(void 0, ["DoWhileStatement"].concat(args)); +} + +function EmptyStatement() { + for (var _len14 = arguments.length, args = new Array(_len14), _key14 = 0; _key14 < _len14; _key14++) { + args[_key14] = arguments[_key14]; + } + + return _builder.default.apply(void 0, ["EmptyStatement"].concat(args)); +} + +function ExpressionStatement() { + for (var _len15 = arguments.length, args = new Array(_len15), _key15 = 0; _key15 < _len15; _key15++) { + args[_key15] = arguments[_key15]; + } + + return _builder.default.apply(void 0, ["ExpressionStatement"].concat(args)); +} + +function File() { + for (var _len16 = arguments.length, args = new Array(_len16), _key16 = 0; _key16 < _len16; _key16++) { + args[_key16] = arguments[_key16]; + } + + return _builder.default.apply(void 0, ["File"].concat(args)); +} + +function ForInStatement() { + for (var _len17 = arguments.length, args = new Array(_len17), _key17 = 0; _key17 < _len17; _key17++) { + args[_key17] = arguments[_key17]; + } + + return _builder.default.apply(void 0, ["ForInStatement"].concat(args)); +} + +function ForStatement() { + for (var _len18 = arguments.length, args = new Array(_len18), _key18 = 0; _key18 < _len18; _key18++) { + args[_key18] = arguments[_key18]; + } + + return _builder.default.apply(void 0, ["ForStatement"].concat(args)); +} + +function FunctionDeclaration() { + for (var _len19 = arguments.length, args = new Array(_len19), _key19 = 0; _key19 < _len19; _key19++) { + args[_key19] = arguments[_key19]; + } + + return _builder.default.apply(void 0, ["FunctionDeclaration"].concat(args)); +} + +function FunctionExpression() { + for (var _len20 = arguments.length, args = new Array(_len20), _key20 = 0; _key20 < _len20; _key20++) { + args[_key20] = arguments[_key20]; + } + + return _builder.default.apply(void 0, ["FunctionExpression"].concat(args)); +} + +function Identifier() { + for (var _len21 = arguments.length, args = new Array(_len21), _key21 = 0; _key21 < _len21; _key21++) { + args[_key21] = arguments[_key21]; + } + + return _builder.default.apply(void 0, ["Identifier"].concat(args)); +} + +function IfStatement() { + for (var _len22 = arguments.length, args = new Array(_len22), _key22 = 0; _key22 < _len22; _key22++) { + args[_key22] = arguments[_key22]; + } + + return _builder.default.apply(void 0, ["IfStatement"].concat(args)); +} + +function LabeledStatement() { + for (var _len23 = arguments.length, args = new Array(_len23), _key23 = 0; _key23 < _len23; _key23++) { + args[_key23] = arguments[_key23]; + } + + return _builder.default.apply(void 0, ["LabeledStatement"].concat(args)); +} + +function StringLiteral() { + for (var _len24 = arguments.length, args = new Array(_len24), _key24 = 0; _key24 < _len24; _key24++) { + args[_key24] = arguments[_key24]; + } + + return _builder.default.apply(void 0, ["StringLiteral"].concat(args)); +} + +function NumericLiteral() { + for (var _len25 = arguments.length, args = new Array(_len25), _key25 = 0; _key25 < _len25; _key25++) { + args[_key25] = arguments[_key25]; + } + + return _builder.default.apply(void 0, ["NumericLiteral"].concat(args)); +} + +function NullLiteral() { + for (var _len26 = arguments.length, args = new Array(_len26), _key26 = 0; _key26 < _len26; _key26++) { + args[_key26] = arguments[_key26]; + } + + return _builder.default.apply(void 0, ["NullLiteral"].concat(args)); +} + +function BooleanLiteral() { + for (var _len27 = arguments.length, args = new Array(_len27), _key27 = 0; _key27 < _len27; _key27++) { + args[_key27] = arguments[_key27]; + } + + return _builder.default.apply(void 0, ["BooleanLiteral"].concat(args)); +} + +function RegExpLiteral() { + for (var _len28 = arguments.length, args = new Array(_len28), _key28 = 0; _key28 < _len28; _key28++) { + args[_key28] = arguments[_key28]; + } + + return _builder.default.apply(void 0, ["RegExpLiteral"].concat(args)); +} + +function LogicalExpression() { + for (var _len29 = arguments.length, args = new Array(_len29), _key29 = 0; _key29 < _len29; _key29++) { + args[_key29] = arguments[_key29]; + } + + return _builder.default.apply(void 0, ["LogicalExpression"].concat(args)); +} + +function MemberExpression() { + for (var _len30 = arguments.length, args = new Array(_len30), _key30 = 0; _key30 < _len30; _key30++) { + args[_key30] = arguments[_key30]; + } + + return _builder.default.apply(void 0, ["MemberExpression"].concat(args)); +} + +function NewExpression() { + for (var _len31 = arguments.length, args = new Array(_len31), _key31 = 0; _key31 < _len31; _key31++) { + args[_key31] = arguments[_key31]; + } + + return _builder.default.apply(void 0, ["NewExpression"].concat(args)); +} + +function Program() { + for (var _len32 = arguments.length, args = new Array(_len32), _key32 = 0; _key32 < _len32; _key32++) { + args[_key32] = arguments[_key32]; + } + + return _builder.default.apply(void 0, ["Program"].concat(args)); +} + +function ObjectExpression() { + for (var _len33 = arguments.length, args = new Array(_len33), _key33 = 0; _key33 < _len33; _key33++) { + args[_key33] = arguments[_key33]; + } + + return _builder.default.apply(void 0, ["ObjectExpression"].concat(args)); +} + +function ObjectMethod() { + for (var _len34 = arguments.length, args = new Array(_len34), _key34 = 0; _key34 < _len34; _key34++) { + args[_key34] = arguments[_key34]; + } + + return _builder.default.apply(void 0, ["ObjectMethod"].concat(args)); +} + +function ObjectProperty() { + for (var _len35 = arguments.length, args = new Array(_len35), _key35 = 0; _key35 < _len35; _key35++) { + args[_key35] = arguments[_key35]; + } + + return _builder.default.apply(void 0, ["ObjectProperty"].concat(args)); +} + +function RestElement() { + for (var _len36 = arguments.length, args = new Array(_len36), _key36 = 0; _key36 < _len36; _key36++) { + args[_key36] = arguments[_key36]; + } + + return _builder.default.apply(void 0, ["RestElement"].concat(args)); +} + +function ReturnStatement() { + for (var _len37 = arguments.length, args = new Array(_len37), _key37 = 0; _key37 < _len37; _key37++) { + args[_key37] = arguments[_key37]; + } + + return _builder.default.apply(void 0, ["ReturnStatement"].concat(args)); +} + +function SequenceExpression() { + for (var _len38 = arguments.length, args = new Array(_len38), _key38 = 0; _key38 < _len38; _key38++) { + args[_key38] = arguments[_key38]; + } + + return _builder.default.apply(void 0, ["SequenceExpression"].concat(args)); +} + +function SwitchCase() { + for (var _len39 = arguments.length, args = new Array(_len39), _key39 = 0; _key39 < _len39; _key39++) { + args[_key39] = arguments[_key39]; + } + + return _builder.default.apply(void 0, ["SwitchCase"].concat(args)); +} + +function SwitchStatement() { + for (var _len40 = arguments.length, args = new Array(_len40), _key40 = 0; _key40 < _len40; _key40++) { + args[_key40] = arguments[_key40]; + } + + return _builder.default.apply(void 0, ["SwitchStatement"].concat(args)); +} + +function ThisExpression() { + for (var _len41 = arguments.length, args = new Array(_len41), _key41 = 0; _key41 < _len41; _key41++) { + args[_key41] = arguments[_key41]; + } + + return _builder.default.apply(void 0, ["ThisExpression"].concat(args)); +} + +function ThrowStatement() { + for (var _len42 = arguments.length, args = new Array(_len42), _key42 = 0; _key42 < _len42; _key42++) { + args[_key42] = arguments[_key42]; + } + + return _builder.default.apply(void 0, ["ThrowStatement"].concat(args)); +} + +function TryStatement() { + for (var _len43 = arguments.length, args = new Array(_len43), _key43 = 0; _key43 < _len43; _key43++) { + args[_key43] = arguments[_key43]; + } + + return _builder.default.apply(void 0, ["TryStatement"].concat(args)); +} + +function UnaryExpression() { + for (var _len44 = arguments.length, args = new Array(_len44), _key44 = 0; _key44 < _len44; _key44++) { + args[_key44] = arguments[_key44]; + } + + return _builder.default.apply(void 0, ["UnaryExpression"].concat(args)); +} + +function UpdateExpression() { + for (var _len45 = arguments.length, args = new Array(_len45), _key45 = 0; _key45 < _len45; _key45++) { + args[_key45] = arguments[_key45]; + } + + return _builder.default.apply(void 0, ["UpdateExpression"].concat(args)); +} + +function VariableDeclaration() { + for (var _len46 = arguments.length, args = new Array(_len46), _key46 = 0; _key46 < _len46; _key46++) { + args[_key46] = arguments[_key46]; + } + + return _builder.default.apply(void 0, ["VariableDeclaration"].concat(args)); +} + +function VariableDeclarator() { + for (var _len47 = arguments.length, args = new Array(_len47), _key47 = 0; _key47 < _len47; _key47++) { + args[_key47] = arguments[_key47]; + } + + return _builder.default.apply(void 0, ["VariableDeclarator"].concat(args)); +} + +function WhileStatement() { + for (var _len48 = arguments.length, args = new Array(_len48), _key48 = 0; _key48 < _len48; _key48++) { + args[_key48] = arguments[_key48]; + } + + return _builder.default.apply(void 0, ["WhileStatement"].concat(args)); +} + +function WithStatement() { + for (var _len49 = arguments.length, args = new Array(_len49), _key49 = 0; _key49 < _len49; _key49++) { + args[_key49] = arguments[_key49]; + } + + return _builder.default.apply(void 0, ["WithStatement"].concat(args)); +} + +function AssignmentPattern() { + for (var _len50 = arguments.length, args = new Array(_len50), _key50 = 0; _key50 < _len50; _key50++) { + args[_key50] = arguments[_key50]; + } + + return _builder.default.apply(void 0, ["AssignmentPattern"].concat(args)); +} + +function ArrayPattern() { + for (var _len51 = arguments.length, args = new Array(_len51), _key51 = 0; _key51 < _len51; _key51++) { + args[_key51] = arguments[_key51]; + } + + return _builder.default.apply(void 0, ["ArrayPattern"].concat(args)); +} + +function ArrowFunctionExpression() { + for (var _len52 = arguments.length, args = new Array(_len52), _key52 = 0; _key52 < _len52; _key52++) { + args[_key52] = arguments[_key52]; + } + + return _builder.default.apply(void 0, ["ArrowFunctionExpression"].concat(args)); +} + +function ClassBody() { + for (var _len53 = arguments.length, args = new Array(_len53), _key53 = 0; _key53 < _len53; _key53++) { + args[_key53] = arguments[_key53]; + } + + return _builder.default.apply(void 0, ["ClassBody"].concat(args)); +} + +function ClassDeclaration() { + for (var _len54 = arguments.length, args = new Array(_len54), _key54 = 0; _key54 < _len54; _key54++) { + args[_key54] = arguments[_key54]; + } + + return _builder.default.apply(void 0, ["ClassDeclaration"].concat(args)); +} + +function ClassExpression() { + for (var _len55 = arguments.length, args = new Array(_len55), _key55 = 0; _key55 < _len55; _key55++) { + args[_key55] = arguments[_key55]; + } + + return _builder.default.apply(void 0, ["ClassExpression"].concat(args)); +} + +function ExportAllDeclaration() { + for (var _len56 = arguments.length, args = new Array(_len56), _key56 = 0; _key56 < _len56; _key56++) { + args[_key56] = arguments[_key56]; + } + + return _builder.default.apply(void 0, ["ExportAllDeclaration"].concat(args)); +} + +function ExportDefaultDeclaration() { + for (var _len57 = arguments.length, args = new Array(_len57), _key57 = 0; _key57 < _len57; _key57++) { + args[_key57] = arguments[_key57]; + } + + return _builder.default.apply(void 0, ["ExportDefaultDeclaration"].concat(args)); +} + +function ExportNamedDeclaration() { + for (var _len58 = arguments.length, args = new Array(_len58), _key58 = 0; _key58 < _len58; _key58++) { + args[_key58] = arguments[_key58]; + } + + return _builder.default.apply(void 0, ["ExportNamedDeclaration"].concat(args)); +} + +function ExportSpecifier() { + for (var _len59 = arguments.length, args = new Array(_len59), _key59 = 0; _key59 < _len59; _key59++) { + args[_key59] = arguments[_key59]; + } + + return _builder.default.apply(void 0, ["ExportSpecifier"].concat(args)); +} + +function ForOfStatement() { + for (var _len60 = arguments.length, args = new Array(_len60), _key60 = 0; _key60 < _len60; _key60++) { + args[_key60] = arguments[_key60]; + } + + return _builder.default.apply(void 0, ["ForOfStatement"].concat(args)); +} + +function ImportDeclaration() { + for (var _len61 = arguments.length, args = new Array(_len61), _key61 = 0; _key61 < _len61; _key61++) { + args[_key61] = arguments[_key61]; + } + + return _builder.default.apply(void 0, ["ImportDeclaration"].concat(args)); +} + +function ImportDefaultSpecifier() { + for (var _len62 = arguments.length, args = new Array(_len62), _key62 = 0; _key62 < _len62; _key62++) { + args[_key62] = arguments[_key62]; + } + + return _builder.default.apply(void 0, ["ImportDefaultSpecifier"].concat(args)); +} + +function ImportNamespaceSpecifier() { + for (var _len63 = arguments.length, args = new Array(_len63), _key63 = 0; _key63 < _len63; _key63++) { + args[_key63] = arguments[_key63]; + } + + return _builder.default.apply(void 0, ["ImportNamespaceSpecifier"].concat(args)); +} + +function ImportSpecifier() { + for (var _len64 = arguments.length, args = new Array(_len64), _key64 = 0; _key64 < _len64; _key64++) { + args[_key64] = arguments[_key64]; + } + + return _builder.default.apply(void 0, ["ImportSpecifier"].concat(args)); +} + +function MetaProperty() { + for (var _len65 = arguments.length, args = new Array(_len65), _key65 = 0; _key65 < _len65; _key65++) { + args[_key65] = arguments[_key65]; + } + + return _builder.default.apply(void 0, ["MetaProperty"].concat(args)); +} + +function ClassMethod() { + for (var _len66 = arguments.length, args = new Array(_len66), _key66 = 0; _key66 < _len66; _key66++) { + args[_key66] = arguments[_key66]; + } + + return _builder.default.apply(void 0, ["ClassMethod"].concat(args)); +} + +function ObjectPattern() { + for (var _len67 = arguments.length, args = new Array(_len67), _key67 = 0; _key67 < _len67; _key67++) { + args[_key67] = arguments[_key67]; + } + + return _builder.default.apply(void 0, ["ObjectPattern"].concat(args)); +} + +function SpreadElement() { + for (var _len68 = arguments.length, args = new Array(_len68), _key68 = 0; _key68 < _len68; _key68++) { + args[_key68] = arguments[_key68]; + } + + return _builder.default.apply(void 0, ["SpreadElement"].concat(args)); +} + +function Super() { + for (var _len69 = arguments.length, args = new Array(_len69), _key69 = 0; _key69 < _len69; _key69++) { + args[_key69] = arguments[_key69]; + } + + return _builder.default.apply(void 0, ["Super"].concat(args)); +} + +function TaggedTemplateExpression() { + for (var _len70 = arguments.length, args = new Array(_len70), _key70 = 0; _key70 < _len70; _key70++) { + args[_key70] = arguments[_key70]; + } + + return _builder.default.apply(void 0, ["TaggedTemplateExpression"].concat(args)); +} + +function TemplateElement() { + for (var _len71 = arguments.length, args = new Array(_len71), _key71 = 0; _key71 < _len71; _key71++) { + args[_key71] = arguments[_key71]; + } + + return _builder.default.apply(void 0, ["TemplateElement"].concat(args)); +} + +function TemplateLiteral() { + for (var _len72 = arguments.length, args = new Array(_len72), _key72 = 0; _key72 < _len72; _key72++) { + args[_key72] = arguments[_key72]; + } + + return _builder.default.apply(void 0, ["TemplateLiteral"].concat(args)); +} + +function YieldExpression() { + for (var _len73 = arguments.length, args = new Array(_len73), _key73 = 0; _key73 < _len73; _key73++) { + args[_key73] = arguments[_key73]; + } + + return _builder.default.apply(void 0, ["YieldExpression"].concat(args)); +} + +function AnyTypeAnnotation() { + for (var _len74 = arguments.length, args = new Array(_len74), _key74 = 0; _key74 < _len74; _key74++) { + args[_key74] = arguments[_key74]; + } + + return _builder.default.apply(void 0, ["AnyTypeAnnotation"].concat(args)); +} + +function ArrayTypeAnnotation() { + for (var _len75 = arguments.length, args = new Array(_len75), _key75 = 0; _key75 < _len75; _key75++) { + args[_key75] = arguments[_key75]; + } + + return _builder.default.apply(void 0, ["ArrayTypeAnnotation"].concat(args)); +} + +function BooleanTypeAnnotation() { + for (var _len76 = arguments.length, args = new Array(_len76), _key76 = 0; _key76 < _len76; _key76++) { + args[_key76] = arguments[_key76]; + } + + return _builder.default.apply(void 0, ["BooleanTypeAnnotation"].concat(args)); +} + +function BooleanLiteralTypeAnnotation() { + for (var _len77 = arguments.length, args = new Array(_len77), _key77 = 0; _key77 < _len77; _key77++) { + args[_key77] = arguments[_key77]; + } + + return _builder.default.apply(void 0, ["BooleanLiteralTypeAnnotation"].concat(args)); +} + +function NullLiteralTypeAnnotation() { + for (var _len78 = arguments.length, args = new Array(_len78), _key78 = 0; _key78 < _len78; _key78++) { + args[_key78] = arguments[_key78]; + } + + return _builder.default.apply(void 0, ["NullLiteralTypeAnnotation"].concat(args)); +} + +function ClassImplements() { + for (var _len79 = arguments.length, args = new Array(_len79), _key79 = 0; _key79 < _len79; _key79++) { + args[_key79] = arguments[_key79]; + } + + return _builder.default.apply(void 0, ["ClassImplements"].concat(args)); +} + +function DeclareClass() { + for (var _len80 = arguments.length, args = new Array(_len80), _key80 = 0; _key80 < _len80; _key80++) { + args[_key80] = arguments[_key80]; + } + + return _builder.default.apply(void 0, ["DeclareClass"].concat(args)); +} + +function DeclareFunction() { + for (var _len81 = arguments.length, args = new Array(_len81), _key81 = 0; _key81 < _len81; _key81++) { + args[_key81] = arguments[_key81]; + } + + return _builder.default.apply(void 0, ["DeclareFunction"].concat(args)); +} + +function DeclareInterface() { + for (var _len82 = arguments.length, args = new Array(_len82), _key82 = 0; _key82 < _len82; _key82++) { + args[_key82] = arguments[_key82]; + } + + return _builder.default.apply(void 0, ["DeclareInterface"].concat(args)); +} + +function DeclareModule() { + for (var _len83 = arguments.length, args = new Array(_len83), _key83 = 0; _key83 < _len83; _key83++) { + args[_key83] = arguments[_key83]; + } + + return _builder.default.apply(void 0, ["DeclareModule"].concat(args)); +} + +function DeclareModuleExports() { + for (var _len84 = arguments.length, args = new Array(_len84), _key84 = 0; _key84 < _len84; _key84++) { + args[_key84] = arguments[_key84]; + } + + return _builder.default.apply(void 0, ["DeclareModuleExports"].concat(args)); +} + +function DeclareTypeAlias() { + for (var _len85 = arguments.length, args = new Array(_len85), _key85 = 0; _key85 < _len85; _key85++) { + args[_key85] = arguments[_key85]; + } + + return _builder.default.apply(void 0, ["DeclareTypeAlias"].concat(args)); +} + +function DeclareOpaqueType() { + for (var _len86 = arguments.length, args = new Array(_len86), _key86 = 0; _key86 < _len86; _key86++) { + args[_key86] = arguments[_key86]; + } + + return _builder.default.apply(void 0, ["DeclareOpaqueType"].concat(args)); +} + +function DeclareVariable() { + for (var _len87 = arguments.length, args = new Array(_len87), _key87 = 0; _key87 < _len87; _key87++) { + args[_key87] = arguments[_key87]; + } + + return _builder.default.apply(void 0, ["DeclareVariable"].concat(args)); +} + +function DeclareExportDeclaration() { + for (var _len88 = arguments.length, args = new Array(_len88), _key88 = 0; _key88 < _len88; _key88++) { + args[_key88] = arguments[_key88]; + } + + return _builder.default.apply(void 0, ["DeclareExportDeclaration"].concat(args)); +} + +function DeclareExportAllDeclaration() { + for (var _len89 = arguments.length, args = new Array(_len89), _key89 = 0; _key89 < _len89; _key89++) { + args[_key89] = arguments[_key89]; + } + + return _builder.default.apply(void 0, ["DeclareExportAllDeclaration"].concat(args)); +} + +function DeclaredPredicate() { + for (var _len90 = arguments.length, args = new Array(_len90), _key90 = 0; _key90 < _len90; _key90++) { + args[_key90] = arguments[_key90]; + } + + return _builder.default.apply(void 0, ["DeclaredPredicate"].concat(args)); +} + +function ExistsTypeAnnotation() { + for (var _len91 = arguments.length, args = new Array(_len91), _key91 = 0; _key91 < _len91; _key91++) { + args[_key91] = arguments[_key91]; + } + + return _builder.default.apply(void 0, ["ExistsTypeAnnotation"].concat(args)); +} + +function FunctionTypeAnnotation() { + for (var _len92 = arguments.length, args = new Array(_len92), _key92 = 0; _key92 < _len92; _key92++) { + args[_key92] = arguments[_key92]; + } + + return _builder.default.apply(void 0, ["FunctionTypeAnnotation"].concat(args)); +} + +function FunctionTypeParam() { + for (var _len93 = arguments.length, args = new Array(_len93), _key93 = 0; _key93 < _len93; _key93++) { + args[_key93] = arguments[_key93]; + } + + return _builder.default.apply(void 0, ["FunctionTypeParam"].concat(args)); +} + +function GenericTypeAnnotation() { + for (var _len94 = arguments.length, args = new Array(_len94), _key94 = 0; _key94 < _len94; _key94++) { + args[_key94] = arguments[_key94]; + } + + return _builder.default.apply(void 0, ["GenericTypeAnnotation"].concat(args)); +} + +function InferredPredicate() { + for (var _len95 = arguments.length, args = new Array(_len95), _key95 = 0; _key95 < _len95; _key95++) { + args[_key95] = arguments[_key95]; + } + + return _builder.default.apply(void 0, ["InferredPredicate"].concat(args)); +} + +function InterfaceExtends() { + for (var _len96 = arguments.length, args = new Array(_len96), _key96 = 0; _key96 < _len96; _key96++) { + args[_key96] = arguments[_key96]; + } + + return _builder.default.apply(void 0, ["InterfaceExtends"].concat(args)); +} + +function InterfaceDeclaration() { + for (var _len97 = arguments.length, args = new Array(_len97), _key97 = 0; _key97 < _len97; _key97++) { + args[_key97] = arguments[_key97]; + } + + return _builder.default.apply(void 0, ["InterfaceDeclaration"].concat(args)); +} + +function IntersectionTypeAnnotation() { + for (var _len98 = arguments.length, args = new Array(_len98), _key98 = 0; _key98 < _len98; _key98++) { + args[_key98] = arguments[_key98]; + } + + return _builder.default.apply(void 0, ["IntersectionTypeAnnotation"].concat(args)); +} + +function MixedTypeAnnotation() { + for (var _len99 = arguments.length, args = new Array(_len99), _key99 = 0; _key99 < _len99; _key99++) { + args[_key99] = arguments[_key99]; + } + + return _builder.default.apply(void 0, ["MixedTypeAnnotation"].concat(args)); +} + +function EmptyTypeAnnotation() { + for (var _len100 = arguments.length, args = new Array(_len100), _key100 = 0; _key100 < _len100; _key100++) { + args[_key100] = arguments[_key100]; + } + + return _builder.default.apply(void 0, ["EmptyTypeAnnotation"].concat(args)); +} + +function NullableTypeAnnotation() { + for (var _len101 = arguments.length, args = new Array(_len101), _key101 = 0; _key101 < _len101; _key101++) { + args[_key101] = arguments[_key101]; + } + + return _builder.default.apply(void 0, ["NullableTypeAnnotation"].concat(args)); +} + +function NumberLiteralTypeAnnotation() { + for (var _len102 = arguments.length, args = new Array(_len102), _key102 = 0; _key102 < _len102; _key102++) { + args[_key102] = arguments[_key102]; + } + + return _builder.default.apply(void 0, ["NumberLiteralTypeAnnotation"].concat(args)); +} + +function NumberTypeAnnotation() { + for (var _len103 = arguments.length, args = new Array(_len103), _key103 = 0; _key103 < _len103; _key103++) { + args[_key103] = arguments[_key103]; + } + + return _builder.default.apply(void 0, ["NumberTypeAnnotation"].concat(args)); +} + +function ObjectTypeAnnotation() { + for (var _len104 = arguments.length, args = new Array(_len104), _key104 = 0; _key104 < _len104; _key104++) { + args[_key104] = arguments[_key104]; + } + + return _builder.default.apply(void 0, ["ObjectTypeAnnotation"].concat(args)); +} + +function ObjectTypeCallProperty() { + for (var _len105 = arguments.length, args = new Array(_len105), _key105 = 0; _key105 < _len105; _key105++) { + args[_key105] = arguments[_key105]; + } + + return _builder.default.apply(void 0, ["ObjectTypeCallProperty"].concat(args)); +} + +function ObjectTypeIndexer() { + for (var _len106 = arguments.length, args = new Array(_len106), _key106 = 0; _key106 < _len106; _key106++) { + args[_key106] = arguments[_key106]; + } + + return _builder.default.apply(void 0, ["ObjectTypeIndexer"].concat(args)); +} + +function ObjectTypeProperty() { + for (var _len107 = arguments.length, args = new Array(_len107), _key107 = 0; _key107 < _len107; _key107++) { + args[_key107] = arguments[_key107]; + } + + return _builder.default.apply(void 0, ["ObjectTypeProperty"].concat(args)); +} + +function ObjectTypeSpreadProperty() { + for (var _len108 = arguments.length, args = new Array(_len108), _key108 = 0; _key108 < _len108; _key108++) { + args[_key108] = arguments[_key108]; + } + + return _builder.default.apply(void 0, ["ObjectTypeSpreadProperty"].concat(args)); +} + +function OpaqueType() { + for (var _len109 = arguments.length, args = new Array(_len109), _key109 = 0; _key109 < _len109; _key109++) { + args[_key109] = arguments[_key109]; + } + + return _builder.default.apply(void 0, ["OpaqueType"].concat(args)); +} + +function QualifiedTypeIdentifier() { + for (var _len110 = arguments.length, args = new Array(_len110), _key110 = 0; _key110 < _len110; _key110++) { + args[_key110] = arguments[_key110]; + } + + return _builder.default.apply(void 0, ["QualifiedTypeIdentifier"].concat(args)); +} + +function StringLiteralTypeAnnotation() { + for (var _len111 = arguments.length, args = new Array(_len111), _key111 = 0; _key111 < _len111; _key111++) { + args[_key111] = arguments[_key111]; + } + + return _builder.default.apply(void 0, ["StringLiteralTypeAnnotation"].concat(args)); +} + +function StringTypeAnnotation() { + for (var _len112 = arguments.length, args = new Array(_len112), _key112 = 0; _key112 < _len112; _key112++) { + args[_key112] = arguments[_key112]; + } + + return _builder.default.apply(void 0, ["StringTypeAnnotation"].concat(args)); +} + +function ThisTypeAnnotation() { + for (var _len113 = arguments.length, args = new Array(_len113), _key113 = 0; _key113 < _len113; _key113++) { + args[_key113] = arguments[_key113]; + } + + return _builder.default.apply(void 0, ["ThisTypeAnnotation"].concat(args)); +} + +function TupleTypeAnnotation() { + for (var _len114 = arguments.length, args = new Array(_len114), _key114 = 0; _key114 < _len114; _key114++) { + args[_key114] = arguments[_key114]; + } + + return _builder.default.apply(void 0, ["TupleTypeAnnotation"].concat(args)); +} + +function TypeofTypeAnnotation() { + for (var _len115 = arguments.length, args = new Array(_len115), _key115 = 0; _key115 < _len115; _key115++) { + args[_key115] = arguments[_key115]; + } + + return _builder.default.apply(void 0, ["TypeofTypeAnnotation"].concat(args)); +} + +function TypeAlias() { + for (var _len116 = arguments.length, args = new Array(_len116), _key116 = 0; _key116 < _len116; _key116++) { + args[_key116] = arguments[_key116]; + } + + return _builder.default.apply(void 0, ["TypeAlias"].concat(args)); +} + +function TypeAnnotation() { + for (var _len117 = arguments.length, args = new Array(_len117), _key117 = 0; _key117 < _len117; _key117++) { + args[_key117] = arguments[_key117]; + } + + return _builder.default.apply(void 0, ["TypeAnnotation"].concat(args)); +} + +function TypeCastExpression() { + for (var _len118 = arguments.length, args = new Array(_len118), _key118 = 0; _key118 < _len118; _key118++) { + args[_key118] = arguments[_key118]; + } + + return _builder.default.apply(void 0, ["TypeCastExpression"].concat(args)); +} + +function TypeParameter() { + for (var _len119 = arguments.length, args = new Array(_len119), _key119 = 0; _key119 < _len119; _key119++) { + args[_key119] = arguments[_key119]; + } + + return _builder.default.apply(void 0, ["TypeParameter"].concat(args)); +} + +function TypeParameterDeclaration() { + for (var _len120 = arguments.length, args = new Array(_len120), _key120 = 0; _key120 < _len120; _key120++) { + args[_key120] = arguments[_key120]; + } + + return _builder.default.apply(void 0, ["TypeParameterDeclaration"].concat(args)); +} + +function TypeParameterInstantiation() { + for (var _len121 = arguments.length, args = new Array(_len121), _key121 = 0; _key121 < _len121; _key121++) { + args[_key121] = arguments[_key121]; + } + + return _builder.default.apply(void 0, ["TypeParameterInstantiation"].concat(args)); +} + +function UnionTypeAnnotation() { + for (var _len122 = arguments.length, args = new Array(_len122), _key122 = 0; _key122 < _len122; _key122++) { + args[_key122] = arguments[_key122]; + } + + return _builder.default.apply(void 0, ["UnionTypeAnnotation"].concat(args)); +} + +function VoidTypeAnnotation() { + for (var _len123 = arguments.length, args = new Array(_len123), _key123 = 0; _key123 < _len123; _key123++) { + args[_key123] = arguments[_key123]; + } + + return _builder.default.apply(void 0, ["VoidTypeAnnotation"].concat(args)); +} + +function JSXAttribute() { + for (var _len124 = arguments.length, args = new Array(_len124), _key124 = 0; _key124 < _len124; _key124++) { + args[_key124] = arguments[_key124]; + } + + return _builder.default.apply(void 0, ["JSXAttribute"].concat(args)); +} + +function JSXClosingElement() { + for (var _len125 = arguments.length, args = new Array(_len125), _key125 = 0; _key125 < _len125; _key125++) { + args[_key125] = arguments[_key125]; + } + + return _builder.default.apply(void 0, ["JSXClosingElement"].concat(args)); +} + +function JSXElement() { + for (var _len126 = arguments.length, args = new Array(_len126), _key126 = 0; _key126 < _len126; _key126++) { + args[_key126] = arguments[_key126]; + } + + return _builder.default.apply(void 0, ["JSXElement"].concat(args)); +} + +function JSXEmptyExpression() { + for (var _len127 = arguments.length, args = new Array(_len127), _key127 = 0; _key127 < _len127; _key127++) { + args[_key127] = arguments[_key127]; + } + + return _builder.default.apply(void 0, ["JSXEmptyExpression"].concat(args)); +} + +function JSXExpressionContainer() { + for (var _len128 = arguments.length, args = new Array(_len128), _key128 = 0; _key128 < _len128; _key128++) { + args[_key128] = arguments[_key128]; + } + + return _builder.default.apply(void 0, ["JSXExpressionContainer"].concat(args)); +} + +function JSXSpreadChild() { + for (var _len129 = arguments.length, args = new Array(_len129), _key129 = 0; _key129 < _len129; _key129++) { + args[_key129] = arguments[_key129]; + } + + return _builder.default.apply(void 0, ["JSXSpreadChild"].concat(args)); +} + +function JSXIdentifier() { + for (var _len130 = arguments.length, args = new Array(_len130), _key130 = 0; _key130 < _len130; _key130++) { + args[_key130] = arguments[_key130]; + } + + return _builder.default.apply(void 0, ["JSXIdentifier"].concat(args)); +} + +function JSXMemberExpression() { + for (var _len131 = arguments.length, args = new Array(_len131), _key131 = 0; _key131 < _len131; _key131++) { + args[_key131] = arguments[_key131]; + } + + return _builder.default.apply(void 0, ["JSXMemberExpression"].concat(args)); +} + +function JSXNamespacedName() { + for (var _len132 = arguments.length, args = new Array(_len132), _key132 = 0; _key132 < _len132; _key132++) { + args[_key132] = arguments[_key132]; + } + + return _builder.default.apply(void 0, ["JSXNamespacedName"].concat(args)); +} + +function JSXOpeningElement() { + for (var _len133 = arguments.length, args = new Array(_len133), _key133 = 0; _key133 < _len133; _key133++) { + args[_key133] = arguments[_key133]; + } + + return _builder.default.apply(void 0, ["JSXOpeningElement"].concat(args)); +} + +function JSXSpreadAttribute() { + for (var _len134 = arguments.length, args = new Array(_len134), _key134 = 0; _key134 < _len134; _key134++) { + args[_key134] = arguments[_key134]; + } + + return _builder.default.apply(void 0, ["JSXSpreadAttribute"].concat(args)); +} + +function JSXText() { + for (var _len135 = arguments.length, args = new Array(_len135), _key135 = 0; _key135 < _len135; _key135++) { + args[_key135] = arguments[_key135]; + } + + return _builder.default.apply(void 0, ["JSXText"].concat(args)); +} + +function JSXFragment() { + for (var _len136 = arguments.length, args = new Array(_len136), _key136 = 0; _key136 < _len136; _key136++) { + args[_key136] = arguments[_key136]; + } + + return _builder.default.apply(void 0, ["JSXFragment"].concat(args)); +} + +function JSXOpeningFragment() { + for (var _len137 = arguments.length, args = new Array(_len137), _key137 = 0; _key137 < _len137; _key137++) { + args[_key137] = arguments[_key137]; + } + + return _builder.default.apply(void 0, ["JSXOpeningFragment"].concat(args)); +} + +function JSXClosingFragment() { + for (var _len138 = arguments.length, args = new Array(_len138), _key138 = 0; _key138 < _len138; _key138++) { + args[_key138] = arguments[_key138]; + } + + return _builder.default.apply(void 0, ["JSXClosingFragment"].concat(args)); +} + +function Noop() { + for (var _len139 = arguments.length, args = new Array(_len139), _key139 = 0; _key139 < _len139; _key139++) { + args[_key139] = arguments[_key139]; + } + + return _builder.default.apply(void 0, ["Noop"].concat(args)); +} + +function ParenthesizedExpression() { + for (var _len140 = arguments.length, args = new Array(_len140), _key140 = 0; _key140 < _len140; _key140++) { + args[_key140] = arguments[_key140]; + } + + return _builder.default.apply(void 0, ["ParenthesizedExpression"].concat(args)); +} + +function AwaitExpression() { + for (var _len141 = arguments.length, args = new Array(_len141), _key141 = 0; _key141 < _len141; _key141++) { + args[_key141] = arguments[_key141]; + } + + return _builder.default.apply(void 0, ["AwaitExpression"].concat(args)); +} + +function BindExpression() { + for (var _len142 = arguments.length, args = new Array(_len142), _key142 = 0; _key142 < _len142; _key142++) { + args[_key142] = arguments[_key142]; + } + + return _builder.default.apply(void 0, ["BindExpression"].concat(args)); +} + +function ClassProperty() { + for (var _len143 = arguments.length, args = new Array(_len143), _key143 = 0; _key143 < _len143; _key143++) { + args[_key143] = arguments[_key143]; + } + + return _builder.default.apply(void 0, ["ClassProperty"].concat(args)); +} + +function Import() { + for (var _len144 = arguments.length, args = new Array(_len144), _key144 = 0; _key144 < _len144; _key144++) { + args[_key144] = arguments[_key144]; + } + + return _builder.default.apply(void 0, ["Import"].concat(args)); +} + +function Decorator() { + for (var _len145 = arguments.length, args = new Array(_len145), _key145 = 0; _key145 < _len145; _key145++) { + args[_key145] = arguments[_key145]; + } + + return _builder.default.apply(void 0, ["Decorator"].concat(args)); +} + +function DoExpression() { + for (var _len146 = arguments.length, args = new Array(_len146), _key146 = 0; _key146 < _len146; _key146++) { + args[_key146] = arguments[_key146]; + } + + return _builder.default.apply(void 0, ["DoExpression"].concat(args)); +} + +function ExportDefaultSpecifier() { + for (var _len147 = arguments.length, args = new Array(_len147), _key147 = 0; _key147 < _len147; _key147++) { + args[_key147] = arguments[_key147]; + } + + return _builder.default.apply(void 0, ["ExportDefaultSpecifier"].concat(args)); +} + +function ExportNamespaceSpecifier() { + for (var _len148 = arguments.length, args = new Array(_len148), _key148 = 0; _key148 < _len148; _key148++) { + args[_key148] = arguments[_key148]; + } + + return _builder.default.apply(void 0, ["ExportNamespaceSpecifier"].concat(args)); +} + +function TSParameterProperty() { + for (var _len149 = arguments.length, args = new Array(_len149), _key149 = 0; _key149 < _len149; _key149++) { + args[_key149] = arguments[_key149]; + } + + return _builder.default.apply(void 0, ["TSParameterProperty"].concat(args)); +} + +function TSDeclareFunction() { + for (var _len150 = arguments.length, args = new Array(_len150), _key150 = 0; _key150 < _len150; _key150++) { + args[_key150] = arguments[_key150]; + } + + return _builder.default.apply(void 0, ["TSDeclareFunction"].concat(args)); +} + +function TSDeclareMethod() { + for (var _len151 = arguments.length, args = new Array(_len151), _key151 = 0; _key151 < _len151; _key151++) { + args[_key151] = arguments[_key151]; + } + + return _builder.default.apply(void 0, ["TSDeclareMethod"].concat(args)); +} + +function TSQualifiedName() { + for (var _len152 = arguments.length, args = new Array(_len152), _key152 = 0; _key152 < _len152; _key152++) { + args[_key152] = arguments[_key152]; + } + + return _builder.default.apply(void 0, ["TSQualifiedName"].concat(args)); +} + +function TSCallSignatureDeclaration() { + for (var _len153 = arguments.length, args = new Array(_len153), _key153 = 0; _key153 < _len153; _key153++) { + args[_key153] = arguments[_key153]; + } + + return _builder.default.apply(void 0, ["TSCallSignatureDeclaration"].concat(args)); +} + +function TSConstructSignatureDeclaration() { + for (var _len154 = arguments.length, args = new Array(_len154), _key154 = 0; _key154 < _len154; _key154++) { + args[_key154] = arguments[_key154]; + } + + return _builder.default.apply(void 0, ["TSConstructSignatureDeclaration"].concat(args)); +} + +function TSPropertySignature() { + for (var _len155 = arguments.length, args = new Array(_len155), _key155 = 0; _key155 < _len155; _key155++) { + args[_key155] = arguments[_key155]; + } + + return _builder.default.apply(void 0, ["TSPropertySignature"].concat(args)); +} + +function TSMethodSignature() { + for (var _len156 = arguments.length, args = new Array(_len156), _key156 = 0; _key156 < _len156; _key156++) { + args[_key156] = arguments[_key156]; + } + + return _builder.default.apply(void 0, ["TSMethodSignature"].concat(args)); +} + +function TSIndexSignature() { + for (var _len157 = arguments.length, args = new Array(_len157), _key157 = 0; _key157 < _len157; _key157++) { + args[_key157] = arguments[_key157]; + } + + return _builder.default.apply(void 0, ["TSIndexSignature"].concat(args)); +} + +function TSAnyKeyword() { + for (var _len158 = arguments.length, args = new Array(_len158), _key158 = 0; _key158 < _len158; _key158++) { + args[_key158] = arguments[_key158]; + } + + return _builder.default.apply(void 0, ["TSAnyKeyword"].concat(args)); +} + +function TSNumberKeyword() { + for (var _len159 = arguments.length, args = new Array(_len159), _key159 = 0; _key159 < _len159; _key159++) { + args[_key159] = arguments[_key159]; + } + + return _builder.default.apply(void 0, ["TSNumberKeyword"].concat(args)); +} + +function TSObjectKeyword() { + for (var _len160 = arguments.length, args = new Array(_len160), _key160 = 0; _key160 < _len160; _key160++) { + args[_key160] = arguments[_key160]; + } + + return _builder.default.apply(void 0, ["TSObjectKeyword"].concat(args)); +} + +function TSBooleanKeyword() { + for (var _len161 = arguments.length, args = new Array(_len161), _key161 = 0; _key161 < _len161; _key161++) { + args[_key161] = arguments[_key161]; + } + + return _builder.default.apply(void 0, ["TSBooleanKeyword"].concat(args)); +} + +function TSStringKeyword() { + for (var _len162 = arguments.length, args = new Array(_len162), _key162 = 0; _key162 < _len162; _key162++) { + args[_key162] = arguments[_key162]; + } + + return _builder.default.apply(void 0, ["TSStringKeyword"].concat(args)); +} + +function TSSymbolKeyword() { + for (var _len163 = arguments.length, args = new Array(_len163), _key163 = 0; _key163 < _len163; _key163++) { + args[_key163] = arguments[_key163]; + } + + return _builder.default.apply(void 0, ["TSSymbolKeyword"].concat(args)); +} + +function TSVoidKeyword() { + for (var _len164 = arguments.length, args = new Array(_len164), _key164 = 0; _key164 < _len164; _key164++) { + args[_key164] = arguments[_key164]; + } + + return _builder.default.apply(void 0, ["TSVoidKeyword"].concat(args)); +} + +function TSUndefinedKeyword() { + for (var _len165 = arguments.length, args = new Array(_len165), _key165 = 0; _key165 < _len165; _key165++) { + args[_key165] = arguments[_key165]; + } + + return _builder.default.apply(void 0, ["TSUndefinedKeyword"].concat(args)); +} + +function TSNullKeyword() { + for (var _len166 = arguments.length, args = new Array(_len166), _key166 = 0; _key166 < _len166; _key166++) { + args[_key166] = arguments[_key166]; + } + + return _builder.default.apply(void 0, ["TSNullKeyword"].concat(args)); +} + +function TSNeverKeyword() { + for (var _len167 = arguments.length, args = new Array(_len167), _key167 = 0; _key167 < _len167; _key167++) { + args[_key167] = arguments[_key167]; + } + + return _builder.default.apply(void 0, ["TSNeverKeyword"].concat(args)); +} + +function TSThisType() { + for (var _len168 = arguments.length, args = new Array(_len168), _key168 = 0; _key168 < _len168; _key168++) { + args[_key168] = arguments[_key168]; + } + + return _builder.default.apply(void 0, ["TSThisType"].concat(args)); +} + +function TSFunctionType() { + for (var _len169 = arguments.length, args = new Array(_len169), _key169 = 0; _key169 < _len169; _key169++) { + args[_key169] = arguments[_key169]; + } + + return _builder.default.apply(void 0, ["TSFunctionType"].concat(args)); +} + +function TSConstructorType() { + for (var _len170 = arguments.length, args = new Array(_len170), _key170 = 0; _key170 < _len170; _key170++) { + args[_key170] = arguments[_key170]; + } + + return _builder.default.apply(void 0, ["TSConstructorType"].concat(args)); +} + +function TSTypeReference() { + for (var _len171 = arguments.length, args = new Array(_len171), _key171 = 0; _key171 < _len171; _key171++) { + args[_key171] = arguments[_key171]; + } + + return _builder.default.apply(void 0, ["TSTypeReference"].concat(args)); +} + +function TSTypePredicate() { + for (var _len172 = arguments.length, args = new Array(_len172), _key172 = 0; _key172 < _len172; _key172++) { + args[_key172] = arguments[_key172]; + } + + return _builder.default.apply(void 0, ["TSTypePredicate"].concat(args)); +} + +function TSTypeQuery() { + for (var _len173 = arguments.length, args = new Array(_len173), _key173 = 0; _key173 < _len173; _key173++) { + args[_key173] = arguments[_key173]; + } + + return _builder.default.apply(void 0, ["TSTypeQuery"].concat(args)); +} + +function TSTypeLiteral() { + for (var _len174 = arguments.length, args = new Array(_len174), _key174 = 0; _key174 < _len174; _key174++) { + args[_key174] = arguments[_key174]; + } + + return _builder.default.apply(void 0, ["TSTypeLiteral"].concat(args)); +} + +function TSArrayType() { + for (var _len175 = arguments.length, args = new Array(_len175), _key175 = 0; _key175 < _len175; _key175++) { + args[_key175] = arguments[_key175]; + } + + return _builder.default.apply(void 0, ["TSArrayType"].concat(args)); +} + +function TSTupleType() { + for (var _len176 = arguments.length, args = new Array(_len176), _key176 = 0; _key176 < _len176; _key176++) { + args[_key176] = arguments[_key176]; + } + + return _builder.default.apply(void 0, ["TSTupleType"].concat(args)); +} + +function TSUnionType() { + for (var _len177 = arguments.length, args = new Array(_len177), _key177 = 0; _key177 < _len177; _key177++) { + args[_key177] = arguments[_key177]; + } + + return _builder.default.apply(void 0, ["TSUnionType"].concat(args)); +} + +function TSIntersectionType() { + for (var _len178 = arguments.length, args = new Array(_len178), _key178 = 0; _key178 < _len178; _key178++) { + args[_key178] = arguments[_key178]; + } + + return _builder.default.apply(void 0, ["TSIntersectionType"].concat(args)); +} + +function TSParenthesizedType() { + for (var _len179 = arguments.length, args = new Array(_len179), _key179 = 0; _key179 < _len179; _key179++) { + args[_key179] = arguments[_key179]; + } + + return _builder.default.apply(void 0, ["TSParenthesizedType"].concat(args)); +} + +function TSTypeOperator() { + for (var _len180 = arguments.length, args = new Array(_len180), _key180 = 0; _key180 < _len180; _key180++) { + args[_key180] = arguments[_key180]; + } + + return _builder.default.apply(void 0, ["TSTypeOperator"].concat(args)); +} + +function TSIndexedAccessType() { + for (var _len181 = arguments.length, args = new Array(_len181), _key181 = 0; _key181 < _len181; _key181++) { + args[_key181] = arguments[_key181]; + } + + return _builder.default.apply(void 0, ["TSIndexedAccessType"].concat(args)); +} + +function TSMappedType() { + for (var _len182 = arguments.length, args = new Array(_len182), _key182 = 0; _key182 < _len182; _key182++) { + args[_key182] = arguments[_key182]; + } + + return _builder.default.apply(void 0, ["TSMappedType"].concat(args)); +} + +function TSLiteralType() { + for (var _len183 = arguments.length, args = new Array(_len183), _key183 = 0; _key183 < _len183; _key183++) { + args[_key183] = arguments[_key183]; + } + + return _builder.default.apply(void 0, ["TSLiteralType"].concat(args)); +} + +function TSExpressionWithTypeArguments() { + for (var _len184 = arguments.length, args = new Array(_len184), _key184 = 0; _key184 < _len184; _key184++) { + args[_key184] = arguments[_key184]; + } + + return _builder.default.apply(void 0, ["TSExpressionWithTypeArguments"].concat(args)); +} + +function TSInterfaceDeclaration() { + for (var _len185 = arguments.length, args = new Array(_len185), _key185 = 0; _key185 < _len185; _key185++) { + args[_key185] = arguments[_key185]; + } + + return _builder.default.apply(void 0, ["TSInterfaceDeclaration"].concat(args)); +} + +function TSInterfaceBody() { + for (var _len186 = arguments.length, args = new Array(_len186), _key186 = 0; _key186 < _len186; _key186++) { + args[_key186] = arguments[_key186]; + } + + return _builder.default.apply(void 0, ["TSInterfaceBody"].concat(args)); +} + +function TSTypeAliasDeclaration() { + for (var _len187 = arguments.length, args = new Array(_len187), _key187 = 0; _key187 < _len187; _key187++) { + args[_key187] = arguments[_key187]; + } + + return _builder.default.apply(void 0, ["TSTypeAliasDeclaration"].concat(args)); +} + +function TSAsExpression() { + for (var _len188 = arguments.length, args = new Array(_len188), _key188 = 0; _key188 < _len188; _key188++) { + args[_key188] = arguments[_key188]; + } + + return _builder.default.apply(void 0, ["TSAsExpression"].concat(args)); +} + +function TSTypeAssertion() { + for (var _len189 = arguments.length, args = new Array(_len189), _key189 = 0; _key189 < _len189; _key189++) { + args[_key189] = arguments[_key189]; + } + + return _builder.default.apply(void 0, ["TSTypeAssertion"].concat(args)); +} + +function TSEnumDeclaration() { + for (var _len190 = arguments.length, args = new Array(_len190), _key190 = 0; _key190 < _len190; _key190++) { + args[_key190] = arguments[_key190]; + } + + return _builder.default.apply(void 0, ["TSEnumDeclaration"].concat(args)); +} + +function TSEnumMember() { + for (var _len191 = arguments.length, args = new Array(_len191), _key191 = 0; _key191 < _len191; _key191++) { + args[_key191] = arguments[_key191]; + } + + return _builder.default.apply(void 0, ["TSEnumMember"].concat(args)); +} + +function TSModuleDeclaration() { + for (var _len192 = arguments.length, args = new Array(_len192), _key192 = 0; _key192 < _len192; _key192++) { + args[_key192] = arguments[_key192]; + } + + return _builder.default.apply(void 0, ["TSModuleDeclaration"].concat(args)); +} + +function TSModuleBlock() { + for (var _len193 = arguments.length, args = new Array(_len193), _key193 = 0; _key193 < _len193; _key193++) { + args[_key193] = arguments[_key193]; + } + + return _builder.default.apply(void 0, ["TSModuleBlock"].concat(args)); +} + +function TSImportEqualsDeclaration() { + for (var _len194 = arguments.length, args = new Array(_len194), _key194 = 0; _key194 < _len194; _key194++) { + args[_key194] = arguments[_key194]; + } + + return _builder.default.apply(void 0, ["TSImportEqualsDeclaration"].concat(args)); +} + +function TSExternalModuleReference() { + for (var _len195 = arguments.length, args = new Array(_len195), _key195 = 0; _key195 < _len195; _key195++) { + args[_key195] = arguments[_key195]; + } + + return _builder.default.apply(void 0, ["TSExternalModuleReference"].concat(args)); +} + +function TSNonNullExpression() { + for (var _len196 = arguments.length, args = new Array(_len196), _key196 = 0; _key196 < _len196; _key196++) { + args[_key196] = arguments[_key196]; + } + + return _builder.default.apply(void 0, ["TSNonNullExpression"].concat(args)); +} + +function TSExportAssignment() { + for (var _len197 = arguments.length, args = new Array(_len197), _key197 = 0; _key197 < _len197; _key197++) { + args[_key197] = arguments[_key197]; + } + + return _builder.default.apply(void 0, ["TSExportAssignment"].concat(args)); +} + +function TSNamespaceExportDeclaration() { + for (var _len198 = arguments.length, args = new Array(_len198), _key198 = 0; _key198 < _len198; _key198++) { + args[_key198] = arguments[_key198]; + } + + return _builder.default.apply(void 0, ["TSNamespaceExportDeclaration"].concat(args)); +} + +function TSTypeAnnotation() { + for (var _len199 = arguments.length, args = new Array(_len199), _key199 = 0; _key199 < _len199; _key199++) { + args[_key199] = arguments[_key199]; + } + + return _builder.default.apply(void 0, ["TSTypeAnnotation"].concat(args)); +} + +function TSTypeParameterInstantiation() { + for (var _len200 = arguments.length, args = new Array(_len200), _key200 = 0; _key200 < _len200; _key200++) { + args[_key200] = arguments[_key200]; + } + + return _builder.default.apply(void 0, ["TSTypeParameterInstantiation"].concat(args)); +} + +function TSTypeParameterDeclaration() { + for (var _len201 = arguments.length, args = new Array(_len201), _key201 = 0; _key201 < _len201; _key201++) { + args[_key201] = arguments[_key201]; + } + + return _builder.default.apply(void 0, ["TSTypeParameterDeclaration"].concat(args)); +} + +function TSTypeParameter() { + for (var _len202 = arguments.length, args = new Array(_len202), _key202 = 0; _key202 < _len202; _key202++) { + args[_key202] = arguments[_key202]; + } + + return _builder.default.apply(void 0, ["TSTypeParameter"].concat(args)); +} + +function NumberLiteral() { + console.trace("The node type NumberLiteral has been renamed to NumericLiteral"); + + for (var _len203 = arguments.length, args = new Array(_len203), _key203 = 0; _key203 < _len203; _key203++) { + args[_key203] = arguments[_key203]; + } + + return NumberLiteral.apply(void 0, ["NumberLiteral"].concat(args)); +} + +function RegexLiteral() { + console.trace("The node type RegexLiteral has been renamed to RegExpLiteral"); + + for (var _len204 = arguments.length, args = new Array(_len204), _key204 = 0; _key204 < _len204; _key204++) { + args[_key204] = arguments[_key204]; + } + + return RegexLiteral.apply(void 0, ["RegexLiteral"].concat(args)); +} + +function RestProperty() { + console.trace("The node type RestProperty has been renamed to RestElement"); + + for (var _len205 = arguments.length, args = new Array(_len205), _key205 = 0; _key205 < _len205; _key205++) { + args[_key205] = arguments[_key205]; + } + + return RestProperty.apply(void 0, ["RestProperty"].concat(args)); +} + +function SpreadProperty() { + console.trace("The node type SpreadProperty has been renamed to SpreadElement"); + + for (var _len206 = arguments.length, args = new Array(_len206), _key206 = 0; _key206 < _len206; _key206++) { + args[_key206] = arguments[_key206]; + } + + return SpreadProperty.apply(void 0, ["SpreadProperty"].concat(args)); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/builders/react/buildChildren.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/builders/react/buildChildren.js new file mode 100644 index 00000000000000..26c3068fd38658 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/builders/react/buildChildren.js @@ -0,0 +1,29 @@ +"use strict"; + +exports.__esModule = true; +exports.default = buildChildren; + +var _generated = require("../../validators/generated"); + +var _cleanJSXElementLiteralChild = _interopRequireDefault(require("../../utils/react/cleanJSXElementLiteralChild")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function buildChildren(node) { + var elements = []; + + for (var i = 0; i < node.children.length; i++) { + var child = node.children[i]; + + if ((0, _generated.isJSXText)(child)) { + (0, _cleanJSXElementLiteralChild.default)(child, elements); + continue; + } + + if ((0, _generated.isJSXExpressionContainer)(child)) child = child.expression; + if ((0, _generated.isJSXEmptyExpression)(child)) continue; + elements.push(child); + } + + return elements; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/clone/clone.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/clone/clone.js new file mode 100644 index 00000000000000..2677f9023a063d --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/clone/clone.js @@ -0,0 +1,14 @@ +"use strict"; + +exports.__esModule = true; +exports.default = clone; + +function clone(node) { + if (!node) return node; + var newNode = {}; + Object.keys(node).forEach(function (key) { + if (key[0] === "_") return; + newNode[key] = node[key]; + }); + return newNode; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/clone/cloneDeep.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/clone/cloneDeep.js new file mode 100644 index 00000000000000..4212edd2bc7482 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/clone/cloneDeep.js @@ -0,0 +1,24 @@ +"use strict"; + +exports.__esModule = true; +exports.default = cloneDeep; + +function cloneDeep(node) { + if (!node) return node; + var newNode = {}; + Object.keys(node).forEach(function (key) { + if (key[0] === "_") return; + var val = node[key]; + + if (val) { + if (val.type) { + val = cloneDeep(val); + } else if (Array.isArray(val)) { + val = val.map(cloneDeep); + } + } + + newNode[key] = val; + }); + return newNode; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/clone/cloneWithoutLoc.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/clone/cloneWithoutLoc.js new file mode 100644 index 00000000000000..a32214294208dc --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/clone/cloneWithoutLoc.js @@ -0,0 +1,14 @@ +"use strict"; + +exports.__esModule = true; +exports.default = cloneWithoutLoc; + +var _clone = _interopRequireDefault(require("./clone")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function cloneWithoutLoc(node) { + var newNode = (0, _clone.default)(node); + newNode.loc = null; + return newNode; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/addComment.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/addComment.js new file mode 100644 index 00000000000000..bbe3c969549b34 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/addComment.js @@ -0,0 +1,15 @@ +"use strict"; + +exports.__esModule = true; +exports.default = addComment; + +var _addComments = _interopRequireDefault(require("./addComments")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function addComment(node, type, content, line) { + return (0, _addComments.default)(node, type, [{ + type: line ? "CommentLine" : "CommentBlock", + value: content + }]); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/addComments.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/addComments.js new file mode 100644 index 00000000000000..1f7c52931da182 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/addComments.js @@ -0,0 +1,21 @@ +"use strict"; + +exports.__esModule = true; +exports.default = addComments; + +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; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/inheritInnerComments.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/inheritInnerComments.js new file mode 100644 index 00000000000000..02f1ad5092e29e --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/inheritInnerComments.js @@ -0,0 +1,12 @@ +"use strict"; + +exports.__esModule = true; +exports.default = inheritInnerComments; + +var _inherit = _interopRequireDefault(require("../utils/inherit")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function inheritInnerComments(child, parent) { + (0, _inherit.default)("innerComments", child, parent); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/inheritLeadingComments.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/inheritLeadingComments.js new file mode 100644 index 00000000000000..f5c213be1fcddd --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/inheritLeadingComments.js @@ -0,0 +1,12 @@ +"use strict"; + +exports.__esModule = true; +exports.default = inheritLeadingComments; + +var _inherit = _interopRequireDefault(require("../utils/inherit")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function inheritLeadingComments(child, parent) { + (0, _inherit.default)("leadingComments", child, parent); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/inheritTrailingComments.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/inheritTrailingComments.js new file mode 100644 index 00000000000000..81d60f74148d4e --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/inheritTrailingComments.js @@ -0,0 +1,12 @@ +"use strict"; + +exports.__esModule = true; +exports.default = inheritTrailingComments; + +var _inherit = _interopRequireDefault(require("../utils/inherit")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function inheritTrailingComments(child, parent) { + (0, _inherit.default)("trailingComments", child, parent); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/inheritsComments.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/inheritsComments.js new file mode 100644 index 00000000000000..f0446776df81ac --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/inheritsComments.js @@ -0,0 +1,19 @@ +"use strict"; + +exports.__esModule = true; +exports.default = inheritsComments; + +var _inheritTrailingComments = _interopRequireDefault(require("./inheritTrailingComments")); + +var _inheritLeadingComments = _interopRequireDefault(require("./inheritLeadingComments")); + +var _inheritInnerComments = _interopRequireDefault(require("./inheritInnerComments")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function inheritsComments(child, parent) { + (0, _inheritTrailingComments.default)(child, parent); + (0, _inheritLeadingComments.default)(child, parent); + (0, _inheritInnerComments.default)(child, parent); + return child; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/removeComments.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/removeComments.js new file mode 100644 index 00000000000000..30319b1c9c5144 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/comments/removeComments.js @@ -0,0 +1,14 @@ +"use strict"; + +exports.__esModule = true; +exports.default = removeComments; + +var _constants = require("../constants"); + +function removeComments(node) { + _constants.COMMENT_KEYS.forEach(function (key) { + node[key] = null; + }); + + return node; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/constants/generated/index.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/constants/generated/index.js new file mode 100644 index 00000000000000..20f182ed1def1f --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/constants/generated/index.js @@ -0,0 +1,87 @@ +"use strict"; + +exports.__esModule = true; +exports.TSTYPE_TYPES = exports.TSTYPEELEMENT_TYPES = exports.JSX_TYPES = exports.FLOWPREDICATE_TYPES = exports.FLOWDECLARATION_TYPES = exports.FLOWBASEANNOTATION_TYPES = exports.FLOW_TYPES = exports.MODULESPECIFIER_TYPES = exports.EXPORTDECLARATION_TYPES = exports.MODULEDECLARATION_TYPES = exports.CLASS_TYPES = exports.PATTERN_TYPES = exports.UNARYLIKE_TYPES = exports.PROPERTY_TYPES = exports.OBJECTMEMBER_TYPES = exports.METHOD_TYPES = exports.USERWHITESPACABLE_TYPES = exports.IMMUTABLE_TYPES = exports.LITERAL_TYPES = exports.TSENTITYNAME_TYPES = exports.LVAL_TYPES = exports.PATTERNLIKE_TYPES = exports.DECLARATION_TYPES = exports.PUREISH_TYPES = exports.FUNCTIONPARENT_TYPES = exports.FUNCTION_TYPES = exports.FORXSTATEMENT_TYPES = exports.FOR_TYPES = exports.EXPRESSIONWRAPPER_TYPES = exports.WHILE_TYPES = exports.LOOP_TYPES = exports.CONDITIONAL_TYPES = exports.COMPLETIONSTATEMENT_TYPES = exports.TERMINATORLESS_TYPES = exports.STATEMENT_TYPES = exports.BLOCK_TYPES = exports.BLOCKPARENT_TYPES = exports.SCOPABLE_TYPES = exports.BINARY_TYPES = exports.EXPRESSION_TYPES = void 0; + +var _definitions = require("../../definitions"); + +var EXPRESSION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Expression"]; +exports.EXPRESSION_TYPES = EXPRESSION_TYPES; +var BINARY_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Binary"]; +exports.BINARY_TYPES = BINARY_TYPES; +var SCOPABLE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Scopable"]; +exports.SCOPABLE_TYPES = SCOPABLE_TYPES; +var BLOCKPARENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["BlockParent"]; +exports.BLOCKPARENT_TYPES = BLOCKPARENT_TYPES; +var BLOCK_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Block"]; +exports.BLOCK_TYPES = BLOCK_TYPES; +var STATEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Statement"]; +exports.STATEMENT_TYPES = STATEMENT_TYPES; +var TERMINATORLESS_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Terminatorless"]; +exports.TERMINATORLESS_TYPES = TERMINATORLESS_TYPES; +var COMPLETIONSTATEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["CompletionStatement"]; +exports.COMPLETIONSTATEMENT_TYPES = COMPLETIONSTATEMENT_TYPES; +var CONDITIONAL_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Conditional"]; +exports.CONDITIONAL_TYPES = CONDITIONAL_TYPES; +var LOOP_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Loop"]; +exports.LOOP_TYPES = LOOP_TYPES; +var WHILE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["While"]; +exports.WHILE_TYPES = WHILE_TYPES; +var EXPRESSIONWRAPPER_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ExpressionWrapper"]; +exports.EXPRESSIONWRAPPER_TYPES = EXPRESSIONWRAPPER_TYPES; +var FOR_TYPES = _definitions.FLIPPED_ALIAS_KEYS["For"]; +exports.FOR_TYPES = FOR_TYPES; +var FORXSTATEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ForXStatement"]; +exports.FORXSTATEMENT_TYPES = FORXSTATEMENT_TYPES; +var FUNCTION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Function"]; +exports.FUNCTION_TYPES = FUNCTION_TYPES; +var FUNCTIONPARENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FunctionParent"]; +exports.FUNCTIONPARENT_TYPES = FUNCTIONPARENT_TYPES; +var PUREISH_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Pureish"]; +exports.PUREISH_TYPES = PUREISH_TYPES; +var DECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Declaration"]; +exports.DECLARATION_TYPES = DECLARATION_TYPES; +var PATTERNLIKE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["PatternLike"]; +exports.PATTERNLIKE_TYPES = PATTERNLIKE_TYPES; +var LVAL_TYPES = _definitions.FLIPPED_ALIAS_KEYS["LVal"]; +exports.LVAL_TYPES = LVAL_TYPES; +var TSENTITYNAME_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TSEntityName"]; +exports.TSENTITYNAME_TYPES = TSENTITYNAME_TYPES; +var LITERAL_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Literal"]; +exports.LITERAL_TYPES = LITERAL_TYPES; +var IMMUTABLE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Immutable"]; +exports.IMMUTABLE_TYPES = IMMUTABLE_TYPES; +var USERWHITESPACABLE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["UserWhitespacable"]; +exports.USERWHITESPACABLE_TYPES = USERWHITESPACABLE_TYPES; +var METHOD_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Method"]; +exports.METHOD_TYPES = METHOD_TYPES; +var OBJECTMEMBER_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ObjectMember"]; +exports.OBJECTMEMBER_TYPES = OBJECTMEMBER_TYPES; +var PROPERTY_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Property"]; +exports.PROPERTY_TYPES = PROPERTY_TYPES; +var UNARYLIKE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["UnaryLike"]; +exports.UNARYLIKE_TYPES = UNARYLIKE_TYPES; +var PATTERN_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Pattern"]; +exports.PATTERN_TYPES = PATTERN_TYPES; +var CLASS_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Class"]; +exports.CLASS_TYPES = CLASS_TYPES; +var MODULEDECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ModuleDeclaration"]; +exports.MODULEDECLARATION_TYPES = MODULEDECLARATION_TYPES; +var EXPORTDECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ExportDeclaration"]; +exports.EXPORTDECLARATION_TYPES = EXPORTDECLARATION_TYPES; +var MODULESPECIFIER_TYPES = _definitions.FLIPPED_ALIAS_KEYS["ModuleSpecifier"]; +exports.MODULESPECIFIER_TYPES = MODULESPECIFIER_TYPES; +var FLOW_TYPES = _definitions.FLIPPED_ALIAS_KEYS["Flow"]; +exports.FLOW_TYPES = FLOW_TYPES; +var FLOWBASEANNOTATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FlowBaseAnnotation"]; +exports.FLOWBASEANNOTATION_TYPES = FLOWBASEANNOTATION_TYPES; +var FLOWDECLARATION_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FlowDeclaration"]; +exports.FLOWDECLARATION_TYPES = FLOWDECLARATION_TYPES; +var FLOWPREDICATE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["FlowPredicate"]; +exports.FLOWPREDICATE_TYPES = FLOWPREDICATE_TYPES; +var JSX_TYPES = _definitions.FLIPPED_ALIAS_KEYS["JSX"]; +exports.JSX_TYPES = JSX_TYPES; +var TSTYPEELEMENT_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TSTypeElement"]; +exports.TSTYPEELEMENT_TYPES = TSTYPEELEMENT_TYPES; +var TSTYPE_TYPES = _definitions.FLIPPED_ALIAS_KEYS["TSType"]; +exports.TSTYPE_TYPES = TSTYPE_TYPES; \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/constants/index.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/constants/index.js new file mode 100644 index 00000000000000..f8eb31b9eed64c --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/constants/index.js @@ -0,0 +1,45 @@ +"use strict"; + +exports.__esModule = true; +exports.NOT_LOCAL_BINDING = exports.BLOCK_SCOPED_SYMBOL = exports.INHERIT_KEYS = exports.UNARY_OPERATORS = exports.STRING_UNARY_OPERATORS = exports.NUMBER_UNARY_OPERATORS = exports.BOOLEAN_UNARY_OPERATORS = exports.BINARY_OPERATORS = exports.NUMBER_BINARY_OPERATORS = exports.BOOLEAN_BINARY_OPERATORS = exports.COMPARISON_BINARY_OPERATORS = exports.EQUALITY_BINARY_OPERATORS = exports.BOOLEAN_NUMBER_BINARY_OPERATORS = exports.UPDATE_OPERATORS = exports.LOGICAL_OPERATORS = exports.COMMENT_KEYS = exports.FOR_INIT_KEYS = exports.FLATTENABLE_KEYS = exports.STATEMENT_OR_BLOCK_KEYS = void 0; +var STATEMENT_OR_BLOCK_KEYS = ["consequent", "body", "alternate"]; +exports.STATEMENT_OR_BLOCK_KEYS = STATEMENT_OR_BLOCK_KEYS; +var FLATTENABLE_KEYS = ["body", "expressions"]; +exports.FLATTENABLE_KEYS = FLATTENABLE_KEYS; +var FOR_INIT_KEYS = ["left", "init"]; +exports.FOR_INIT_KEYS = FOR_INIT_KEYS; +var COMMENT_KEYS = ["leadingComments", "trailingComments", "innerComments"]; +exports.COMMENT_KEYS = COMMENT_KEYS; +var LOGICAL_OPERATORS = ["||", "&&", "??"]; +exports.LOGICAL_OPERATORS = LOGICAL_OPERATORS; +var UPDATE_OPERATORS = ["++", "--"]; +exports.UPDATE_OPERATORS = UPDATE_OPERATORS; +var BOOLEAN_NUMBER_BINARY_OPERATORS = [">", "<", ">=", "<="]; +exports.BOOLEAN_NUMBER_BINARY_OPERATORS = BOOLEAN_NUMBER_BINARY_OPERATORS; +var EQUALITY_BINARY_OPERATORS = ["==", "===", "!=", "!=="]; +exports.EQUALITY_BINARY_OPERATORS = EQUALITY_BINARY_OPERATORS; +var COMPARISON_BINARY_OPERATORS = EQUALITY_BINARY_OPERATORS.concat(["in", "instanceof"]); +exports.COMPARISON_BINARY_OPERATORS = COMPARISON_BINARY_OPERATORS; +var BOOLEAN_BINARY_OPERATORS = COMPARISON_BINARY_OPERATORS.concat(BOOLEAN_NUMBER_BINARY_OPERATORS); +exports.BOOLEAN_BINARY_OPERATORS = BOOLEAN_BINARY_OPERATORS; +var NUMBER_BINARY_OPERATORS = ["-", "/", "%", "*", "**", "&", "|", ">>", ">>>", "<<", "^"]; +exports.NUMBER_BINARY_OPERATORS = NUMBER_BINARY_OPERATORS; +var BINARY_OPERATORS = ["+"].concat(NUMBER_BINARY_OPERATORS, BOOLEAN_BINARY_OPERATORS); +exports.BINARY_OPERATORS = BINARY_OPERATORS; +var BOOLEAN_UNARY_OPERATORS = ["delete", "!"]; +exports.BOOLEAN_UNARY_OPERATORS = BOOLEAN_UNARY_OPERATORS; +var NUMBER_UNARY_OPERATORS = ["+", "-", "~"]; +exports.NUMBER_UNARY_OPERATORS = NUMBER_UNARY_OPERATORS; +var STRING_UNARY_OPERATORS = ["typeof"]; +exports.STRING_UNARY_OPERATORS = STRING_UNARY_OPERATORS; +var UNARY_OPERATORS = ["void", "throw"].concat(BOOLEAN_UNARY_OPERATORS, NUMBER_UNARY_OPERATORS, STRING_UNARY_OPERATORS); +exports.UNARY_OPERATORS = UNARY_OPERATORS; +var INHERIT_KEYS = { + optional: ["typeAnnotation", "typeParameters", "returnType"], + force: ["start", "loc", "end"] +}; +exports.INHERIT_KEYS = INHERIT_KEYS; +var BLOCK_SCOPED_SYMBOL = Symbol.for("var used to be block scoped"); +exports.BLOCK_SCOPED_SYMBOL = BLOCK_SCOPED_SYMBOL; +var NOT_LOCAL_BINDING = Symbol.for("should not be considered a local binding"); +exports.NOT_LOCAL_BINDING = NOT_LOCAL_BINDING; \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/ensureBlock.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/ensureBlock.js new file mode 100644 index 00000000000000..da69103d9ef20b --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/ensureBlock.js @@ -0,0 +1,16 @@ +"use strict"; + +exports.__esModule = true; +exports.default = ensureBlock; + +var _toBlock = _interopRequireDefault(require("./toBlock")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function ensureBlock(node, key) { + if (key === void 0) { + key = "body"; + } + + return node[key] = (0, _toBlock.default)(node[key], node); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/gatherSequenceExpressions.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/gatherSequenceExpressions.js new file mode 100644 index 00000000000000..0e07cbe18f0e3e --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/gatherSequenceExpressions.js @@ -0,0 +1,83 @@ +"use strict"; + +exports.__esModule = true; +exports.default = gatherSequenceExpressions; + +var _getBindingIdentifiers = _interopRequireDefault(require("../retrievers/getBindingIdentifiers")); + +var _generated = require("../validators/generated"); + +var _generated2 = require("../builders/generated"); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +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 ((0, _generated.isExpression)(_node)) { + exprs.push(_node); + } else if ((0, _generated.isExpressionStatement)(_node)) { + exprs.push(_node.expression); + } else if ((0, _generated.isVariableDeclaration)(_node)) { + if (_node.kind !== "var") return; + var _arr = _node.declarations; + + for (var _i2 = 0; _i2 < _arr.length; _i2++) { + var declar = _arr[_i2]; + var bindings = (0, _getBindingIdentifiers.default)(declar); + + for (var key in bindings) { + declars.push({ + kind: _node.kind, + id: bindings[key] + }); + } + + if (declar.init) { + exprs.push((0, _generated2.assignmentExpression)("=", declar.id, declar.init)); + } + } + + ensureLastUndefined = true; + } else if ((0, _generated.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((0, _generated2.conditionalExpression)(_node.test, consequent, alternate)); + } else if ((0, _generated.isBlockStatement)(_node)) { + var body = gatherSequenceExpressions(_node.body, scope, declars); + if (!body) return; + exprs.push(body); + } else if ((0, _generated.isEmptyStatement)(_node)) { + ensureLastUndefined = true; + } else { + return; + } + } + + if (ensureLastUndefined) { + exprs.push(scope.buildUndefinedNode()); + } + + if (exprs.length === 1) { + return exprs[0]; + } else { + return (0, _generated2.sequenceExpression)(exprs); + } +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toBindingIdentifierName.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toBindingIdentifierName.js new file mode 100644 index 00000000000000..3bda98aa834e10 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toBindingIdentifierName.js @@ -0,0 +1,14 @@ +"use strict"; + +exports.__esModule = true; +exports.default = toBindingIdentifierName; + +var _toIdentifier = _interopRequireDefault(require("./toIdentifier")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function toBindingIdentifierName(name) { + name = (0, _toIdentifier.default)(name); + if (name === "eval" || name === "arguments") name = "_" + name; + return name; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toBlock.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toBlock.js new file mode 100644 index 00000000000000..542ff552103516 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toBlock.js @@ -0,0 +1,32 @@ +"use strict"; + +exports.__esModule = true; +exports.default = toBlock; + +var _generated = require("../validators/generated"); + +var _generated2 = require("../builders/generated"); + +function toBlock(node, parent) { + if ((0, _generated.isBlockStatement)(node)) { + return node; + } + + var blockNodes = []; + + if ((0, _generated.isEmptyStatement)(node)) { + blockNodes = []; + } else { + if (!(0, _generated.isStatement)(node)) { + if ((0, _generated.isFunction)(parent)) { + node = (0, _generated2.returnStatement)(node); + } else { + node = (0, _generated2.expressionStatement)(node); + } + } + + blockNodes = [node]; + } + + return (0, _generated2.blockStatement)(blockNodes); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toComputedKey.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toComputedKey.js new file mode 100644 index 00000000000000..71bd8e4a6628cb --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toComputedKey.js @@ -0,0 +1,17 @@ +"use strict"; + +exports.__esModule = true; +exports.default = toComputedKey; + +var _generated = require("../validators/generated"); + +var _generated2 = require("../builders/generated"); + +function toComputedKey(node, key) { + if (key === void 0) { + key = node.key || node.property; + } + + if (!node.computed && (0, _generated.isIdentifier)(key)) key = (0, _generated2.stringLiteral)(key.name); + return key; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toExpression.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toExpression.js new file mode 100644 index 00000000000000..dfb5bb87b84743 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toExpression.js @@ -0,0 +1,28 @@ +"use strict"; + +exports.__esModule = true; +exports.default = toExpression; + +var _generated = require("../validators/generated"); + +function toExpression(node) { + if ((0, _generated.isExpressionStatement)(node)) { + node = node.expression; + } + + if ((0, _generated.isExpression)(node)) { + return node; + } + + if ((0, _generated.isClass)(node)) { + node.type = "ClassExpression"; + } else if ((0, _generated.isFunction)(node)) { + node.type = "FunctionExpression"; + } + + if (!(0, _generated.isExpression)(node)) { + throw new Error("cannot turn " + node.type + " to an expression"); + } + + return node; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toIdentifier.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toIdentifier.js new file mode 100644 index 00000000000000..d929872af5e553 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toIdentifier.js @@ -0,0 +1,23 @@ +"use strict"; + +exports.__esModule = true; +exports.default = toIdentifier; + +var _isValidIdentifier = _interopRequireDefault(require("../validators/isValidIdentifier")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +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 (!(0, _isValidIdentifier.default)(name)) { + name = "_" + name; + } + + return name || "_"; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toKeyAlias.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toKeyAlias.js new file mode 100644 index 00000000000000..88aa30ed979b77 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toKeyAlias.js @@ -0,0 +1,50 @@ +"use strict"; + +exports.__esModule = true; +exports.default = toKeyAlias; + +var _generated = require("../validators/generated"); + +var _cloneDeep = _interopRequireDefault(require("../clone/cloneDeep")); + +var _removePropertiesDeep = _interopRequireDefault(require("../modifications/removePropertiesDeep")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function toKeyAlias(node, key) { + if (key === void 0) { + key = node.key; + } + + var alias; + + if (node.kind === "method") { + return toKeyAlias.increment() + ""; + } else if ((0, _generated.isIdentifier)(key)) { + alias = key.name; + } else if ((0, _generated.isStringLiteral)(key)) { + alias = JSON.stringify(key.value); + } else { + alias = JSON.stringify((0, _removePropertiesDeep.default)((0, _cloneDeep.default)(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++; + } +}; \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toSequenceExpression.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toSequenceExpression.js new file mode 100644 index 00000000000000..c5488ef9d5526f --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toSequenceExpression.js @@ -0,0 +1,22 @@ +"use strict"; + +exports.__esModule = true; +exports.default = toSequenceExpression; + +var _gatherSequenceExpressions = _interopRequireDefault(require("./gatherSequenceExpressions")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function toSequenceExpression(nodes, scope) { + if (!nodes || !nodes.length) return; + var declars = []; + var result = (0, _gatherSequenceExpressions.default)(nodes, scope, declars); + if (!result) return; + + for (var _i = 0; _i < declars.length; _i++) { + var declar = declars[_i]; + scope.push(declar); + } + + return result; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toStatement.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toStatement.js new file mode 100644 index 00000000000000..8fa5a97e20d9cc --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/toStatement.js @@ -0,0 +1,42 @@ +"use strict"; + +exports.__esModule = true; +exports.default = toStatement; + +var _generated = require("../validators/generated"); + +var _generated2 = require("../builders/generated"); + +function toStatement(node, ignore) { + if ((0, _generated.isStatement)(node)) { + return node; + } + + var mustHaveId = false; + var newType; + + if ((0, _generated.isClass)(node)) { + mustHaveId = true; + newType = "ClassDeclaration"; + } else if ((0, _generated.isFunction)(node)) { + mustHaveId = true; + newType = "FunctionDeclaration"; + } else if ((0, _generated.isAssignmentExpression)(node)) { + return (0, _generated2.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; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/valueToNode.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/valueToNode.js new file mode 100644 index 00000000000000..d8f82ffd05e606 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/converters/valueToNode.js @@ -0,0 +1,66 @@ +"use strict"; + +exports.__esModule = true; +exports.default = valueToNode; + +var _isPlainObject = _interopRequireDefault(require("lodash/isPlainObject")); + +var _isRegExp = _interopRequireDefault(require("lodash/isRegExp")); + +var _isValidIdentifier = _interopRequireDefault(require("../validators/isValidIdentifier")); + +var _generated = require("../builders/generated"); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function valueToNode(value) { + if (value === undefined) { + return (0, _generated.identifier)("undefined"); + } + + if (value === true || value === false) { + return (0, _generated.booleanLiteral)(value); + } + + if (value === null) { + return (0, _generated.nullLiteral)(); + } + + if (typeof value === "string") { + return (0, _generated.stringLiteral)(value); + } + + if (typeof value === "number") { + return (0, _generated.numericLiteral)(value); + } + + if ((0, _isRegExp.default)(value)) { + var pattern = value.source; + var flags = value.toString().match(/\/([a-z]+|)$/)[1]; + return (0, _generated.regExpLiteral)(pattern, flags); + } + + if (Array.isArray(value)) { + return (0, _generated.arrayExpression)(value.map(valueToNode)); + } + + if ((0, _isPlainObject.default)(value)) { + var props = []; + + for (var key in value) { + var nodeKey = void 0; + + if ((0, _isValidIdentifier.default)(key)) { + nodeKey = (0, _generated.identifier)(key); + } else { + nodeKey = (0, _generated.stringLiteral)(key); + } + + props.push((0, _generated.objectProperty)(nodeKey, valueToNode(value[key]))); + } + + return (0, _generated.objectExpression)(props); + } + + throw new Error("don't know how to turn this value into a node"); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/core.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/core.js new file mode 100644 index 00000000000000..d8abe51f151946 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/core.js @@ -0,0 +1,693 @@ +"use strict"; + +exports.__esModule = true; +exports.patternLikeCommon = exports.functionDeclarationCommon = exports.functionTypeAnnotationCommon = exports.functionCommon = void 0; + +var _isValidIdentifier = _interopRequireDefault(require("../validators/isValidIdentifier")); + +var _constants = require("../constants"); + +var _utils = _interopRequireWildcard(require("./utils")); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +(0, _utils.default)("ArrayExpression", { + fields: { + elements: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeOrValueType)("null", "Expression", "SpreadElement"))), + default: [] + } + }, + visitor: ["elements"], + aliases: ["Expression"] +}); +(0, _utils.default)("AssignmentExpression", { + fields: { + operator: { + validate: (0, _utils.assertValueType)("string") + }, + left: { + validate: (0, _utils.assertNodeType)("LVal") + }, + right: { + validate: (0, _utils.assertNodeType)("Expression") + } + }, + builder: ["operator", "left", "right"], + visitor: ["left", "right"], + aliases: ["Expression"] +}); +(0, _utils.default)("BinaryExpression", { + builder: ["operator", "left", "right"], + fields: { + operator: { + validate: _utils.assertOneOf.apply(void 0, _constants.BINARY_OPERATORS) + }, + left: { + validate: (0, _utils.assertNodeType)("Expression") + }, + right: { + validate: (0, _utils.assertNodeType)("Expression") + } + }, + visitor: ["left", "right"], + aliases: ["Binary", "Expression"] +}); +(0, _utils.default)("Directive", { + visitor: ["value"], + fields: { + value: { + validate: (0, _utils.assertNodeType)("DirectiveLiteral") + } + } +}); +(0, _utils.default)("DirectiveLiteral", { + builder: ["value"], + fields: { + value: { + validate: (0, _utils.assertValueType)("string") + } + } +}); +(0, _utils.default)("BlockStatement", { + builder: ["body", "directives"], + visitor: ["directives", "body"], + fields: { + directives: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("Directive"))), + default: [] + }, + body: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("Statement"))) + } + }, + aliases: ["Scopable", "BlockParent", "Block", "Statement"] +}); +(0, _utils.default)("BreakStatement", { + visitor: ["label"], + fields: { + label: { + validate: (0, _utils.assertNodeType)("Identifier"), + optional: true + } + }, + aliases: ["Statement", "Terminatorless", "CompletionStatement"] +}); +(0, _utils.default)("CallExpression", { + visitor: ["callee", "arguments", "typeParameters"], + builder: ["callee", "arguments"], + aliases: ["Expression"], + fields: { + callee: { + validate: (0, _utils.assertNodeType)("Expression") + }, + arguments: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("Expression", "SpreadElement", "JSXNamespacedName"))) + }, + optional: { + validate: (0, _utils.assertOneOf)(true, false), + optional: true + }, + typeParameters: { + validate: (0, _utils.assertNodeType)("TypeParameterInstantiation", "TSTypeParameterInstantiation"), + optional: true + } + } +}); +(0, _utils.default)("CatchClause", { + visitor: ["param", "body"], + fields: { + param: { + validate: (0, _utils.assertNodeType)("Identifier"), + optional: true + }, + body: { + validate: (0, _utils.assertNodeType)("BlockStatement") + } + }, + aliases: ["Scopable", "BlockParent"] +}); +(0, _utils.default)("ConditionalExpression", { + visitor: ["test", "consequent", "alternate"], + fields: { + test: { + validate: (0, _utils.assertNodeType)("Expression") + }, + consequent: { + validate: (0, _utils.assertNodeType)("Expression") + }, + alternate: { + validate: (0, _utils.assertNodeType)("Expression") + } + }, + aliases: ["Expression", "Conditional"] +}); +(0, _utils.default)("ContinueStatement", { + visitor: ["label"], + fields: { + label: { + validate: (0, _utils.assertNodeType)("Identifier"), + optional: true + } + }, + aliases: ["Statement", "Terminatorless", "CompletionStatement"] +}); +(0, _utils.default)("DebuggerStatement", { + aliases: ["Statement"] +}); +(0, _utils.default)("DoWhileStatement", { + visitor: ["test", "body"], + fields: { + test: { + validate: (0, _utils.assertNodeType)("Expression") + }, + body: { + validate: (0, _utils.assertNodeType)("Statement") + } + }, + aliases: ["Statement", "BlockParent", "Loop", "While", "Scopable"] +}); +(0, _utils.default)("EmptyStatement", { + aliases: ["Statement"] +}); +(0, _utils.default)("ExpressionStatement", { + visitor: ["expression"], + fields: { + expression: { + validate: (0, _utils.assertNodeType)("Expression") + } + }, + aliases: ["Statement", "ExpressionWrapper"] +}); +(0, _utils.default)("File", { + builder: ["program", "comments", "tokens"], + visitor: ["program"], + fields: { + program: { + validate: (0, _utils.assertNodeType)("Program") + } + } +}); +(0, _utils.default)("ForInStatement", { + visitor: ["left", "right", "body"], + aliases: ["Scopable", "Statement", "For", "BlockParent", "Loop", "ForXStatement"], + fields: { + left: { + validate: (0, _utils.assertNodeType)("VariableDeclaration", "LVal") + }, + right: { + validate: (0, _utils.assertNodeType)("Expression") + }, + body: { + validate: (0, _utils.assertNodeType)("Statement") + } + } +}); +(0, _utils.default)("ForStatement", { + visitor: ["init", "test", "update", "body"], + aliases: ["Scopable", "Statement", "For", "BlockParent", "Loop"], + fields: { + init: { + validate: (0, _utils.assertNodeType)("VariableDeclaration", "Expression"), + optional: true + }, + test: { + validate: (0, _utils.assertNodeType)("Expression"), + optional: true + }, + update: { + validate: (0, _utils.assertNodeType)("Expression"), + optional: true + }, + body: { + validate: (0, _utils.assertNodeType)("Statement") + } + } +}); +var functionCommon = { + params: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("LVal"))) + }, + generator: { + default: false, + validate: (0, _utils.assertValueType)("boolean") + }, + async: { + validate: (0, _utils.assertValueType)("boolean"), + default: false + } +}; +exports.functionCommon = functionCommon; +var functionTypeAnnotationCommon = { + returnType: { + validate: (0, _utils.assertNodeType)("TypeAnnotation", "TSTypeAnnotation", "Noop"), + optional: true + }, + typeParameters: { + validate: (0, _utils.assertNodeType)("TypeParameterDeclaration", "TSTypeParameterDeclaration", "Noop"), + optional: true + } +}; +exports.functionTypeAnnotationCommon = functionTypeAnnotationCommon; +var functionDeclarationCommon = Object.assign({}, functionCommon, { + declare: { + validate: (0, _utils.assertValueType)("boolean"), + optional: true + }, + id: { + validate: (0, _utils.assertNodeType)("Identifier"), + optional: true + } +}); +exports.functionDeclarationCommon = functionDeclarationCommon; +(0, _utils.default)("FunctionDeclaration", { + builder: ["id", "params", "body", "generator", "async"], + visitor: ["id", "params", "body", "returnType", "typeParameters"], + fields: Object.assign({}, functionDeclarationCommon, functionTypeAnnotationCommon, { + body: { + validate: (0, _utils.assertNodeType)("BlockStatement") + } + }), + aliases: ["Scopable", "Function", "BlockParent", "FunctionParent", "Statement", "Pureish", "Declaration"] +}); +(0, _utils.default)("FunctionExpression", { + inherits: "FunctionDeclaration", + aliases: ["Scopable", "Function", "BlockParent", "FunctionParent", "Expression", "Pureish"], + fields: Object.assign({}, functionCommon, functionTypeAnnotationCommon, { + id: { + validate: (0, _utils.assertNodeType)("Identifier"), + optional: true + }, + body: { + validate: (0, _utils.assertNodeType)("BlockStatement") + } + }) +}); +var patternLikeCommon = { + typeAnnotation: { + validate: (0, _utils.assertNodeType)("TypeAnnotation", "TSTypeAnnotation", "Noop"), + optional: true + }, + decorators: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("Decorator"))) + } +}; +exports.patternLikeCommon = patternLikeCommon; +(0, _utils.default)("Identifier", { + builder: ["name"], + visitor: ["typeAnnotation"], + aliases: ["Expression", "PatternLike", "LVal", "TSEntityName"], + fields: Object.assign({}, patternLikeCommon, { + name: { + validate: function validate(node, key, val) { + if (!(0, _isValidIdentifier.default)(val)) {} + } + }, + optional: { + validate: (0, _utils.assertValueType)("boolean"), + optional: true + } + }) +}); +(0, _utils.default)("IfStatement", { + visitor: ["test", "consequent", "alternate"], + aliases: ["Statement", "Conditional"], + fields: { + test: { + validate: (0, _utils.assertNodeType)("Expression") + }, + consequent: { + validate: (0, _utils.assertNodeType)("Statement") + }, + alternate: { + optional: true, + validate: (0, _utils.assertNodeType)("Statement") + } + } +}); +(0, _utils.default)("LabeledStatement", { + visitor: ["label", "body"], + aliases: ["Statement"], + fields: { + label: { + validate: (0, _utils.assertNodeType)("Identifier") + }, + body: { + validate: (0, _utils.assertNodeType)("Statement") + } + } +}); +(0, _utils.default)("StringLiteral", { + builder: ["value"], + fields: { + value: { + validate: (0, _utils.assertValueType)("string") + } + }, + aliases: ["Expression", "Pureish", "Literal", "Immutable"] +}); +(0, _utils.default)("NumericLiteral", { + builder: ["value"], + deprecatedAlias: "NumberLiteral", + fields: { + value: { + validate: (0, _utils.assertValueType)("number") + } + }, + aliases: ["Expression", "Pureish", "Literal", "Immutable"] +}); +(0, _utils.default)("NullLiteral", { + aliases: ["Expression", "Pureish", "Literal", "Immutable"] +}); +(0, _utils.default)("BooleanLiteral", { + builder: ["value"], + fields: { + value: { + validate: (0, _utils.assertValueType)("boolean") + } + }, + aliases: ["Expression", "Pureish", "Literal", "Immutable"] +}); +(0, _utils.default)("RegExpLiteral", { + builder: ["pattern", "flags"], + deprecatedAlias: "RegexLiteral", + aliases: ["Expression", "Literal"], + fields: { + pattern: { + validate: (0, _utils.assertValueType)("string") + }, + flags: { + validate: (0, _utils.assertValueType)("string"), + default: "" + } + } +}); +(0, _utils.default)("LogicalExpression", { + builder: ["operator", "left", "right"], + visitor: ["left", "right"], + aliases: ["Binary", "Expression"], + fields: { + operator: { + validate: _utils.assertOneOf.apply(void 0, _constants.LOGICAL_OPERATORS) + }, + left: { + validate: (0, _utils.assertNodeType)("Expression") + }, + right: { + validate: (0, _utils.assertNodeType)("Expression") + } + } +}); +(0, _utils.default)("MemberExpression", { + builder: ["object", "property", "computed", "optional"], + visitor: ["object", "property"], + aliases: ["Expression", "LVal"], + fields: { + object: { + validate: (0, _utils.assertNodeType)("Expression") + }, + property: { + validate: function () { + var normal = (0, _utils.assertNodeType)("Identifier"); + var computed = (0, _utils.assertNodeType)("Expression"); + return function (node, key, val) { + var validator = node.computed ? computed : normal; + validator(node, key, val); + }; + }() + }, + computed: { + default: false + }, + optional: { + validate: (0, _utils.assertOneOf)(true, false), + optional: true + } + } +}); +(0, _utils.default)("NewExpression", { + inherits: "CallExpression" +}); +(0, _utils.default)("Program", { + visitor: ["directives", "body"], + builder: ["body", "directives", "sourceType"], + fields: { + sourceFile: { + validate: (0, _utils.assertValueType)("string") + }, + sourceType: { + validate: (0, _utils.assertOneOf)("script", "module"), + default: "script" + }, + directives: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("Directive"))), + default: [] + }, + body: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("Statement"))) + } + }, + aliases: ["Scopable", "BlockParent", "Block"] +}); +(0, _utils.default)("ObjectExpression", { + visitor: ["properties"], + aliases: ["Expression"], + fields: { + properties: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("ObjectMethod", "ObjectProperty", "SpreadElement"))) + } + } +}); +(0, _utils.default)("ObjectMethod", { + builder: ["kind", "key", "params", "body", "computed"], + fields: Object.assign({}, functionCommon, functionTypeAnnotationCommon, { + kind: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("string"), (0, _utils.assertOneOf)("method", "get", "set")), + default: "method" + }, + computed: { + validate: (0, _utils.assertValueType)("boolean"), + default: false + }, + key: { + validate: function () { + var normal = (0, _utils.assertNodeType)("Identifier", "StringLiteral", "NumericLiteral"); + var computed = (0, _utils.assertNodeType)("Expression"); + return function (node, key, val) { + var validator = node.computed ? computed : normal; + validator(node, key, val); + }; + }() + }, + decorators: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("Decorator"))) + }, + body: { + validate: (0, _utils.assertNodeType)("BlockStatement") + } + }), + visitor: ["key", "params", "body", "decorators", "returnType", "typeParameters"], + aliases: ["UserWhitespacable", "Function", "Scopable", "BlockParent", "FunctionParent", "Method", "ObjectMember"] +}); +(0, _utils.default)("ObjectProperty", { + builder: ["key", "value", "computed", "shorthand", "decorators"], + fields: { + computed: { + validate: (0, _utils.assertValueType)("boolean"), + default: false + }, + key: { + validate: function () { + var normal = (0, _utils.assertNodeType)("Identifier", "StringLiteral", "NumericLiteral"); + var computed = (0, _utils.assertNodeType)("Expression"); + return function (node, key, val) { + var validator = node.computed ? computed : normal; + validator(node, key, val); + }; + }() + }, + value: { + validate: (0, _utils.assertNodeType)("Expression", "PatternLike") + }, + shorthand: { + validate: (0, _utils.assertValueType)("boolean"), + default: false + }, + decorators: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("Decorator"))), + optional: true + } + }, + visitor: ["key", "value", "decorators"], + aliases: ["UserWhitespacable", "Property", "ObjectMember"] +}); +(0, _utils.default)("RestElement", { + visitor: ["argument", "typeAnnotation"], + builder: ["argument"], + aliases: ["LVal", "PatternLike"], + deprecatedAlias: "RestProperty", + fields: Object.assign({}, patternLikeCommon, { + argument: { + validate: (0, _utils.assertNodeType)("LVal") + } + }) +}); +(0, _utils.default)("ReturnStatement", { + visitor: ["argument"], + aliases: ["Statement", "Terminatorless", "CompletionStatement"], + fields: { + argument: { + validate: (0, _utils.assertNodeType)("Expression"), + optional: true + } + } +}); +(0, _utils.default)("SequenceExpression", { + visitor: ["expressions"], + fields: { + expressions: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("Expression"))) + } + }, + aliases: ["Expression"] +}); +(0, _utils.default)("SwitchCase", { + visitor: ["test", "consequent"], + fields: { + test: { + validate: (0, _utils.assertNodeType)("Expression"), + optional: true + }, + consequent: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("Statement"))) + } + } +}); +(0, _utils.default)("SwitchStatement", { + visitor: ["discriminant", "cases"], + aliases: ["Statement", "BlockParent", "Scopable"], + fields: { + discriminant: { + validate: (0, _utils.assertNodeType)("Expression") + }, + cases: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("SwitchCase"))) + } + } +}); +(0, _utils.default)("ThisExpression", { + aliases: ["Expression"] +}); +(0, _utils.default)("ThrowStatement", { + visitor: ["argument"], + aliases: ["Statement", "Terminatorless", "CompletionStatement"], + fields: { + argument: { + validate: (0, _utils.assertNodeType)("Expression") + } + } +}); +(0, _utils.default)("TryStatement", { + visitor: ["block", "handler", "finalizer"], + aliases: ["Statement"], + fields: { + block: { + validate: (0, _utils.assertNodeType)("BlockStatement") + }, + handler: { + optional: true, + validate: (0, _utils.assertNodeType)("CatchClause") + }, + finalizer: { + optional: true, + validate: (0, _utils.assertNodeType)("BlockStatement") + } + } +}); +(0, _utils.default)("UnaryExpression", { + builder: ["operator", "argument", "prefix"], + fields: { + prefix: { + default: true + }, + argument: { + validate: (0, _utils.assertNodeType)("Expression") + }, + operator: { + validate: _utils.assertOneOf.apply(void 0, _constants.UNARY_OPERATORS) + } + }, + visitor: ["argument"], + aliases: ["UnaryLike", "Expression"] +}); +(0, _utils.default)("UpdateExpression", { + builder: ["operator", "argument", "prefix"], + fields: { + prefix: { + default: false + }, + argument: { + validate: (0, _utils.assertNodeType)("Expression") + }, + operator: { + validate: _utils.assertOneOf.apply(void 0, _constants.UPDATE_OPERATORS) + } + }, + visitor: ["argument"], + aliases: ["Expression"] +}); +(0, _utils.default)("VariableDeclaration", { + builder: ["kind", "declarations"], + visitor: ["declarations"], + aliases: ["Statement", "Declaration"], + fields: { + declare: { + validate: (0, _utils.assertValueType)("boolean"), + optional: true + }, + kind: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("string"), (0, _utils.assertOneOf)("var", "let", "const")) + }, + declarations: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("VariableDeclarator"))) + } + } +}); +(0, _utils.default)("VariableDeclarator", { + visitor: ["id", "init"], + fields: { + id: { + validate: (0, _utils.assertNodeType)("LVal") + }, + init: { + optional: true, + validate: (0, _utils.assertNodeType)("Expression") + } + } +}); +(0, _utils.default)("WhileStatement", { + visitor: ["test", "body"], + aliases: ["Statement", "BlockParent", "Loop", "While", "Scopable"], + fields: { + test: { + validate: (0, _utils.assertNodeType)("Expression") + }, + body: { + validate: (0, _utils.assertNodeType)("BlockStatement", "Statement") + } + } +}); +(0, _utils.default)("WithStatement", { + visitor: ["object", "body"], + aliases: ["Statement"], + fields: { + object: { + validate: (0, _utils.assertNodeType)("Expression") + }, + body: { + validate: (0, _utils.assertNodeType)("BlockStatement", "Statement") + } + } +}); \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/es2015.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/es2015.js new file mode 100644 index 00000000000000..62e2b4b0c27848 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/es2015.js @@ -0,0 +1,379 @@ +"use strict"; + +exports.__esModule = true; +exports.classMethodOrDeclareMethodCommon = exports.classMethodOrPropertyCommon = void 0; + +var _utils = _interopRequireWildcard(require("./utils")); + +var _core = require("./core"); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +(0, _utils.default)("AssignmentPattern", { + visitor: ["left", "right"], + builder: ["left", "right"], + aliases: ["Pattern", "PatternLike", "LVal"], + fields: Object.assign({}, _core.patternLikeCommon, { + left: { + validate: (0, _utils.assertNodeType)("Identifier", "ObjectPattern", "ArrayPattern") + }, + right: { + validate: (0, _utils.assertNodeType)("Expression") + }, + decorators: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("Decorator"))) + } + }) +}); +(0, _utils.default)("ArrayPattern", { + visitor: ["elements", "typeAnnotation"], + builder: ["elements"], + aliases: ["Pattern", "PatternLike", "LVal"], + fields: Object.assign({}, _core.patternLikeCommon, { + elements: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("PatternLike"))) + }, + decorators: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("Decorator"))) + } + }) +}); +(0, _utils.default)("ArrowFunctionExpression", { + builder: ["params", "body", "async"], + visitor: ["params", "body", "returnType", "typeParameters"], + aliases: ["Scopable", "Function", "BlockParent", "FunctionParent", "Expression", "Pureish"], + fields: Object.assign({}, _core.functionCommon, _core.functionTypeAnnotationCommon, { + expression: { + validate: (0, _utils.assertValueType)("boolean") + }, + body: { + validate: (0, _utils.assertNodeType)("BlockStatement", "Expression") + } + }) +}); +(0, _utils.default)("ClassBody", { + visitor: ["body"], + fields: { + body: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("ClassMethod", "ClassProperty", "TSDeclareMethod", "TSIndexSignature"))) + } + } +}); +var classCommon = { + typeParameters: { + validate: (0, _utils.assertNodeType)("TypeParameterDeclaration", "TSTypeParameterDeclaration", "Noop"), + optional: true + }, + body: { + validate: (0, _utils.assertNodeType)("ClassBody") + }, + superClass: { + optional: true, + validate: (0, _utils.assertNodeType)("Expression") + }, + superTypeParameters: { + validate: (0, _utils.assertNodeType)("TypeParameterInstantiation", "TSTypeParameterInstantiation"), + optional: true + }, + implements: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("TSExpressionWithTypeArguments", "FlowClassImplements"))), + optional: true + } +}; +(0, _utils.default)("ClassDeclaration", { + builder: ["id", "superClass", "body", "decorators"], + visitor: ["id", "body", "superClass", "mixins", "typeParameters", "superTypeParameters", "implements", "decorators"], + aliases: ["Scopable", "Class", "Statement", "Declaration", "Pureish"], + fields: Object.assign({}, classCommon, { + declare: { + validate: (0, _utils.assertValueType)("boolean"), + optional: true + }, + abstract: { + validate: (0, _utils.assertValueType)("boolean"), + optional: true + }, + id: { + validate: (0, _utils.assertNodeType)("Identifier"), + optional: true + }, + decorators: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("Decorator"))), + optional: true + } + }) +}); +(0, _utils.default)("ClassExpression", { + inherits: "ClassDeclaration", + aliases: ["Scopable", "Class", "Expression", "Pureish"], + fields: Object.assign({}, classCommon, { + id: { + optional: true, + validate: (0, _utils.assertNodeType)("Identifier") + }, + body: { + validate: (0, _utils.assertNodeType)("ClassBody") + }, + superClass: { + optional: true, + validate: (0, _utils.assertNodeType)("Expression") + }, + decorators: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("Decorator"))), + optional: true + } + }) +}); +(0, _utils.default)("ExportAllDeclaration", { + visitor: ["source"], + aliases: ["Statement", "Declaration", "ModuleDeclaration", "ExportDeclaration"], + fields: { + source: { + validate: (0, _utils.assertNodeType)("StringLiteral") + } + } +}); +(0, _utils.default)("ExportDefaultDeclaration", { + visitor: ["declaration"], + aliases: ["Statement", "Declaration", "ModuleDeclaration", "ExportDeclaration"], + fields: { + declaration: { + validate: (0, _utils.assertNodeType)("FunctionDeclaration", "TSDeclareFunction", "ClassDeclaration", "Expression") + } + } +}); +(0, _utils.default)("ExportNamedDeclaration", { + visitor: ["declaration", "specifiers", "source"], + aliases: ["Statement", "Declaration", "ModuleDeclaration", "ExportDeclaration"], + fields: { + declaration: { + validate: (0, _utils.assertNodeType)("Declaration"), + optional: true + }, + specifiers: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("ExportSpecifier", "ExportDefaultSpecifier", "ExportNamespaceSpecifier"))) + }, + source: { + validate: (0, _utils.assertNodeType)("StringLiteral"), + optional: true + } + } +}); +(0, _utils.default)("ExportSpecifier", { + visitor: ["local", "exported"], + aliases: ["ModuleSpecifier"], + fields: { + local: { + validate: (0, _utils.assertNodeType)("Identifier") + }, + exported: { + validate: (0, _utils.assertNodeType)("Identifier") + } + } +}); +(0, _utils.default)("ForOfStatement", { + visitor: ["left", "right", "body"], + aliases: ["Scopable", "Statement", "For", "BlockParent", "Loop", "ForXStatement"], + fields: { + left: { + validate: (0, _utils.assertNodeType)("VariableDeclaration", "LVal") + }, + right: { + validate: (0, _utils.assertNodeType)("Expression") + }, + body: { + validate: (0, _utils.assertNodeType)("Statement") + }, + await: { + default: false, + validate: (0, _utils.assertValueType)("boolean") + } + } +}); +(0, _utils.default)("ImportDeclaration", { + visitor: ["specifiers", "source"], + aliases: ["Statement", "Declaration", "ModuleDeclaration"], + fields: { + specifiers: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("ImportSpecifier", "ImportDefaultSpecifier", "ImportNamespaceSpecifier"))) + }, + source: { + validate: (0, _utils.assertNodeType)("StringLiteral") + } + } +}); +(0, _utils.default)("ImportDefaultSpecifier", { + visitor: ["local"], + aliases: ["ModuleSpecifier"], + fields: { + local: { + validate: (0, _utils.assertNodeType)("Identifier") + } + } +}); +(0, _utils.default)("ImportNamespaceSpecifier", { + visitor: ["local"], + aliases: ["ModuleSpecifier"], + fields: { + local: { + validate: (0, _utils.assertNodeType)("Identifier") + } + } +}); +(0, _utils.default)("ImportSpecifier", { + visitor: ["local", "imported"], + aliases: ["ModuleSpecifier"], + fields: { + local: { + validate: (0, _utils.assertNodeType)("Identifier") + }, + imported: { + validate: (0, _utils.assertNodeType)("Identifier") + }, + importKind: { + validate: (0, _utils.assertOneOf)(null, "type", "typeof") + } + } +}); +(0, _utils.default)("MetaProperty", { + visitor: ["meta", "property"], + aliases: ["Expression"], + fields: { + meta: { + validate: (0, _utils.assertNodeType)("Identifier") + }, + property: { + validate: (0, _utils.assertNodeType)("Identifier") + } + } +}); +var classMethodOrPropertyCommon = { + abstract: { + validate: (0, _utils.assertValueType)("boolean"), + optional: true + }, + accessibility: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("string"), (0, _utils.assertOneOf)("public", "private", "protected")), + optional: true + }, + static: { + validate: (0, _utils.assertValueType)("boolean"), + optional: true + }, + computed: { + default: false, + validate: (0, _utils.assertValueType)("boolean") + }, + optional: { + validate: (0, _utils.assertValueType)("boolean"), + optional: true + }, + key: { + validate: function () { + var normal = (0, _utils.assertNodeType)("Identifier", "StringLiteral", "NumericLiteral"); + var computed = (0, _utils.assertNodeType)("Expression"); + return function (node, key, val) { + var validator = node.computed ? computed : normal; + validator(node, key, val); + }; + }() + } +}; +exports.classMethodOrPropertyCommon = classMethodOrPropertyCommon; +var classMethodOrDeclareMethodCommon = Object.assign({}, _core.functionCommon, classMethodOrPropertyCommon, { + kind: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("string"), (0, _utils.assertOneOf)("get", "set", "method", "constructor")), + default: "method" + }, + access: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("string"), (0, _utils.assertOneOf)("public", "private", "protected")), + optional: true + }, + decorators: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("Decorator"))), + optional: true + } +}); +exports.classMethodOrDeclareMethodCommon = classMethodOrDeclareMethodCommon; +(0, _utils.default)("ClassMethod", { + aliases: ["Function", "Scopable", "BlockParent", "FunctionParent", "Method"], + builder: ["kind", "key", "params", "body", "computed", "static"], + visitor: ["key", "params", "body", "decorators", "returnType", "typeParameters"], + fields: Object.assign({}, classMethodOrDeclareMethodCommon, _core.functionTypeAnnotationCommon, { + body: { + validate: (0, _utils.assertNodeType)("BlockStatement") + } + }) +}); +(0, _utils.default)("ObjectPattern", { + visitor: ["properties", "typeAnnotation"], + builder: ["properties"], + aliases: ["Pattern", "PatternLike", "LVal"], + fields: Object.assign({}, _core.patternLikeCommon, { + properties: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("RestElement", "ObjectProperty"))) + } + }) +}); +(0, _utils.default)("SpreadElement", { + visitor: ["argument"], + aliases: ["UnaryLike"], + deprecatedAlias: "SpreadProperty", + fields: { + argument: { + validate: (0, _utils.assertNodeType)("Expression") + } + } +}); +(0, _utils.default)("Super", { + aliases: ["Expression"] +}); +(0, _utils.default)("TaggedTemplateExpression", { + visitor: ["tag", "quasi"], + aliases: ["Expression"], + fields: { + tag: { + validate: (0, _utils.assertNodeType)("Expression") + }, + quasi: { + validate: (0, _utils.assertNodeType)("TemplateLiteral") + } + } +}); +(0, _utils.default)("TemplateElement", { + builder: ["value", "tail"], + fields: { + value: {}, + tail: { + validate: (0, _utils.assertValueType)("boolean"), + default: false + } + } +}); +(0, _utils.default)("TemplateLiteral", { + visitor: ["quasis", "expressions"], + aliases: ["Expression", "Literal"], + fields: { + quasis: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("TemplateElement"))) + }, + expressions: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("Expression"))) + } + } +}); +(0, _utils.default)("YieldExpression", { + builder: ["argument", "delegate"], + visitor: ["argument"], + aliases: ["Expression", "Terminatorless"], + fields: { + delegate: { + validate: (0, _utils.assertValueType)("boolean"), + default: false + }, + argument: { + optional: true, + validate: (0, _utils.assertNodeType)("Expression") + } + } +}); \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/experimental.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/experimental.js new file mode 100644 index 00000000000000..968f3009d868b9 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/experimental.js @@ -0,0 +1,84 @@ +"use strict"; + +var _utils = _interopRequireWildcard(require("./utils")); + +var _es = require("./es2015"); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +(0, _utils.default)("AwaitExpression", { + builder: ["argument"], + visitor: ["argument"], + aliases: ["Expression", "Terminatorless"], + fields: { + argument: { + validate: (0, _utils.assertNodeType)("Expression") + } + } +}); +(0, _utils.default)("BindExpression", { + visitor: ["object", "callee"], + aliases: ["Expression"], + fields: {} +}); +(0, _utils.default)("ClassProperty", { + visitor: ["key", "value", "typeAnnotation", "decorators"], + builder: ["key", "value", "typeAnnotation", "decorators", "computed"], + aliases: ["Property"], + fields: Object.assign({}, _es.classMethodOrPropertyCommon, { + value: { + validate: (0, _utils.assertNodeType)("Expression"), + optional: true + }, + typeAnnotation: { + validate: (0, _utils.assertNodeType)("TypeAnnotation", "TSTypeAnnotation", "Noop"), + optional: true + }, + decorators: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("Decorator"))), + optional: true + }, + readonly: { + validate: (0, _utils.assertValueType)("boolean"), + optional: true + } + }) +}); +(0, _utils.default)("Import", { + aliases: ["Expression"] +}); +(0, _utils.default)("Decorator", { + visitor: ["expression"], + fields: { + expression: { + validate: (0, _utils.assertNodeType)("Expression") + } + } +}); +(0, _utils.default)("DoExpression", { + visitor: ["body"], + aliases: ["Expression"], + fields: { + body: { + validate: (0, _utils.assertNodeType)("BlockStatement") + } + } +}); +(0, _utils.default)("ExportDefaultSpecifier", { + visitor: ["exported"], + aliases: ["ModuleSpecifier"], + fields: { + exported: { + validate: (0, _utils.assertNodeType)("Identifier") + } + } +}); +(0, _utils.default)("ExportNamespaceSpecifier", { + visitor: ["exported"], + aliases: ["ModuleSpecifier"], + fields: { + exported: { + validate: (0, _utils.assertNodeType)("Identifier") + } + } +}); \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/flow.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/flow.js new file mode 100644 index 00000000000000..db54ee1a953b9e --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/flow.js @@ -0,0 +1,263 @@ +"use strict"; + +var _utils = _interopRequireWildcard(require("./utils")); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +(0, _utils.default)("AnyTypeAnnotation", { + aliases: ["Flow", "FlowBaseAnnotation"], + fields: {} +}); +(0, _utils.default)("ArrayTypeAnnotation", { + visitor: ["elementType"], + aliases: ["Flow"], + fields: {} +}); +(0, _utils.default)("BooleanTypeAnnotation", { + aliases: ["Flow", "FlowBaseAnnotation"], + fields: {} +}); +(0, _utils.default)("BooleanLiteralTypeAnnotation", { + aliases: ["Flow"], + fields: {} +}); +(0, _utils.default)("NullLiteralTypeAnnotation", { + aliases: ["Flow", "FlowBaseAnnotation"], + fields: {} +}); +(0, _utils.default)("ClassImplements", { + visitor: ["id", "typeParameters"], + aliases: ["Flow"], + fields: {} +}); +(0, _utils.default)("DeclareClass", { + visitor: ["id", "typeParameters", "extends", "body"], + aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], + fields: {} +}); +(0, _utils.default)("DeclareFunction", { + visitor: ["id"], + aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], + fields: {} +}); +(0, _utils.default)("DeclareInterface", { + visitor: ["id", "typeParameters", "extends", "body"], + aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], + fields: {} +}); +(0, _utils.default)("DeclareModule", { + visitor: ["id", "body"], + aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], + fields: {} +}); +(0, _utils.default)("DeclareModuleExports", { + visitor: ["typeAnnotation"], + aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], + fields: {} +}); +(0, _utils.default)("DeclareTypeAlias", { + visitor: ["id", "typeParameters", "right"], + aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], + fields: {} +}); +(0, _utils.default)("DeclareOpaqueType", { + visitor: ["id", "typeParameters", "supertype"], + aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], + fields: {} +}); +(0, _utils.default)("DeclareVariable", { + visitor: ["id"], + aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], + fields: {} +}); +(0, _utils.default)("DeclareExportDeclaration", { + visitor: ["declaration", "specifiers", "source"], + aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], + fields: {} +}); +(0, _utils.default)("DeclareExportAllDeclaration", { + visitor: ["source"], + aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], + fields: {} +}); +(0, _utils.default)("DeclaredPredicate", { + visitor: ["value"], + aliases: ["Flow", "FlowPredicate"], + fields: {} +}); +(0, _utils.default)("ExistsTypeAnnotation", { + aliases: ["Flow"] +}); +(0, _utils.default)("FunctionTypeAnnotation", { + visitor: ["typeParameters", "params", "rest", "returnType"], + aliases: ["Flow"], + fields: {} +}); +(0, _utils.default)("FunctionTypeParam", { + visitor: ["name", "typeAnnotation"], + aliases: ["Flow"], + fields: {} +}); +(0, _utils.default)("GenericTypeAnnotation", { + visitor: ["id", "typeParameters"], + aliases: ["Flow"], + fields: {} +}); +(0, _utils.default)("InferredPredicate", { + aliases: ["Flow", "FlowPredicate"], + fields: {} +}); +(0, _utils.default)("InterfaceExtends", { + visitor: ["id", "typeParameters"], + aliases: ["Flow"], + fields: {} +}); +(0, _utils.default)("InterfaceDeclaration", { + visitor: ["id", "typeParameters", "extends", "body"], + aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], + fields: {} +}); +(0, _utils.default)("IntersectionTypeAnnotation", { + visitor: ["types"], + aliases: ["Flow"], + fields: {} +}); +(0, _utils.default)("MixedTypeAnnotation", { + aliases: ["Flow", "FlowBaseAnnotation"] +}); +(0, _utils.default)("EmptyTypeAnnotation", { + aliases: ["Flow", "FlowBaseAnnotation"] +}); +(0, _utils.default)("NullableTypeAnnotation", { + visitor: ["typeAnnotation"], + aliases: ["Flow"], + fields: {} +}); +(0, _utils.default)("NumberLiteralTypeAnnotation", { + aliases: ["Flow"], + fields: {} +}); +(0, _utils.default)("NumberTypeAnnotation", { + aliases: ["Flow", "FlowBaseAnnotation"], + fields: {} +}); +(0, _utils.default)("ObjectTypeAnnotation", { + visitor: ["properties", "indexers", "callProperties"], + aliases: ["Flow"], + fields: {} +}); +(0, _utils.default)("ObjectTypeCallProperty", { + visitor: ["value"], + aliases: ["Flow", "UserWhitespacable"], + fields: {} +}); +(0, _utils.default)("ObjectTypeIndexer", { + visitor: ["id", "key", "value"], + aliases: ["Flow", "UserWhitespacable"], + fields: {} +}); +(0, _utils.default)("ObjectTypeProperty", { + visitor: ["key", "value"], + aliases: ["Flow", "UserWhitespacable"], + fields: {} +}); +(0, _utils.default)("ObjectTypeSpreadProperty", { + visitor: ["argument"], + aliases: ["Flow", "UserWhitespacable"], + fields: {} +}); +(0, _utils.default)("OpaqueType", { + visitor: ["id", "typeParameters", "supertype", "impltype"], + aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], + fields: {} +}); +(0, _utils.default)("QualifiedTypeIdentifier", { + visitor: ["id", "qualification"], + aliases: ["Flow"], + fields: {} +}); +(0, _utils.default)("StringLiteralTypeAnnotation", { + aliases: ["Flow"], + fields: {} +}); +(0, _utils.default)("StringTypeAnnotation", { + aliases: ["Flow", "FlowBaseAnnotation"], + fields: {} +}); +(0, _utils.default)("ThisTypeAnnotation", { + aliases: ["Flow", "FlowBaseAnnotation"], + fields: {} +}); +(0, _utils.default)("TupleTypeAnnotation", { + visitor: ["types"], + aliases: ["Flow"], + fields: {} +}); +(0, _utils.default)("TypeofTypeAnnotation", { + visitor: ["argument"], + aliases: ["Flow"], + fields: {} +}); +(0, _utils.default)("TypeAlias", { + visitor: ["id", "typeParameters", "right"], + aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"], + fields: {} +}); +(0, _utils.default)("TypeAnnotation", { + aliases: ["Flow"], + visitor: ["typeAnnotation"], + fields: { + typeAnnotation: { + validate: (0, _utils.assertNodeType)("Flow") + } + } +}); +(0, _utils.default)("TypeCastExpression", { + visitor: ["expression", "typeAnnotation"], + aliases: ["Flow", "ExpressionWrapper", "Expression"], + fields: {} +}); +(0, _utils.default)("TypeParameter", { + aliases: ["Flow"], + visitor: ["bound", "default"], + fields: { + name: { + validate: (0, _utils.assertValueType)("string") + }, + bound: { + validate: (0, _utils.assertNodeType)("TypeAnnotation"), + optional: true + }, + default: { + validate: (0, _utils.assertNodeType)("Flow"), + optional: true + } + } +}); +(0, _utils.default)("TypeParameterDeclaration", { + aliases: ["Flow"], + visitor: ["params"], + fields: { + params: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("TypeParameter"))) + } + } +}); +(0, _utils.default)("TypeParameterInstantiation", { + aliases: ["Flow"], + visitor: ["params"], + fields: { + params: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("Flow"))) + } + } +}); +(0, _utils.default)("UnionTypeAnnotation", { + visitor: ["types"], + aliases: ["Flow"], + fields: {} +}); +(0, _utils.default)("VoidTypeAnnotation", { + aliases: ["Flow", "FlowBaseAnnotation"], + fields: {} +}); \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/index.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/index.js new file mode 100644 index 00000000000000..a0bbfb84678026 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/index.js @@ -0,0 +1,40 @@ +"use strict"; + +exports.__esModule = true; +exports.TYPES = void 0; + +var _toFastProperties = _interopRequireDefault(require("to-fast-properties")); + +require("./core"); + +require("./es2015"); + +require("./flow"); + +require("./jsx"); + +require("./misc"); + +require("./experimental"); + +require("./typescript"); + +var _utils = require("./utils"); + +exports.VISITOR_KEYS = _utils.VISITOR_KEYS; +exports.ALIAS_KEYS = _utils.ALIAS_KEYS; +exports.FLIPPED_ALIAS_KEYS = _utils.FLIPPED_ALIAS_KEYS; +exports.NODE_FIELDS = _utils.NODE_FIELDS; +exports.BUILDER_KEYS = _utils.BUILDER_KEYS; +exports.DEPRECATED_KEYS = _utils.DEPRECATED_KEYS; + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +(0, _toFastProperties.default)(_utils.VISITOR_KEYS); +(0, _toFastProperties.default)(_utils.ALIAS_KEYS); +(0, _toFastProperties.default)(_utils.FLIPPED_ALIAS_KEYS); +(0, _toFastProperties.default)(_utils.NODE_FIELDS); +(0, _toFastProperties.default)(_utils.BUILDER_KEYS); +(0, _toFastProperties.default)(_utils.DEPRECATED_KEYS); +var TYPES = Object.keys(_utils.VISITOR_KEYS).concat(Object.keys(_utils.FLIPPED_ALIAS_KEYS)).concat(Object.keys(_utils.DEPRECATED_KEYS)); +exports.TYPES = TYPES; \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/jsx.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/jsx.js new file mode 100644 index 00000000000000..0ed8978b12e168 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/jsx.js @@ -0,0 +1,156 @@ +"use strict"; + +var _utils = _interopRequireWildcard(require("./utils")); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +(0, _utils.default)("JSXAttribute", { + visitor: ["name", "value"], + aliases: ["JSX", "Immutable"], + fields: { + name: { + validate: (0, _utils.assertNodeType)("JSXIdentifier", "JSXNamespacedName") + }, + value: { + optional: true, + validate: (0, _utils.assertNodeType)("JSXElement", "JSXFragment", "StringLiteral", "JSXExpressionContainer") + } + } +}); +(0, _utils.default)("JSXClosingElement", { + visitor: ["name"], + aliases: ["JSX", "Immutable"], + fields: { + name: { + validate: (0, _utils.assertNodeType)("JSXIdentifier", "JSXMemberExpression") + } + } +}); +(0, _utils.default)("JSXElement", { + builder: ["openingElement", "closingElement", "children", "selfClosing"], + visitor: ["openingElement", "children", "closingElement"], + aliases: ["JSX", "Immutable", "Expression"], + fields: { + openingElement: { + validate: (0, _utils.assertNodeType)("JSXOpeningElement") + }, + closingElement: { + optional: true, + validate: (0, _utils.assertNodeType)("JSXClosingElement") + }, + children: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("JSXText", "JSXExpressionContainer", "JSXSpreadChild", "JSXElement", "JSXFragment"))) + } + } +}); +(0, _utils.default)("JSXEmptyExpression", { + aliases: ["JSX"] +}); +(0, _utils.default)("JSXExpressionContainer", { + visitor: ["expression"], + aliases: ["JSX", "Immutable"], + fields: { + expression: { + validate: (0, _utils.assertNodeType)("Expression") + } + } +}); +(0, _utils.default)("JSXSpreadChild", { + visitor: ["expression"], + aliases: ["JSX", "Immutable"], + fields: { + expression: { + validate: (0, _utils.assertNodeType)("Expression") + } + } +}); +(0, _utils.default)("JSXIdentifier", { + builder: ["name"], + aliases: ["JSX"], + fields: { + name: { + validate: (0, _utils.assertValueType)("string") + } + } +}); +(0, _utils.default)("JSXMemberExpression", { + visitor: ["object", "property"], + aliases: ["JSX"], + fields: { + object: { + validate: (0, _utils.assertNodeType)("JSXMemberExpression", "JSXIdentifier") + }, + property: { + validate: (0, _utils.assertNodeType)("JSXIdentifier") + } + } +}); +(0, _utils.default)("JSXNamespacedName", { + visitor: ["namespace", "name"], + aliases: ["JSX"], + fields: { + namespace: { + validate: (0, _utils.assertNodeType)("JSXIdentifier") + }, + name: { + validate: (0, _utils.assertNodeType)("JSXIdentifier") + } + } +}); +(0, _utils.default)("JSXOpeningElement", { + builder: ["name", "attributes", "selfClosing"], + visitor: ["name", "attributes"], + aliases: ["JSX", "Immutable"], + fields: { + name: { + validate: (0, _utils.assertNodeType)("JSXIdentifier", "JSXMemberExpression") + }, + selfClosing: { + default: false, + validate: (0, _utils.assertValueType)("boolean") + }, + attributes: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("JSXAttribute", "JSXSpreadAttribute"))) + } + } +}); +(0, _utils.default)("JSXSpreadAttribute", { + visitor: ["argument"], + aliases: ["JSX"], + fields: { + argument: { + validate: (0, _utils.assertNodeType)("Expression") + } + } +}); +(0, _utils.default)("JSXText", { + aliases: ["JSX", "Immutable"], + builder: ["value"], + fields: { + value: { + validate: (0, _utils.assertValueType)("string") + } + } +}); +(0, _utils.default)("JSXFragment", { + builder: ["openingFragment", "closingFragment", "children"], + visitor: ["openingFragment", "children", "closingFragment"], + aliases: ["JSX", "Immutable", "Expression"], + fields: { + openingFragment: { + validate: (0, _utils.assertNodeType)("JSXOpeningFragment") + }, + closingFragment: { + validate: (0, _utils.assertNodeType)("JSXClosingFragment") + }, + children: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("JSXText", "JSXExpressionContainer", "JSXSpreadChild", "JSXElement", "JSXFragment"))) + } + } +}); +(0, _utils.default)("JSXOpeningFragment", { + aliases: ["JSX", "Immutable"] +}); +(0, _utils.default)("JSXClosingFragment", { + aliases: ["JSX", "Immutable"] +}); \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/misc.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/misc.js new file mode 100644 index 00000000000000..714f2979447e2a --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/misc.js @@ -0,0 +1,18 @@ +"use strict"; + +var _utils = _interopRequireWildcard(require("./utils")); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +(0, _utils.default)("Noop", { + visitor: [] +}); +(0, _utils.default)("ParenthesizedExpression", { + visitor: ["expression"], + aliases: ["Expression", "ExpressionWrapper"], + fields: { + expression: { + validate: (0, _utils.assertNodeType)("Expression") + } + } +}); \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/typescript.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/typescript.js new file mode 100644 index 00000000000000..90dca181f26981 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/typescript.js @@ -0,0 +1,413 @@ +"use strict"; + +var _utils = _interopRequireWildcard(require("./utils")); + +var _core = require("./core"); + +var _es = require("./es2015"); + +function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } + +var bool = (0, _utils.assertValueType)("boolean"); + +function validate(validate) { + return { + validate: validate + }; +} + +function typeIs(typeName) { + return typeof typeName === "string" ? (0, _utils.assertNodeType)(typeName) : _utils.assertNodeType.apply(void 0, typeName); +} + +function validateType(name) { + return validate(typeIs(name)); +} + +function validateOptional(validate) { + return { + validate: validate, + optional: true + }; +} + +function validateOptionalType(typeName) { + return { + validate: typeIs(typeName), + optional: true + }; +} + +function arrayOf(elementType) { + return (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)(elementType)); +} + +function arrayOfType(nodeTypeName) { + return arrayOf(typeIs(nodeTypeName)); +} + +function validateArrayOfType(nodeTypeName) { + return validate(arrayOfType(nodeTypeName)); +} + +var tSFunctionTypeAnnotationCommon = { + returnType: { + validate: (0, _utils.assertNodeType)("TSTypeAnnotation", "Noop"), + optional: true + }, + typeParameters: { + validate: (0, _utils.assertNodeType)("TSTypeParameterDeclaration", "Noop"), + optional: true + } +}; +(0, _utils.default)("TSParameterProperty", { + aliases: ["LVal"], + visitor: ["parameter"], + fields: { + accessibility: { + validate: (0, _utils.assertOneOf)("public", "private", "protected"), + optional: true + }, + readonly: { + validate: (0, _utils.assertValueType)("boolean"), + optional: true + }, + parameter: { + validate: (0, _utils.assertNodeType)("Identifier", "AssignmentPattern") + } + } +}); +(0, _utils.default)("TSDeclareFunction", { + aliases: ["Statement", "Declaration"], + visitor: ["id", "typeParameters", "params", "returnType"], + fields: Object.assign({}, _core.functionDeclarationCommon, tSFunctionTypeAnnotationCommon) +}); +(0, _utils.default)("TSDeclareMethod", { + visitor: ["decorators", "key", "typeParameters", "params", "returnType"], + fields: Object.assign({}, _es.classMethodOrDeclareMethodCommon, tSFunctionTypeAnnotationCommon) +}); +(0, _utils.default)("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 +}; +(0, _utils.default)("TSCallSignatureDeclaration", callConstructSignatureDeclaration); +(0, _utils.default)("TSConstructSignatureDeclaration", callConstructSignatureDeclaration); +var namedTypeElementCommon = { + key: validateType("Expression"), + computed: validate(bool), + optional: validateOptional(bool) +}; +(0, _utils.default)("TSPropertySignature", { + aliases: ["TSTypeElement"], + visitor: ["key", "typeAnnotation", "initializer"], + fields: Object.assign({}, namedTypeElementCommon, { + readonly: validateOptional(bool), + typeAnnotation: validateOptionalType("TSTypeAnnotation"), + initializer: validateOptionalType("Expression") + }) +}); +(0, _utils.default)("TSMethodSignature", { + aliases: ["TSTypeElement"], + visitor: ["key", "typeParameters", "parameters", "typeAnnotation"], + fields: Object.assign({}, signatureDeclarationCommon, namedTypeElementCommon) +}); +(0, _utils.default)("TSIndexSignature", { + aliases: ["TSTypeElement"], + visitor: ["parameters", "typeAnnotation"], + fields: { + readonly: validateOptional(bool), + parameters: validateArrayOfType("Identifier"), + typeAnnotation: validateOptionalType("TSTypeAnnotation") + } +}); +var tsKeywordTypes = ["TSAnyKeyword", "TSNumberKeyword", "TSObjectKeyword", "TSBooleanKeyword", "TSStringKeyword", "TSSymbolKeyword", "TSVoidKeyword", "TSUndefinedKeyword", "TSNullKeyword", "TSNeverKeyword"]; + +for (var _i = 0; _i < tsKeywordTypes.length; _i++) { + var type = tsKeywordTypes[_i]; + (0, _utils.default)(type, { + aliases: ["TSType"], + visitor: [], + fields: {} + }); +} + +(0, _utils.default)("TSThisType", { + aliases: ["TSType"], + visitor: [], + fields: {} +}); +var fnOrCtr = { + aliases: ["TSType"], + visitor: ["typeParameters", "typeAnnotation"], + fields: signatureDeclarationCommon +}; +(0, _utils.default)("TSFunctionType", fnOrCtr); +(0, _utils.default)("TSConstructorType", fnOrCtr); +(0, _utils.default)("TSTypeReference", { + aliases: ["TSType"], + visitor: ["typeName", "typeParameters"], + fields: { + typeName: validateType("TSEntityName"), + typeParameters: validateOptionalType("TSTypeParameterInstantiation") + } +}); +(0, _utils.default)("TSTypePredicate", { + aliases: ["TSType"], + visitor: ["parameterName", "typeAnnotation"], + fields: { + parameterName: validateType(["Identifier", "TSThisType"]), + typeAnnotation: validateType("TSTypeAnnotation") + } +}); +(0, _utils.default)("TSTypeQuery", { + aliases: ["TSType"], + visitor: ["exprName"], + fields: { + exprName: validateType("TSEntityName") + } +}); +(0, _utils.default)("TSTypeLiteral", { + aliases: ["TSType"], + visitor: ["members"], + fields: { + members: validateArrayOfType("TSTypeElement") + } +}); +(0, _utils.default)("TSArrayType", { + aliases: ["TSType"], + visitor: ["elementType"], + fields: { + elementType: validateType("TSType") + } +}); +(0, _utils.default)("TSTupleType", { + aliases: ["TSType"], + visitor: ["elementTypes"], + fields: { + elementTypes: validateArrayOfType("TSType") + } +}); +var unionOrIntersection = { + aliases: ["TSType"], + visitor: ["types"], + fields: { + types: validateArrayOfType("TSType") + } +}; +(0, _utils.default)("TSUnionType", unionOrIntersection); +(0, _utils.default)("TSIntersectionType", unionOrIntersection); +(0, _utils.default)("TSParenthesizedType", { + aliases: ["TSType"], + visitor: ["typeAnnotation"], + fields: { + typeAnnotation: validateType("TSType") + } +}); +(0, _utils.default)("TSTypeOperator", { + aliases: ["TSType"], + visitor: ["typeAnnotation"], + fields: { + operator: validate((0, _utils.assertValueType)("string")), + typeAnnotation: validateType("TSType") + } +}); +(0, _utils.default)("TSIndexedAccessType", { + aliases: ["TSType"], + visitor: ["objectType", "indexType"], + fields: { + objectType: validateType("TSType"), + indexType: validateType("TSType") + } +}); +(0, _utils.default)("TSMappedType", { + aliases: ["TSType"], + visitor: ["typeParameter", "typeAnnotation"], + fields: { + readonly: validateOptional(bool), + typeParameter: validateType("TSTypeParameter"), + optional: validateOptional(bool), + typeAnnotation: validateOptionalType("TSType") + } +}); +(0, _utils.default)("TSLiteralType", { + aliases: ["TSType"], + visitor: ["literal"], + fields: { + literal: validateType(["NumericLiteral", "StringLiteral", "BooleanLiteral"]) + } +}); +(0, _utils.default)("TSExpressionWithTypeArguments", { + aliases: ["TSType"], + visitor: ["expression", "typeParameters"], + fields: { + expression: validateType("TSEntityName"), + typeParameters: validateOptionalType("TSTypeParameterInstantiation") + } +}); +(0, _utils.default)("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") + } +}); +(0, _utils.default)("TSInterfaceBody", { + visitor: ["body"], + fields: { + body: validateArrayOfType("TSTypeElement") + } +}); +(0, _utils.default)("TSTypeAliasDeclaration", { + aliases: ["Statement", "Declaration"], + visitor: ["id", "typeParameters", "typeAnnotation"], + fields: { + declare: validateOptional(bool), + id: validateType("Identifier"), + typeParameters: validateOptionalType("TSTypeParameterDeclaration"), + typeAnnotation: validateType("TSType") + } +}); +(0, _utils.default)("TSAsExpression", { + aliases: ["Expression"], + visitor: ["expression", "typeAnnotation"], + fields: { + expression: validateType("Expression"), + typeAnnotation: validateType("TSType") + } +}); +(0, _utils.default)("TSTypeAssertion", { + aliases: ["Expression"], + visitor: ["typeAnnotation", "expression"], + fields: { + typeAnnotation: validateType("TSType"), + expression: validateType("Expression") + } +}); +(0, _utils.default)("TSEnumDeclaration", { + aliases: ["Statement", "Declaration"], + visitor: ["id", "members"], + fields: { + declare: validateOptional(bool), + const: validateOptional(bool), + id: validateType("Identifier"), + members: validateArrayOfType("TSEnumMember"), + initializer: validateOptionalType("Expression") + } +}); +(0, _utils.default)("TSEnumMember", { + visitor: ["id", "initializer"], + fields: { + id: validateType(["Identifier", "StringLiteral"]), + initializer: validateOptionalType("Expression") + } +}); +(0, _utils.default)("TSModuleDeclaration", { + aliases: ["Statement", "Declaration"], + visitor: ["id", "body"], + fields: { + declare: validateOptional(bool), + global: validateOptional(bool), + id: validateType(["Identifier", "StringLiteral"]), + body: validateType(["TSModuleBlock", "TSModuleDeclaration"]) + } +}); +(0, _utils.default)("TSModuleBlock", { + visitor: ["body"], + fields: { + body: validateArrayOfType("Statement") + } +}); +(0, _utils.default)("TSImportEqualsDeclaration", { + aliases: ["Statement"], + visitor: ["id", "moduleReference"], + fields: { + isExport: validate(bool), + id: validateType("Identifier"), + moduleReference: validateType(["TSEntityName", "TSExternalModuleReference"]) + } +}); +(0, _utils.default)("TSExternalModuleReference", { + visitor: ["expression"], + fields: { + expression: validateType("StringLiteral") + } +}); +(0, _utils.default)("TSNonNullExpression", { + aliases: ["Expression"], + visitor: ["expression"], + fields: { + expression: validateType("Expression") + } +}); +(0, _utils.default)("TSExportAssignment", { + aliases: ["Statement"], + visitor: ["expression"], + fields: { + expression: validateType("Expression") + } +}); +(0, _utils.default)("TSNamespaceExportDeclaration", { + aliases: ["Statement"], + visitor: ["id"], + fields: { + id: validateType("Identifier") + } +}); +(0, _utils.default)("TSTypeAnnotation", { + visitor: ["typeAnnotation"], + fields: { + typeAnnotation: { + validate: (0, _utils.assertNodeType)("TSType") + } + } +}); +(0, _utils.default)("TSTypeParameterInstantiation", { + visitor: ["params"], + fields: { + params: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("TSType"))) + } + } +}); +(0, _utils.default)("TSTypeParameterDeclaration", { + visitor: ["params"], + fields: { + params: { + validate: (0, _utils.chain)((0, _utils.assertValueType)("array"), (0, _utils.assertEach)((0, _utils.assertNodeType)("TSTypeParameter"))) + } + } +}); +(0, _utils.default)("TSTypeParameter", { + visitor: ["constraint", "default"], + fields: { + name: { + validate: (0, _utils.assertValueType)("string") + }, + constraint: { + validate: (0, _utils.assertNodeType)("TSType"), + optional: true + }, + default: { + validate: (0, _utils.assertNodeType)("TSType"), + optional: true + } + } +}); \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/utils.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/utils.js new file mode 100644 index 00000000000000..6d323768cea5c0 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/definitions/utils.js @@ -0,0 +1,198 @@ +"use strict"; + +exports.__esModule = true; +exports.assertEach = assertEach; +exports.assertOneOf = assertOneOf; +exports.assertNodeType = assertNodeType; +exports.assertNodeOrValueType = assertNodeOrValueType; +exports.assertValueType = assertValueType; +exports.chain = chain; +exports.default = defineType; +exports.DEPRECATED_KEYS = exports.BUILDER_KEYS = exports.NODE_FIELDS = exports.FLIPPED_ALIAS_KEYS = exports.ALIAS_KEYS = exports.VISITOR_KEYS = void 0; + +var _is = _interopRequireDefault(require("../validators/is")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +var VISITOR_KEYS = {}; +exports.VISITOR_KEYS = VISITOR_KEYS; +var ALIAS_KEYS = {}; +exports.ALIAS_KEYS = ALIAS_KEYS; +var FLIPPED_ALIAS_KEYS = {}; +exports.FLIPPED_ALIAS_KEYS = FLIPPED_ALIAS_KEYS; +var NODE_FIELDS = {}; +exports.NODE_FIELDS = NODE_FIELDS; +var BUILDER_KEYS = {}; +exports.BUILDER_KEYS = BUILDER_KEYS; +var DEPRECATED_KEYS = {}; +exports.DEPRECATED_KEYS = DEPRECATED_KEYS; + +function getType(val) { + if (Array.isArray(val)) { + return "array"; + } else if (val === null) { + return "null"; + } else if (val === undefined) { + return "undefined"; + } else { + return typeof val; + } +} + +function assertEach(callback) { + function validator(node, key, val) { + if (!Array.isArray(val)) return; + + for (var i = 0; i < val.length; i++) { + callback(node, key + "[" + i + "]", val[i]); + } + } + + 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) { + var valid = false; + + for (var _i = 0; _i < types.length; _i++) { + var type = types[_i]; + + if ((0, _is.default)(type, val)) { + valid = true; + break; + } + } + + if (!valid) { + 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) { + var valid = false; + + for (var _i2 = 0; _i2 < types.length; _i2++) { + var type = types[_i2]; + + if (getType(val) === type || (0, _is.default)(type, val)) { + valid = true; + break; + } + } + + if (!valid) { + 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 chain() { + for (var _len4 = arguments.length, fns = new Array(_len4), _key4 = 0; _key4 < _len4; _key4++) { + fns[_key4] = arguments[_key4]; + } + + function validate() { + for (var _i3 = 0; _i3 < fns.length; _i3++) { + var fn = fns[_i3]; + fn.apply(void 0, arguments); + } + } + + validate.chainOf = fns; + return validate; +} + +function defineType(type, opts) { + if (opts === void 0) { + opts = {}; + } + + var inherits = opts.inherits && store[opts.inherits] || {}; + var fields = opts.fields || inherits.fields || {}; + var visitor = opts.visitor || inherits.visitor || []; + var aliases = opts.aliases || inherits.aliases || []; + var builder = opts.builder || inherits.builder || opts.visitor || []; + + if (opts.deprecatedAlias) { + DEPRECATED_KEYS[opts.deprecatedAlias] = type; + } + + var _arr = visitor.concat(builder); + + for (var _i4 = 0; _i4 < _arr.length; _i4++) { + var key = _arr[_i4]; + fields[key] = fields[key] || {}; + } + + for (var _key5 in fields) { + var field = fields[_key5]; + + if (builder.indexOf(_key5) === -1) { + field.optional = true; + } + + if (field.default === undefined) { + field.default = null; + } else if (!field.validate) { + field.validate = assertValueType(getType(field.default)); + } + } + + 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); + }); + store[type] = opts; +} + +var store = {}; \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/index.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/index.js new file mode 100644 index 00000000000000..dc6952d70657ab --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/index.js @@ -0,0 +1,325 @@ +"use strict"; + +exports.__esModule = true; +var _exportNames = { + assertNode: true, + createTypeAnnotationBasedOnTypeof: true, + createUnionTypeAnnotation: true, + clone: true, + cloneDeep: true, + cloneWithoutLoc: true, + addComment: true, + addComments: true, + inheritInnerComments: true, + inheritLeadingComments: true, + inheritsComments: true, + inheritTrailingComments: true, + removeComments: true, + ensureBlock: true, + toBindingIdentifierName: true, + toBlock: true, + toComputedKey: true, + toExpression: true, + toIdentifier: true, + toKeyAlias: true, + toSequenceExpression: true, + toStatement: true, + valueToNode: true, + appendToMemberExpression: true, + inherits: true, + prependToMemberExpression: true, + removeProperties: true, + removePropertiesDeep: true, + removeTypeDuplicates: true, + getBindingIdentifiers: true, + getOuterBindingIdentifiers: true, + traverse: true, + traverseFast: true, + shallowEqual: true, + is: true, + isBinding: true, + isBlockScoped: true, + isImmutable: true, + isLet: true, + isNode: true, + isNodesEquivalent: true, + isReferenced: true, + isScope: true, + isSpecifierDefault: true, + isType: true, + isValidES3Identifier: true, + isValidIdentifier: true, + isVar: true, + matchesPattern: true, + validate: true, + buildMatchMemberExpression: true, + react: true +}; +exports.react = exports.buildMatchMemberExpression = exports.validate = exports.matchesPattern = exports.isVar = exports.isValidIdentifier = exports.isValidES3Identifier = exports.isType = exports.isSpecifierDefault = exports.isScope = exports.isReferenced = exports.isNodesEquivalent = exports.isNode = exports.isLet = exports.isImmutable = exports.isBlockScoped = exports.isBinding = exports.is = exports.shallowEqual = exports.traverseFast = exports.traverse = exports.getOuterBindingIdentifiers = exports.getBindingIdentifiers = exports.removeTypeDuplicates = exports.removePropertiesDeep = exports.removeProperties = exports.prependToMemberExpression = exports.inherits = exports.appendToMemberExpression = exports.valueToNode = exports.toStatement = exports.toSequenceExpression = exports.toKeyAlias = exports.toIdentifier = exports.toExpression = exports.toComputedKey = exports.toBlock = exports.toBindingIdentifierName = exports.ensureBlock = exports.removeComments = exports.inheritTrailingComments = exports.inheritsComments = exports.inheritLeadingComments = exports.inheritInnerComments = exports.addComments = exports.addComment = exports.cloneWithoutLoc = exports.cloneDeep = exports.clone = exports.createUnionTypeAnnotation = exports.createTypeAnnotationBasedOnTypeof = exports.assertNode = void 0; + +var _isReactComponent = _interopRequireDefault(require("./validators/react/isReactComponent")); + +var _isCompatTag = _interopRequireDefault(require("./validators/react/isCompatTag")); + +var _buildChildren = _interopRequireDefault(require("./builders/react/buildChildren")); + +var _assertNode = _interopRequireDefault(require("./asserts/assertNode")); + +exports.assertNode = _assertNode.default; + +var _generated = require("./asserts/generated"); + +Object.keys(_generated).forEach(function (key) { + if (key === "default" || key === "__esModule") return; + if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return; + exports[key] = _generated[key]; +}); + +var _createTypeAnnotationBasedOnTypeof = _interopRequireDefault(require("./builders/flow/createTypeAnnotationBasedOnTypeof")); + +exports.createTypeAnnotationBasedOnTypeof = _createTypeAnnotationBasedOnTypeof.default; + +var _createUnionTypeAnnotation = _interopRequireDefault(require("./builders/flow/createUnionTypeAnnotation")); + +exports.createUnionTypeAnnotation = _createUnionTypeAnnotation.default; + +var _generated2 = require("./builders/generated"); + +Object.keys(_generated2).forEach(function (key) { + if (key === "default" || key === "__esModule") return; + if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return; + exports[key] = _generated2[key]; +}); + +var _clone = _interopRequireDefault(require("./clone/clone")); + +exports.clone = _clone.default; + +var _cloneDeep = _interopRequireDefault(require("./clone/cloneDeep")); + +exports.cloneDeep = _cloneDeep.default; + +var _cloneWithoutLoc = _interopRequireDefault(require("./clone/cloneWithoutLoc")); + +exports.cloneWithoutLoc = _cloneWithoutLoc.default; + +var _addComment = _interopRequireDefault(require("./comments/addComment")); + +exports.addComment = _addComment.default; + +var _addComments = _interopRequireDefault(require("./comments/addComments")); + +exports.addComments = _addComments.default; + +var _inheritInnerComments = _interopRequireDefault(require("./comments/inheritInnerComments")); + +exports.inheritInnerComments = _inheritInnerComments.default; + +var _inheritLeadingComments = _interopRequireDefault(require("./comments/inheritLeadingComments")); + +exports.inheritLeadingComments = _inheritLeadingComments.default; + +var _inheritsComments = _interopRequireDefault(require("./comments/inheritsComments")); + +exports.inheritsComments = _inheritsComments.default; + +var _inheritTrailingComments = _interopRequireDefault(require("./comments/inheritTrailingComments")); + +exports.inheritTrailingComments = _inheritTrailingComments.default; + +var _removeComments = _interopRequireDefault(require("./comments/removeComments")); + +exports.removeComments = _removeComments.default; + +var _generated3 = require("./constants/generated"); + +Object.keys(_generated3).forEach(function (key) { + if (key === "default" || key === "__esModule") return; + if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return; + exports[key] = _generated3[key]; +}); + +var _constants = require("./constants"); + +Object.keys(_constants).forEach(function (key) { + if (key === "default" || key === "__esModule") return; + if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return; + exports[key] = _constants[key]; +}); + +var _ensureBlock = _interopRequireDefault(require("./converters/ensureBlock")); + +exports.ensureBlock = _ensureBlock.default; + +var _toBindingIdentifierName = _interopRequireDefault(require("./converters/toBindingIdentifierName")); + +exports.toBindingIdentifierName = _toBindingIdentifierName.default; + +var _toBlock = _interopRequireDefault(require("./converters/toBlock")); + +exports.toBlock = _toBlock.default; + +var _toComputedKey = _interopRequireDefault(require("./converters/toComputedKey")); + +exports.toComputedKey = _toComputedKey.default; + +var _toExpression = _interopRequireDefault(require("./converters/toExpression")); + +exports.toExpression = _toExpression.default; + +var _toIdentifier = _interopRequireDefault(require("./converters/toIdentifier")); + +exports.toIdentifier = _toIdentifier.default; + +var _toKeyAlias = _interopRequireDefault(require("./converters/toKeyAlias")); + +exports.toKeyAlias = _toKeyAlias.default; + +var _toSequenceExpression = _interopRequireDefault(require("./converters/toSequenceExpression")); + +exports.toSequenceExpression = _toSequenceExpression.default; + +var _toStatement = _interopRequireDefault(require("./converters/toStatement")); + +exports.toStatement = _toStatement.default; + +var _valueToNode = _interopRequireDefault(require("./converters/valueToNode")); + +exports.valueToNode = _valueToNode.default; + +var _definitions = require("./definitions"); + +Object.keys(_definitions).forEach(function (key) { + if (key === "default" || key === "__esModule") return; + if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return; + exports[key] = _definitions[key]; +}); + +var _appendToMemberExpression = _interopRequireDefault(require("./modifications/appendToMemberExpression")); + +exports.appendToMemberExpression = _appendToMemberExpression.default; + +var _inherits = _interopRequireDefault(require("./modifications/inherits")); + +exports.inherits = _inherits.default; + +var _prependToMemberExpression = _interopRequireDefault(require("./modifications/prependToMemberExpression")); + +exports.prependToMemberExpression = _prependToMemberExpression.default; + +var _removeProperties = _interopRequireDefault(require("./modifications/removeProperties")); + +exports.removeProperties = _removeProperties.default; + +var _removePropertiesDeep = _interopRequireDefault(require("./modifications/removePropertiesDeep")); + +exports.removePropertiesDeep = _removePropertiesDeep.default; + +var _removeTypeDuplicates = _interopRequireDefault(require("./modifications/flow/removeTypeDuplicates")); + +exports.removeTypeDuplicates = _removeTypeDuplicates.default; + +var _getBindingIdentifiers = _interopRequireDefault(require("./retrievers/getBindingIdentifiers")); + +exports.getBindingIdentifiers = _getBindingIdentifiers.default; + +var _getOuterBindingIdentifiers = _interopRequireDefault(require("./retrievers/getOuterBindingIdentifiers")); + +exports.getOuterBindingIdentifiers = _getOuterBindingIdentifiers.default; + +var _traverse = _interopRequireDefault(require("./traverse/traverse")); + +exports.traverse = _traverse.default; + +var _traverseFast = _interopRequireDefault(require("./traverse/traverseFast")); + +exports.traverseFast = _traverseFast.default; + +var _shallowEqual = _interopRequireDefault(require("./utils/shallowEqual")); + +exports.shallowEqual = _shallowEqual.default; + +var _is = _interopRequireDefault(require("./validators/is")); + +exports.is = _is.default; + +var _isBinding = _interopRequireDefault(require("./validators/isBinding")); + +exports.isBinding = _isBinding.default; + +var _isBlockScoped = _interopRequireDefault(require("./validators/isBlockScoped")); + +exports.isBlockScoped = _isBlockScoped.default; + +var _isImmutable = _interopRequireDefault(require("./validators/isImmutable")); + +exports.isImmutable = _isImmutable.default; + +var _isLet = _interopRequireDefault(require("./validators/isLet")); + +exports.isLet = _isLet.default; + +var _isNode = _interopRequireDefault(require("./validators/isNode")); + +exports.isNode = _isNode.default; + +var _isNodesEquivalent = _interopRequireDefault(require("./validators/isNodesEquivalent")); + +exports.isNodesEquivalent = _isNodesEquivalent.default; + +var _isReferenced = _interopRequireDefault(require("./validators/isReferenced")); + +exports.isReferenced = _isReferenced.default; + +var _isScope = _interopRequireDefault(require("./validators/isScope")); + +exports.isScope = _isScope.default; + +var _isSpecifierDefault = _interopRequireDefault(require("./validators/isSpecifierDefault")); + +exports.isSpecifierDefault = _isSpecifierDefault.default; + +var _isType = _interopRequireDefault(require("./validators/isType")); + +exports.isType = _isType.default; + +var _isValidES3Identifier = _interopRequireDefault(require("./validators/isValidES3Identifier")); + +exports.isValidES3Identifier = _isValidES3Identifier.default; + +var _isValidIdentifier = _interopRequireDefault(require("./validators/isValidIdentifier")); + +exports.isValidIdentifier = _isValidIdentifier.default; + +var _isVar = _interopRequireDefault(require("./validators/isVar")); + +exports.isVar = _isVar.default; + +var _matchesPattern = _interopRequireDefault(require("./validators/matchesPattern")); + +exports.matchesPattern = _matchesPattern.default; + +var _validate = _interopRequireDefault(require("./validators/validate")); + +exports.validate = _validate.default; + +var _buildMatchMemberExpression = _interopRequireDefault(require("./validators/buildMatchMemberExpression")); + +exports.buildMatchMemberExpression = _buildMatchMemberExpression.default; + +var _generated4 = require("./validators/generated"); + +Object.keys(_generated4).forEach(function (key) { + if (key === "default" || key === "__esModule") return; + if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return; + exports[key] = _generated4[key]; +}); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +var react = { + isReactComponent: _isReactComponent.default, + isCompatTag: _isCompatTag.default, + buildChildren: _buildChildren.default +}; +exports.react = react; \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/appendToMemberExpression.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/appendToMemberExpression.js new file mode 100644 index 00000000000000..f9d971c6237d1c --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/appendToMemberExpression.js @@ -0,0 +1,17 @@ +"use strict"; + +exports.__esModule = true; +exports.default = appendToMemberExpression; + +var _generated = require("../builders/generated"); + +function appendToMemberExpression(member, append, computed) { + if (computed === void 0) { + computed = false; + } + + member.object = (0, _generated.memberExpression)(member.object, member.property, member.computed); + member.property = append; + member.computed = !!computed; + return member; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/flow/removeTypeDuplicates.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/flow/removeTypeDuplicates.js new file mode 100644 index 00000000000000..c0f402088c52ce --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/flow/removeTypeDuplicates.js @@ -0,0 +1,72 @@ +"use strict"; + +exports.__esModule = true; +exports.default = removeTypeDuplicates; + +var _generated = require("../../validators/generated"); + +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 ((0, _generated.isAnyTypeAnnotation)(node)) { + return [node]; + } + + if ((0, _generated.isFlowBaseAnnotation)(node)) { + bases[node.type] = node; + continue; + } + + if ((0, _generated.isUnionTypeAnnotation)(node)) { + if (typeGroups.indexOf(node.types) < 0) { + nodes = nodes.concat(node.types); + typeGroups.push(node.types); + } + + continue; + } + + if ((0, _generated.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 type in bases) { + types.push(bases[type]); + } + + for (var _name in generics) { + types.push(generics[_name]); + } + + return types; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/inherits.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/inherits.js new file mode 100644 index 00000000000000..195f714cf3afd3 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/inherits.js @@ -0,0 +1,37 @@ +"use strict"; + +exports.__esModule = true; +exports.default = inherits; + +var _constants = require("../constants"); + +var _inheritsComments = _interopRequireDefault(require("../comments/inheritsComments")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function inherits(child, parent) { + if (!child || !parent) return child; + var _arr = _constants.INHERIT_KEYS.optional; + + for (var _i = 0; _i < _arr.length; _i++) { + var key = _arr[_i]; + + if (child[key] == null) { + child[key] = parent[key]; + } + } + + for (var _key in parent) { + if (_key[0] === "_" && _key !== "__clone") child[_key] = parent[_key]; + } + + var _arr2 = _constants.INHERIT_KEYS.force; + + for (var _i2 = 0; _i2 < _arr2.length; _i2++) { + var _key2 = _arr2[_i2]; + child[_key2] = parent[_key2]; + } + + (0, _inheritsComments.default)(child, parent); + return child; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/prependToMemberExpression.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/prependToMemberExpression.js new file mode 100644 index 00000000000000..9b0f8aef69a1c7 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/prependToMemberExpression.js @@ -0,0 +1,11 @@ +"use strict"; + +exports.__esModule = true; +exports.default = prependToMemberExpression; + +var _generated = require("../builders/generated"); + +function prependToMemberExpression(member, prepend) { + member.object = (0, _generated.memberExpression)(prepend, member.object); + return member; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/removeProperties.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/removeProperties.js new file mode 100644 index 00000000000000..0f3a5c31b8be4c --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/removeProperties.js @@ -0,0 +1,56 @@ +"use strict"; + +exports.__esModule = true; +exports.default = removeProperties; + +var _constants = require("../constants"); + +var CLEAR_KEYS = ["tokens", "start", "end", "loc", "raw", "rawValue"]; + +var CLEAR_KEYS_PLUS_COMMENTS = _constants.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 _key2 = _ref; + if (node[_key2] != null) node[_key2] = undefined; + } + + for (var _key in node) { + if (_key[0] === "_" && node[_key] != null) node[_key] = undefined; + } + + var symbols = Object.getOwnPropertySymbols(node); + + for (var _iterator2 = symbols, _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 _sym = _ref2; + node[_sym] = null; + } +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/removePropertiesDeep.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/removePropertiesDeep.js new file mode 100644 index 00000000000000..78453469680298 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/modifications/removePropertiesDeep.js @@ -0,0 +1,15 @@ +"use strict"; + +exports.__esModule = true; +exports.default = removePropertiesDeep; + +var _traverseFast = _interopRequireDefault(require("../traverse/traverseFast")); + +var _removeProperties = _interopRequireDefault(require("./removeProperties")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function removePropertiesDeep(tree, opts) { + (0, _traverseFast.default)(tree, _removeProperties.default, opts); + return tree; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/retrievers/getBindingIdentifiers.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/retrievers/getBindingIdentifiers.js new file mode 100644 index 00000000000000..689b15e6a4cc38 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/retrievers/getBindingIdentifiers.js @@ -0,0 +1,95 @@ +"use strict"; + +exports.__esModule = true; +exports.default = getBindingIdentifiers; + +var _generated = require("../validators/generated"); + +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 ((0, _generated.isIdentifier)(id)) { + if (duplicates) { + var _ids = ids[id.name] = ids[id.name] || []; + + _ids.push(id); + } else { + ids[id.name] = id; + } + + continue; + } + + if ((0, _generated.isExportDeclaration)(id)) { + if ((0, _generated.isDeclaration)(id.declaration)) { + search.push(id.declaration); + } + + continue; + } + + if (outerOnly) { + if ((0, _generated.isFunctionDeclaration)(id)) { + search.push(id.id); + continue; + } + + if ((0, _generated.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"], + 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"], + ForInStatement: ["left"], + ForOfStatement: ["left"], + ClassDeclaration: ["id"], + ClassExpression: ["id"], + RestElement: ["argument"], + UpdateExpression: ["argument"], + ObjectProperty: ["value"], + AssignmentPattern: ["left"], + ArrayPattern: ["elements"], + ObjectPattern: ["properties"], + VariableDeclaration: ["declarations"], + VariableDeclarator: ["id"] +}; \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/retrievers/getOuterBindingIdentifiers.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/retrievers/getOuterBindingIdentifiers.js new file mode 100644 index 00000000000000..367f2d87a523eb --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/retrievers/getOuterBindingIdentifiers.js @@ -0,0 +1,12 @@ +"use strict"; + +exports.__esModule = true; +exports.default = getOuterBindingIdentifiers; + +var _getBindingIdentifiers = _interopRequireDefault(require("./getBindingIdentifiers")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function getOuterBindingIdentifiers(node, duplicates) { + return (0, _getBindingIdentifiers.default)(node, duplicates, true); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/traverse/traverse.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/traverse/traverse.js new file mode 100644 index 00000000000000..b51ed99de03a7e --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/traverse/traverse.js @@ -0,0 +1,64 @@ +"use strict"; + +exports.__esModule = true; +exports.default = traverse; + +var _definitions = require("../definitions"); + +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 = _definitions.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 _key2 = _ref2; + var subNode = node[_key2]; + + if (Array.isArray(subNode)) { + for (var i = 0; i < subNode.length; i++) { + var child = subNode[i]; + if (!child) continue; + ancestors.push({ + node: node, + key: _key2, + index: i + }); + traverseSimpleImpl(child, enter, exit, state, ancestors); + ancestors.pop(); + } + } else if (subNode) { + ancestors.push({ + node: node, + key: _key2 + }); + traverseSimpleImpl(subNode, enter, exit, state, ancestors); + ancestors.pop(); + } + } + + if (exit) exit(node, ancestors, state); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/traverse/traverseFast.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/traverse/traverseFast.js new file mode 100644 index 00000000000000..1ccd727f367aa7 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/traverse/traverseFast.js @@ -0,0 +1,50 @@ +"use strict"; + +exports.__esModule = true; +exports.default = traverseFast; + +var _definitions = require("../definitions"); + +function traverseFast(node, enter, opts) { + if (!node) return; + var keys = _definitions.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 _node2 = _ref2; + traverseFast(_node2, enter, opts); + } + } else { + traverseFast(subNode, enter, opts); + } + } +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/utils/inherit.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/utils/inherit.js new file mode 100644 index 00000000000000..6c57f50d239af4 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/utils/inherit.js @@ -0,0 +1,14 @@ +"use strict"; + +exports.__esModule = true; +exports.default = inherit; + +var _uniq = _interopRequireDefault(require("lodash/uniq")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function inherit(key, child, parent) { + if (child && parent) { + child[key] = (0, _uniq.default)([].concat(child[key], parent[key]).filter(Boolean)); + } +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/utils/react/cleanJSXElementLiteralChild.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/utils/react/cleanJSXElementLiteralChild.js new file mode 100644 index 00000000000000..84de7435c9aa11 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/utils/react/cleanJSXElementLiteralChild.js @@ -0,0 +1,45 @@ +"use strict"; + +exports.__esModule = true; +exports.default = cleanJSXElementLiteralChild; + +var _generated = require("../../builders/generated"); + +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((0, _generated.stringLiteral)(str)); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/utils/shallowEqual.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/utils/shallowEqual.js new file mode 100644 index 00000000000000..8969d543a854d7 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/utils/shallowEqual.js @@ -0,0 +1,19 @@ +"use strict"; + +exports.__esModule = true; +exports.default = shallowEqual; + +function shallowEqual(actual, expected) { + var keys = Object.keys(expected); + var _arr = keys; + + for (var _i = 0; _i < _arr.length; _i++) { + var key = _arr[_i]; + + if (actual[key] !== expected[key]) { + return false; + } + } + + return true; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/buildMatchMemberExpression.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/buildMatchMemberExpression.js new file mode 100644 index 00000000000000..5c5d242d196852 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/buildMatchMemberExpression.js @@ -0,0 +1,15 @@ +"use strict"; + +exports.__esModule = true; +exports.default = buildMatchMemberExpression; + +var _matchesPattern = _interopRequireDefault(require("./matchesPattern")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function buildMatchMemberExpression(match, allowPartial) { + var parts = match.split("."); + return function (member) { + return (0, _matchesPattern.default)(member, parts, allowPartial); + }; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/generated/index.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/generated/index.js new file mode 100644 index 00000000000000..684966d41dfe06 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/generated/index.js @@ -0,0 +1,1241 @@ +"use strict"; + +exports.__esModule = true; +exports.isArrayExpression = isArrayExpression; +exports.isAssignmentExpression = isAssignmentExpression; +exports.isBinaryExpression = isBinaryExpression; +exports.isDirective = isDirective; +exports.isDirectiveLiteral = isDirectiveLiteral; +exports.isBlockStatement = isBlockStatement; +exports.isBreakStatement = isBreakStatement; +exports.isCallExpression = isCallExpression; +exports.isCatchClause = isCatchClause; +exports.isConditionalExpression = isConditionalExpression; +exports.isContinueStatement = isContinueStatement; +exports.isDebuggerStatement = isDebuggerStatement; +exports.isDoWhileStatement = isDoWhileStatement; +exports.isEmptyStatement = isEmptyStatement; +exports.isExpressionStatement = isExpressionStatement; +exports.isFile = isFile; +exports.isForInStatement = isForInStatement; +exports.isForStatement = isForStatement; +exports.isFunctionDeclaration = isFunctionDeclaration; +exports.isFunctionExpression = isFunctionExpression; +exports.isIdentifier = isIdentifier; +exports.isIfStatement = isIfStatement; +exports.isLabeledStatement = isLabeledStatement; +exports.isStringLiteral = isStringLiteral; +exports.isNumericLiteral = isNumericLiteral; +exports.isNullLiteral = isNullLiteral; +exports.isBooleanLiteral = isBooleanLiteral; +exports.isRegExpLiteral = isRegExpLiteral; +exports.isLogicalExpression = isLogicalExpression; +exports.isMemberExpression = isMemberExpression; +exports.isNewExpression = isNewExpression; +exports.isProgram = isProgram; +exports.isObjectExpression = isObjectExpression; +exports.isObjectMethod = isObjectMethod; +exports.isObjectProperty = isObjectProperty; +exports.isRestElement = isRestElement; +exports.isReturnStatement = isReturnStatement; +exports.isSequenceExpression = isSequenceExpression; +exports.isSwitchCase = isSwitchCase; +exports.isSwitchStatement = isSwitchStatement; +exports.isThisExpression = isThisExpression; +exports.isThrowStatement = isThrowStatement; +exports.isTryStatement = isTryStatement; +exports.isUnaryExpression = isUnaryExpression; +exports.isUpdateExpression = isUpdateExpression; +exports.isVariableDeclaration = isVariableDeclaration; +exports.isVariableDeclarator = isVariableDeclarator; +exports.isWhileStatement = isWhileStatement; +exports.isWithStatement = isWithStatement; +exports.isAssignmentPattern = isAssignmentPattern; +exports.isArrayPattern = isArrayPattern; +exports.isArrowFunctionExpression = isArrowFunctionExpression; +exports.isClassBody = isClassBody; +exports.isClassDeclaration = isClassDeclaration; +exports.isClassExpression = isClassExpression; +exports.isExportAllDeclaration = isExportAllDeclaration; +exports.isExportDefaultDeclaration = isExportDefaultDeclaration; +exports.isExportNamedDeclaration = isExportNamedDeclaration; +exports.isExportSpecifier = isExportSpecifier; +exports.isForOfStatement = isForOfStatement; +exports.isImportDeclaration = isImportDeclaration; +exports.isImportDefaultSpecifier = isImportDefaultSpecifier; +exports.isImportNamespaceSpecifier = isImportNamespaceSpecifier; +exports.isImportSpecifier = isImportSpecifier; +exports.isMetaProperty = isMetaProperty; +exports.isClassMethod = isClassMethod; +exports.isObjectPattern = isObjectPattern; +exports.isSpreadElement = isSpreadElement; +exports.isSuper = isSuper; +exports.isTaggedTemplateExpression = isTaggedTemplateExpression; +exports.isTemplateElement = isTemplateElement; +exports.isTemplateLiteral = isTemplateLiteral; +exports.isYieldExpression = isYieldExpression; +exports.isAnyTypeAnnotation = isAnyTypeAnnotation; +exports.isArrayTypeAnnotation = isArrayTypeAnnotation; +exports.isBooleanTypeAnnotation = isBooleanTypeAnnotation; +exports.isBooleanLiteralTypeAnnotation = isBooleanLiteralTypeAnnotation; +exports.isNullLiteralTypeAnnotation = isNullLiteralTypeAnnotation; +exports.isClassImplements = isClassImplements; +exports.isDeclareClass = isDeclareClass; +exports.isDeclareFunction = isDeclareFunction; +exports.isDeclareInterface = isDeclareInterface; +exports.isDeclareModule = isDeclareModule; +exports.isDeclareModuleExports = isDeclareModuleExports; +exports.isDeclareTypeAlias = isDeclareTypeAlias; +exports.isDeclareOpaqueType = isDeclareOpaqueType; +exports.isDeclareVariable = isDeclareVariable; +exports.isDeclareExportDeclaration = isDeclareExportDeclaration; +exports.isDeclareExportAllDeclaration = isDeclareExportAllDeclaration; +exports.isDeclaredPredicate = isDeclaredPredicate; +exports.isExistsTypeAnnotation = isExistsTypeAnnotation; +exports.isFunctionTypeAnnotation = isFunctionTypeAnnotation; +exports.isFunctionTypeParam = isFunctionTypeParam; +exports.isGenericTypeAnnotation = isGenericTypeAnnotation; +exports.isInferredPredicate = isInferredPredicate; +exports.isInterfaceExtends = isInterfaceExtends; +exports.isInterfaceDeclaration = isInterfaceDeclaration; +exports.isIntersectionTypeAnnotation = isIntersectionTypeAnnotation; +exports.isMixedTypeAnnotation = isMixedTypeAnnotation; +exports.isEmptyTypeAnnotation = isEmptyTypeAnnotation; +exports.isNullableTypeAnnotation = isNullableTypeAnnotation; +exports.isNumberLiteralTypeAnnotation = isNumberLiteralTypeAnnotation; +exports.isNumberTypeAnnotation = isNumberTypeAnnotation; +exports.isObjectTypeAnnotation = isObjectTypeAnnotation; +exports.isObjectTypeCallProperty = isObjectTypeCallProperty; +exports.isObjectTypeIndexer = isObjectTypeIndexer; +exports.isObjectTypeProperty = isObjectTypeProperty; +exports.isObjectTypeSpreadProperty = isObjectTypeSpreadProperty; +exports.isOpaqueType = isOpaqueType; +exports.isQualifiedTypeIdentifier = isQualifiedTypeIdentifier; +exports.isStringLiteralTypeAnnotation = isStringLiteralTypeAnnotation; +exports.isStringTypeAnnotation = isStringTypeAnnotation; +exports.isThisTypeAnnotation = isThisTypeAnnotation; +exports.isTupleTypeAnnotation = isTupleTypeAnnotation; +exports.isTypeofTypeAnnotation = isTypeofTypeAnnotation; +exports.isTypeAlias = isTypeAlias; +exports.isTypeAnnotation = isTypeAnnotation; +exports.isTypeCastExpression = isTypeCastExpression; +exports.isTypeParameter = isTypeParameter; +exports.isTypeParameterDeclaration = isTypeParameterDeclaration; +exports.isTypeParameterInstantiation = isTypeParameterInstantiation; +exports.isUnionTypeAnnotation = isUnionTypeAnnotation; +exports.isVoidTypeAnnotation = isVoidTypeAnnotation; +exports.isJSXAttribute = isJSXAttribute; +exports.isJSXClosingElement = isJSXClosingElement; +exports.isJSXElement = isJSXElement; +exports.isJSXEmptyExpression = isJSXEmptyExpression; +exports.isJSXExpressionContainer = isJSXExpressionContainer; +exports.isJSXSpreadChild = isJSXSpreadChild; +exports.isJSXIdentifier = isJSXIdentifier; +exports.isJSXMemberExpression = isJSXMemberExpression; +exports.isJSXNamespacedName = isJSXNamespacedName; +exports.isJSXOpeningElement = isJSXOpeningElement; +exports.isJSXSpreadAttribute = isJSXSpreadAttribute; +exports.isJSXText = isJSXText; +exports.isJSXFragment = isJSXFragment; +exports.isJSXOpeningFragment = isJSXOpeningFragment; +exports.isJSXClosingFragment = isJSXClosingFragment; +exports.isNoop = isNoop; +exports.isParenthesizedExpression = isParenthesizedExpression; +exports.isAwaitExpression = isAwaitExpression; +exports.isBindExpression = isBindExpression; +exports.isClassProperty = isClassProperty; +exports.isImport = isImport; +exports.isDecorator = isDecorator; +exports.isDoExpression = isDoExpression; +exports.isExportDefaultSpecifier = isExportDefaultSpecifier; +exports.isExportNamespaceSpecifier = isExportNamespaceSpecifier; +exports.isTSParameterProperty = isTSParameterProperty; +exports.isTSDeclareFunction = isTSDeclareFunction; +exports.isTSDeclareMethod = isTSDeclareMethod; +exports.isTSQualifiedName = isTSQualifiedName; +exports.isTSCallSignatureDeclaration = isTSCallSignatureDeclaration; +exports.isTSConstructSignatureDeclaration = isTSConstructSignatureDeclaration; +exports.isTSPropertySignature = isTSPropertySignature; +exports.isTSMethodSignature = isTSMethodSignature; +exports.isTSIndexSignature = isTSIndexSignature; +exports.isTSAnyKeyword = isTSAnyKeyword; +exports.isTSNumberKeyword = isTSNumberKeyword; +exports.isTSObjectKeyword = isTSObjectKeyword; +exports.isTSBooleanKeyword = isTSBooleanKeyword; +exports.isTSStringKeyword = isTSStringKeyword; +exports.isTSSymbolKeyword = isTSSymbolKeyword; +exports.isTSVoidKeyword = isTSVoidKeyword; +exports.isTSUndefinedKeyword = isTSUndefinedKeyword; +exports.isTSNullKeyword = isTSNullKeyword; +exports.isTSNeverKeyword = isTSNeverKeyword; +exports.isTSThisType = isTSThisType; +exports.isTSFunctionType = isTSFunctionType; +exports.isTSConstructorType = isTSConstructorType; +exports.isTSTypeReference = isTSTypeReference; +exports.isTSTypePredicate = isTSTypePredicate; +exports.isTSTypeQuery = isTSTypeQuery; +exports.isTSTypeLiteral = isTSTypeLiteral; +exports.isTSArrayType = isTSArrayType; +exports.isTSTupleType = isTSTupleType; +exports.isTSUnionType = isTSUnionType; +exports.isTSIntersectionType = isTSIntersectionType; +exports.isTSParenthesizedType = isTSParenthesizedType; +exports.isTSTypeOperator = isTSTypeOperator; +exports.isTSIndexedAccessType = isTSIndexedAccessType; +exports.isTSMappedType = isTSMappedType; +exports.isTSLiteralType = isTSLiteralType; +exports.isTSExpressionWithTypeArguments = isTSExpressionWithTypeArguments; +exports.isTSInterfaceDeclaration = isTSInterfaceDeclaration; +exports.isTSInterfaceBody = isTSInterfaceBody; +exports.isTSTypeAliasDeclaration = isTSTypeAliasDeclaration; +exports.isTSAsExpression = isTSAsExpression; +exports.isTSTypeAssertion = isTSTypeAssertion; +exports.isTSEnumDeclaration = isTSEnumDeclaration; +exports.isTSEnumMember = isTSEnumMember; +exports.isTSModuleDeclaration = isTSModuleDeclaration; +exports.isTSModuleBlock = isTSModuleBlock; +exports.isTSImportEqualsDeclaration = isTSImportEqualsDeclaration; +exports.isTSExternalModuleReference = isTSExternalModuleReference; +exports.isTSNonNullExpression = isTSNonNullExpression; +exports.isTSExportAssignment = isTSExportAssignment; +exports.isTSNamespaceExportDeclaration = isTSNamespaceExportDeclaration; +exports.isTSTypeAnnotation = isTSTypeAnnotation; +exports.isTSTypeParameterInstantiation = isTSTypeParameterInstantiation; +exports.isTSTypeParameterDeclaration = isTSTypeParameterDeclaration; +exports.isTSTypeParameter = isTSTypeParameter; +exports.isExpression = isExpression; +exports.isBinary = isBinary; +exports.isScopable = isScopable; +exports.isBlockParent = isBlockParent; +exports.isBlock = isBlock; +exports.isStatement = isStatement; +exports.isTerminatorless = isTerminatorless; +exports.isCompletionStatement = isCompletionStatement; +exports.isConditional = isConditional; +exports.isLoop = isLoop; +exports.isWhile = isWhile; +exports.isExpressionWrapper = isExpressionWrapper; +exports.isFor = isFor; +exports.isForXStatement = isForXStatement; +exports.isFunction = isFunction; +exports.isFunctionParent = isFunctionParent; +exports.isPureish = isPureish; +exports.isDeclaration = isDeclaration; +exports.isPatternLike = isPatternLike; +exports.isLVal = isLVal; +exports.isTSEntityName = isTSEntityName; +exports.isLiteral = isLiteral; +exports.isImmutable = isImmutable; +exports.isUserWhitespacable = isUserWhitespacable; +exports.isMethod = isMethod; +exports.isObjectMember = isObjectMember; +exports.isProperty = isProperty; +exports.isUnaryLike = isUnaryLike; +exports.isPattern = isPattern; +exports.isClass = isClass; +exports.isModuleDeclaration = isModuleDeclaration; +exports.isExportDeclaration = isExportDeclaration; +exports.isModuleSpecifier = isModuleSpecifier; +exports.isFlow = isFlow; +exports.isFlowBaseAnnotation = isFlowBaseAnnotation; +exports.isFlowDeclaration = isFlowDeclaration; +exports.isFlowPredicate = isFlowPredicate; +exports.isJSX = isJSX; +exports.isTSTypeElement = isTSTypeElement; +exports.isTSType = isTSType; +exports.isNumberLiteral = isNumberLiteral; +exports.isRegexLiteral = isRegexLiteral; +exports.isRestProperty = isRestProperty; +exports.isSpreadProperty = isSpreadProperty; + +var _is = _interopRequireDefault(require("../is")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function isArrayExpression(node, opts) { + return (0, _is.default)("ArrayExpression", node, opts); +} + +function isAssignmentExpression(node, opts) { + return (0, _is.default)("AssignmentExpression", node, opts); +} + +function isBinaryExpression(node, opts) { + return (0, _is.default)("BinaryExpression", node, opts); +} + +function isDirective(node, opts) { + return (0, _is.default)("Directive", node, opts); +} + +function isDirectiveLiteral(node, opts) { + return (0, _is.default)("DirectiveLiteral", node, opts); +} + +function isBlockStatement(node, opts) { + return (0, _is.default)("BlockStatement", node, opts); +} + +function isBreakStatement(node, opts) { + return (0, _is.default)("BreakStatement", node, opts); +} + +function isCallExpression(node, opts) { + return (0, _is.default)("CallExpression", node, opts); +} + +function isCatchClause(node, opts) { + return (0, _is.default)("CatchClause", node, opts); +} + +function isConditionalExpression(node, opts) { + return (0, _is.default)("ConditionalExpression", node, opts); +} + +function isContinueStatement(node, opts) { + return (0, _is.default)("ContinueStatement", node, opts); +} + +function isDebuggerStatement(node, opts) { + return (0, _is.default)("DebuggerStatement", node, opts); +} + +function isDoWhileStatement(node, opts) { + return (0, _is.default)("DoWhileStatement", node, opts); +} + +function isEmptyStatement(node, opts) { + return (0, _is.default)("EmptyStatement", node, opts); +} + +function isExpressionStatement(node, opts) { + return (0, _is.default)("ExpressionStatement", node, opts); +} + +function isFile(node, opts) { + return (0, _is.default)("File", node, opts); +} + +function isForInStatement(node, opts) { + return (0, _is.default)("ForInStatement", node, opts); +} + +function isForStatement(node, opts) { + return (0, _is.default)("ForStatement", node, opts); +} + +function isFunctionDeclaration(node, opts) { + return (0, _is.default)("FunctionDeclaration", node, opts); +} + +function isFunctionExpression(node, opts) { + return (0, _is.default)("FunctionExpression", node, opts); +} + +function isIdentifier(node, opts) { + return (0, _is.default)("Identifier", node, opts); +} + +function isIfStatement(node, opts) { + return (0, _is.default)("IfStatement", node, opts); +} + +function isLabeledStatement(node, opts) { + return (0, _is.default)("LabeledStatement", node, opts); +} + +function isStringLiteral(node, opts) { + return (0, _is.default)("StringLiteral", node, opts); +} + +function isNumericLiteral(node, opts) { + return (0, _is.default)("NumericLiteral", node, opts); +} + +function isNullLiteral(node, opts) { + return (0, _is.default)("NullLiteral", node, opts); +} + +function isBooleanLiteral(node, opts) { + return (0, _is.default)("BooleanLiteral", node, opts); +} + +function isRegExpLiteral(node, opts) { + return (0, _is.default)("RegExpLiteral", node, opts); +} + +function isLogicalExpression(node, opts) { + return (0, _is.default)("LogicalExpression", node, opts); +} + +function isMemberExpression(node, opts) { + return (0, _is.default)("MemberExpression", node, opts); +} + +function isNewExpression(node, opts) { + return (0, _is.default)("NewExpression", node, opts); +} + +function isProgram(node, opts) { + return (0, _is.default)("Program", node, opts); +} + +function isObjectExpression(node, opts) { + return (0, _is.default)("ObjectExpression", node, opts); +} + +function isObjectMethod(node, opts) { + return (0, _is.default)("ObjectMethod", node, opts); +} + +function isObjectProperty(node, opts) { + return (0, _is.default)("ObjectProperty", node, opts); +} + +function isRestElement(node, opts) { + return (0, _is.default)("RestElement", node, opts); +} + +function isReturnStatement(node, opts) { + return (0, _is.default)("ReturnStatement", node, opts); +} + +function isSequenceExpression(node, opts) { + return (0, _is.default)("SequenceExpression", node, opts); +} + +function isSwitchCase(node, opts) { + return (0, _is.default)("SwitchCase", node, opts); +} + +function isSwitchStatement(node, opts) { + return (0, _is.default)("SwitchStatement", node, opts); +} + +function isThisExpression(node, opts) { + return (0, _is.default)("ThisExpression", node, opts); +} + +function isThrowStatement(node, opts) { + return (0, _is.default)("ThrowStatement", node, opts); +} + +function isTryStatement(node, opts) { + return (0, _is.default)("TryStatement", node, opts); +} + +function isUnaryExpression(node, opts) { + return (0, _is.default)("UnaryExpression", node, opts); +} + +function isUpdateExpression(node, opts) { + return (0, _is.default)("UpdateExpression", node, opts); +} + +function isVariableDeclaration(node, opts) { + return (0, _is.default)("VariableDeclaration", node, opts); +} + +function isVariableDeclarator(node, opts) { + return (0, _is.default)("VariableDeclarator", node, opts); +} + +function isWhileStatement(node, opts) { + return (0, _is.default)("WhileStatement", node, opts); +} + +function isWithStatement(node, opts) { + return (0, _is.default)("WithStatement", node, opts); +} + +function isAssignmentPattern(node, opts) { + return (0, _is.default)("AssignmentPattern", node, opts); +} + +function isArrayPattern(node, opts) { + return (0, _is.default)("ArrayPattern", node, opts); +} + +function isArrowFunctionExpression(node, opts) { + return (0, _is.default)("ArrowFunctionExpression", node, opts); +} + +function isClassBody(node, opts) { + return (0, _is.default)("ClassBody", node, opts); +} + +function isClassDeclaration(node, opts) { + return (0, _is.default)("ClassDeclaration", node, opts); +} + +function isClassExpression(node, opts) { + return (0, _is.default)("ClassExpression", node, opts); +} + +function isExportAllDeclaration(node, opts) { + return (0, _is.default)("ExportAllDeclaration", node, opts); +} + +function isExportDefaultDeclaration(node, opts) { + return (0, _is.default)("ExportDefaultDeclaration", node, opts); +} + +function isExportNamedDeclaration(node, opts) { + return (0, _is.default)("ExportNamedDeclaration", node, opts); +} + +function isExportSpecifier(node, opts) { + return (0, _is.default)("ExportSpecifier", node, opts); +} + +function isForOfStatement(node, opts) { + return (0, _is.default)("ForOfStatement", node, opts); +} + +function isImportDeclaration(node, opts) { + return (0, _is.default)("ImportDeclaration", node, opts); +} + +function isImportDefaultSpecifier(node, opts) { + return (0, _is.default)("ImportDefaultSpecifier", node, opts); +} + +function isImportNamespaceSpecifier(node, opts) { + return (0, _is.default)("ImportNamespaceSpecifier", node, opts); +} + +function isImportSpecifier(node, opts) { + return (0, _is.default)("ImportSpecifier", node, opts); +} + +function isMetaProperty(node, opts) { + return (0, _is.default)("MetaProperty", node, opts); +} + +function isClassMethod(node, opts) { + return (0, _is.default)("ClassMethod", node, opts); +} + +function isObjectPattern(node, opts) { + return (0, _is.default)("ObjectPattern", node, opts); +} + +function isSpreadElement(node, opts) { + return (0, _is.default)("SpreadElement", node, opts); +} + +function isSuper(node, opts) { + return (0, _is.default)("Super", node, opts); +} + +function isTaggedTemplateExpression(node, opts) { + return (0, _is.default)("TaggedTemplateExpression", node, opts); +} + +function isTemplateElement(node, opts) { + return (0, _is.default)("TemplateElement", node, opts); +} + +function isTemplateLiteral(node, opts) { + return (0, _is.default)("TemplateLiteral", node, opts); +} + +function isYieldExpression(node, opts) { + return (0, _is.default)("YieldExpression", node, opts); +} + +function isAnyTypeAnnotation(node, opts) { + return (0, _is.default)("AnyTypeAnnotation", node, opts); +} + +function isArrayTypeAnnotation(node, opts) { + return (0, _is.default)("ArrayTypeAnnotation", node, opts); +} + +function isBooleanTypeAnnotation(node, opts) { + return (0, _is.default)("BooleanTypeAnnotation", node, opts); +} + +function isBooleanLiteralTypeAnnotation(node, opts) { + return (0, _is.default)("BooleanLiteralTypeAnnotation", node, opts); +} + +function isNullLiteralTypeAnnotation(node, opts) { + return (0, _is.default)("NullLiteralTypeAnnotation", node, opts); +} + +function isClassImplements(node, opts) { + return (0, _is.default)("ClassImplements", node, opts); +} + +function isDeclareClass(node, opts) { + return (0, _is.default)("DeclareClass", node, opts); +} + +function isDeclareFunction(node, opts) { + return (0, _is.default)("DeclareFunction", node, opts); +} + +function isDeclareInterface(node, opts) { + return (0, _is.default)("DeclareInterface", node, opts); +} + +function isDeclareModule(node, opts) { + return (0, _is.default)("DeclareModule", node, opts); +} + +function isDeclareModuleExports(node, opts) { + return (0, _is.default)("DeclareModuleExports", node, opts); +} + +function isDeclareTypeAlias(node, opts) { + return (0, _is.default)("DeclareTypeAlias", node, opts); +} + +function isDeclareOpaqueType(node, opts) { + return (0, _is.default)("DeclareOpaqueType", node, opts); +} + +function isDeclareVariable(node, opts) { + return (0, _is.default)("DeclareVariable", node, opts); +} + +function isDeclareExportDeclaration(node, opts) { + return (0, _is.default)("DeclareExportDeclaration", node, opts); +} + +function isDeclareExportAllDeclaration(node, opts) { + return (0, _is.default)("DeclareExportAllDeclaration", node, opts); +} + +function isDeclaredPredicate(node, opts) { + return (0, _is.default)("DeclaredPredicate", node, opts); +} + +function isExistsTypeAnnotation(node, opts) { + return (0, _is.default)("ExistsTypeAnnotation", node, opts); +} + +function isFunctionTypeAnnotation(node, opts) { + return (0, _is.default)("FunctionTypeAnnotation", node, opts); +} + +function isFunctionTypeParam(node, opts) { + return (0, _is.default)("FunctionTypeParam", node, opts); +} + +function isGenericTypeAnnotation(node, opts) { + return (0, _is.default)("GenericTypeAnnotation", node, opts); +} + +function isInferredPredicate(node, opts) { + return (0, _is.default)("InferredPredicate", node, opts); +} + +function isInterfaceExtends(node, opts) { + return (0, _is.default)("InterfaceExtends", node, opts); +} + +function isInterfaceDeclaration(node, opts) { + return (0, _is.default)("InterfaceDeclaration", node, opts); +} + +function isIntersectionTypeAnnotation(node, opts) { + return (0, _is.default)("IntersectionTypeAnnotation", node, opts); +} + +function isMixedTypeAnnotation(node, opts) { + return (0, _is.default)("MixedTypeAnnotation", node, opts); +} + +function isEmptyTypeAnnotation(node, opts) { + return (0, _is.default)("EmptyTypeAnnotation", node, opts); +} + +function isNullableTypeAnnotation(node, opts) { + return (0, _is.default)("NullableTypeAnnotation", node, opts); +} + +function isNumberLiteralTypeAnnotation(node, opts) { + return (0, _is.default)("NumberLiteralTypeAnnotation", node, opts); +} + +function isNumberTypeAnnotation(node, opts) { + return (0, _is.default)("NumberTypeAnnotation", node, opts); +} + +function isObjectTypeAnnotation(node, opts) { + return (0, _is.default)("ObjectTypeAnnotation", node, opts); +} + +function isObjectTypeCallProperty(node, opts) { + return (0, _is.default)("ObjectTypeCallProperty", node, opts); +} + +function isObjectTypeIndexer(node, opts) { + return (0, _is.default)("ObjectTypeIndexer", node, opts); +} + +function isObjectTypeProperty(node, opts) { + return (0, _is.default)("ObjectTypeProperty", node, opts); +} + +function isObjectTypeSpreadProperty(node, opts) { + return (0, _is.default)("ObjectTypeSpreadProperty", node, opts); +} + +function isOpaqueType(node, opts) { + return (0, _is.default)("OpaqueType", node, opts); +} + +function isQualifiedTypeIdentifier(node, opts) { + return (0, _is.default)("QualifiedTypeIdentifier", node, opts); +} + +function isStringLiteralTypeAnnotation(node, opts) { + return (0, _is.default)("StringLiteralTypeAnnotation", node, opts); +} + +function isStringTypeAnnotation(node, opts) { + return (0, _is.default)("StringTypeAnnotation", node, opts); +} + +function isThisTypeAnnotation(node, opts) { + return (0, _is.default)("ThisTypeAnnotation", node, opts); +} + +function isTupleTypeAnnotation(node, opts) { + return (0, _is.default)("TupleTypeAnnotation", node, opts); +} + +function isTypeofTypeAnnotation(node, opts) { + return (0, _is.default)("TypeofTypeAnnotation", node, opts); +} + +function isTypeAlias(node, opts) { + return (0, _is.default)("TypeAlias", node, opts); +} + +function isTypeAnnotation(node, opts) { + return (0, _is.default)("TypeAnnotation", node, opts); +} + +function isTypeCastExpression(node, opts) { + return (0, _is.default)("TypeCastExpression", node, opts); +} + +function isTypeParameter(node, opts) { + return (0, _is.default)("TypeParameter", node, opts); +} + +function isTypeParameterDeclaration(node, opts) { + return (0, _is.default)("TypeParameterDeclaration", node, opts); +} + +function isTypeParameterInstantiation(node, opts) { + return (0, _is.default)("TypeParameterInstantiation", node, opts); +} + +function isUnionTypeAnnotation(node, opts) { + return (0, _is.default)("UnionTypeAnnotation", node, opts); +} + +function isVoidTypeAnnotation(node, opts) { + return (0, _is.default)("VoidTypeAnnotation", node, opts); +} + +function isJSXAttribute(node, opts) { + return (0, _is.default)("JSXAttribute", node, opts); +} + +function isJSXClosingElement(node, opts) { + return (0, _is.default)("JSXClosingElement", node, opts); +} + +function isJSXElement(node, opts) { + return (0, _is.default)("JSXElement", node, opts); +} + +function isJSXEmptyExpression(node, opts) { + return (0, _is.default)("JSXEmptyExpression", node, opts); +} + +function isJSXExpressionContainer(node, opts) { + return (0, _is.default)("JSXExpressionContainer", node, opts); +} + +function isJSXSpreadChild(node, opts) { + return (0, _is.default)("JSXSpreadChild", node, opts); +} + +function isJSXIdentifier(node, opts) { + return (0, _is.default)("JSXIdentifier", node, opts); +} + +function isJSXMemberExpression(node, opts) { + return (0, _is.default)("JSXMemberExpression", node, opts); +} + +function isJSXNamespacedName(node, opts) { + return (0, _is.default)("JSXNamespacedName", node, opts); +} + +function isJSXOpeningElement(node, opts) { + return (0, _is.default)("JSXOpeningElement", node, opts); +} + +function isJSXSpreadAttribute(node, opts) { + return (0, _is.default)("JSXSpreadAttribute", node, opts); +} + +function isJSXText(node, opts) { + return (0, _is.default)("JSXText", node, opts); +} + +function isJSXFragment(node, opts) { + return (0, _is.default)("JSXFragment", node, opts); +} + +function isJSXOpeningFragment(node, opts) { + return (0, _is.default)("JSXOpeningFragment", node, opts); +} + +function isJSXClosingFragment(node, opts) { + return (0, _is.default)("JSXClosingFragment", node, opts); +} + +function isNoop(node, opts) { + return (0, _is.default)("Noop", node, opts); +} + +function isParenthesizedExpression(node, opts) { + return (0, _is.default)("ParenthesizedExpression", node, opts); +} + +function isAwaitExpression(node, opts) { + return (0, _is.default)("AwaitExpression", node, opts); +} + +function isBindExpression(node, opts) { + return (0, _is.default)("BindExpression", node, opts); +} + +function isClassProperty(node, opts) { + return (0, _is.default)("ClassProperty", node, opts); +} + +function isImport(node, opts) { + return (0, _is.default)("Import", node, opts); +} + +function isDecorator(node, opts) { + return (0, _is.default)("Decorator", node, opts); +} + +function isDoExpression(node, opts) { + return (0, _is.default)("DoExpression", node, opts); +} + +function isExportDefaultSpecifier(node, opts) { + return (0, _is.default)("ExportDefaultSpecifier", node, opts); +} + +function isExportNamespaceSpecifier(node, opts) { + return (0, _is.default)("ExportNamespaceSpecifier", node, opts); +} + +function isTSParameterProperty(node, opts) { + return (0, _is.default)("TSParameterProperty", node, opts); +} + +function isTSDeclareFunction(node, opts) { + return (0, _is.default)("TSDeclareFunction", node, opts); +} + +function isTSDeclareMethod(node, opts) { + return (0, _is.default)("TSDeclareMethod", node, opts); +} + +function isTSQualifiedName(node, opts) { + return (0, _is.default)("TSQualifiedName", node, opts); +} + +function isTSCallSignatureDeclaration(node, opts) { + return (0, _is.default)("TSCallSignatureDeclaration", node, opts); +} + +function isTSConstructSignatureDeclaration(node, opts) { + return (0, _is.default)("TSConstructSignatureDeclaration", node, opts); +} + +function isTSPropertySignature(node, opts) { + return (0, _is.default)("TSPropertySignature", node, opts); +} + +function isTSMethodSignature(node, opts) { + return (0, _is.default)("TSMethodSignature", node, opts); +} + +function isTSIndexSignature(node, opts) { + return (0, _is.default)("TSIndexSignature", node, opts); +} + +function isTSAnyKeyword(node, opts) { + return (0, _is.default)("TSAnyKeyword", node, opts); +} + +function isTSNumberKeyword(node, opts) { + return (0, _is.default)("TSNumberKeyword", node, opts); +} + +function isTSObjectKeyword(node, opts) { + return (0, _is.default)("TSObjectKeyword", node, opts); +} + +function isTSBooleanKeyword(node, opts) { + return (0, _is.default)("TSBooleanKeyword", node, opts); +} + +function isTSStringKeyword(node, opts) { + return (0, _is.default)("TSStringKeyword", node, opts); +} + +function isTSSymbolKeyword(node, opts) { + return (0, _is.default)("TSSymbolKeyword", node, opts); +} + +function isTSVoidKeyword(node, opts) { + return (0, _is.default)("TSVoidKeyword", node, opts); +} + +function isTSUndefinedKeyword(node, opts) { + return (0, _is.default)("TSUndefinedKeyword", node, opts); +} + +function isTSNullKeyword(node, opts) { + return (0, _is.default)("TSNullKeyword", node, opts); +} + +function isTSNeverKeyword(node, opts) { + return (0, _is.default)("TSNeverKeyword", node, opts); +} + +function isTSThisType(node, opts) { + return (0, _is.default)("TSThisType", node, opts); +} + +function isTSFunctionType(node, opts) { + return (0, _is.default)("TSFunctionType", node, opts); +} + +function isTSConstructorType(node, opts) { + return (0, _is.default)("TSConstructorType", node, opts); +} + +function isTSTypeReference(node, opts) { + return (0, _is.default)("TSTypeReference", node, opts); +} + +function isTSTypePredicate(node, opts) { + return (0, _is.default)("TSTypePredicate", node, opts); +} + +function isTSTypeQuery(node, opts) { + return (0, _is.default)("TSTypeQuery", node, opts); +} + +function isTSTypeLiteral(node, opts) { + return (0, _is.default)("TSTypeLiteral", node, opts); +} + +function isTSArrayType(node, opts) { + return (0, _is.default)("TSArrayType", node, opts); +} + +function isTSTupleType(node, opts) { + return (0, _is.default)("TSTupleType", node, opts); +} + +function isTSUnionType(node, opts) { + return (0, _is.default)("TSUnionType", node, opts); +} + +function isTSIntersectionType(node, opts) { + return (0, _is.default)("TSIntersectionType", node, opts); +} + +function isTSParenthesizedType(node, opts) { + return (0, _is.default)("TSParenthesizedType", node, opts); +} + +function isTSTypeOperator(node, opts) { + return (0, _is.default)("TSTypeOperator", node, opts); +} + +function isTSIndexedAccessType(node, opts) { + return (0, _is.default)("TSIndexedAccessType", node, opts); +} + +function isTSMappedType(node, opts) { + return (0, _is.default)("TSMappedType", node, opts); +} + +function isTSLiteralType(node, opts) { + return (0, _is.default)("TSLiteralType", node, opts); +} + +function isTSExpressionWithTypeArguments(node, opts) { + return (0, _is.default)("TSExpressionWithTypeArguments", node, opts); +} + +function isTSInterfaceDeclaration(node, opts) { + return (0, _is.default)("TSInterfaceDeclaration", node, opts); +} + +function isTSInterfaceBody(node, opts) { + return (0, _is.default)("TSInterfaceBody", node, opts); +} + +function isTSTypeAliasDeclaration(node, opts) { + return (0, _is.default)("TSTypeAliasDeclaration", node, opts); +} + +function isTSAsExpression(node, opts) { + return (0, _is.default)("TSAsExpression", node, opts); +} + +function isTSTypeAssertion(node, opts) { + return (0, _is.default)("TSTypeAssertion", node, opts); +} + +function isTSEnumDeclaration(node, opts) { + return (0, _is.default)("TSEnumDeclaration", node, opts); +} + +function isTSEnumMember(node, opts) { + return (0, _is.default)("TSEnumMember", node, opts); +} + +function isTSModuleDeclaration(node, opts) { + return (0, _is.default)("TSModuleDeclaration", node, opts); +} + +function isTSModuleBlock(node, opts) { + return (0, _is.default)("TSModuleBlock", node, opts); +} + +function isTSImportEqualsDeclaration(node, opts) { + return (0, _is.default)("TSImportEqualsDeclaration", node, opts); +} + +function isTSExternalModuleReference(node, opts) { + return (0, _is.default)("TSExternalModuleReference", node, opts); +} + +function isTSNonNullExpression(node, opts) { + return (0, _is.default)("TSNonNullExpression", node, opts); +} + +function isTSExportAssignment(node, opts) { + return (0, _is.default)("TSExportAssignment", node, opts); +} + +function isTSNamespaceExportDeclaration(node, opts) { + return (0, _is.default)("TSNamespaceExportDeclaration", node, opts); +} + +function isTSTypeAnnotation(node, opts) { + return (0, _is.default)("TSTypeAnnotation", node, opts); +} + +function isTSTypeParameterInstantiation(node, opts) { + return (0, _is.default)("TSTypeParameterInstantiation", node, opts); +} + +function isTSTypeParameterDeclaration(node, opts) { + return (0, _is.default)("TSTypeParameterDeclaration", node, opts); +} + +function isTSTypeParameter(node, opts) { + return (0, _is.default)("TSTypeParameter", node, opts); +} + +function isExpression(node, opts) { + return (0, _is.default)("Expression", node, opts); +} + +function isBinary(node, opts) { + return (0, _is.default)("Binary", node, opts); +} + +function isScopable(node, opts) { + return (0, _is.default)("Scopable", node, opts); +} + +function isBlockParent(node, opts) { + return (0, _is.default)("BlockParent", node, opts); +} + +function isBlock(node, opts) { + return (0, _is.default)("Block", node, opts); +} + +function isStatement(node, opts) { + return (0, _is.default)("Statement", node, opts); +} + +function isTerminatorless(node, opts) { + return (0, _is.default)("Terminatorless", node, opts); +} + +function isCompletionStatement(node, opts) { + return (0, _is.default)("CompletionStatement", node, opts); +} + +function isConditional(node, opts) { + return (0, _is.default)("Conditional", node, opts); +} + +function isLoop(node, opts) { + return (0, _is.default)("Loop", node, opts); +} + +function isWhile(node, opts) { + return (0, _is.default)("While", node, opts); +} + +function isExpressionWrapper(node, opts) { + return (0, _is.default)("ExpressionWrapper", node, opts); +} + +function isFor(node, opts) { + return (0, _is.default)("For", node, opts); +} + +function isForXStatement(node, opts) { + return (0, _is.default)("ForXStatement", node, opts); +} + +function isFunction(node, opts) { + return (0, _is.default)("Function", node, opts); +} + +function isFunctionParent(node, opts) { + return (0, _is.default)("FunctionParent", node, opts); +} + +function isPureish(node, opts) { + return (0, _is.default)("Pureish", node, opts); +} + +function isDeclaration(node, opts) { + return (0, _is.default)("Declaration", node, opts); +} + +function isPatternLike(node, opts) { + return (0, _is.default)("PatternLike", node, opts); +} + +function isLVal(node, opts) { + return (0, _is.default)("LVal", node, opts); +} + +function isTSEntityName(node, opts) { + return (0, _is.default)("TSEntityName", node, opts); +} + +function isLiteral(node, opts) { + return (0, _is.default)("Literal", node, opts); +} + +function isImmutable(node, opts) { + return (0, _is.default)("Immutable", node, opts); +} + +function isUserWhitespacable(node, opts) { + return (0, _is.default)("UserWhitespacable", node, opts); +} + +function isMethod(node, opts) { + return (0, _is.default)("Method", node, opts); +} + +function isObjectMember(node, opts) { + return (0, _is.default)("ObjectMember", node, opts); +} + +function isProperty(node, opts) { + return (0, _is.default)("Property", node, opts); +} + +function isUnaryLike(node, opts) { + return (0, _is.default)("UnaryLike", node, opts); +} + +function isPattern(node, opts) { + return (0, _is.default)("Pattern", node, opts); +} + +function isClass(node, opts) { + return (0, _is.default)("Class", node, opts); +} + +function isModuleDeclaration(node, opts) { + return (0, _is.default)("ModuleDeclaration", node, opts); +} + +function isExportDeclaration(node, opts) { + return (0, _is.default)("ExportDeclaration", node, opts); +} + +function isModuleSpecifier(node, opts) { + return (0, _is.default)("ModuleSpecifier", node, opts); +} + +function isFlow(node, opts) { + return (0, _is.default)("Flow", node, opts); +} + +function isFlowBaseAnnotation(node, opts) { + return (0, _is.default)("FlowBaseAnnotation", node, opts); +} + +function isFlowDeclaration(node, opts) { + return (0, _is.default)("FlowDeclaration", node, opts); +} + +function isFlowPredicate(node, opts) { + return (0, _is.default)("FlowPredicate", node, opts); +} + +function isJSX(node, opts) { + return (0, _is.default)("JSX", node, opts); +} + +function isTSTypeElement(node, opts) { + return (0, _is.default)("TSTypeElement", node, opts); +} + +function isTSType(node, opts) { + return (0, _is.default)("TSType", node, opts); +} + +function isNumberLiteral(node, opts) { + console.trace("The node type NumberLiteral has been renamed to NumericLiteral"); + return (0, _is.default)("NumberLiteral", node, opts); +} + +function isRegexLiteral(node, opts) { + console.trace("The node type RegexLiteral has been renamed to RegExpLiteral"); + return (0, _is.default)("RegexLiteral", node, opts); +} + +function isRestProperty(node, opts) { + console.trace("The node type RestProperty has been renamed to RestElement"); + return (0, _is.default)("RestProperty", node, opts); +} + +function isSpreadProperty(node, opts) { + console.trace("The node type SpreadProperty has been renamed to SpreadElement"); + return (0, _is.default)("SpreadProperty", node, opts); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/is.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/is.js new file mode 100644 index 00000000000000..c1e50d857b94a8 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/is.js @@ -0,0 +1,22 @@ +"use strict"; + +exports.__esModule = true; +exports.default = is; + +var _shallowEqual = _interopRequireDefault(require("../utils/shallowEqual")); + +var _isType = _interopRequireDefault(require("./isType")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function is(type, node, opts) { + if (!node) return false; + var matches = (0, _isType.default)(node.type, type); + if (!matches) return false; + + if (typeof opts === "undefined") { + return true; + } else { + return (0, _shallowEqual.default)(node, opts); + } +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isBinding.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isBinding.js new file mode 100644 index 00000000000000..3644879cdde3c4 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isBinding.js @@ -0,0 +1,27 @@ +"use strict"; + +exports.__esModule = true; +exports.default = isBinding; + +var _getBindingIdentifiers = _interopRequireDefault(require("../retrievers/getBindingIdentifiers")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function isBinding(node, parent) { + var keys = _getBindingIdentifiers.default.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; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isBlockScoped.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isBlockScoped.js new file mode 100644 index 00000000000000..da5c53fce452a4 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isBlockScoped.js @@ -0,0 +1,14 @@ +"use strict"; + +exports.__esModule = true; +exports.default = isBlockScoped; + +var _generated = require("./generated"); + +var _isLet = _interopRequireDefault(require("./isLet")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function isBlockScoped(node) { + return (0, _generated.isFunctionDeclaration)(node) || (0, _generated.isClassDeclaration)(node) || (0, _isLet.default)(node); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isImmutable.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isImmutable.js new file mode 100644 index 00000000000000..2ea002713e0de7 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isImmutable.js @@ -0,0 +1,24 @@ +"use strict"; + +exports.__esModule = true; +exports.default = isImmutable; + +var _isType = _interopRequireDefault(require("./isType")); + +var _generated = require("./generated"); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function isImmutable(node) { + if ((0, _isType.default)(node.type, "Immutable")) return true; + + if ((0, _generated.isIdentifier)(node)) { + if (node.name === "undefined") { + return true; + } else { + return false; + } + } + + return false; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isLet.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isLet.js new file mode 100644 index 00000000000000..a3a6169a030fa1 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isLet.js @@ -0,0 +1,12 @@ +"use strict"; + +exports.__esModule = true; +exports.default = isLet; + +var _generated = require("./generated"); + +var _constants = require("../constants"); + +function isLet(node) { + return (0, _generated.isVariableDeclaration)(node) && (node.kind !== "var" || node[_constants.BLOCK_SCOPED_SYMBOL]); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isNode.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isNode.js new file mode 100644 index 00000000000000..641cb9c52b46c2 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isNode.js @@ -0,0 +1,10 @@ +"use strict"; + +exports.__esModule = true; +exports.default = isNode; + +var _definitions = require("../definitions"); + +function isNode(node) { + return !!(node && _definitions.VISITOR_KEYS[node.type]); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isNodesEquivalent.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isNodesEquivalent.js new file mode 100644 index 00000000000000..549c0b470ff1d9 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isNodesEquivalent.js @@ -0,0 +1,50 @@ +"use strict"; + +exports.__esModule = true; +exports.default = isNodesEquivalent; + +var _definitions = require("../definitions"); + +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(_definitions.NODE_FIELDS[a.type] || a.type); + + for (var _i = 0; _i < fields.length; _i++) { + var field = fields[_i]; + + if (typeof a[field] !== typeof b[field]) { + 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 (!isNodesEquivalent(a[field], b[field])) { + return false; + } + } + + return true; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isReferenced.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isReferenced.js new file mode 100644 index 00000000000000..5bb68b4ad44001 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isReferenced.js @@ -0,0 +1,99 @@ +"use strict"; + +exports.__esModule = true; +exports.default = isReferenced; + +function isReferenced(node, parent) { + switch (parent.type) { + case "BindExpression": + return parent.object === node || parent.callee === node; + + case "MemberExpression": + case "JSXMemberExpression": + if (parent.property === node && parent.computed) { + return true; + } else if (parent.object === node) { + return true; + } else { + return false; + } + + case "MetaProperty": + return false; + + case "ObjectProperty": + if (parent.key === node) { + return parent.computed; + } + + case "VariableDeclarator": + return parent.id !== node; + + case "ArrowFunctionExpression": + case "FunctionDeclaration": + case "FunctionExpression": + var _arr = parent.params; + + for (var _i = 0; _i < _arr.length; _i++) { + var param = _arr[_i]; + if (param === node) return false; + } + + return parent.id !== node; + + case "ExportSpecifier": + if (parent.source) { + return false; + } else { + return parent.local === node; + } + + case "ExportNamespaceSpecifier": + case "ExportDefaultSpecifier": + return false; + + case "JSXAttribute": + return parent.name !== node; + + case "ClassProperty": + if (parent.key === node) { + return parent.computed; + } else { + return parent.value === node; + } + + case "ImportDefaultSpecifier": + case "ImportNamespaceSpecifier": + case "ImportSpecifier": + return false; + + case "ClassDeclaration": + case "ClassExpression": + return parent.id !== node; + + case "ClassMethod": + case "ObjectMethod": + return parent.key === node && parent.computed; + + case "LabeledStatement": + return false; + + case "CatchClause": + return parent.param !== node; + + case "RestElement": + return false; + + case "AssignmentExpression": + return parent.right === node; + + case "AssignmentPattern": + return parent.right === node; + + case "ObjectPattern": + case "ArrayPattern": + return false; + } + + return true; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isScope.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isScope.js new file mode 100644 index 00000000000000..91928ca59ef83a --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isScope.js @@ -0,0 +1,22 @@ +"use strict"; + +exports.__esModule = true; +exports.default = isScope; + +var _generated = require("./generated"); + +function isScope(node, parent) { + if ((0, _generated.isBlockStatement)(node) && (0, _generated.isFunction)(parent, { + body: node + })) { + return false; + } + + if ((0, _generated.isBlockStatement)(node) && (0, _generated.isCatchClause)(parent, { + body: node + })) { + return false; + } + + return (0, _generated.isScopable)(node); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isSpecifierDefault.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isSpecifierDefault.js new file mode 100644 index 00000000000000..936d58e9e5b8e0 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isSpecifierDefault.js @@ -0,0 +1,12 @@ +"use strict"; + +exports.__esModule = true; +exports.default = isSpecifierDefault; + +var _generated = require("./generated"); + +function isSpecifierDefault(specifier) { + return (0, _generated.isImportDefaultSpecifier)(specifier) || (0, _generated.isIdentifier)(specifier.imported || specifier.exported, { + name: "default" + }); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isType.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isType.js new file mode 100644 index 00000000000000..04410ca5d0b878 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isType.js @@ -0,0 +1,34 @@ +"use strict"; + +exports.__esModule = true; +exports.default = isType; + +var _definitions = require("../definitions"); + +function isType(nodeType, targetType) { + if (nodeType === targetType) return true; + if (_definitions.ALIAS_KEYS[targetType]) return false; + var aliases = _definitions.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; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isValidES3Identifier.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isValidES3Identifier.js new file mode 100644 index 00000000000000..ce98b3819c748a --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isValidES3Identifier.js @@ -0,0 +1,14 @@ +"use strict"; + +exports.__esModule = true; +exports.default = isValidES3Identifier; + +var _isValidIdentifier = _interopRequireDefault(require("./isValidIdentifier")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +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 (0, _isValidIdentifier.default)(name) && !RESERVED_WORDS_ES3_ONLY.has(name); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isValidIdentifier.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isValidIdentifier.js new file mode 100644 index 00000000000000..981ae2a6473fe4 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isValidIdentifier.js @@ -0,0 +1,18 @@ +"use strict"; + +exports.__esModule = true; +exports.default = isValidIdentifier; + +var _esutils = _interopRequireDefault(require("esutils")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function isValidIdentifier(name) { + if (typeof name !== "string" || _esutils.default.keyword.isReservedWordES6(name, true)) { + return false; + } else if (name === "await") { + return false; + } else { + return _esutils.default.keyword.isIdentifierNameES6(name); + } +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isVar.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isVar.js new file mode 100644 index 00000000000000..df6b20731c833f --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/isVar.js @@ -0,0 +1,14 @@ +"use strict"; + +exports.__esModule = true; +exports.default = isVar; + +var _generated = require("./generated"); + +var _constants = require("../constants"); + +function isVar(node) { + return (0, _generated.isVariableDeclaration)(node, { + kind: "var" + }) && !node[_constants.BLOCK_SCOPED_SYMBOL]; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/matchesPattern.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/matchesPattern.js new file mode 100644 index 00000000000000..b2cf579423a404 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/matchesPattern.js @@ -0,0 +1,38 @@ +"use strict"; + +exports.__esModule = true; +exports.default = matchesPattern; + +var _generated = require("./generated"); + +function matchesPattern(member, match, allowPartial) { + if (!(0, _generated.isMemberExpression)(member)) return false; + var parts = Array.isArray(match) ? match : match.split("."); + var nodes = []; + var node; + + for (node = member; (0, _generated.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 ((0, _generated.isIdentifier)(_node)) { + value = _node.name; + } else if ((0, _generated.isStringLiteral)(_node)) { + value = _node.value; + } else { + return false; + } + + if (parts[i] !== value) return false; + } + + return true; +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/react/isCompatTag.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/react/isCompatTag.js new file mode 100644 index 00000000000000..f5dc829a9b9529 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/react/isCompatTag.js @@ -0,0 +1,8 @@ +"use strict"; + +exports.__esModule = true; +exports.default = isCompatTag; + +function isCompatTag(tagName) { + return !!tagName && /^[a-z]|-/.test(tagName); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/react/isReactComponent.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/react/isReactComponent.js new file mode 100644 index 00000000000000..af7abc2b0719a6 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/react/isReactComponent.js @@ -0,0 +1,12 @@ +"use strict"; + +exports.__esModule = true; +exports.default = void 0; + +var _buildMatchMemberExpression = _interopRequireDefault(require("../buildMatchMemberExpression")); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +var isReactComponent = (0, _buildMatchMemberExpression.default)("React.Component"); +var _default = isReactComponent; +exports.default = _default; \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/validate.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/validate.js new file mode 100644 index 00000000000000..ab96408b3a7760 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/lib/validators/validate.js @@ -0,0 +1,16 @@ +"use strict"; + +exports.__esModule = true; +exports.default = validate; + +var _definitions = require("../definitions"); + +function validate(node, key, val) { + if (!node) return; + var fields = _definitions.NODE_FIELDS[node.type]; + if (!fields) return; + var field = fields[key]; + if (!field || !field.validate) return; + if (field.optional && val == null) return; + field.validate(node, key, val); +} \ No newline at end of file diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/package.json b/tools/node_modules/babel-eslint/node_modules/@babel/types/package.json new file mode 100644 index 00000000000000..af3128ee9f3589 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/package.json @@ -0,0 +1,55 @@ +{ + "_from": "@babel/types@7.0.0-beta.36", + "_id": "@babel/types@7.0.0-beta.36", + "_inBundle": false, + "_integrity": "sha512-PyAORDO9um9tfnrddXgmWN9e6Sq9qxraQIt5ynqBOSXKA5qvK1kUr+Q3nSzKFdzorsiK+oqcUnAFvEoKxv9D+Q==", + "_location": "/babel-eslint/@babel/types", + "_phantomChildren": {}, + "_requested": { + "type": "version", + "registry": true, + "raw": "@babel/types@7.0.0-beta.36", + "name": "@babel/types", + "escapedName": "@babel%2ftypes", + "scope": "@babel", + "rawSpec": "7.0.0-beta.36", + "saveSpec": null, + "fetchSpec": "7.0.0-beta.36" + }, + "_requiredBy": [ + "/babel-eslint", + "/babel-eslint/@babel/helper-function-name", + "/babel-eslint/@babel/helper-get-function-arity", + "/babel-eslint/@babel/template", + "/babel-eslint/@babel/traverse" + ], + "_resolved": "https://registry.npmjs.org/@babel/types/-/types-7.0.0-beta.36.tgz", + "_shasum": "64f2004353de42adb72f9ebb4665fc35b5499d23", + "_spec": "@babel/types@7.0.0-beta.36", + "_where": "/home/mzasso/git/nodejs/node/tools/babel-eslint-tmp/node_modules/babel-eslint", + "author": { + "name": "Sebastian McKenzie", + "email": "sebmck@gmail.com" + }, + "bundleDependencies": false, + "dependencies": { + "esutils": "^2.0.2", + "lodash": "^4.2.0", + "to-fast-properties": "^2.0.0" + }, + "deprecated": false, + "description": "Babel Types is a Lodash-esque utility library for AST nodes", + "devDependencies": { + "@babel/generator": "7.0.0-beta.36", + "babylon": "7.0.0-beta.36" + }, + "homepage": "https://babeljs.io/", + "license": "MIT", + "main": "lib/index.js", + "name": "@babel/types", + "repository": { + "type": "git", + "url": "https://github.com/babel/babel/tree/master/packages/babel-types" + }, + "version": "7.0.0-beta.36" +} diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/generateTypeHelpers.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/generateTypeHelpers.js new file mode 100644 index 00000000000000..e122145c3ca1f7 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/generateTypeHelpers.js @@ -0,0 +1,31 @@ +"use strict"; +const fs = require("fs"); +const path = require("path"); +const generateBuilders = require("./generators/generateBuilders"); +const generateValidators = require("./generators/generateValidators"); +const generateAsserts = require("./generators/generateAsserts"); +const generateConstants = require("./generators/generateConstants"); +const format = require("./utils/formatCode"); + +const baseDir = path.join(__dirname, "../src"); + +function writeFile(content, location) { + const file = path.join(baseDir, location); + + try { + fs.mkdirSync(path.dirname(file)); + } catch (error) { + if (error.code !== "EEXIST") { + throw error; + } + } + + fs.writeFileSync(file, format(content, file)); +} + +console.log("Generating @babel/types dynamic functions"); + +writeFile(generateBuilders(), "builders/generated/index.js"); +writeFile(generateValidators(), "validators/generated/index.js"); +writeFile(generateAsserts(), "asserts/generated/index.js"); +writeFile(generateConstants(), "constants/generated/index.js"); diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/generators/generateAsserts.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/generators/generateAsserts.js new file mode 100644 index 00000000000000..150e8557c733e4 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/generators/generateAsserts.js @@ -0,0 +1,43 @@ +"use strict"; +const definitions = require("../../lib/definitions"); + +function addAssertHelper(type) { + return `export function assert${type}(node: Object, opts?: Object = {}): void { + assert("${type}", node, opts) } + `; +} + +module.exports = function generateAsserts() { + let output = `// @flow +/* + * This file is auto-generated! Do not modify it directly. + * To re-generate run 'make build' + */ +import is from "../../validators/is"; + +function assert(type: string, node: Object, opts?: Object): void { + if (!is(type, node, opts)) { + throw new Error( + \`Expected type "\${type}" with option \${JSON.stringify(opts)}, but instead got "\${node.type}".\`, + ); + } +}\n\n`; + + Object.keys(definitions.VISITOR_KEYS).forEach(type => { + output += addAssertHelper(type); + }); + + Object.keys(definitions.FLIPPED_ALIAS_KEYS).forEach(type => { + output += addAssertHelper(type); + }); + + Object.keys(definitions.DEPRECATED_KEYS).forEach(type => { + const newType = definitions.DEPRECATED_KEYS[type]; + output += `export function assert${type}(node: Object, opts: Object): void { + console.trace("The node type ${type} has been renamed to ${newType}"); + assert("${type}", node, opts); +}\n`; + }); + + return output; +}; diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/generators/generateBuilders.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/generators/generateBuilders.js new file mode 100644 index 00000000000000..08a5b6fc61555f --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/generators/generateBuilders.js @@ -0,0 +1,43 @@ +"use strict"; +const definitions = require("../../lib/definitions"); +const formatBuilderName = require("../utils/formatBuilderName"); +const lowerFirst = require("../utils/lowerFirst"); + +module.exports = function generateBuilders() { + let output = `// @flow +/* + * This file is auto-generated! Do not modify it directly. + * To re-generate run 'make build' + */ +import builder from "../builder";\n\n`; + + Object.keys(definitions.BUILDER_KEYS).forEach(type => { + output += `export function ${type}(...args: Array): Object { return builder("${type}", ...args); } +export { ${type} as ${formatBuilderName(type)} };\n`; + + // This is needed for backwards compatibility. + // It should be removed in the next major version. + // JSXIdentifier -> jSXIdentifier + if (/^[A-Z]{2}/.test(type)) { + output += `export { ${type} as ${lowerFirst(type)} }\n`; + } + }); + + Object.keys(definitions.DEPRECATED_KEYS).forEach(type => { + const newType = definitions.DEPRECATED_KEYS[type]; + output += `export function ${type}(...args: Array): Object { + console.trace("The node type ${type} has been renamed to ${newType}"); + return ${type}("${type}", ...args); +} +export { ${type} as ${formatBuilderName(type)} };\n`; + + // This is needed for backwards compatibility. + // It should be removed in the next major version. + // JSXIdentifier -> jSXIdentifier + if (/^[A-Z]{2}/.test(type)) { + output += `export { ${type} as ${lowerFirst(type)} }\n`; + } + }); + + return output; +}; diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/generators/generateConstants.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/generators/generateConstants.js new file mode 100644 index 00000000000000..1e4d2cabaec4da --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/generators/generateConstants.js @@ -0,0 +1,17 @@ +"use strict"; +const definitions = require("../../lib/definitions"); + +module.exports = function generateConstants() { + let output = `// @flow +/* + * This file is auto-generated! Do not modify it directly. + * To re-generate run 'make build' + */ +import { FLIPPED_ALIAS_KEYS } from "../../definitions";\n\n`; + + Object.keys(definitions.FLIPPED_ALIAS_KEYS).forEach(type => { + output += `export const ${type.toUpperCase()}_TYPES = FLIPPED_ALIAS_KEYS["${type}"];\n`; + }); + + return output; +}; diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/generators/generateValidators.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/generators/generateValidators.js new file mode 100644 index 00000000000000..b523d6adc85354 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/generators/generateValidators.js @@ -0,0 +1,35 @@ +"use strict"; +const definitions = require("../../lib/definitions"); + +function addIsHelper(type) { + return `export function is${type}(node: Object, opts?: Object): boolean { + return is("${type}", node, opts) } + `; +} + +module.exports = function generateValidators() { + let output = `// @flow +/* + * This file is auto-generated! Do not modify it directly. + * To re-generate run 'make build' + */ +import is from "../is";\n\n`; + + Object.keys(definitions.VISITOR_KEYS).forEach(type => { + output += addIsHelper(type); + }); + + Object.keys(definitions.FLIPPED_ALIAS_KEYS).forEach(type => { + output += addIsHelper(type); + }); + + Object.keys(definitions.DEPRECATED_KEYS).forEach(type => { + const newType = definitions.DEPRECATED_KEYS[type]; + output += `export function is${type}(node: Object, opts: Object): boolean { + console.trace("The node type ${type} has been renamed to ${newType}"); + return is("${type}", node, opts); +}\n`; + }); + + return output; +}; diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/utils/formatBuilderName.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/utils/formatBuilderName.js new file mode 100644 index 00000000000000..1b543a9bfaf570 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/utils/formatBuilderName.js @@ -0,0 +1,9 @@ +"use strict"; + +const toLowerCase = Function.call.bind("".toLowerCase); + +module.exports = function formatBuilderName(type) { + // FunctionExpression -> functionExpression + // JSXIdentifier -> jsxIdentifier + return type.replace(/^([A-Z](?=[a-z])|[A-Z]+(?=[A-Z]))/, toLowerCase); +}; diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/utils/formatCode.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/utils/formatCode.js new file mode 100644 index 00000000000000..9d279e6e49ec41 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/utils/formatCode.js @@ -0,0 +1,9 @@ +"use strict"; +const prettier = require("prettier"); + +module.exports = function formatCode(code, filename) { + filename = filename || __filename; + const prettierConfig = prettier.resolveConfig.sync(filename); + + return prettier.format(code, prettierConfig); +}; diff --git a/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/utils/lowerFirst.js b/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/utils/lowerFirst.js new file mode 100644 index 00000000000000..9e7b0cee51c116 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/@babel/types/scripts/utils/lowerFirst.js @@ -0,0 +1,4 @@ +"use strict"; +module.exports = function lowerFirst(string) { + return string[0].toLowerCase() + string.slice(1); +}; diff --git a/tools/node_modules/babel-eslint/node_modules/ansi-styles/index.js b/tools/node_modules/babel-eslint/node_modules/ansi-styles/index.js new file mode 100644 index 00000000000000..3d3baa66d75d1c --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/ansi-styles/index.js @@ -0,0 +1,152 @@ +'use strict'; +const colorConvert = require('color-convert'); + +const wrapAnsi16 = (fn, offset) => function () { + const code = fn.apply(colorConvert, arguments); + return `\u001B[${code + offset}m`; +}; + +const wrapAnsi256 = (fn, offset) => function () { + const code = fn.apply(colorConvert, arguments); + return `\u001B[${38 + offset};5;${code}m`; +}; + +const wrapAnsi16m = (fn, offset) => function () { + const rgb = fn.apply(colorConvert, arguments); + return `\u001B[${38 + offset};2;${rgb[0]};${rgb[1]};${rgb[2]}m`; +}; + +function assembleStyles() { + const codes = new Map(); + const styles = { + modifier: { + reset: [0, 0], + // 21 isn't widely supported and 22 does the same thing + bold: [1, 22], + dim: [2, 22], + italic: [3, 23], + underline: [4, 24], + inverse: [7, 27], + hidden: [8, 28], + strikethrough: [9, 29] + }, + color: { + black: [30, 39], + red: [31, 39], + green: [32, 39], + yellow: [33, 39], + blue: [34, 39], + magenta: [35, 39], + cyan: [36, 39], + white: [37, 39], + gray: [90, 39], + + // Bright color + redBright: [91, 39], + greenBright: [92, 39], + yellowBright: [93, 39], + blueBright: [94, 39], + magentaBright: [95, 39], + cyanBright: [96, 39], + whiteBright: [97, 39] + }, + bgColor: { + bgBlack: [40, 49], + bgRed: [41, 49], + bgGreen: [42, 49], + bgYellow: [43, 49], + bgBlue: [44, 49], + bgMagenta: [45, 49], + bgCyan: [46, 49], + bgWhite: [47, 49], + + // Bright color + bgBlackBright: [100, 49], + bgRedBright: [101, 49], + bgGreenBright: [102, 49], + bgYellowBright: [103, 49], + bgBlueBright: [104, 49], + bgMagentaBright: [105, 49], + bgCyanBright: [106, 49], + bgWhiteBright: [107, 49] + } + }; + + // Fix humans + styles.color.grey = styles.color.gray; + + for (const groupName of Object.keys(styles)) { + const group = styles[groupName]; + + for (const styleName of Object.keys(group)) { + const style = group[styleName]; + + styles[styleName] = { + open: `\u001B[${style[0]}m`, + close: `\u001B[${style[1]}m` + }; + + group[styleName] = styles[styleName]; + + codes.set(style[0], style[1]); + } + + Object.defineProperty(styles, groupName, { + value: group, + enumerable: false + }); + + Object.defineProperty(styles, 'codes', { + value: codes, + enumerable: false + }); + } + + const rgb2rgb = (r, g, b) => [r, g, b]; + + styles.color.close = '\u001B[39m'; + styles.bgColor.close = '\u001B[49m'; + + styles.color.ansi = {}; + styles.color.ansi256 = {}; + styles.color.ansi16m = { + rgb: wrapAnsi16m(rgb2rgb, 0) + }; + + styles.bgColor.ansi = {}; + styles.bgColor.ansi256 = {}; + styles.bgColor.ansi16m = { + rgb: wrapAnsi16m(rgb2rgb, 10) + }; + + for (const key of Object.keys(colorConvert)) { + if (typeof colorConvert[key] !== 'object') { + continue; + } + + const suite = colorConvert[key]; + + if ('ansi16' in suite) { + styles.color.ansi[key] = wrapAnsi16(suite.ansi16, 0); + styles.bgColor.ansi[key] = wrapAnsi16(suite.ansi16, 10); + } + + if ('ansi256' in suite) { + styles.color.ansi256[key] = wrapAnsi256(suite.ansi256, 0); + styles.bgColor.ansi256[key] = wrapAnsi256(suite.ansi256, 10); + } + + if ('rgb' in suite) { + styles.color.ansi16m[key] = wrapAnsi16m(suite.rgb, 0); + styles.bgColor.ansi16m[key] = wrapAnsi16m(suite.rgb, 10); + } + } + + return styles; +} + +// Make the export immutable +Object.defineProperty(module, 'exports', { + enumerable: true, + get: assembleStyles +}); diff --git a/tools/node_modules/babel-eslint/node_modules/ansi-styles/license b/tools/node_modules/babel-eslint/node_modules/ansi-styles/license new file mode 100644 index 00000000000000..e7af2f77107d73 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/ansi-styles/license @@ -0,0 +1,9 @@ +MIT License + +Copyright (c) Sindre Sorhus (sindresorhus.com) + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/tools/node_modules/babel-eslint/node_modules/ansi-styles/package.json b/tools/node_modules/babel-eslint/node_modules/ansi-styles/package.json new file mode 100644 index 00000000000000..6e9e19423b4668 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/ansi-styles/package.json @@ -0,0 +1,86 @@ +{ + "_from": "ansi-styles@^3.1.0", + "_id": "ansi-styles@3.2.0", + "_inBundle": false, + "_integrity": "sha512-NnSOmMEYtVR2JVMIGTzynRkkaxtiq1xnFBcdQD/DnNCYPoEPsVJhM98BDyaoNOQIi7p4okdi3E27eN7GQbsUug==", + "_location": "/babel-eslint/ansi-styles", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "ansi-styles@^3.1.0", + "name": "ansi-styles", + "escapedName": "ansi-styles", + "rawSpec": "^3.1.0", + "saveSpec": null, + "fetchSpec": "^3.1.0" + }, + "_requiredBy": [ + "/babel-eslint/chalk" + ], + "_resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.0.tgz", + "_shasum": "c159b8d5be0f9e5a6f346dab94f16ce022161b88", + "_spec": "ansi-styles@^3.1.0", + "_where": "/home/mzasso/git/nodejs/node/tools/babel-eslint-tmp/node_modules/babel-eslint/node_modules/chalk", + "author": { + "name": "Sindre Sorhus", + "email": "sindresorhus@gmail.com", + "url": "sindresorhus.com" + }, + "ava": { + "require": "babel-polyfill" + }, + "bugs": { + "url": "https://github.com/chalk/ansi-styles/issues" + }, + "bundleDependencies": false, + "dependencies": { + "color-convert": "^1.9.0" + }, + "deprecated": false, + "description": "ANSI escape codes for styling strings in the terminal", + "devDependencies": { + "ava": "*", + "babel-polyfill": "^6.23.0", + "xo": "*" + }, + "engines": { + "node": ">=4" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/chalk/ansi-styles#readme", + "keywords": [ + "ansi", + "styles", + "color", + "colour", + "colors", + "terminal", + "console", + "cli", + "string", + "tty", + "escape", + "formatting", + "rgb", + "256", + "shell", + "xterm", + "log", + "logging", + "command-line", + "text" + ], + "license": "MIT", + "name": "ansi-styles", + "repository": { + "type": "git", + "url": "git+https://github.com/chalk/ansi-styles.git" + }, + "scripts": { + "test": "xo && ava" + }, + "version": "3.2.0" +} diff --git a/tools/node_modules/babel-eslint/node_modules/ansi-styles/readme.md b/tools/node_modules/babel-eslint/node_modules/ansi-styles/readme.md new file mode 100644 index 00000000000000..dce368742b42af --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/ansi-styles/readme.md @@ -0,0 +1,147 @@ +# ansi-styles [![Build Status](https://travis-ci.org/chalk/ansi-styles.svg?branch=master)](https://travis-ci.org/chalk/ansi-styles) + +> [ANSI escape codes](http://en.wikipedia.org/wiki/ANSI_escape_code#Colors_and_Styles) for styling strings in the terminal + +You probably want the higher-level [chalk](https://github.com/chalk/chalk) module for styling your strings. + +![](screenshot.png) + + +## Install + +``` +$ npm install ansi-styles +``` + + +## Usage + +```js +const style = require('ansi-styles'); + +console.log(`${style.green.open}Hello world!${style.green.close}`); + + +// Color conversion between 16/256/truecolor +// NOTE: If conversion goes to 16 colors or 256 colors, the original color +// may be degraded to fit that color palette. This means terminals +// that do not support 16 million colors will best-match the +// original color. +console.log(style.bgColor.ansi.hsl(120, 80, 72) + 'Hello world!' + style.bgColor.close); +console.log(style.color.ansi256.rgb(199, 20, 250) + 'Hello world!' + style.color.close); +console.log(style.color.ansi16m.hex('#ABCDEF') + 'Hello world!' + style.color.close); +``` + +## API + +Each style has an `open` and `close` property. + + +## Styles + +### Modifiers + +- `reset` +- `bold` +- `dim` +- `italic` *(Not widely supported)* +- `underline` +- `inverse` +- `hidden` +- `strikethrough` *(Not widely supported)* + +### Colors + +- `black` +- `red` +- `green` +- `yellow` +- `blue` +- `magenta` +- `cyan` +- `white` +- `gray` ("bright black") +- `redBright` +- `greenBright` +- `yellowBright` +- `blueBright` +- `magentaBright` +- `cyanBright` +- `whiteBright` + +### Background colors + +- `bgBlack` +- `bgRed` +- `bgGreen` +- `bgYellow` +- `bgBlue` +- `bgMagenta` +- `bgCyan` +- `bgWhite` +- `bgBlackBright` +- `bgRedBright` +- `bgGreenBright` +- `bgYellowBright` +- `bgBlueBright` +- `bgMagentaBright` +- `bgCyanBright` +- `bgWhiteBright` + + +## Advanced usage + +By default, you get a map of styles, but the styles are also available as groups. They are non-enumerable so they don't show up unless you access them explicitly. This makes it easier to expose only a subset in a higher-level module. + +- `style.modifier` +- `style.color` +- `style.bgColor` + +###### Example + +```js +console.log(style.color.green.open); +``` + +Raw escape codes (i.e. without the CSI escape prefix `\u001B[` and render mode postfix `m`) are available under `style.codes`, which returns a `Map` with the open codes as keys and close codes as values. + +###### Example + +```js +console.log(style.codes.get(36)); +//=> 39 +``` + + +## [256 / 16 million (TrueColor) support](https://gist.github.com/XVilka/8346728) + +`ansi-styles` uses the [`color-convert`](https://github.com/Qix-/color-convert) package to allow for converting between various colors and ANSI escapes, with support for 256 and 16 million colors. + +To use these, call the associated conversion function with the intended output, for example: + +```js +style.color.ansi.rgb(100, 200, 15); // RGB to 16 color ansi foreground code +style.bgColor.ansi.rgb(100, 200, 15); // RGB to 16 color ansi background code + +style.color.ansi256.hsl(120, 100, 60); // HSL to 256 color ansi foreground code +style.bgColor.ansi256.hsl(120, 100, 60); // HSL to 256 color ansi foreground code + +style.color.ansi16m.hex('#C0FFEE'); // Hex (RGB) to 16 million color foreground code +style.bgColor.ansi16m.hex('#C0FFEE'); // Hex (RGB) to 16 million color background code +``` + + +## Related + +- [ansi-escapes](https://github.com/sindresorhus/ansi-escapes) - ANSI escape codes for manipulating the terminal + + +## Maintainers + +- [Sindre Sorhus](https://github.com/sindresorhus) +- [Josh Junon](https://github.com/qix-) + + +## License + +MIT diff --git a/tools/node_modules/babel-eslint/node_modules/babylon/LICENSE b/tools/node_modules/babel-eslint/node_modules/babylon/LICENSE new file mode 100644 index 00000000000000..d4c7fc583804df --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/babylon/LICENSE @@ -0,0 +1,19 @@ +Copyright (C) 2012-2014 by various contributors (see AUTHORS) + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/tools/node_modules/babel-eslint/node_modules/babylon/README.md b/tools/node_modules/babel-eslint/node_modules/babylon/README.md new file mode 100644 index 00000000000000..78dd00be332591 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/babylon/README.md @@ -0,0 +1,163 @@ +

+ babylon +

+ +

+ Babylon is a JavaScript parser used in Babel. +

+ + - The latest ECMAScript version enabled by default (ES2017). + - Comment attachment. + - Support for JSX, Flow, Typescript. + - Support for experimental language proposals (accepting PRs for anything at least [stage-0](https://github.com/tc39/proposals/blob/master/stage-0-proposals.md)). + +## Credits + +Heavily based on [acorn](https://github.com/marijnh/acorn) and [acorn-jsx](https://github.com/RReverser/acorn-jsx), +thanks to the awesome work of [@RReverser](https://github.com/RReverser) and [@marijnh](https://github.com/marijnh). + +## API + +### `babylon.parse(code, [options])` + +### `babylon.parseExpression(code, [options])` + +`parse()` parses the provided `code` as an entire ECMAScript program, while +`parseExpression()` tries to parse a single Expression with performance in +mind. When in doubt, use `.parse()`. + +### Options + +- **allowImportExportEverywhere**: By default, `import` and `export` + declarations can only appear at a program's top level. Setting this + option to `true` allows them anywhere where a statement is allowed. + +- **allowReturnOutsideFunction**: By default, a return statement at + the top level raises an error. Set this to `true` to accept such + code. + +- **allowSuperOutsideMethod**: TODO + +- **sourceType**: Indicate the mode the code should be parsed in. Can be + one of `"script"`, `"module"`, or `"unambiguous"`. Defaults to `"script"`. `"unambiguous"` will make Babylon attempt to _guess_, based on the presence of ES6 `import` or `export` statements. Files with ES6 `import`s and `export`s are considered `"module"` and are otherwise `"script"`. + +- **sourceFilename**: Correlate output AST nodes with their source filename. Useful when generating code and source maps from the ASTs of multiple input files. + +- **startLine**: By default, the first line of code parsed is treated as line 1. You can provide a line number to alternatively start with. Useful for integration with other source tools. + +- **plugins**: Array containing the plugins that you want to enable. + +- **strictMode**: TODO + +- **ranges**: Adds a `ranges` property to each node: `[node.start, node.end]` + +- **tokens**: Adds all parsed tokens to a `tokens` property on the `File` node + +### Output + +Babylon generates AST according to [Babel AST format][]. +It is based on [ESTree spec][] with the following deviations: + +> There is now an `estree` plugin which reverts these deviations + +- [Literal][] token is replaced with [StringLiteral][], [NumericLiteral][], [BooleanLiteral][], [NullLiteral][], [RegExpLiteral][] +- [Property][] token is replaced with [ObjectProperty][] and [ObjectMethod][] +- [MethodDefinition][] is replaced with [ClassMethod][] +- [Program][] and [BlockStatement][] contain additional `directives` field with [Directive][] and [DirectiveLiteral][] +- [ClassMethod][], [ObjectProperty][], and [ObjectMethod][] value property's properties in [FunctionExpression][] is coerced/brought into the main method node. + +AST for JSX code is based on [Facebook JSX AST][] with the addition of one node type: + +- `JSXText` + +[Babel AST format]: https://github.com/babel/babylon/blob/master/ast/spec.md +[ESTree spec]: https://github.com/estree/estree + +[Literal]: https://github.com/estree/estree/blob/master/es5.md#literal +[Property]: https://github.com/estree/estree/blob/master/es5.md#property +[MethodDefinition]: https://github.com/estree/estree/blob/master/es2015.md#methoddefinition + +[StringLiteral]: https://github.com/babel/babylon/blob/master/ast/spec.md#stringliteral +[NumericLiteral]: https://github.com/babel/babylon/blob/master/ast/spec.md#numericliteral +[BooleanLiteral]: https://github.com/babel/babylon/blob/master/ast/spec.md#booleanliteral +[NullLiteral]: https://github.com/babel/babylon/blob/master/ast/spec.md#nullliteral +[RegExpLiteral]: https://github.com/babel/babylon/blob/master/ast/spec.md#regexpliteral +[ObjectProperty]: https://github.com/babel/babylon/blob/master/ast/spec.md#objectproperty +[ObjectMethod]: https://github.com/babel/babylon/blob/master/ast/spec.md#objectmethod +[ClassMethod]: https://github.com/babel/babylon/blob/master/ast/spec.md#classmethod +[Program]: https://github.com/babel/babylon/blob/master/ast/spec.md#programs +[BlockStatement]: https://github.com/babel/babylon/blob/master/ast/spec.md#blockstatement +[Directive]: https://github.com/babel/babylon/blob/master/ast/spec.md#directive +[DirectiveLiteral]: https://github.com/babel/babylon/blob/master/ast/spec.md#directiveliteral +[FunctionExpression]: https://github.com/babel/babylon/blob/master/ast/spec.md#functionexpression + +[Facebook JSX AST]: https://github.com/facebook/jsx/blob/master/AST.md + +### Semver + +Babylon follows semver in most situations. The only thing to note is that some spec-compliancy bug fixes may be released under patch versions. + +For example: We push a fix to early error on something like [#107](https://github.com/babel/babylon/pull/107) - multiple default exports per file. That would be considered a bug fix even though it would cause a build to fail. + +### Example + +```javascript +require("babylon").parse("code", { + // parse in strict mode and allow module declarations + sourceType: "module", + + plugins: [ + // enable jsx and flow syntax + "jsx", + "flow" + ] +}); +``` + +### Plugins + +| Name | Code Example | +|------|--------------| +| `estree` ([repo](https://github.com/estree/estree)) | n/a | +| `jsx` ([repo](https://facebook.github.io/jsx/)) | `{s}` | +| `flow` ([repo](https://github.com/facebook/flow)) | `var a: string = "";` | +| `typescript` ([repo](https://github.com/Microsoft/TypeScript)) | `var a: string = "";` | +| `doExpressions` | `var a = do { if (true) { 'hi'; } };` | +| `objectRestSpread` ([proposal](https://github.com/tc39/proposal-object-rest-spread)) | `var a = { b, ...c };` | +| `decorators` (Stage 1) and `decorators2` (Stage 2 [proposal](https://github.com/tc39/proposal-decorators)) | `@a class A {}` | +| `classProperties` ([proposal](https://github.com/tc39/proposal-class-public-fields)) | `class A { b = 1; }` | +| `classPrivateProperties` ([proposal](https://github.com/tc39/proposal-private-fields)) | `class A { #b = 1; }` | +| `classPrivateMethods` ([proposal](https://github.com/tc39/proposal-private-methods)) | `class A { #c() {} }` | +| `exportExtensions` ([proposal 1](https://github.com/leebyron/ecmascript-export-default-from)), ([proposal 2](https://github.com/leebyron/ecmascript-export-ns-from)) | Proposal 1: `export v from "mod"` Proposal 2: `export * as ns from "mod"` | +| `asyncGenerators` ([proposal](https://github.com/tc39/proposal-async-iteration)) | `async function*() {}`, `for await (let a of b) {}` | +| `functionBind` ([proposal](https://github.com/zenparsing/es-function-bind)) | `a::b`, `::console.log` | +| `functionSent` | `function.sent` | +| `dynamicImport` ([proposal](https://github.com/tc39/proposal-dynamic-import)) | `import('./guy').then(a)` | +| `numericSeparator` ([proposal](https://github.com/samuelgoto/proposal-numeric-separator)) | `1_000_000` | +| `optionalChaining` ([proposal](https://github.com/tc39/proposal-optional-chaining)) | `a?.b` | +| `importMeta` ([proposal](https://github.com/tc39/proposal-import-meta)) | `import.meta.url` | +| `bigInt` ([proposal](https://github.com/tc39/proposal-bigint)) | `100n` | +| `optionalCatchBinding` ([proposal](https://github.com/babel/proposals/issues/7)) | `try {throw 0;} catch{do();}` | +| `throwExpressions` ([proposal](https://github.com/babel/proposals/issues/23)) | `() => throw new Error("")` | +| `pipelineOperator` ([proposal](https://github.com/babel/proposals/issues/29)) | `a \|> b` | +| `nullishCoalescingOperator` ([proposal](https://github.com/babel/proposals/issues/14)) | `a ?? b` | + +### FAQ + +#### Will Babylon support a plugin system? + +Previous issues: [babel/babel#1351](https://github.com/babel/babel/issues/1351), [#500](https://github.com/babel/babylon/issues/500). + +We currently aren't willing to commit to supporting the API for plugins or the resulting ecosystem (there is already enough work maintaining Babel's own plugin system). It's not clear how to make that API effective, and it would limit out ability to refactor and optimize the codebase. + +Our current recommendation for those that want to create their own custom syntax is for users to fork Babylon. + +To consume your custom parser, you can add to your `.babelrc` via its npm package name or require it if using JavaScript, + +```json +{ + "parserOpts": { + "parser": "custom-fork-of-babylon-on-npm-here" + } +} +``` diff --git a/tools/node_modules/babel-eslint/node_modules/babylon/bin/babylon.js b/tools/node_modules/babel-eslint/node_modules/babylon/bin/babylon.js new file mode 100755 index 00000000000000..440eef35ff8f8f --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/babylon/bin/babylon.js @@ -0,0 +1,16 @@ +#!/usr/bin/env node +/* eslint no-var: 0 */ + +var babylon = require(".."); +var fs = require("fs"); + +var filename = process.argv[2]; +if (!filename) { + console.error("no filename specified"); + process.exit(0); +} + +var file = fs.readFileSync(filename, "utf8"); +var ast = babylon.parse(file); + +console.log(JSON.stringify(ast, null, " ")); diff --git a/tools/node_modules/babel-eslint/node_modules/babylon/lib/index.js b/tools/node_modules/babel-eslint/node_modules/babylon/lib/index.js new file mode 100644 index 00000000000000..901202fd4d02b9 --- /dev/null +++ b/tools/node_modules/babel-eslint/node_modules/babylon/lib/index.js @@ -0,0 +1,10635 @@ +'use strict'; + +Object.defineProperty(exports, '__esModule', { value: true }); + +function _inheritsLoose(subClass, superClass) { + subClass.prototype = Object.create(superClass.prototype); + subClass.prototype.constructor = subClass; + subClass.__proto__ = superClass; +} + +// A second optional argument can be given to further configure +// the parser process. These options are recognized: +var defaultOptions = { + // Source type ("script" or "module") for different semantics + sourceType: "script", + // Source filename. + sourceFilename: undefined, + // Line from which to start counting source. Useful for + // integration with other tools. + startLine: 1, + // When enabled, a return at the top level is not considered an + // error. + allowReturnOutsideFunction: false, + // When enabled, import/export statements are not constrained to + // appearing at the top of the program. + allowImportExportEverywhere: false, + // TODO + allowSuperOutsideMethod: false, + // An array of plugins to enable + plugins: [], + // TODO + strictMode: null, + // Nodes have their start and end characters offsets recorded in + // `start` and `end` properties (directly on the node, rather than + // the `loc` object, which holds line/column data. To also add a + // [semi-standardized][range] `range` property holding a `[start, + // end]` array with the same numbers, set the `ranges` option to + // `true`. + // + // [range]: https://bugzilla.mozilla.org/show_bug.cgi?id=745678 + ranges: false, + // Adds all parsed tokens to a `tokens` property on the `File` node + tokens: false +}; // Interpret and default an options object + +function getOptions(opts) { + var options = {}; + + for (var key in defaultOptions) { + options[key] = opts && opts[key] != null ? opts[key] : defaultOptions[key]; + } + + return options; +} + +// ## Token types +// The assignment of fine-grained, information-carrying type objects +// allows the tokenizer to store the information it has about a +// token in a way that is very cheap for the parser to look up. +// All token type variables start with an underscore, to make them +// easy to recognize. +// The `beforeExpr` property is used to disambiguate between regular +// expressions and divisions. It is set on all token types that can +// be followed by an expression (thus, a slash after them would be a +// regular expression). +// +// `isLoop` marks a keyword as starting a loop, which is important +// to know when parsing a label, in order to allow or disallow +// continue jumps to that label. +var beforeExpr = true; +var startsExpr = true; +var isLoop = true; +var isAssign = true; +var prefix = true; +var postfix = true; +var TokenType = function TokenType(label, conf) { + if (conf === void 0) { + conf = {}; + } + + this.label = label; + this.keyword = conf.keyword; + this.beforeExpr = !!conf.beforeExpr; + this.startsExpr = !!conf.startsExpr; + this.rightAssociative = !!conf.rightAssociative; + this.isLoop = !!conf.isLoop; + this.isAssign = !!conf.isAssign; + this.prefix = !!conf.prefix; + this.postfix = !!conf.postfix; + this.binop = conf.binop === 0 ? 0 : conf.binop || null; + this.updateContext = null; +}; + +var KeywordTokenType = +/*#__PURE__*/ +function (_TokenType) { + _inheritsLoose(KeywordTokenType, _TokenType); + + function KeywordTokenType(name, options) { + if (options === void 0) { + options = {}; + } + + options.keyword = name; + return _TokenType.call(this, name, options) || this; + } + + return KeywordTokenType; +}(TokenType); + +var BinopTokenType = +/*#__PURE__*/ +function (_TokenType2) { + _inheritsLoose(BinopTokenType, _TokenType2); + + function BinopTokenType(name, prec) { + return _TokenType2.call(this, name, { + beforeExpr, + binop: prec + }) || this; + } + + return BinopTokenType; +}(TokenType); +var types = { + num: new TokenType("num", { + startsExpr + }), + bigint: new TokenType("bigint", { + startsExpr + }), + regexp: new TokenType("regexp", { + startsExpr + }), + string: new TokenType("string", { + startsExpr + }), + name: new TokenType("name", { + startsExpr + }), + eof: new TokenType("eof"), + // Punctuation token types. + bracketL: new TokenType("[", { + beforeExpr, + startsExpr + }), + bracketR: new TokenType("]"), + braceL: new TokenType("{", { + beforeExpr, + startsExpr + }), + braceBarL: new TokenType("{|", { + beforeExpr, + startsExpr + }), + braceR: new TokenType("}"), + braceBarR: new TokenType("|}"), + parenL: new TokenType("(", { + beforeExpr, + startsExpr + }), + parenR: new TokenType(")"), + comma: new TokenType(",", { + beforeExpr + }), + semi: new TokenType(";", { + beforeExpr + }), + colon: new TokenType(":", { + beforeExpr + }), + doubleColon: new TokenType("::", { + beforeExpr + }), + dot: new TokenType("."), + question: new TokenType("?", { + beforeExpr + }), + questionDot: new TokenType("?."), + arrow: new TokenType("=>", { + beforeExpr + }), + template: new TokenType("template"), + ellipsis: new TokenType("...", { + beforeExpr + }), + backQuote: new TokenType("`", { + startsExpr + }), + dollarBraceL: new TokenType("${", { + beforeExpr, + startsExpr + }), + at: new TokenType("@"), + hash: new TokenType("#"), + // Operators. These carry several kinds of properties to help the + // parser use them properly (the presence of these properties is + // what categorizes them as operators). + // + // `binop`, when present, specifies that this operator is a binary + // operator, and will refer to its precedence. + // + // `prefix` and `postfix` mark the operator as a prefix or postfix + // unary operator. + // + // `isAssign` marks all of `=`, `+=`, `-=` etcetera, which act as + // binary operators with a very low precedence, that should result + // in AssignmentExpression nodes. + eq: new TokenType("=", { + beforeExpr, + isAssign + }), + assign: new TokenType("_=", { + beforeExpr, + isAssign + }), + incDec: new TokenType("++/--", { + prefix, + postfix, + startsExpr + }), + bang: new TokenType("!", { + beforeExpr, + prefix, + startsExpr + }), + tilde: new TokenType("~", { + beforeExpr, + prefix, + startsExpr + }), + pipeline: new BinopTokenType("|>", 0), + nullishCoalescing: new BinopTokenType("??", 1), + logicalOR: new BinopTokenType("||", 1), + logicalAND: new BinopTokenType("&&", 2), + bitwiseOR: new BinopTokenType("|", 3), + bitwiseXOR: new BinopTokenType("^", 4), + bitwiseAND: new BinopTokenType("&", 5), + equality: new BinopTokenType("==/!=", 6), + relational: new BinopTokenType("", 7), + bitShift: new BinopTokenType("<>", 8), + plusMin: new TokenType("+/-", { + beforeExpr, + binop: 9, + prefix, + startsExpr + }), + modulo: new BinopTokenType("%", 10), + star: new BinopTokenType("*", 10), + slash: new BinopTokenType("/", 10), + exponent: new TokenType("**", { + beforeExpr, + binop: 11, + rightAssociative: true + }) +}; +var keywords = { + break: new KeywordTokenType("break"), + case: new KeywordTokenType("case", { + beforeExpr + }), + catch: new KeywordTokenType("catch"), + continue: new KeywordTokenType("continue"), + debugger: new KeywordTokenType("debugger"), + default: new KeywordTokenType("default", { + beforeExpr + }), + do: new KeywordTokenType("do", { + isLoop, + beforeExpr + }), + else: new KeywordTokenType("else", { + beforeExpr + }), + finally: new KeywordTokenType("finally"), + for: new KeywordTokenType("for", { + isLoop + }), + function: new KeywordTokenType("function", { + startsExpr + }), + if: new KeywordTokenType("if"), + return: new KeywordTokenType("return", { + beforeExpr + }), + switch: new KeywordTokenType("switch"), + throw: new KeywordTokenType("throw", { + beforeExpr, + prefix, + startsExpr + }), + try: new KeywordTokenType("try"), + var: new KeywordTokenType("var"), + let: new KeywordTokenType("let"), + const: new KeywordTokenType("const"), + while: new KeywordTokenType("while", { + isLoop + }), + with: new KeywordTokenType("with"), + new: new KeywordTokenType("new", { + beforeExpr, + startsExpr + }), + this: new KeywordTokenType("this", { + startsExpr + }), + super: new KeywordTokenType("super", { + startsExpr + }), + class: new KeywordTokenType("class"), + extends: new KeywordTokenType("extends", { + beforeExpr + }), + export: new KeywordTokenType("export"), + import: new KeywordTokenType("import", { + startsExpr + }), + yield: new KeywordTokenType("yield", { + beforeExpr, + startsExpr + }), + null: new KeywordTokenType("null", { + startsExpr + }), + true: new KeywordTokenType("true", { + startsExpr + }), + false: new KeywordTokenType("false", { + startsExpr + }), + in: new KeywordTokenType("in", { + beforeExpr, + binop: 7 + }), + instanceof: new KeywordTokenType("instanceof", { + beforeExpr, + binop: 7 + }), + typeof: new KeywordTokenType("typeof", { + beforeExpr, + prefix, + startsExpr + }), + void: new KeywordTokenType("void", { + beforeExpr, + prefix, + startsExpr + }), + delete: new KeywordTokenType("delete", { + beforeExpr, + prefix, + startsExpr + }) +}; // Map keyword names to token types. + +Object.keys(keywords).forEach(function (name) { + types["_" + name] = keywords[name]; +}); + +/* eslint max-len: 0 */ +function makePredicate(words) { + var wordsArr = words.split(" "); + return function (str) { + return wordsArr.indexOf(str) >= 0; + }; +} // Reserved word lists for various dialects of the language + + +var reservedWords = { + "6": makePredicate("enum await"), + strict: makePredicate("implements interface let package private protected public static yield"), + strictBind: makePredicate("eval arguments") +}; // And the keywords + +var isKeyword = makePredicate("break case catch continue debugger default do else finally for function if return switch throw try var while with null true false instanceof typeof void delete new in this let const class extends export import yield super"); // ## Character categories +// Big ugly regular expressions that match characters in the +// whitespace, identifier, and identifier-start categories. These +// are only applied when a character is found to actually have a +// code point above 128. +// Generated by `bin/generate-identifier-regex.js`. + +/* prettier-ignore */ + +var nonASCIIidentifierStartChars = "\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\u0860-\u086a\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\u09fc\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-\u312e\u3131-\u318e\u31a0-\u31ba\u31f0-\u31ff\u3400-\u4db5\u4e00-\u9fea\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"; +/* prettier-ignore */ + +var nonASCIIidentifierChars = "\u200c\u200d\xb7\u0300-\u036f\u0387\u0483-\u0487\u0591-\u05bd\u05bf\u05c1\u05c2\u05c4\u05c5\u05c7\u0610-\u061a\u064b-\u0669\u0670\u06d6-\u06dc\u06df-\u06e4\u06e7\u06e8\u06ea-\u06ed\u06f0-\u06f9\u0711\u0730-\u074a\u07a6-\u07b0\u07c0-\u07c9\u07eb-\u07f3\u0816-\u0819\u081b-\u0823\u0825-\u0827\u0829-\u082d\u0859-\u085b\u08d4-\u08e1\u08e3-\u0903\u093a-\u093c\u093e-\u094f\u0951-\u0957\u0962\u0963\u0966-\u096f\u0981-\u0983\u09bc\u09be-\u09c4\u09c7\u09c8\u09cb-\u09cd\u09d7\u09e2\u09e3\u09e6-\u09ef\u0a01-\u0a03\u0a3c\u0a3e-\u0a42\u0a47\u0a48\u0a4b-\u0a4d\u0a51\u0a66-\u0a71\u0a75\u0a81-\u0a83\u0abc\u0abe-\u0ac5\u0ac7-\u0ac9\u0acb-\u0acd\u0ae2\u0ae3\u0ae6-\u0aef\u0afa-\u0aff\u0b01-\u0b03\u0b3c\u0b3e-\u0b44\u0b47\u0b48\u0b4b-\u0b4d\u0b56\u0b57\u0b62\u0b63\u0b66-\u0b6f\u0b82\u0bbe-\u0bc2\u0bc6-\u0bc8\u0bca-\u0bcd\u0bd7\u0be6-\u0bef\u0c00-\u0c03\u0c3e-\u0c44\u0c46-\u0c48\u0c4a-\u0c4d\u0c55\u0c56\u0c62\u0c63\u0c66-\u0c6f\u0c81-\u0c83\u0cbc\u0cbe-\u0cc4\u0cc6-\u0cc8\u0cca-\u0ccd\u0cd5\u0cd6\u0ce2\u0ce3\u0ce6-\u0cef\u0d00-\u0d03\u0d3b\u0d3c\u0d3e-\u0d44\u0d46-\u0d48\u0d4a-\u0d4d\u0d57\u0d62\u0d63\u0d66-\u0d6f\u0d82\u0d83\u0dca\u0dcf-\u0dd4\u0dd6\u0dd8-\u0ddf\u0de6-\u0def\u0df2\u0df3\u0e31\u0e34-\u0e3a\u0e47-\u0e4e\u0e50-\u0e59\u0eb1\u0eb4-\u0eb9\u0ebb\u0ebc\u0ec8-\u0ecd\u0ed0-\u0ed9\u0f18\u0f19\u0f20-\u0f29\u0f35\u0f37\u0f39\u0f3e\u0f3f\u0f71-\u0f84\u0f86\u0f87\u0f8d-\u0f97\u0f99-\u0fbc\u0fc6\u102b-\u103e\u1040-\u1049\u1056-\u1059\u105e-\u1060\u1062-\u1064\u1067-\u106d\u1071-\u1074\u1082-\u108d\u108f-\u109d\u135d-\u135f\u1369-\u1371\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17b4-\u17d3\u17dd\u17e0-\u17e9\u180b-\u180d\u1810-\u1819\u18a9\u1920-\u192b\u1930-\u193b\u1946-\u194f\u19d0-\u19da\u1a17-\u1a1b\u1a55-\u1a5e\u1a60-\u1a7c\u1a7f-\u1a89\u1a90-\u1a99\u1ab0-\u1abd\u1b00-\u1b04\u1b34-\u1b44\u1b50-\u1b59\u1b6b-\u1b73\u1b80-\u1b82\u1ba1-\u1bad\u1bb0-\u1bb9\u1be6-\u1bf3\u1c24-\u1c37\u1c40-\u1c49\u1c50-\u1c59\u1cd0-\u1cd2\u1cd4-\u1ce8\u1ced\u1cf2-\u1cf4\u1cf7-\u1cf9\u1dc0-\u1df9\u1dfb-\u1dff\u203f\u2040\u2054\u20d0-\u20dc\u20e1\u20e5-\u20f0\u2cef-\u2cf1\u2d7f\u2de0-\u2dff\u302a-\u302f\u3099\u309a\ua620-\ua629\ua66f\ua674-\ua67d\ua69e\ua69f\ua6f0\ua6f1\ua802\ua806\ua80b\ua823-\ua827\ua880\ua881\ua8b4-\ua8c5\ua8d0-\ua8d9\ua8e0-\ua8f1\ua900-\ua909\ua926-\ua92d\ua947-\ua953\ua980-\ua983\ua9b3-\ua9c0\ua9d0-\ua9d9\ua9e5\ua9f0-\ua9f9\uaa29-\uaa36\uaa43\uaa4c\uaa4d\uaa50-\uaa59\uaa7b-\uaa7d\uaab0\uaab2-\uaab4\uaab7\uaab8\uaabe\uaabf\uaac1\uaaeb-\uaaef\uaaf5\uaaf6\uabe3-\uabea\uabec\uabed\uabf0-\uabf9\ufb1e\ufe00-\ufe0f\ufe20-\ufe2f\ufe33\ufe34\ufe4d-\ufe4f\uff10-\uff19\uff3f"; +var nonASCIIidentifierStart = new RegExp("[" + nonASCIIidentifierStartChars + "]"); +var nonASCIIidentifier = new RegExp("[" + nonASCIIidentifierStartChars + nonASCIIidentifierChars + "]"); +nonASCIIidentifierStartChars = nonASCIIidentifierChars = null; // These are a run-length and offset encoded representation of the +// >0xffff code points that are a valid part of identifiers. The +// offset starts at 0x10000, and each pair of numbers represents an +// offset to the next range, and then a size of the range. They were +// generated by `bin/generate-identifier-regex.js`. + +/* prettier-ignore */ + +var astralIdentifierStartCodes = [0, 11, 2, 25, 2, 18, 2, 1, 2, 14, 3, 13, 35, 122, 70, 52, 268, 28, 4, 48, 48, 31, 14, 29, 6, 37, 11, 29, 3, 35, 5, 7, 2, 4, 43, 157, 19, 35, 5, 35, 5, 39, 9, 51, 157, 310, 10, 21, 11, 7, 153, 5, 3, 0, 2, 43, 2, 1, 4, 0, 3, 22, 11, 22, 10, 30, 66, 18, 2, 1, 11, 21, 11, 25, 71, 55, 7, 1, 65, 0, 16, 3, 2, 2, 2, 26, 45, 28, 4, 28, 36, 7, 2, 27, 28, 53, 11, 21, 11, 18, 14, 17, 111, 72, 56, 50, 14, 50, 785, 52, 76, 44, 33, 24, 27, 35, 42, 34, 4, 0, 13, 47, 15, 3, 22, 0, 2, 0, 36, 17, 2, 24, 85, 6, 2, 0, 2, 3, 2, 14, 2, 9, 8, 46, 39, 7, 3, 1, 3, 21, 2, 6, 2, 1, 2, 4, 4, 0, 19, 0, 13, 4, 159, 52, 19, 3, 54, 47, 21, 1, 2, 0, 185, 46, 42, 3, 37, 47, 21, 0, 60, 42, 86, 25, 391, 63, 32, 0, 257, 0, 11, 39, 8, 0, 22, 0, 12, 39, 3, 3, 55, 56, 264, 8, 2, 36, 18, 0, 50, 29, 113, 6, 2, 1, 2, 37, 22, 0, 698, 921, 103, 110, 18, 195, 2749, 1070, 4050, 582, 8634, 568, 8, 30, 114, 29, 19, 47, 17, 3, 32, 20, 6, 18, 881, 68, 12, 0, 67, 12, 65, 1, 31, 6124, 20, 754, 9486, 286, 82, 395, 2309, 106, 6, 12, 4, 8, 8, 9, 5991, 84, 2, 70, 2, 1, 3, 0, 3, 1, 3, 3, 2, 11, 2, 0, 2, 6, 2, 64, 2, 3, 3, 7, 2, 6, 2, 27, 2, 3, 2, 4, 2, 0, 4, 6, 2, 339, 3, 24, 2, 24, 2, 30, 2, 24, 2, 30, 2, 24, 2, 30, 2, 24, 2, 30, 2, 24, 2, 7, 4149, 196, 60, 67, 1213, 3, 2, 26, 2, 1, 2, 0, 3, 0, 2, 9, 2, 3, 2, 0, 2, 0, 7, 0, 5, 0, 2, 0, 2, 0, 2, 2, 2, 1, 2, 0, 3, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 3, 3, 2, 6, 2, 3, 2, 3, 2, 0, 2, 9, 2, 16, 6, 2, 2, 4, 2, 16, 4421, 42710, 42, 4148, 12, 221, 3, 5761, 15, 7472, 3104, 541]; +/* prettier-ignore */ + +var astralIdentifierCodes = [509, 0, 227, 0, 150, 4, 294, 9, 1368, 2, 2, 1, 6, 3, 41, 2, 5, 0, 166, 1, 1306, 2, 54, 14, 32, 9, 16, 3, 46, 10, 54, 9, 7, 2, 37, 13, 2, 9, 52, 0, 13, 2, 49, 13, 10, 2, 4, 9, 83, 11, 7, 0, 161, 11, 6, 9, 7, 3, 57, 0, 2, 6, 3, 1, 3, 2, 10, 0, 11, 1, 3, 6, 4, 4, 193, 17, 10, 9, 87, 19, 13, 9, 214, 6, 3, 8, 28, 1, 83, 16, 16, 9, 82, 12, 9, 9, 84, 14, 5, 9, 423, 9, 280, 9, 41, 6, 2, 3, 9, 0, 10, 10, 47, 15, 406, 7, 2, 7, 17, 9, 57, 21, 2, 13, 123, 5, 4, 0, 2, 1, 2, 6, 2, 0, 9, 9, 19719, 9, 135, 4, 60, 6, 26, 9, 1016, 45, 17, 3, 19723, 1, 5319, 4, 4, 5, 9, 7, 3, 6, 31, 3, 149, 2, 1418, 49, 513, 54, 5, 49, 9, 0, 15, 0, 23, 4, 2, 14, 1361, 6, 2, 16, 3, 6, 2, 1, 2, 4, 2214, 6, 110, 6, 6, 9, 792487, 239]; // This has a complexity linear to the value of the code. The +// assumption is that looking up astral identifier characters is +// rare. + +function isInAstralSet(code, set) { + var pos = 0x10000; + + for (var i = 0; i < set.length; i += 2) { + pos += set[i]; + if (pos > code) return false; + pos += set[i + 1]; + if (pos >= code) return true; + } + + return false; +} // Test whether a given character code starts an identifier. + + +function isIdentifierStart(code) { + if (code < 65) return code === 36; + if (code < 91) return true; + if (code < 97) return code === 95; + if (code < 123) return true; + + if (code <= 0xffff) { + return code >= 0xaa && nonASCIIidentifierStart.test(String.fromCharCode(code)); + } + + return isInAstralSet(code, astralIdentifierStartCodes); +} // Test whether a given character is part of an identifier. + +function isIdentifierChar(code) { + if (code < 48) return code === 36; + if (code < 58) return true; + if (code < 65) return false; + if (code < 91) return true; + if (code < 97) return code === 95; + if (code < 123) return true; + + if (code <= 0xffff) { + return code >= 0xaa && nonASCIIidentifier.test(String.fromCharCode(code)); + } + + return isInAstralSet(code, astralIdentifierStartCodes) || isInAstralSet(code, astralIdentifierCodes); +} + +// Matches a whole line break (where CRLF is considered a single +// line break). Used to count lines. +var lineBreak = /\r\n?|\n|\u2028|\u2029/; +var lineBreakG = new RegExp(lineBreak.source, "g"); +function isNewLine(code) { + return code === 10 || code === 13 || code === 0x2028 || code === 0x2029; +} +var nonASCIIwhitespace = /[\u1680\u180e\u2000-\u200a\u202f\u205f\u3000\ufeff]/; + +// The algorithm used to determine whether a regexp can appear at a +// given point in the program is loosely based on sweet.js' approach. +// See https://github.com/mozilla/sweet.js/wiki/design +var TokContext = function TokContext(token, isExpr, preserveSpace, override) // Takes a Tokenizer as a this-parameter, and returns void. +{ + this.token = token; + this.isExpr = !!isExpr; + this.preserveSpace = !!preserveSpace; + this.override = override; +}; +var types$1 = { + braceStatement: new TokContext("{", false), + braceExpression: new TokContext("{", true), + templateQuasi: new TokContext("${", true), + parenStatement: new TokContext("(", false), + parenExpression: new TokContext("(", true), + template: new TokContext("`", true, true, function (p) { + return p.readTmplToken(); + }), + functionExpression: new TokContext("function", true) +}; // Token-specific context update code + +types.parenR.updateContext = types.braceR.updateContext = function () { + if (this.state.context.length === 1) { + this.state.exprAllowed = true; + return; + } + + var out = this.state.context.pop(); + + if (out === types$1.braceStatement && this.curContext() === types$1.functionExpression) { + this.state.context.pop(); + this.state.exprAllowed = false; + } else if (out === types$1.templateQuasi) { + this.state.exprAllowed = true; + } else { + this.state.exprAllowed = !out.isExpr; + } +}; + +types.name.updateContext = function (prevType) { + if (this.state.value === "of" && this.curContext() === types$1.parenStatement) { + this.state.exprAllowed = !prevType.beforeExpr; + return; + } + + this.state.exprAllowed = false; + + if (prevType === types._let || prevType === types._const || prevType === types._var) { + if (lineBreak.test(this.input.slice(this.state.end))) { + this.state.exprAllowed = true; + } + } +}; + +types.braceL.updateContext = function (prevType) { + this.state.context.push(this.braceIsBlock(prevType) ? types$1.braceStatement : types$1.braceExpression); + this.state.exprAllowed = true; +}; + +types.dollarBraceL.updateContext = function () { + this.state.context.push(types$1.templateQuasi); + this.state.exprAllowed = true; +}; + +types.parenL.updateContext = function (prevType) { + var statementParens = prevType === types._if || prevType === types._for || prevType === types._with || prevType === types._while; + this.state.context.push(statementParens ? types$1.parenStatement : types$1.parenExpression); + this.state.exprAllowed = true; +}; + +types.incDec.updateContext = function () {// tokExprAllowed stays unchanged +}; + +types._function.updateContext = function () { + if (this.curContext() !== types$1.braceStatement) { + this.state.context.push(types$1.functionExpression); + } + + this.state.exprAllowed = false; +}; + +types.backQuote.updateContext = function () { + if (this.curContext() === types$1.template) { + this.state.context.pop(); + } else { + this.state.context.push(types$1.template); + } + + this.state.exprAllowed = false; +}; + +// These are used when `options.locations` is on, for the +// `startLoc` and `endLoc` properties. +var Position = function Position(line, col) { + this.line = line; + this.column = col; +}; +var SourceLocation = function SourceLocation(start, end) { + this.start = start; // $FlowIgnore (may start as null, but initialized later) + + this.end = end; +}; // The `getLineInfo` function is mostly useful when the +// `locations` option is off (for performance reasons) and you +// want to find the line/column position for a given character +// offset. `input` should be the code string that the offset refers +// into. + +function getLineInfo(input, offset) { + for (var line = 1, cur = 0;;) { + lineBreakG.lastIndex = cur; + var match = lineBreakG.exec(input); + + if (match && match.index < offset) { + ++line; + cur = match.index + match[0].length; + } else { + return new Position(line, offset - cur); + } + } // istanbul ignore next + + + throw new Error("Unreachable"); +} + +var BaseParser = +/*#__PURE__*/ +function () { + function BaseParser() {} + + var _proto = BaseParser.prototype; + + // Properties set by constructor in index.js + // Initialized by Tokenizer + _proto.isReservedWord = function isReservedWord(word) { + if (word === "await") { + return this.inModule; + } else { + return reservedWords[6](word); + } + }; + + _proto.hasPlugin = function hasPlugin(name) { + return !!this.plugins[name]; + }; + + return BaseParser; +}(); + +/* eslint max-len: 0 */ + +/** + * Based on the comment attachment algorithm used in espree and estraverse. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" + * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +function last(stack) { + return stack[stack.length - 1]; +} + +var CommentsParser = +/*#__PURE__*/ +function (_BaseParser) { + _inheritsLoose(CommentsParser, _BaseParser); + + function CommentsParser() { + return _BaseParser.apply(this, arguments) || this; + } + + var _proto = CommentsParser.prototype; + + _proto.addComment = function addComment(comment) { + if (this.filename) comment.loc.filename = this.filename; + this.state.trailingComments.push(comment); + this.state.leadingComments.push(comment); + }; + + _proto.processComment = function processComment(node) { + if (node.type === "Program" && node.body.length > 0) return; + var stack = this.state.commentStack; + var firstChild, lastChild, trailingComments, i, j; + + if (this.state.trailingComments.length > 0) { + // If the first comment in trailingComments comes after the + // current node, then we're good - all comments in the array will + // come after the node and so it's safe to add them as official + // trailingComments. + if (this.state.trailingComments[0].start >= node.end) { + trailingComments = this.state.trailingComments; + this.state.trailingComments = []; + } else { + // Otherwise, if the first comment doesn't come after the + // current node, that means we have a mix of leading and trailing + // comments in the array and that leadingComments contains the + // same items as trailingComments. Reset trailingComments to + // zero items and we'll handle this by evaluating leadingComments + // later. + this.state.trailingComments.length = 0; + } + } else { + if (stack.length > 0) { + var lastInStack = last(stack); + + if (lastInStack.trailingComments && lastInStack.trailingComments[0].start >= node.end) { + trailingComments = lastInStack.trailingComments; + lastInStack.trailingComments = null; + } + } + } // Eating the stack. + + + if (stack.length > 0 && last(stack).start >= node.start) { + firstChild = stack.pop(); + } + + while (stack.length > 0 && last(stack).start >= node.start) { + lastChild = stack.pop(); + } + + if (!lastChild && firstChild) lastChild = firstChild; // Attach comments that follow a trailing comma on the last + // property in an object literal or a trailing comma in function arguments + // as trailing comments + + if (firstChild && this.state.leadingComments.length > 0) { + var lastComment = last(this.state.leadingComments); + + if (firstChild.type === "ObjectProperty") { + if (lastComment.start >= node.start) { + if (this.state.commentPreviousNode) { + for (j = 0; j < this.state.leadingComments.length; j++) { + if (this.state.leadingComments[j].end < this.state.commentPreviousNode.end) { + this.state.leadingComments.splice(j, 1); + j--; + } + } + + if (this.state.leadingComments.length > 0) { + firstChild.trailingComments = this.state.leadingComments; + this.state.leadingComments = []; + } + } + } + } else if (node.type === "CallExpression" && node.arguments && node.arguments.length) { + var lastArg = last(node.arguments); + + if (lastArg && lastComment.start >= lastArg.start && lastComment.end <= node.end) { + if (this.state.commentPreviousNode) { + if (this.state.leadingComments.length > 0) { + lastArg.trailingComments = this.state.leadingComments; + this.state.leadingComments = []; + } + } + } + } + } + + if (lastChild) { + if (lastChild.leadingComments) { + if (lastChild !== node && lastChild.leadingComments.length > 0 && last(lastChild.leadingComments).end <= node.start) { + node.leadingComments = lastChild.leadingComments; + lastChild.leadingComments = null; + } else { + // A leading comment for an anonymous class had been stolen by its first ClassMethod, + // so this takes back the leading comment. + // See also: https://github.com/eslint/espree/issues/158 + for (i = lastChild.leadingComments.length - 2; i >= 0; --i) { + if (lastChild.leadingComments[i].end <= node.start) { + node.leadingComments = lastChild.leadingComments.splice(0, i + 1); + break; + } + } + } + } + } else if (this.state.leadingComments.length > 0) { + if (last(this.state.leadingComments).end <= node.start) { + if (this.state.commentPreviousNode) { + for (j = 0; j < this.state.leadingComments.length; j++) { + if (this.state.leadingComments[j].end < this.state.commentPreviousNode.end) { + this.state.leadingComments.splice(j, 1); + j--; + } + } + } + + if (this.state.leadingComments.length > 0) { + node.leadingComments = this.state.leadingComments; + this.state.leadingComments = []; + } + } else { + // https://github.com/eslint/espree/issues/2 + // + // In special cases, such as return (without a value) and + // debugger, all comments will end up as leadingComments and + // will otherwise be eliminated. This step runs when the + // commentStack is empty and there are comments left + // in leadingComments. + // + // This loop figures out the stopping point between the actual + // leading and trailing comments by finding the location of the + // first comment that comes after the given node. + for (i = 0; i < this.state.leadingComments.length; i++) { + if (this.state.leadingComments[i].end > node.start) { + break; + } + } // Split the array based on the location of the first comment + // that comes after the node. Keep in mind that this could + // result in an empty array, and if so, the array must be + // deleted. + + + var leadingComments = this.state.leadingComments.slice(0, i); + node.leadingComments = leadingComments.length === 0 ? null : leadingComments; // Similarly, trailing comments are attached later. The variable + // must be reset to null if there are no trailing comments. + + trailingComments = this.state.leadingComments.slice(i); + + if (trailingComments.length === 0) { + trailingComments = null; + } + } + } + + this.state.commentPreviousNode = node; + + if (trailingComments) { + if (trailingComments.length && trailingComments[0].start >= node.start && last(trailingComments).end <= node.end) { + node.innerComments = trailingComments; + } else { + node.trailingComments = trailingComments; + } + } + + stack.push(node); + }; + + return CommentsParser; +}(BaseParser); + +// takes an offset integer (into the current `input`) to indicate +// the location of the error, attaches the position to the end +// of the error message, and then raises a `SyntaxError` with that +// message. + +var LocationParser = +/*#__PURE__*/ +function (_CommentsParser) { + _inheritsLoose(LocationParser, _CommentsParser); + + function LocationParser() { + return _CommentsParser.apply(this, arguments) || this; + } + + var _proto = LocationParser.prototype; + + _proto.raise = function raise(pos, message, missingPluginNames) { + var loc = getLineInfo(this.input, pos); + message += ` (${loc.line}:${loc.column})`; // $FlowIgnore + + var err = new SyntaxError(message); + err.pos = pos; + err.loc = loc; + + if (missingPluginNames) { + err.missingPlugin = missingPluginNames; + } + + throw err; + }; + + return LocationParser; +}(CommentsParser); + +var State = +/*#__PURE__*/ +function () { + function State() {} + + var _proto = State.prototype; + + _proto.init = function init(options, input) { + this.strict = options.strictMode === false ? false : options.sourceType === "module"; + this.input = input; + this.potentialArrowAt = -1; + this.noArrowAt = []; + this.noArrowParamsConversionAt = []; // eslint-disable-next-line max-len + + this.inMethod = this.inFunction = this.inParameters = this.maybeInArrowParameters = this.inGenerator = this.inAsync = this.inPropertyName = this.inType = this.inClassProperty = this.noAnonFunctionType = false; + this.classLevel = 0; + this.labels = []; + this.decoratorStack = [[]]; + this.yieldInPossibleArrowParameters = null; + this.tokens = []; + this.comments = []; + this.trailingComments = []; + this.leadingComments = []; + this.commentStack = []; // $FlowIgnore + + this.commentPreviousNode = null; + this.pos = this.lineStart = 0; + this.curLine = options.startLine; + this.type = types.eof; + this.value = null; + this.start = this.end = this.pos; + this.startLoc = this.endLoc = this.curPosition(); // $FlowIgnore + + this.lastTokEndLoc = this.lastTokStartLoc = null; + this.lastTokStart = this.lastTokEnd = this.pos; + this.context = [types$1.braceStatement]; + this.exprAllowed = true; + this.containsEsc = this.containsOctal = false; + this.octalPosition = null; + this.invalidTemplateEscapePosition = null; + this.exportedIdentifiers = []; + }; // TODO + + + _proto.curPosition = function curPosition() { + return new Position(this.curLine, this.pos - this.lineStart); + }; + + _proto.clone = function clone(skipArrays) { + var _this = this; + + var state = new State(); + Object.keys(this).forEach(function (key) { + // $FlowIgnore + var val = _this[key]; + + if ((!skipArrays || key === "context") && Array.isArray(val)) { + val = val.slice(); + } // $FlowIgnore + + + state[key] = val; + }); + return state; + }; + + return State; +}(); + +var _isDigit = function isDigit(code) { + return code >= 48 && code <= 57; +}; + +/* eslint max-len: 0 */ +// an immediate sibling of NumericLiteralSeparator _ + +var forbiddenNumericSeparatorSiblings = { + decBinOct: [46, 66, 69, 79, 95, // multiple separators are not allowed + 98, 101, 111], + hex: [46, 88, 95, // multiple separators are not allowed + 120] +}; +var allowedNumericSeparatorSiblings = {}; +allowedNumericSeparatorSiblings.bin = [// 0 - 1 +48, 49]; +allowedNumericSeparatorSiblings.oct = allowedNumericSeparatorSiblings.bin.concat([50, 51, 52, 53, 54, 55]); +allowedNumericSeparatorSiblings.dec = allowedNumericSeparatorSiblings.oct.concat([56, 57]); +allowedNumericSeparatorSiblings.hex = allowedNumericSeparatorSiblings.dec.concat([65, 66, 67, 68, 69, 70, 97, 98, 99, 100, 101, 102]); // Object type used to represent tokens. Note that normally, tokens +// simply exist as properties on the parser object. This is only +// used for the onToken callback and the external tokenizer. + +var Token = function Token(state) { + this.type = state.type; + this.value = state.value; + this.start = state.start; + this.end = state.end; + this.loc = new SourceLocation(state.startLoc, state.endLoc); +}; // ## Tokenizer + +function codePointToString(code) { + // UTF-16 Decoding + if (code <= 0xffff) { + return String.fromCharCode(code); + } else { + return String.fromCharCode((code - 0x10000 >> 10) + 0xd800, (code - 0x10000 & 1023) + 0xdc00); + } +} + +var Tokenizer = +/*#__PURE__*/ +function (_LocationParser) { + _inheritsLoose(Tokenizer, _LocationParser); + + // Forward-declarations + // parser/util.js + function Tokenizer(options, input) { + var _this; + + _this = _LocationParser.call(this) || this; + _this.state = new State(); + + _this.state.init(options, input); + + _this.isLookahead = false; + return _this; + } // Move to the next token + + + var _proto = Tokenizer.prototype; + + _proto.next = function next() { + if (this.options.tokens && !this.isLookahead) { + this.state.tokens.push(new Token(this.state)); + } + + this.state.lastTokEnd = this.state.end; + this.state.lastTokStart = this.state.start; + this.state.lastTokEndLoc = this.state.endLoc; + this.state.lastTokStartLoc = this.state.startLoc; + this.nextToken(); + }; // TODO + + + _proto.eat = function eat(type) { + if (this.match(type)) { + this.next(); + return true; + } else { + return false; + } + }; // TODO + + + _proto.match = function match(type) { + return this.state.type === type; + }; // TODO + + + _proto.isKeyword = function isKeyword$$1(word) { + return isKeyword(word); + }; // TODO + + + _proto.lookahead = function lookahead() { + var old = this.state; + this.state = old.clone(true); + this.isLookahead = true; + this.next(); + this.isLookahead = false; + var curr = this.state; + this.state = old; + return curr; + }; // Toggle strict mode. Re-reads the next number or string to please + // pedantic tests (`"use strict"; 010;` should fail). + + + _proto.setStrict = function setStrict(strict) { + this.state.strict = strict; + if (!this.match(types.num) && !this.match(types.string)) return; + this.state.pos = this.state.start; + + while (this.state.pos < this.state.lineStart) { + this.state.lineStart = this.input.lastIndexOf("\n", this.state.lineStart - 2) + 1; + --this.state.curLine; + } + + this.nextToken(); + }; + + _proto.curContext = function curContext() { + return this.state.context[this.state.context.length - 1]; + }; // Read a single token, updating the parser object's token-related + // properties. + + + _proto.nextToken = function nextToken() { + var curContext = this.curContext(); + if (!curContext || !curContext.preserveSpace) this.skipSpace(); + this.state.containsOctal = false; + this.state.octalPosition = null; + this.state.start = this.state.pos; + this.state.startLoc = this.state.curPosition(); + + if (this.state.pos >= this.input.length) { + this.finishToken(types.eof); + return; + } + + if (curContext.override) { + curContext.override(this); + } else { + this.readToken(this.fullCharCodeAtPos()); + } + }; + + _proto.readToken = function readToken(code) { + // Identifier or keyword. '\uXXXX' sequences are allowed in + // identifiers, so '\' also dispatches to that. + if (isIdentifierStart(code) || code === 92) { + this.readWord(); + } else { + this.getTokenFromCode(code); + } + }; + + _proto.fullCharCodeAtPos = function fullCharCodeAtPos() { + var code = this.input.charCodeAt(this.state.pos); + if (code <= 0xd7ff || code >= 0xe000) return code; + var next = this.input.charCodeAt(this.state.pos + 1); + return (code << 10) + next - 0x35fdc00; + }; + + _proto.pushComment = function pushComment(block, text, start, end, startLoc, endLoc) { + var comment = { + type: block ? "CommentBlock" : "CommentLine", + value: text, + start: start, + end: end, + loc: new SourceLocation(startLoc, endLoc) + }; + + if (!this.isLookahead) { + if (this.options.tokens) this.state.tokens.push(comment); + this.state.comments.push(comment); + this.addComment(comment); + } + }; + + _proto.skipBlockComment = function skipBlockComment() { + var startLoc = this.state.curPosition(); + var start = this.state.pos; + var end = this.input.indexOf("*/", this.state.pos += 2); + if (end === -1) this.raise(this.state.pos - 2, "Unterminated comment"); + this.state.pos = end + 2; + lineBreakG.lastIndex = start; + var match; + + while ((match = lineBreakG.exec(this.input)) && match.index < this.state.pos) { + ++this.state.curLine; + this.state.lineStart = match.index + match[0].length; + } + + this.pushComment(true, this.input.slice(start + 2, end), start, this.state.pos, startLoc, this.state.curPosition()); + }; + + _proto.skipLineComment = function skipLineComment(startSkip) { + var start = this.state.pos; + var startLoc = this.state.curPosition(); + var ch = this.input.charCodeAt(this.state.pos += startSkip); + + if (this.state.pos < this.input.length) { + while (ch !== 10 && ch !== 13 && ch !== 8232 && ch !== 8233 && ++this.state.pos < this.input.length) { + ch = this.input.charCodeAt(this.state.pos); + } + } + + this.pushComment(false, this.input.slice(start + startSkip, this.state.pos), start, this.state.pos, startLoc, this.state.curPosition()); + }; // Called at the start of the parse and after every token. Skips + // whitespace and comments, and. + + + _proto.skipSpace = function skipSpace() { + loop: while (this.state.pos < this.input.length) { + var ch = this.input.charCodeAt(this.state.pos); + + switch (ch) { + case 32: + case 160: + ++this.state.pos; + break; + + case 13: + if (this.input.charCodeAt(this.state.pos + 1) === 10) { + ++this.state.pos; + } + + case 10: + case 8232: + case 8233: + ++this.state.pos; + ++this.state.curLine; + this.state.lineStart = this.state.pos; + break; + + case 47: + switch (this.input.charCodeAt(this.state.pos + 1)) { + case 42: + this.skipBlockComment(); + break; + + case 47: + this.skipLineComment(2); + break; + + default: + break loop; + } + + break; + + default: + if (ch > 8 && ch < 14 || ch >= 5760 && nonASCIIwhitespace.test(String.fromCharCode(ch))) { + ++this.state.pos; + } else { + break loop; + } + + } + } + }; // Called at the end of every token. Sets `end`, `val`, and + // maintains `context` and `exprAllowed`, and skips the space after + // the token, so that the next one's `start` will point at the + // right position. + + + _proto.finishToken = function finishToken(type, val) { + this.state.end = this.state.pos; + this.state.endLoc = this.state.curPosition(); + var prevType = this.state.type; + this.state.type = type; + this.state.value = val; + this.updateContext(prevType); + }; // ### Token reading + // This is the function that is called to fetch the next token. It + // is somewhat obscure, because it works in character codes rather + // than characters, and because operator parsing has been inlined + // into it. + // + // All in the name of speed. + // + + + _proto.readToken_dot = function readToken_dot() { + var next = this.input.charCodeAt(this.state.pos + 1); + + if (next >= 48 && next <= 57) { + this.readNumber(true); + return; + } + + var next2 = this.input.charCodeAt(this.state.pos + 2); + + if (next === 46 && next2 === 46) { + this.state.pos += 3; + this.finishToken(types.ellipsis); + } else { + ++this.state.pos; + this.finishToken(types.dot); + } + }; + + _proto.readToken_slash = function readToken_slash() { + // '/' + if (this.state.exprAllowed) { + ++this.state.pos; + this.readRegexp(); + return; + } + + var next = this.input.charCodeAt(this.state.pos + 1); + + if (next === 61) { + this.finishOp(types.assign, 2); + } else { + this.finishOp(types.slash, 1); + } + }; + + _proto.readToken_mult_modulo = function readToken_mult_modulo(code) { + // '%*' + var type = code === 42 ? types.star : types.modulo; + var width = 1; + var next = this.input.charCodeAt(this.state.pos + 1); + var exprAllowed = this.state.exprAllowed; // Exponentiation operator ** + + if (code === 42 && next === 42) { + width++; + next = this.input.charCodeAt(this.state.pos + 2); + type = types.exponent; + } + + if (next === 61 && !exprAllowed) { + width++; + type = types.assign; + } + + this.finishOp(type, width); + }; + + _proto.readToken_pipe_amp = function readToken_pipe_amp(code) { + // '|&' + var next = this.input.charCodeAt(this.state.pos + 1); + + if (next === code) { + this.finishOp(code === 124 ? types.logicalOR : types.logicalAND, 2); + return; + } + + if (code === 124) { + // '|>' + if (next === 62) { + this.finishOp(types.pipeline, 2); + return; + } else if (next === 125 && this.hasPlugin("flow")) { + // '|}' + this.finishOp(types.braceBarR, 2); + return; + } + } + + if (next === 61) { + this.finishOp(types.assign, 2); + return; + } + + this.finishOp(code === 124 ? types.bitwiseOR : types.bitwiseAND, 1); + }; + + _proto.readToken_caret = function readToken_caret() { + // '^' + var next = this.input.charCodeAt(this.state.pos + 1); + + if (next === 61) { + this.finishOp(types.assign, 2); + } else { + this.finishOp(types.bitwiseXOR, 1); + } + }; + + _proto.readToken_plus_min = function readToken_plus_min(code) { + // '+-' + var next = this.input.charCodeAt(this.state.pos + 1); + + if (next === code) { + if (next === 45 && !this.inModule && this.input.charCodeAt(this.state.pos + 2) === 62 && lineBreak.test(this.input.slice(this.state.lastTokEnd, this.state.pos))) { + // A `-->` line comment + this.skipLineComment(3); + this.skipSpace(); + this.nextToken(); + return; + } + + this.finishOp(types.incDec, 2); + return; + } + + if (next === 61) { + this.finishOp(types.assign, 2); + } else { + this.finishOp(types.plusMin, 1); + } + }; + + _proto.readToken_lt_gt = function readToken_lt_gt(code) { + // '<>' + var next = this.input.charCodeAt(this.state.pos + 1); + var size = 1; + + if (next === code) { + size = code === 62 && this.input.charCodeAt(this.state.pos + 2) === 62 ? 3 : 2; + + if (this.input.charCodeAt(this.state.pos + size) === 61) { + this.finishOp(types.assign, size + 1); + return; + } + + this.finishOp(types.bitShift, size); + return; + } + + if (next === 33 && code === 60 && !this.inModule && this.input.charCodeAt(this.state.pos + 2) === 45 && this.input.charCodeAt(this.state.pos + 3) === 45) { + // `