diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2a08d7bd3d1..32e5fa02b36 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -19,7 +19,7 @@ jobs: node-version: [10.x, 12.x, 13.x] steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v2 with: fetch-depth: 5 - name: Use node version ${{ matrix.node-version }} @@ -45,4 +45,4 @@ jobs: - name: Validate the browser can import TypeScript run: gulp test-browser-integration - \ No newline at end of file + diff --git a/.github/workflows/nightly.yaml b/.github/workflows/nightly.yaml index 99a8a007ac3..24c3ed774f3 100644 --- a/.github/workflows/nightly.yaml +++ b/.github/workflows/nightly.yaml @@ -3,6 +3,8 @@ name: Publish Nightly on: schedule: - cron: '0 7 * * *' + # enable users to manually trigger with workflow_dispatch + workflow_dispatch: {} repository_dispatch: types: publish-nightly diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 756b2a12028..9c7f69b24e2 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -63,7 +63,7 @@ TypeScript is currently accepting contributions in the form of bug fixes. A bug ## Contributing features -Features (things that add new or improved functionality to TypeScript) may be accepted, but will need to first be approved (labelled ["help wanted"](https://github.com/Microsoft/TypeScript/issues?q=is%3Aopen+is%3Aissue+label%3A%22help+wanted%22) or in the "Backlog" milestone) by a TypeScript project maintainer) in the suggestion issue. Features with language design impact, or that are adequately satisfied with external tools, will not be accepted. +Features (things that add new or improved functionality to TypeScript) may be accepted, but will need to first be approved (labelled ["help wanted"](https://github.com/Microsoft/TypeScript/issues?q=is%3Aopen+is%3Aissue+label%3A%22help+wanted%22) or in the "Backlog" milestone) by a TypeScript project maintainer in the suggestion issue. Features with language design impact, or that are adequately satisfied with external tools, will not be accepted. Design changes will not be accepted at this time. If you have a design change proposal, please log a suggestion issue. diff --git a/src/compat/deprecations.ts b/src/compat/deprecations.ts index e9a6dc3b9a8..ed1034b7e6a 100644 --- a/src/compat/deprecations.ts +++ b/src/compat/deprecations.ts @@ -1321,4 +1321,24 @@ namespace ts { }); // #endregion Renamed node Tests + + // DEPRECATION: Renamed `Map` and `ReadonlyMap` interfaces + // DEPRECATION PLAN: + // - soft: 4.0 + // - remove: TBD (will remove for at least one release before replacing with `ESMap`/`ReadonlyESMap`) + // - replace: TBD (will eventually replace with `ESMap`/`ReadonlyESMap`) + // #region Renamed `Map` and `ReadonlyMap` interfaces + + /** + * @deprecated Use `ts.ReadonlyESMap` instead. + */ + export interface ReadonlyMap extends ReadonlyESMap { + } + + /** + * @deprecated Use `ts.ESMap` instead. + */ + export interface Map extends ESMap { } + + // #endregion } \ No newline at end of file diff --git a/src/compiler/binder.ts b/src/compiler/binder.ts index b9126ca464c..f61aa3ab900 100644 --- a/src/compiler/binder.ts +++ b/src/compiler/binder.ts @@ -218,7 +218,7 @@ namespace ts { let symbolCount = 0; let Symbol: new (flags: SymbolFlags, name: __String) => Symbol; - let classifiableNames: UnderscoreEscapedMap; + let classifiableNames: Set<__String>; const unreachableFlow: FlowNode = { flags: FlowFlags.Unreachable }; const reportedUnreachableFlow: FlowNode = { flags: FlowFlags.Unreachable }; @@ -237,7 +237,7 @@ namespace ts { options = opts; languageVersion = getEmitScriptTarget(options); inStrictMode = bindInStrictMode(file, opts); - classifiableNames = createUnderscoreEscapedMap(); + classifiableNames = new Set(); symbolCount = 0; Symbol = objectAllocator.getSymbolConstructor(); @@ -445,7 +445,7 @@ namespace ts { symbol = symbolTable.get(name); if (includes & SymbolFlags.Classifiable) { - classifiableNames.set(name, true); + classifiableNames.add(name); } if (!symbol) { @@ -1965,7 +1965,7 @@ namespace ts { } if (inStrictMode && !isAssignmentTarget(node)) { - const seen = createUnderscoreEscapedMap(); + const seen = new Map<__String, ElementKind>(); for (const prop of node.properties) { if (prop.kind === SyntaxKind.SpreadAssignment || prop.name.kind !== SyntaxKind.Identifier) { @@ -2980,6 +2980,9 @@ namespace ts { } function bindPotentiallyMissingNamespaces(namespaceSymbol: Symbol | undefined, entityName: BindableStaticNameExpression, isToplevel: boolean, isPrototypeProperty: boolean, containerIsClass: boolean) { + if (namespaceSymbol?.flags! & SymbolFlags.Alias) { + return namespaceSymbol; + } if (isToplevel && !isPrototypeProperty) { // make symbols or add declarations for intermediate containers const flags = SymbolFlags.Module | SymbolFlags.Assignment; @@ -3143,7 +3146,7 @@ namespace ts { bindAnonymousDeclaration(node, SymbolFlags.Class, bindingName); // Add name of class expression into the map for semantic classifier if (node.name) { - classifiableNames.set(node.name.escapedText, true); + classifiableNames.add(node.name.escapedText); } } diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index c9f61599a1d..a0ff7fdf895 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -134,7 +134,7 @@ namespace ts { EmptyObjectFacts = All, } - const typeofEQFacts: ReadonlyESMap = createMapFromTemplate({ + const typeofEQFacts: ReadonlyESMap = new Map(getEntries({ string: TypeFacts.TypeofEQString, number: TypeFacts.TypeofEQNumber, bigint: TypeFacts.TypeofEQBigInt, @@ -143,9 +143,9 @@ namespace ts { undefined: TypeFacts.EQUndefined, object: TypeFacts.TypeofEQObject, function: TypeFacts.TypeofEQFunction - }); + })); - const typeofNEFacts: ReadonlyESMap = createMapFromTemplate({ + const typeofNEFacts: ReadonlyESMap = new Map(getEntries({ string: TypeFacts.TypeofNEString, number: TypeFacts.TypeofNENumber, bigint: TypeFacts.TypeofNEBigInt, @@ -154,7 +154,7 @@ namespace ts { undefined: TypeFacts.NEUndefined, object: TypeFacts.TypeofNEObject, function: TypeFacts.TypeofNEFunction - }); + })); type TypeSystemEntity = Node | Symbol | Type | Signature; @@ -261,7 +261,7 @@ namespace ts { return node.id; } - export function getSymbolId(symbol: Symbol): number { + export function getSymbolId(symbol: Symbol): SymbolId { if (!symbol.id) { symbol.id = nextSymbolId; nextSymbolId++; @@ -685,14 +685,14 @@ namespace ts { return res; } - const tupleTypes = createMap(); - const unionTypes = createMap(); - const intersectionTypes = createMap(); - const literalTypes = createMap(); - const indexedAccessTypes = createMap(); - const substitutionTypes = createMap(); + const tupleTypes = new Map(); + const unionTypes = new Map(); + const intersectionTypes = new Map(); + const literalTypes = new Map(); + const indexedAccessTypes = new Map(); + const substitutionTypes = new Map(); const evolvingArrayTypes: EvolvingArrayType[] = []; - const undefinedProperties = createMap() as UnderscoreEscapedMap; + const undefinedProperties: SymbolTable = new Map(); const unknownSymbol = createSymbol(SymbolFlags.Property, "unknown" as __String); const resolvingSymbol = createSymbol(0, InternalSymbolName.Resolving); @@ -753,7 +753,7 @@ namespace ts { const emptyTypeLiteralType = createAnonymousType(emptyTypeLiteralSymbol, emptySymbols, emptyArray, emptyArray, undefined, undefined); const emptyGenericType = createAnonymousType(undefined, emptySymbols, emptyArray, emptyArray, undefined, undefined); - emptyGenericType.instantiations = createMap(); + emptyGenericType.instantiations = new Map(); const anyFunctionType = createAnonymousType(undefined, emptySymbols, emptyArray, emptyArray, undefined, undefined); // The anyFunctionType contains the anyFunctionType by definition. The flag is further propagated @@ -778,7 +778,7 @@ namespace ts { const enumNumberIndexInfo = createIndexInfo(stringType, /*isReadonly*/ true); - const iterationTypesCache = createMap(); // cache for common IterationTypes instances + const iterationTypesCache = new Map(); // cache for common IterationTypes instances const noIterationTypes: IterationTypes = { get yieldType(): Type { return Debug.fail("Not supported"); }, get returnType(): Type { return Debug.fail("Not supported"); }, @@ -830,7 +830,7 @@ namespace ts { } /** Key is "/path/to/a.ts|/path/to/b.ts". */ let amalgamatedDuplicates: ESMap | undefined; - const reverseMappedCache = createMap(); + const reverseMappedCache = new Map(); let inInferTypeForHomomorphicMappedType = false; let ambientModulesCache: Symbol[] | undefined; /** @@ -883,7 +883,7 @@ namespace ts { let deferredGlobalOmitSymbol: Symbol; let deferredGlobalBigIntType: ObjectType; - const allPotentiallyUnusedIdentifiers = createMap(); // key is file name + const allPotentiallyUnusedIdentifiers = new Map(); // key is file name let flowLoopStart = 0; let flowLoopCount = 0; @@ -923,26 +923,26 @@ namespace ts { const diagnostics = createDiagnosticCollection(); const suggestionDiagnostics = createDiagnosticCollection(); - const typeofTypesByName: ReadonlyESMap = createMapFromTemplate({ + const typeofTypesByName: ReadonlyESMap = new Map(getEntries({ string: stringType, number: numberType, bigint: bigintType, boolean: booleanType, symbol: esSymbolType, undefined: undefinedType - }); + })); const typeofType = createTypeofType(); let _jsxNamespace: __String; let _jsxFactoryEntity: EntityName | undefined; let outofbandVarianceMarkerHandler: ((onlyUnreliable: boolean) => void) | undefined; - const subtypeRelation = createMap(); - const strictSubtypeRelation = createMap(); - const assignableRelation = createMap(); - const comparableRelation = createMap(); - const identityRelation = createMap(); - const enumRelation = createMap(); + const subtypeRelation = new Map(); + const strictSubtypeRelation = new Map(); + const assignableRelation = new Map(); + const comparableRelation = new Map(); + const identityRelation = new Map(); + const enumRelation = new Map(); const builtinGlobals = createSymbolTable(); builtinGlobals.set(undefinedSymbol.escapedName, undefinedSymbol); @@ -1111,8 +1111,8 @@ namespace ts { result.parent = symbol.parent; if (symbol.valueDeclaration) result.valueDeclaration = symbol.valueDeclaration; if (symbol.constEnumOnlyModule) result.constEnumOnlyModule = true; - if (symbol.members) result.members = cloneMap(symbol.members); - if (symbol.exports) result.exports = cloneMap(symbol.exports); + if (symbol.members) result.members = new Map(symbol.members); + if (symbol.exports) result.exports = new Map(symbol.exports); recordMergedSymbol(result, symbol); return result; } @@ -1182,10 +1182,10 @@ namespace ts { if (sourceSymbolFile && targetSymbolFile && amalgamatedDuplicates && !isEitherEnum && sourceSymbolFile !== targetSymbolFile) { const firstFile = comparePaths(sourceSymbolFile.path, targetSymbolFile.path) === Comparison.LessThan ? sourceSymbolFile : targetSymbolFile; const secondFile = firstFile === sourceSymbolFile ? targetSymbolFile : sourceSymbolFile; - const filesDuplicates = getOrUpdate(amalgamatedDuplicates, `${firstFile.path}|${secondFile.path}`, () => - ({ firstFile, secondFile, conflictingSymbols: createMap() })); - const conflictingSymbolInfo = getOrUpdate(filesDuplicates.conflictingSymbols, symbolName, () => - ({ isBlockScoped: isEitherBlockScoped, firstFileLocations: [], secondFileLocations: [] })); + const filesDuplicates = getOrUpdate(amalgamatedDuplicates, `${firstFile.path}|${secondFile.path}`, () => + ({ firstFile, secondFile, conflictingSymbols: new Map() } as DuplicateInfoForFiles)); + const conflictingSymbolInfo = getOrUpdate(filesDuplicates.conflictingSymbols, symbolName, () => + ({ isBlockScoped: isEitherBlockScoped, firstFileLocations: [], secondFileLocations: [] } as DuplicateInfoForSymbol)); addDuplicateLocations(conflictingSymbolInfo.firstFileLocations, source); addDuplicateLocations(conflictingSymbolInfo.secondFileLocations, target); } @@ -1224,8 +1224,8 @@ namespace ts { } function combineSymbolTables(first: SymbolTable | undefined, second: SymbolTable | undefined): SymbolTable | undefined { - if (!hasEntries(first)) return second; - if (!hasEntries(second)) return first; + if (!first?.size) return second; + if (!second?.size) return first; const combined = createSymbolTable(); mergeSymbolTable(combined, first); mergeSymbolTable(combined, second); @@ -1273,7 +1273,7 @@ namespace ts { if (some(patternAmbientModules, module => mainModule === module.symbol)) { const merged = mergeSymbol(moduleAugmentation.symbol, mainModule, /*unidirectional*/ true); if (!patternAmbientModuleAugmentations) { - patternAmbientModuleAugmentations = createMap(); + patternAmbientModuleAugmentations = new Map(); } // moduleName will be a StringLiteral since this is not `declare global`. patternAmbientModuleAugmentations.set((moduleName as StringLiteral).text, merged); @@ -2573,8 +2573,8 @@ namespace ts { result.declarations = deduplicate(concatenate(valueSymbol.declarations, typeSymbol.declarations), equateValues); result.parent = valueSymbol.parent || typeSymbol.parent; if (valueSymbol.valueDeclaration) result.valueDeclaration = valueSymbol.valueDeclaration; - if (typeSymbol.members) result.members = cloneMap(typeSymbol.members); - if (valueSymbol.exports) result.exports = cloneMap(valueSymbol.exports); + if (typeSymbol.members) result.members = new Map(typeSymbol.members); + if (valueSymbol.exports) result.exports = new Map(valueSymbol.exports); return result; } @@ -3300,8 +3300,8 @@ namespace ts { result.originatingImport = referenceParent; if (symbol.valueDeclaration) result.valueDeclaration = symbol.valueDeclaration; if (symbol.constEnumOnlyModule) result.constEnumOnlyModule = true; - if (symbol.members) result.members = cloneMap(symbol.members); - if (symbol.exports) result.exports = cloneMap(symbol.exports); + if (symbol.members) result.members = new Map(symbol.members); + if (symbol.exports) result.exports = new Map(symbol.exports); const resolvedModuleType = resolveStructuredTypeMembers(moduleType as StructuredType); // Should already be resolved from the signature checks above result.type = createAnonymousType(result, resolvedModuleType.members, emptyArray, emptyArray, resolvedModuleType.stringIndexInfo, resolvedModuleType.numberIndexInfo); return result; @@ -3417,12 +3417,12 @@ namespace ts { if (!(symbol && symbol.exports && pushIfUnique(visitedSymbols, symbol))) { return; } - const symbols = cloneMap(symbol.exports); + const symbols = new Map(symbol.exports); // All export * declarations are collected in an __export symbol by the binder const exportStars = symbol.exports.get(InternalSymbolName.ExportStar); if (exportStars) { const nestedSymbols = createSymbolTable(); - const lookupTable = createMap() as ExportCollisionTrackerTable; + const lookupTable: ExportCollisionTrackerTable = new Map(); for (const node of exportStars.declarations) { const resolvedModule = resolveExternalModuleName(node, (node as ExportDeclaration).moduleSpecifier!); const exportedSymbols = visit(resolvedModule); @@ -3472,7 +3472,7 @@ namespace ts { function getAlternativeContainingModules(symbol: Symbol, enclosingDeclaration: Node): Symbol[] { const containingFile = getSourceFileOfNode(enclosingDeclaration); - const id = "" + getNodeId(containingFile); + const id = getNodeId(containingFile); const links = getSymbolLinks(symbol); let results: Symbol[] | undefined; if (links.extendedContainersByFile && (results = links.extendedContainersByFile.get(id))) { @@ -3489,7 +3489,7 @@ namespace ts { results = append(results, resolvedModule); } if (length(results)) { - (links.extendedContainersByFile || (links.extendedContainersByFile = createMap())).set(id, results!); + (links.extendedContainersByFile || (links.extendedContainersByFile = new Map())).set(id, results!); return results!; } } @@ -3753,12 +3753,12 @@ namespace ts { return rightMeaning === SymbolFlags.Value ? SymbolFlags.Value : SymbolFlags.Namespace; } - function getAccessibleSymbolChain(symbol: Symbol | undefined, enclosingDeclaration: Node | undefined, meaning: SymbolFlags, useOnlyExternalAliasing: boolean, visitedSymbolTablesMap: ESMap = createMap()): Symbol[] | undefined { + function getAccessibleSymbolChain(symbol: Symbol | undefined, enclosingDeclaration: Node | undefined, meaning: SymbolFlags, useOnlyExternalAliasing: boolean, visitedSymbolTablesMap: ESMap = new Map()): Symbol[] | undefined { if (!(symbol && !isPropertyOrMethodDeclarationSymbol(symbol))) { return undefined; } - const id = "" + getSymbolId(symbol); + const id = getSymbolId(symbol); let visitedSymbolTables = visitedSymbolTablesMap.get(id); if (!visitedSymbolTables) { visitedSymbolTablesMap.set(id, visitedSymbolTables = []); @@ -4551,7 +4551,7 @@ namespace ts { context.visitedTypes = new Set(); } if (id && !context.symbolDepth) { - context.symbolDepth = createMap(); + context.symbolDepth = new Map(); } let depth: number | undefined; @@ -5094,6 +5094,9 @@ namespace ts { if (parameterDeclaration && isRequiredInitializedParameter(parameterDeclaration)) { parameterType = getOptionalType(parameterType); } + if ((context.flags & NodeBuilderFlags.NoUndefinedOptionalParameterType) && parameterDeclaration && !isJSDocParameterTag(parameterDeclaration) && isOptionalUninitializedParameter(parameterDeclaration)) { + parameterType = getTypeWithFacts(parameterType, TypeFacts.NEUndefined); + } const parameterTypeNode = serializeTypeForDeclaration(context, parameterType, parameterSymbol, context.enclosingDeclaration, privateSymbolVisitor, bundledImports); const modifiers = !(context.flags & NodeBuilderFlags.OmitParameterModifiers) && preserveModifierFlags && parameterDeclaration && parameterDeclaration.modifiers ? parameterDeclaration.modifiers.map(factory.cloneNode) : undefined; @@ -5333,7 +5336,7 @@ namespace ts { moduleResolverHost, { importModuleSpecifierPreference: isBundle ? "non-relative" : "relative" }, )); - links.specifierCache = links.specifierCache || createMap(); + links.specifierCache ??= new Map(); links.specifierCache.set(contextFile.path, specifier); } return specifier; @@ -5455,7 +5458,7 @@ namespace ts { function typeParameterToName(type: TypeParameter, context: NodeBuilderContext) { if (context.flags & NodeBuilderFlags.GenerateNamesForShadowedTypeParams && context.typeParameterNames) { - const cached = context.typeParameterNames.get("" + getTypeId(type)); + const cached = context.typeParameterNames.get(getTypeId(type)); if (cached) { return cached; } @@ -5475,7 +5478,7 @@ namespace ts { if (text !== rawtext) { result = factory.createIdentifier(text, result.typeArguments); } - (context.typeParameterNames || (context.typeParameterNames = createMap())).set("" + getTypeId(type), result); + (context.typeParameterNames || (context.typeParameterNames = new Map())).set(getTypeId(type), result); (context.typeParameterNamesByText || (context.typeParameterNamesByText = new Set())).add(result.escapedText as string); } return result; @@ -5632,7 +5635,7 @@ namespace ts { // export const x: (x: T) => T // export const y: (x: T_1) => T_1 if (initial.typeParameterNames) { - initial.typeParameterNames = cloneMap(initial.typeParameterNames); + initial.typeParameterNames = new Map(initial.typeParameterNames); } if (initial.typeParameterNamesByText) { initial.typeParameterNamesByText = new Set(initial.typeParameterNamesByText); @@ -5878,12 +5881,12 @@ namespace ts { const enclosingDeclaration = context.enclosingDeclaration!; let results: Statement[] = []; const visitedSymbols = new Set(); - let deferredPrivates: ESMap | undefined; + let deferredPrivates: ESMap | undefined; const oldcontext = context; context = { ...oldcontext, usedSymbolNames: new Set(oldcontext.usedSymbolNames), - remappedSymbolNames: createMap(), + remappedSymbolNames: new Map(), tracker: { ...oldcontext.tracker, trackSymbol: (sym, decl, meaning) => { @@ -6091,7 +6094,7 @@ namespace ts { function visitSymbolTable(symbolTable: SymbolTable, suppressNewPrivateContext?: boolean, propertyAsAlias?: boolean) { const oldDeferredPrivates = deferredPrivates; if (!suppressNewPrivateContext) { - deferredPrivates = createMap(); + deferredPrivates = new Map(); } symbolTable.forEach((symbol: Symbol) => { serializeSymbol(symbol, /*isPrivate*/ false, !!propertyAsAlias); @@ -6290,7 +6293,7 @@ namespace ts { if (some(symbol.declarations, isParameterDeclaration)) return; Debug.assertIsDefined(deferredPrivates); getUnusedName(unescapeLeadingUnderscores(symbol.escapedName), symbol); // Call to cache unique name for symbol - deferredPrivates.set("" + getSymbolId(symbol), symbol); + deferredPrivates.set(getSymbolId(symbol), symbol); } function isExportingScope(enclosingDeclaration: Node) { @@ -6510,7 +6513,8 @@ namespace ts { } function isNamespaceMember(p: Symbol) { - return !(p.flags & SymbolFlags.Prototype || p.escapedName === "prototype" || p.valueDeclaration && isClassLike(p.valueDeclaration.parent)); + return !!(p.flags & (SymbolFlags.Type | SymbolFlags.Namespace | SymbolFlags.Alias)) || + !(p.flags & SymbolFlags.Prototype || p.escapedName === "prototype" || p.valueDeclaration && isClassLike(p.valueDeclaration.parent)); } function serializeAsClass(symbol: Symbol, localName: string, modifierFlags: ModifierFlags) { @@ -7059,9 +7063,10 @@ namespace ts { } function getUnusedName(input: string, symbol?: Symbol): string { - if (symbol) { - if (context.remappedSymbolNames!.has("" + getSymbolId(symbol))) { - return context.remappedSymbolNames!.get("" + getSymbolId(symbol))!; + const id = symbol ? getSymbolId(symbol) : undefined; + if (id) { + if (context.remappedSymbolNames!.has(id)) { + return context.remappedSymbolNames!.get(id)!; } } if (symbol) { @@ -7074,8 +7079,8 @@ namespace ts { input = `${original}_${i}`; } context.usedSymbolNames?.add(input); - if (symbol) { - context.remappedSymbolNames!.set("" + getSymbolId(symbol), input); + if (id) { + context.remappedSymbolNames!.set(id, input); } return input; } @@ -7099,12 +7104,13 @@ namespace ts { } function getInternalSymbolName(symbol: Symbol, localName: string) { - if (context.remappedSymbolNames!.has("" + getSymbolId(symbol))) { - return context.remappedSymbolNames!.get("" + getSymbolId(symbol))!; + const id = getSymbolId(symbol); + if (context.remappedSymbolNames!.has(id)) { + return context.remappedSymbolNames!.get(id)!; } localName = getNameCandidateWorker(symbol, localName); // The result of this is going to be used as the symbol's name - lock it in, so `getUnusedName` will also pick it up - context.remappedSymbolNames!.set("" + getSymbolId(symbol), localName); + context.remappedSymbolNames!.set(id, localName); return localName; } } @@ -7191,10 +7197,10 @@ namespace ts { approximateLength: number; truncating?: boolean; typeParameterSymbolList?: Set; - typeParameterNames?: ESMap; + typeParameterNames?: ESMap; typeParameterNamesByText?: Set; usedSymbolNames?: Set; - remappedSymbolNames?: ESMap; + remappedSymbolNames?: ESMap; } function isDefaultBindingContext(location: Node) { @@ -7736,7 +7742,7 @@ namespace ts { } // Return the inferred type for a variable, parameter, or property declaration - function getTypeForVariableLikeDeclaration(declaration: ParameterDeclaration | PropertyDeclaration | PropertySignature | VariableDeclaration | BindingElement, includeOptionality: boolean): Type | undefined { + function getTypeForVariableLikeDeclaration(declaration: ParameterDeclaration | PropertyDeclaration | PropertySignature | VariableDeclaration | BindingElement | JSDocPropertyLikeTag, includeOptionality: boolean): Type | undefined { // A variable declared in a for..in statement is of type string, or of type keyof T when the // right hand expression is of a type parameter type. if (isVariableDeclaration(declaration) && declaration.parent.parent.kind === SyntaxKind.ForInStatement) { @@ -7759,6 +7765,7 @@ namespace ts { const isOptional = includeOptionality && ( isParameter(declaration) && isJSDocOptionalParameter(declaration) + || isOptionalJSDocPropertyLikeTag(declaration) || !isBindingElement(declaration) && !isVariableDeclaration(declaration) && !!declaration.questionToken); // Use type from type annotation if one is present @@ -7768,7 +7775,7 @@ namespace ts { } if ((noImplicitAny || isInJSFile(declaration)) && - declaration.kind === SyntaxKind.VariableDeclaration && !isBindingPattern(declaration.name) && + isVariableDeclaration(declaration) && !isBindingPattern(declaration.name) && !(getCombinedModifierFlags(declaration) & ModifierFlags.Export) && !(declaration.flags & NodeFlags.Ambient)) { // If --noImplicitAny is on or the declaration is in a Javascript file, // use control flow tracked 'any' type for non-ambient, non-exported var or let variables with no @@ -7783,7 +7790,7 @@ namespace ts { } } - if (declaration.kind === SyntaxKind.Parameter) { + if (isParameter(declaration)) { const func = declaration.parent; // For a parameter of a set accessor, use the type of the get accessor if one is present if (func.kind === SyntaxKind.SetAccessor && !hasNonBindableDynamicName(func)) { @@ -7802,7 +7809,9 @@ namespace ts { if (isInJSFile(declaration)) { const typeTag = getJSDocType(func); if (typeTag && isFunctionTypeNode(typeTag)) { - return getTypeAtPosition(getSignatureFromDeclaration(typeTag), func.parameters.indexOf(declaration)); + const signature = getSignatureFromDeclaration(typeTag); + const pos = func.parameters.indexOf(declaration); + return declaration.dotDotDotToken ? getRestTypeAtPosition(signature, pos) : getTypeAtPosition(signature, pos); } } // Use contextual parameter type if one is available @@ -7811,16 +7820,16 @@ namespace ts { return addOptionality(type, isOptional); } } - else if (isInJSFile(declaration)) { - const containerObjectType = getJSContainerObjectType(declaration, getSymbolOfNode(declaration), getDeclaredExpandoInitializer(declaration)); - if (containerObjectType) { - return containerObjectType; - } - } // Use the type of the initializer expression if one is present and the declaration is // not a parameter of a contextually typed function - if (declaration.initializer) { + if (hasOnlyExpressionInitializer(declaration) && !!declaration.initializer) { + if (isInJSFile(declaration) && !isParameter(declaration)) { + const containerObjectType = getJSContainerObjectType(declaration, getSymbolOfNode(declaration), getDeclaredExpandoInitializer(declaration)); + if (containerObjectType) { + return containerObjectType; + } + } const type = widenTypeInferredFromInitializer(declaration, checkDeclarationInitializer(declaration)); return addOptionality(type, isOptional); } @@ -7985,13 +7994,13 @@ namespace ts { const exports = createSymbolTable(); while (isBinaryExpression(decl) || isPropertyAccessExpression(decl)) { const s = getSymbolOfNode(decl); - if (s && hasEntries(s.exports)) { + if (s?.exports?.size) { mergeSymbolTable(exports, s.exports); } decl = isBinaryExpression(decl) ? decl.parent : decl.parent.parent; } const s = getSymbolOfNode(decl); - if (s && hasEntries(s.exports)) { + if (s?.exports?.size) { mergeSymbolTable(exports, s.exports); } const type = createAnonymousType(symbol, exports, emptyArray, emptyArray, undefined, undefined); @@ -8240,7 +8249,7 @@ namespace ts { // Here, the array literal [1, "one"] is contextually typed by the type [any, string], which is the implied type of the // binding pattern [x, s = ""]. Because the contextual type is a tuple type, the resulting type of [1, "one"] is the // tuple type [number, string]. Thus, the type inferred for 'x' is number and the type inferred for 's' is string. - function getWidenedTypeForVariableLikeDeclaration(declaration: ParameterDeclaration | PropertyDeclaration | PropertySignature | VariableDeclaration | BindingElement, reportErrors?: boolean): Type { + function getWidenedTypeForVariableLikeDeclaration(declaration: ParameterDeclaration | PropertyDeclaration | PropertySignature | VariableDeclaration | BindingElement | JSDocPropertyLikeTag, reportErrors?: boolean): Type { return widenTypeForVariableLikeDeclaration(getTypeForVariableLikeDeclaration(declaration, /*includeOptionality*/ true), declaration, reportErrors); } @@ -8347,8 +8356,7 @@ namespace ts { (isCallExpression(declaration) || (isPropertyAccessExpression(declaration) || isBindableStaticElementAccessExpression(declaration)) && isBinaryExpression(declaration.parent)))) { type = getWidenedTypeForAssignmentDeclaration(symbol); } - else if (isJSDocPropertyLikeTag(declaration) - || isPropertyAccessExpression(declaration) + else if (isPropertyAccessExpression(declaration) || isElementAccessExpression(declaration) || isIdentifier(declaration) || isStringLiteralLike(declaration) @@ -8382,7 +8390,8 @@ namespace ts { || isPropertyDeclaration(declaration) || isPropertySignature(declaration) || isVariableDeclaration(declaration) - || isBindingElement(declaration)) { + || isBindingElement(declaration) + || isJSDocPropertyLikeTag(declaration)) { type = getWidenedTypeForVariableLikeDeclaration(declaration, /*includeOptionality*/ true); } // getTypeOfSymbol dispatches some JS merges incorrectly because their symbol flags are not mutually exclusive. @@ -8751,6 +8760,12 @@ namespace ts { (node.kind === SyntaxKind.ClassDeclaration || node.kind === SyntaxKind.ClassExpression || node.kind === SyntaxKind.InterfaceDeclaration || isJSConstructor(node)) && getDeclaredTypeOfClassOrInterface(getSymbolOfNode(node as ClassLikeDeclaration | InterfaceDeclaration)).thisType; return thisType ? append(outerAndOwnTypeParameters, thisType) : outerAndOwnTypeParameters; + case SyntaxKind.JSDocParameterTag: + const paramSymbol = getParameterSymbolFromJSDoc(node as JSDocParameterTag); + if (paramSymbol) { + node = paramSymbol.valueDeclaration; + } + break; } } } @@ -9086,7 +9101,7 @@ namespace ts { type.typeParameters = concatenate(outerTypeParameters, localTypeParameters); type.outerTypeParameters = outerTypeParameters; type.localTypeParameters = localTypeParameters; - (type).instantiations = createMap(); + (type).instantiations = new Map(); (type).instantiations.set(getTypeListId(type.typeParameters), type); (type).target = type; (type).resolvedTypeArguments = type.typeParameters; @@ -9118,7 +9133,7 @@ namespace ts { // Initialize the instantiation cache for generic type aliases. The declared type corresponds to // an instantiation of the type alias with the type parameters supplied as type arguments. links.typeParameters = typeParameters; - links.instantiations = createMap(); + links.instantiations = new Map(); links.instantiations.set(getTypeListId(typeParameters), type); } } @@ -10112,7 +10127,7 @@ namespace ts { if (symbol.exports) { members = getExportsOfSymbol(symbol); if (symbol === globalThisSymbol) { - const varsOnly = createMap() as SymbolTable; + const varsOnly = new Map() as SymbolTable; members.forEach(p => { if (!(p.flags & SymbolFlags.BlockScoped)) { varsOnly.set(p.escapedName, p); @@ -10829,7 +10844,7 @@ namespace ts { function createUnionOrIntersectionProperty(containingType: UnionOrIntersectionType, name: __String): Symbol | undefined { let singleProp: Symbol | undefined; - let propSet: ESMap | undefined; + let propSet: ESMap | undefined; let indexTypes: Type[] | undefined; const isUnion = containingType.flags & TypeFlags.Union; // Flags we want to propagate to the result if they exist in all source symbols @@ -10853,10 +10868,10 @@ namespace ts { } else if (prop !== singleProp) { if (!propSet) { - propSet = createMap(); - propSet.set("" + getSymbolId(singleProp), singleProp); + propSet = new Map(); + propSet.set(getSymbolId(singleProp), singleProp); } - const id = "" + getSymbolId(prop); + const id = getSymbolId(prop); if (!propSet.has(id)) { propSet.set(id, prop); } @@ -11168,8 +11183,8 @@ namespace ts { return symbol && withAugmentations ? getMergedSymbol(symbol) : symbol; } - function isOptionalParameter(node: ParameterDeclaration | JSDocParameterTag) { - if (hasQuestionToken(node) || isOptionalJSDocParameterTag(node) || isJSDocOptionalParameter(node)) { + function isOptionalParameter(node: ParameterDeclaration | JSDocParameterTag | JSDocPropertyTag) { + if (hasQuestionToken(node) || isOptionalJSDocPropertyLikeTag(node) || isJSDocOptionalParameter(node)) { return true; } @@ -11189,8 +11204,8 @@ namespace ts { return false; } - function isOptionalJSDocParameterTag(node: Node): node is JSDocParameterTag { - if (!isJSDocParameterTag(node)) { + function isOptionalJSDocPropertyLikeTag(node: Node): node is JSDocPropertyLikeTag { + if (!isJSDocPropertyLikeTag(node)) { return false; } const { isBracketed, typeExpression } = node; @@ -11298,7 +11313,7 @@ namespace ts { } // Record a new minimum argument count if this is not an optional parameter - const isOptionalParameter = isOptionalJSDocParameterTag(param) || + const isOptionalParameter = isOptionalJSDocPropertyLikeTag(param) || param.initializer || param.questionToken || param.dotDotDotToken || iife && parameters.length > iife.arguments.length && !type || isJSDocOptionalParameter(param); @@ -11572,7 +11587,7 @@ namespace ts { } function getSignatureInstantiationWithoutFillingInTypeArguments(signature: Signature, typeArguments: readonly Type[] | undefined): Signature { - const instantiations = signature.instantiations || (signature.instantiations = createMap()); + const instantiations = signature.instantiations || (signature.instantiations = new Map()); const id = getTypeListId(typeArguments); let instantiation = instantiations.get(id); if (!instantiation) { @@ -12531,7 +12546,7 @@ namespace ts { type.typeParameters = typeParameters; type.outerTypeParameters = undefined; type.localTypeParameters = typeParameters; - type.instantiations = createMap(); + type.instantiations = new Map(); type.instantiations.set(getTypeListId(type.typeParameters), type); type.target = type; type.resolvedTypeArguments = type.typeParameters; @@ -12657,7 +12672,7 @@ namespace ts { return strictNullChecks ? getOptionalType(type) : type; } - function getTypeId(type: Type) { + function getTypeId(type: Type): TypeId { return type.id; } @@ -13037,7 +13052,7 @@ namespace ts { // Also, unlike union types, the order of the constituent types is preserved in order that overload resolution // for intersections of types with signatures can be deterministic. function getIntersectionType(types: readonly Type[], aliasSymbol?: Symbol, aliasTypeArguments?: readonly Type[]): Type { - const typeMembershipMap: ESMap = createMap(); + const typeMembershipMap: ESMap = new Map(); const includes = addTypesToIntersection(typeMembershipMap, 0, types); const typeSet: Type[] = arrayFrom(typeMembershipMap.values()); // An intersection type is considered empty if it contains @@ -13837,7 +13852,7 @@ namespace ts { }; links.resolvedType = getConditionalType(root, /*mapper*/ undefined); if (outerTypeParameters) { - root.instantiations = createMap(); + root.instantiations = new Map(); root.instantiations.set(getTypeListId(outerTypeParameters), links.resolvedType); } } @@ -14075,7 +14090,7 @@ namespace ts { } const members = createSymbolTable(); - const skippedPrivateMembers = createUnderscoreEscapedMap(); + const skippedPrivateMembers = new Set<__String>(); let stringIndexInfo: IndexInfo | undefined; let numberIndexInfo: IndexInfo | undefined; if (left === emptyObjectType) { @@ -14090,7 +14105,7 @@ namespace ts { for (const rightProp of getPropertiesOfType(right)) { if (getDeclarationModifierFlagsFromSymbol(rightProp) & (ModifierFlags.Private | ModifierFlags.Protected)) { - skippedPrivateMembers.set(rightProp.escapedName, true); + skippedPrivateMembers.add(rightProp.escapedName); } else if (isSpreadableProperty(rightProp)) { members.set(rightProp.escapedName, getSpreadSymbol(rightProp, readonly)); @@ -14387,11 +14402,12 @@ namespace ts { return getTypeFromInferTypeNode(node); case SyntaxKind.ImportType: return getTypeFromImportTypeNode(node); - // This function assumes that an identifier or qualified name is a type expression + // This function assumes that an identifier, qualified name, or property access expression is a type expression // Callers should first ensure this by calling `isPartOfTypeNode` // TODO(rbuckton): These aren't valid TypeNodes, but we treat them as such because of `isPartOfTypeNode`, which returns `true` for things that aren't `TypeNode`s. case SyntaxKind.Identifier as TypeNodeSyntaxKind: case SyntaxKind.QualifiedName as TypeNodeSyntaxKind: + case SyntaxKind.PropertyAccessExpression as TypeNodeSyntaxKind: const symbol = getSymbolAtLocation(node); return symbol ? getDeclaredTypeOfSymbol(symbol) : errorType; default: @@ -14576,24 +14592,14 @@ namespace ts { function getObjectTypeInstantiation(type: AnonymousType | DeferredTypeReference, mapper: TypeMapper) { const target = type.objectFlags & ObjectFlags.Instantiated ? type.target! : type; - const node = type.objectFlags & ObjectFlags.Reference ? (type).node! : type.symbol.declarations[0]; - const links = getNodeLinks(node); + const declaration = type.objectFlags & ObjectFlags.Reference ? (type).node! : type.symbol.declarations[0]; + const links = getNodeLinks(declaration); let typeParameters = links.outerTypeParameters; if (!typeParameters) { // The first time an anonymous type is instantiated we compute and store a list of the type // parameters that are in scope (and therefore potentially referenced). For type literals that // aren't the right hand side of a generic type alias declaration we optimize by reducing the // set of type parameters to those that are possibly referenced in the literal. - let declaration = node; - if (isInJSFile(declaration)) { - const paramTag = findAncestor(declaration, isJSDocParameterTag); - if (paramTag) { - const paramSymbol = getParameterSymbolFromJSDoc(paramTag); - if (paramSymbol) { - declaration = paramSymbol.valueDeclaration; - } - } - } let outerTypeParameters = getOuterTypeParameters(declaration, /*includeThisTypes*/ true); if (isJSConstructor(declaration)) { const templateTagParameters = getTypeParametersFromDeclaration(declaration as DeclarationWithTypeParameters); @@ -14605,7 +14611,7 @@ namespace ts { typeParameters; links.outerTypeParameters = typeParameters; if (typeParameters.length) { - links.instantiations = createMap(); + links.instantiations = new Map(); links.instantiations.set(getTypeListId(typeParameters), target); } } @@ -17230,14 +17236,14 @@ namespace ts { // Compute the set of types for each discriminant property. const sourceDiscriminantTypes: Type[][] = new Array(sourcePropertiesFiltered.length); - const excludedProperties = createUnderscoreEscapedMap(); + const excludedProperties = new Set<__String>(); for (let i = 0; i < sourcePropertiesFiltered.length; i++) { const sourceProperty = sourcePropertiesFiltered[i]; const sourcePropertyType = getTypeOfSymbol(sourceProperty); sourceDiscriminantTypes[i] = sourcePropertyType.flags & TypeFlags.Union ? (sourcePropertyType as UnionType).types : [sourcePropertyType]; - excludedProperties.set(sourceProperty.escapedName, true); + excludedProperties.add(sourceProperty.escapedName); } // Match each combination of the cartesian product of discriminant properties to one or more @@ -17296,7 +17302,7 @@ namespace ts { return result; } - function excludeProperties(properties: Symbol[], excludedProperties: UnderscoreEscapedMap | undefined) { + function excludeProperties(properties: Symbol[], excludedProperties: Set<__String> | undefined) { if (!excludedProperties || properties.length === 0) return properties; let result: Symbol[] | undefined; for (let i = 0; i < properties.length; i++) { @@ -17465,7 +17471,7 @@ namespace ts { // No array like or unmatched property error - just issue top level error (errorInfo = undefined) } - function propertiesRelatedTo(source: Type, target: Type, reportErrors: boolean, excludedProperties: UnderscoreEscapedMap | undefined, intersectionState: IntersectionState): Ternary { + function propertiesRelatedTo(source: Type, target: Type, reportErrors: boolean, excludedProperties: Set<__String> | undefined, intersectionState: IntersectionState): Ternary { if (relation === identityRelation) { return propertiesIdenticalTo(source, target, excludedProperties); } @@ -17594,7 +17600,7 @@ namespace ts { return result; } - function propertiesIdenticalTo(source: Type, target: Type, excludedProperties: UnderscoreEscapedMap | undefined): Ternary { + function propertiesIdenticalTo(source: Type, target: Type, excludedProperties: Set<__String> | undefined): Ternary { if (!(source.flags & TypeFlags.Object && target.flags & TypeFlags.Object)) { return Ternary.False; } @@ -18727,7 +18733,7 @@ namespace ts { function getPropertiesOfContext(context: WideningContext): Symbol[] { if (!context.resolvedProperties) { - const names = createMap() as UnderscoreEscapedMap; + const names = new Map() as UnderscoreEscapedMap; for (const t of getSiblingsOfContext(context)) { if (isObjectLiteralType(t) && !(getObjectFlags(t) & ObjectFlags.ContainsSpread)) { for (const prop of getPropertiesOfType(t)) { @@ -19479,7 +19485,7 @@ namespace ts { inferencePriority = Math.min(inferencePriority, status); return; } - (visited || (visited = createMap())).set(key, InferencePriority.Circularity); + (visited || (visited = new Map())).set(key, InferencePriority.Circularity); const saveInferencePriority = inferencePriority; inferencePriority = InferencePriority.MaxValue; action(source, target); @@ -20629,7 +20635,7 @@ namespace ts { // we defer subtype reduction until the evolving array type is finalized into a manifest // array type. function addEvolvingArrayElementType(evolvingArrayType: EvolvingArrayType, node: Expression): EvolvingArrayType { - const elementType = getBaseTypeOfLiteralType(getContextFreeTypeOfExpression(node)); + const elementType = getRegularTypeOfObjectLiteral(getBaseTypeOfLiteralType(getContextFreeTypeOfExpression(node))); return isTypeSubsetOf(elementType, evolvingArrayType.elementType) ? evolvingArrayType : getEvolvingArrayType(getUnionType([evolvingArrayType.elementType, elementType])); } @@ -21285,7 +21291,7 @@ namespace ts { // If we have previously computed the control flow type for the reference at // this flow loop junction, return the cached type. const id = getFlowNodeId(flow); - const cache = flowLoopCaches[id] || (flowLoopCaches[id] = createMap()); + const cache = flowLoopCaches[id] || (flowLoopCaches[id] = new Map()); const key = getOrSetCacheKey(); if (!key) { // No cache key is generated when binding patterns are in unnarrowable situations @@ -22436,30 +22442,23 @@ namespace ts { const isInJS = isInJSFile(node); if (isFunctionLike(container) && (!isInParameterInitializerBeforeContainingFunction(node) || getThisParameter(container))) { + let thisType = getThisTypeOfDeclaration(container) || isInJS && getTypeForThisExpressionFromJSDoc(container); // Note: a parameter initializer should refer to class-this unless function-this is explicitly annotated. // If this is a function in a JS file, it might be a class method. - const className = getClassNameFromPrototypeMethod(container); - if (isInJS && className) { - const classSymbol = checkExpression(className).symbol; - if (classSymbol && classSymbol.members && (classSymbol.flags & SymbolFlags.Function)) { - const classType = (getDeclaredTypeOfSymbol(classSymbol) as InterfaceType).thisType; - if (classType) { - return getFlowTypeOfReference(node, classType); + if (!thisType) { + const className = getClassNameFromPrototypeMethod(container); + if (isInJS && className) { + const classSymbol = checkExpression(className).symbol; + if (classSymbol && classSymbol.members && (classSymbol.flags & SymbolFlags.Function)) { + thisType = (getDeclaredTypeOfSymbol(classSymbol) as InterfaceType).thisType; } } - } - // Check if it's a constructor definition, can be either a variable decl or function decl - // i.e. - // * /** @constructor */ function [name]() { ... } - // * /** @constructor */ var x = function() { ... } - else if (isInJS && - (container.kind === SyntaxKind.FunctionExpression || container.kind === SyntaxKind.FunctionDeclaration) && - getJSDocClassTag(container)) { - const classType = (getDeclaredTypeOfSymbol(getMergedSymbol(container.symbol)) as InterfaceType).thisType!; - return getFlowTypeOfReference(node, classType); + else if (isJSConstructor(container)) { + thisType = (getDeclaredTypeOfSymbol(getMergedSymbol(container.symbol)) as InterfaceType).thisType; + } + thisType ||= getContextualThisParameterType(container); } - const thisType = getThisTypeOfDeclaration(container) || getContextualThisParameterType(container); if (thisType) { return getFlowTypeOfReference(node, thisType); } @@ -22471,12 +22470,6 @@ namespace ts { return getFlowTypeOfReference(node, type); } - if (isInJS) { - const type = getTypeForThisExpressionFromJSDoc(container); - if (type && type !== errorType) { - return getFlowTypeOfReference(node, type); - } - } if (isSourceFile(container)) { // look up in the source file's locals or exports if (container.commonJsModuleIndicator) { @@ -27392,7 +27385,7 @@ namespace ts { // If the symbol of the node has members, treat it like a constructor. const symbol = getSymbolOfNode(func); - return !!symbol && hasEntries(symbol.members); + return !!symbol?.members?.size; } return false; } @@ -27400,21 +27393,21 @@ namespace ts { function mergeJSSymbols(target: Symbol, source: Symbol | undefined) { if (source) { const links = getSymbolLinks(source); - if (!links.inferredClassSymbol || !links.inferredClassSymbol.has("" + getSymbolId(target))) { + if (!links.inferredClassSymbol || !links.inferredClassSymbol.has(getSymbolId(target))) { const inferred = isTransientSymbol(target) ? target : cloneSymbol(target) as TransientSymbol; inferred.exports = inferred.exports || createSymbolTable(); inferred.members = inferred.members || createSymbolTable(); inferred.flags |= source.flags & SymbolFlags.Class; - if (hasEntries(source.exports)) { + if (source.exports?.size) { mergeSymbolTable(inferred.exports, source.exports); } - if (hasEntries(source.members)) { + if (source.members?.size) { mergeSymbolTable(inferred.members, source.members); } - (links.inferredClassSymbol || (links.inferredClassSymbol = createMap())).set("" + getSymbolId(inferred), inferred); + (links.inferredClassSymbol || (links.inferredClassSymbol = new Map())).set(getSymbolId(inferred), inferred); return inferred; } - return links.inferredClassSymbol.get("" + getSymbolId(target)); + return links.inferredClassSymbol.get(getSymbolId(target)); } } @@ -27507,7 +27500,7 @@ namespace ts { const decl = getDeclarationOfExpando(node); if (decl) { const jsSymbol = getSymbolOfNode(decl); - if (jsSymbol && hasEntries(jsSymbol.exports)) { + if (jsSymbol?.exports?.size) { const jsAssignmentType = createAnonymousType(jsSymbol, jsSymbol.exports, emptyArray, emptyArray, undefined, undefined); jsAssignmentType.objectFlags |= ObjectFlags.JSLiteral; return getIntersectionType([returnType, jsAssignmentType]); @@ -28570,7 +28563,7 @@ namespace ts { expr.expression.kind === SyntaxKind.ThisKeyword) { // Look for if this is the constructor for the class that `symbol` is a property of. const ctor = getContainingFunction(expr); - if (!(ctor && ctor.kind === SyntaxKind.Constructor)) { + if (!(ctor && (ctor.kind === SyntaxKind.Constructor || isJSConstructor(ctor)))) { return true; } if (symbol.valueDeclaration) { @@ -29541,8 +29534,8 @@ namespace ts { case AssignmentDeclarationKind.ThisProperty: const symbol = getSymbolOfNode(left); const init = getAssignedExpandoInitializer(right); - return init && isObjectLiteralExpression(init) && - symbol && hasEntries(symbol.exports); + return !!init && isObjectLiteralExpression(init) && + !!symbol?.exports?.size; default: return false; } @@ -30501,10 +30494,10 @@ namespace ts { } function checkClassForDuplicateDeclarations(node: ClassLikeDeclaration) { - const instanceNames = createUnderscoreEscapedMap(); - const staticNames = createUnderscoreEscapedMap(); + const instanceNames = new Map<__String, DeclarationMeaning>(); + const staticNames = new Map<__String, DeclarationMeaning>(); // instance and static private identifiers share the same scope - const privateIdentifiers = createUnderscoreEscapedMap(); + const privateIdentifiers = new Map<__String, DeclarationMeaning>(); for (const member of node.members) { if (member.kind === SyntaxKind.Constructor) { for (const param of (member as ConstructorDeclaration).parameters) { @@ -30600,7 +30593,7 @@ namespace ts { } function checkObjectTypeForDuplicateDeclarations(node: TypeLiteralNode | InterfaceDeclaration) { - const names = createMap(); + const names = new Map(); for (const member of node.members) { if (member.kind === SyntaxKind.PropertySignature) { let memberName: string; @@ -32298,7 +32291,7 @@ namespace ts { if (last(getSymbolOfNode(node).declarations) !== node) return; const typeParameters = getEffectiveTypeParameterDeclarations(node); - const seenParentsWithEveryUnused = new NodeSet(); + const seenParentsWithEveryUnused = new Set(); for (const typeParameter of typeParameters) { if (!isTypeParameterUnused(typeParameter)) continue; @@ -32306,7 +32299,7 @@ namespace ts { const name = idText(typeParameter.name); const { parent } = typeParameter; if (parent.kind !== SyntaxKind.InferType && parent.typeParameters!.every(isTypeParameterUnused)) { - if (seenParentsWithEveryUnused.tryAdd(parent)) { + if (tryAddToSet(seenParentsWithEveryUnused, parent)) { const range = isJSDocTemplateTag(parent) // Whole @template tag ? rangeOfNode(parent) @@ -32356,9 +32349,9 @@ namespace ts { function checkUnusedLocalsAndParameters(nodeWithLocals: Node, addDiagnostic: AddUnusedDiagnostic): void { // Ideally we could use the ImportClause directly as a key, but must wait until we have full ES6 maps. So must store key along with value. - const unusedImports = createMap<[ImportClause, ImportedDeclaration[]]>(); - const unusedDestructures = createMap<[ObjectBindingPattern, BindingElement[]]>(); - const unusedVariables = createMap<[VariableDeclarationList, VariableDeclaration[]]>(); + const unusedImports = new Map(); + const unusedDestructures = new Map(); + const unusedVariables = new Map(); nodeWithLocals.locals!.forEach(local => { // If it's purely a type parameter, ignore, will be checked in `checkUnusedTypeParameters`. // If it's a type parameter merged with a parameter, check if the parameter-side is used. @@ -32785,7 +32778,7 @@ namespace ts { const isJSObjectLiteralInitializer = isInJSFile(node) && isObjectLiteralExpression(initializer) && (initializer.properties.length === 0 || isPrototypeAccess(node.name)) && - hasEntries(symbol.exports); + !!symbol.exports?.size; if (!isJSObjectLiteralInitializer && node.parent.parent.kind !== SyntaxKind.ForInStatement) { checkTypeAssignableToAndOptionallyElaborate(checkExpressionCached(initializer), type, node, initializer, /*headMessage*/ undefined); } @@ -34609,7 +34602,7 @@ namespace ts { if (!length(baseTypes)) { return properties; } - const seen = createUnderscoreEscapedMap(); + const seen = new Map<__String, Symbol>(); forEach(properties, p => { seen.set(p.escapedName, p); }); for (const base of baseTypes) { @@ -34632,7 +34625,7 @@ namespace ts { } interface InheritanceInfoMap { prop: Symbol; containingType: Type; } - const seen = createUnderscoreEscapedMap(); + const seen = new Map<__String, InheritanceInfoMap>(); forEach(resolveDeclaredMembers(type).declaredProperties, p => { seen.set(p.escapedName, { prop: p, containingType: type }); }); let ok = true; @@ -35226,39 +35219,36 @@ namespace ts { const target = resolveAlias(symbol); if (target !== unknownSymbol) { - const shouldSkipWithJSExpandoTargets = symbol.flags & SymbolFlags.Assignment; - if (!shouldSkipWithJSExpandoTargets) { - // For external modules symbol represents local symbol for an alias. - // This local symbol will merge any other local declarations (excluding other aliases) - // and symbol.flags will contains combined representation for all merged declaration. - // Based on symbol.flags we can compute a set of excluded meanings (meaning that resolved alias should not have, - // otherwise it will conflict with some local declaration). Note that in addition to normal flags we include matching SymbolFlags.Export* - // in order to prevent collisions with declarations that were exported from the current module (they still contribute to local names). - symbol = getMergedSymbol(symbol.exportSymbol || symbol); - const excludedMeanings = - (symbol.flags & (SymbolFlags.Value | SymbolFlags.ExportValue) ? SymbolFlags.Value : 0) | - (symbol.flags & SymbolFlags.Type ? SymbolFlags.Type : 0) | - (symbol.flags & SymbolFlags.Namespace ? SymbolFlags.Namespace : 0); - if (target.flags & excludedMeanings) { - const message = node.kind === SyntaxKind.ExportSpecifier ? - Diagnostics.Export_declaration_conflicts_with_exported_declaration_of_0 : - Diagnostics.Import_declaration_conflicts_with_local_declaration_of_0; - error(node, message, symbolToString(symbol)); - } + // For external modules, `symbol` represents the local symbol for an alias. + // This local symbol will merge any other local declarations (excluding other aliases) + // and symbol.flags will contains combined representation for all merged declaration. + // Based on symbol.flags we can compute a set of excluded meanings (meaning that resolved alias should not have, + // otherwise it will conflict with some local declaration). Note that in addition to normal flags we include matching SymbolFlags.Export* + // in order to prevent collisions with declarations that were exported from the current module (they still contribute to local names). + symbol = getMergedSymbol(symbol.exportSymbol || symbol); + const excludedMeanings = + (symbol.flags & (SymbolFlags.Value | SymbolFlags.ExportValue) ? SymbolFlags.Value : 0) | + (symbol.flags & SymbolFlags.Type ? SymbolFlags.Type : 0) | + (symbol.flags & SymbolFlags.Namespace ? SymbolFlags.Namespace : 0); + if (target.flags & excludedMeanings) { + const message = node.kind === SyntaxKind.ExportSpecifier ? + Diagnostics.Export_declaration_conflicts_with_exported_declaration_of_0 : + Diagnostics.Import_declaration_conflicts_with_local_declaration_of_0; + error(node, message, symbolToString(symbol)); + } - // Don't allow to re-export something with no value side when `--isolatedModules` is set. - if (compilerOptions.isolatedModules - && node.kind === SyntaxKind.ExportSpecifier - && !node.parent.parent.isTypeOnly - && !(target.flags & SymbolFlags.Value) - && !(node.flags & NodeFlags.Ambient)) { - error(node, Diagnostics.Re_exporting_a_type_when_the_isolatedModules_flag_is_provided_requires_using_export_type); - } + // Don't allow to re-export something with no value side when `--isolatedModules` is set. + if (compilerOptions.isolatedModules + && node.kind === SyntaxKind.ExportSpecifier + && !node.parent.parent.isTypeOnly + && !(target.flags & SymbolFlags.Value) + && !(node.flags & NodeFlags.Ambient)) { + error(node, Diagnostics.Re_exporting_a_type_when_the_isolatedModules_flag_is_provided_requires_using_export_type); } if (isImportSpecifier(node) && (target.valueDeclaration && target.valueDeclaration.flags & NodeFlags.Deprecated - || every(target.declarations, d => !!(d.flags & NodeFlags.Deprecated)))) { + || every(target.declarations, d => !!(d.flags & NodeFlags.Deprecated)))) { errorOrSuggestion(/* isError */ false, node.name, Diagnostics._0_is_deprecated, symbol.escapedName as string); } } @@ -35855,8 +35845,8 @@ namespace ts { const enclosingFile = getSourceFileOfNode(node); const links = getNodeLinks(enclosingFile); if (!(links.flags & NodeCheckFlags.TypeChecked)) { - links.deferredNodes = links.deferredNodes || createMap(); - const id = "" + getNodeId(node); + links.deferredNodes = links.deferredNodes || new Map(); + const id = getNodeId(node); links.deferredNodes.set(id, node); } } @@ -36997,6 +36987,12 @@ namespace ts { hasSyntacticModifier(parameter, ModifierFlags.ParameterPropertyModifier); } + function isOptionalUninitializedParameter(parameter: ParameterDeclaration) { + return !!strictNullChecks && + isOptionalParameter(parameter) && + !parameter.initializer; + } + function isExpandoFunctionDeclaration(node: Declaration): boolean { const declaration = getParseTreeNode(node, isFunctionDeclaration); if (!declaration) { @@ -37259,7 +37255,7 @@ namespace ts { let fileToDirective: ESMap; if (resolvedTypeReferenceDirectives) { // populate reverse mapping: file path -> type reference directive that was resolved to this file - fileToDirective = createMap(); + fileToDirective = new Map(); resolvedTypeReferenceDirectives.forEach((resolvedDirective, key) => { if (!resolvedDirective || !resolvedDirective.resolvedFileName) { return; @@ -37492,7 +37488,7 @@ namespace ts { bindSourceFile(file, compilerOptions); } - amalgamatedDuplicates = createMap(); + amalgamatedDuplicates = new Map(); // Initialize global symbol table let augmentations: (readonly (StringLiteral | Identifier)[])[] | undefined; @@ -38300,7 +38296,7 @@ namespace ts { } function checkGrammarObjectLiteralExpression(node: ObjectLiteralExpression, inDestructuring: boolean) { - const seen = createUnderscoreEscapedMap(); + const seen = new Map<__String, DeclarationMeaning>(); for (const prop of node.properties) { if (prop.kind === SyntaxKind.SpreadAssignment) { @@ -38405,7 +38401,7 @@ namespace ts { function checkGrammarJsxElement(node: JsxOpeningLikeElement) { checkGrammarTypeArguments(node, node.typeArguments); - const seen = createUnderscoreEscapedMap(); + const seen = new Map<__String, boolean>(); for (const attr of node.attributes.properties) { if (attr.kind === SyntaxKind.JsxSpreadAttribute) { diff --git a/src/compiler/commandLineParser.ts b/src/compiler/commandLineParser.ts index a8bd8c1dcd2..f5cb2990a59 100644 --- a/src/compiler/commandLineParser.ts +++ b/src/compiler/commandLineParser.ts @@ -83,33 +83,33 @@ namespace ts { export const optionsForWatch: CommandLineOption[] = [ { name: "watchFile", - type: createMapFromTemplate({ + type: new Map(getEntries({ fixedpollinginterval: WatchFileKind.FixedPollingInterval, prioritypollinginterval: WatchFileKind.PriorityPollingInterval, dynamicprioritypolling: WatchFileKind.DynamicPriorityPolling, usefsevents: WatchFileKind.UseFsEvents, usefseventsonparentdirectory: WatchFileKind.UseFsEventsOnParentDirectory, - }), + })), category: Diagnostics.Advanced_Options, description: Diagnostics.Specify_strategy_for_watching_file_Colon_FixedPollingInterval_default_PriorityPollingInterval_DynamicPriorityPolling_UseFsEvents_UseFsEventsOnParentDirectory, }, { name: "watchDirectory", - type: createMapFromTemplate({ + type: new Map(getEntries({ usefsevents: WatchDirectoryKind.UseFsEvents, fixedpollinginterval: WatchDirectoryKind.FixedPollingInterval, dynamicprioritypolling: WatchDirectoryKind.DynamicPriorityPolling, - }), + })), category: Diagnostics.Advanced_Options, description: Diagnostics.Specify_strategy_for_watching_directory_on_platforms_that_don_t_support_recursive_watching_natively_Colon_UseFsEvents_default_FixedPollingInterval_DynamicPriorityPolling, }, { name: "fallbackPolling", - type: createMapFromTemplate({ + type: new Map(getEntries({ fixedinterval: PollingWatchKind.FixedInterval, priorityinterval: PollingWatchKind.PriorityInterval, dynamicpriority: PollingWatchKind.DynamicPriority, - }), + })), category: Diagnostics.Advanced_Options, description: Diagnostics.Specify_strategy_for_creating_a_polling_watch_when_it_fails_to_create_using_file_system_events_Colon_FixedInterval_default_PriorityInterval_DynamicPriority, }, @@ -286,7 +286,7 @@ namespace ts { { name: "target", shortName: "t", - type: createMapFromTemplate({ + type: new Map(getEntries({ es3: ScriptTarget.ES3, es5: ScriptTarget.ES5, es6: ScriptTarget.ES2015, @@ -297,7 +297,7 @@ namespace ts { es2019: ScriptTarget.ES2019, es2020: ScriptTarget.ES2020, esnext: ScriptTarget.ESNext, - }), + })), affectsSourceFile: true, affectsModuleResolution: true, affectsEmit: true, @@ -309,7 +309,7 @@ namespace ts { { name: "module", shortName: "m", - type: createMapFromTemplate({ + type: new Map(getEntries({ none: ModuleKind.None, commonjs: ModuleKind.CommonJS, amd: ModuleKind.AMD, @@ -319,7 +319,7 @@ namespace ts { es2015: ModuleKind.ES2015, es2020: ModuleKind.ES2020, esnext: ModuleKind.ESNext - }), + })), affectsModuleResolution: true, affectsEmit: true, paramType: Diagnostics.KIND, @@ -356,11 +356,11 @@ namespace ts { }, { name: "jsx", - type: createMapFromTemplate({ + type: new Map(getEntries({ "preserve": JsxEmit.Preserve, "react-native": JsxEmit.ReactNative, "react": JsxEmit.React - }), + })), affectsSourceFile: true, paramType: Diagnostics.KIND, showInSimplifiedHelpView: true, @@ -476,11 +476,11 @@ namespace ts { }, { name: "importsNotUsedAsValues", - type: createMapFromTemplate({ + type: new Map(getEntries({ remove: ImportsNotUsedAsValues.Remove, preserve: ImportsNotUsedAsValues.Preserve, error: ImportsNotUsedAsValues.Error - }), + })), affectsEmit: true, affectsSemanticDiagnostics: true, category: Diagnostics.Advanced_Options, @@ -610,10 +610,10 @@ namespace ts { // Module Resolution { name: "moduleResolution", - type: createMapFromTemplate({ + type: new Map(getEntries({ node: ModuleResolutionKind.NodeJs, classic: ModuleResolutionKind.Classic, - }), + })), affectsModuleResolution: true, paramType: Diagnostics.STRATEGY, category: Diagnostics.Module_Resolution_Options, @@ -818,10 +818,10 @@ namespace ts { }, { name: "newLine", - type: createMapFromTemplate({ + type: new Map(getEntries({ crlf: NewLineKind.CarriageReturnLineFeed, lf: NewLineKind.LineFeed - }), + })), affectsEmit: true, paramType: Diagnostics.NEWLINE, category: Diagnostics.Advanced_Options, @@ -1096,8 +1096,8 @@ namespace ts { /*@internal*/ export function createOptionNameMap(optionDeclarations: readonly CommandLineOption[]): OptionsNameMap { - const optionsNameMap = createMap(); - const shortOptionNames = createMap(); + const optionsNameMap = new Map(); + const shortOptionNames = new Map(); forEach(optionDeclarations, option => { optionsNameMap.set(option.name.toLowerCase(), option); if (option.shortName) { @@ -2032,7 +2032,7 @@ namespace ts { { optionsNameMap }: OptionsNameMap, pathOptions?: { configFilePath: string, useCaseSensitiveFileNames: boolean } ): ESMap { - const result = createMap(); + const result = new Map(); const getCanonicalFileName = pathOptions && createGetCanonicalFileName(pathOptions.useCaseSensitiveFileNames); for (const name in options) { @@ -2962,17 +2962,17 @@ namespace ts { // Literal file names (provided via the "files" array in tsconfig.json) are stored in a // file map with a possibly case insensitive key. We use this map later when when including // wildcard paths. - const literalFileMap = createMap(); + const literalFileMap = new Map(); // Wildcard paths (provided via the "includes" array in tsconfig.json) are stored in a // file map with a possibly case insensitive key. We use this map to store paths matched // via wildcard, and to handle extension priority. - const wildcardFileMap = createMap(); + const wildcardFileMap = new Map(); // Wildcard paths of json files (provided via the "includes" array in tsconfig.json) are stored in a // file map with a possibly case insensitive key. We use this map to store paths matched // via wildcard of *.json kind - const wildCardJsonFileMap = createMap(); + const wildCardJsonFileMap = new Map(); const { filesSpecs, validatedIncludeSpecs, validatedExcludeSpecs, wildcardDirectories } = spec; // Rather than requery this for each file and filespec, we query the supported extensions diff --git a/src/compiler/core.ts b/src/compiler/core.ts index b79f09154a6..753af89b590 100644 --- a/src/compiler/core.ts +++ b/src/compiler/core.ts @@ -40,15 +40,23 @@ namespace ts { } export const emptyArray: never[] = [] as never[]; + export const emptyMap: ReadonlyESMap = new Map(); + export const emptySet: ReadonlySet = new Set(); - /** Create a new map. */ + /** + * Create a new map. + * @deprecated Use `new Map()` instead. + */ export function createMap(): ESMap; export function createMap(): ESMap; export function createMap(): ESMap { return new Map(); } - /** Create a new map from a template object is provided, the map will copy entries from it. */ + /** + * Create a new map from a template object is provided, the map will copy entries from it. + * @deprecated Use `new Map(getEntries(template))` instead. + */ export function createMapFromTemplate(template: MapLike): ESMap { const map: ESMap = new Map(); @@ -590,6 +598,15 @@ namespace ts { } } + export function getOrUpdate(map: ESMap, key: K, callback: () => V) { + if (map.has(key)) { + return map.get(key)!; + } + const value = callback(); + map.set(key, value); + return value; + } + export function tryAddToSet(set: Set, value: T) { if (!set.has(value)) { set.add(value); @@ -819,6 +836,18 @@ namespace ts { return deduplicateSorted(sort(array, comparer), equalityComparer || comparer || compareStringsCaseSensitive as any as Comparer); } + export function arrayIsSorted(array: readonly T[], comparer: Comparer) { + if (array.length < 2) return true; + let prevElement = array[0]; + for (const element of array.slice(1)) { + if (comparer(prevElement, element) === Comparison.GreaterThan) { + return false; + } + prevElement = element; + } + return true; + } + export function arrayIsEqualTo(array1: readonly T[] | undefined, array2: readonly T[] | undefined, equalityComparer: (a: T, b: T, index: number) => boolean = equateValues): boolean { if (!array1 || !array2) { return array1 === array2; @@ -1275,6 +1304,19 @@ namespace ts { return values; } + const _entries = Object.entries ? Object.entries : (obj: MapLike) => { + const keys = getOwnKeys(obj); + const result: [string, T][] = Array(keys.length); + for (const key of keys) { + result.push([key, obj[key]]); + } + return result; + }; + + export function getEntries(obj: MapLike): [string, T][] { + return obj ? _entries(obj) : []; + } + export function arrayOf(count: number, f: (index: number) => T): T[] { const result = new Array(count); for (let i = 0; i < count; i++) { @@ -1375,9 +1417,11 @@ namespace ts { return result; } + export function group(values: readonly T[], getGroupId: (value: T) => K): readonly (readonly T[])[]; + export function group(values: readonly T[], getGroupId: (value: T) => K, resultSelector: (values: readonly T[]) => R): R[]; export function group(values: readonly T[], getGroupId: (value: T) => string): readonly (readonly T[])[]; export function group(values: readonly T[], getGroupId: (value: T) => string, resultSelector: (values: readonly T[]) => R): R[]; - export function group(values: readonly T[], getGroupId: (value: T) => string, resultSelector: (values: readonly T[]) => readonly T[] = identity): readonly (readonly T[])[] { + export function group(values: readonly T[], getGroupId: (value: T) => K, resultSelector: (values: readonly T[]) => readonly T[] = identity): readonly (readonly T[])[] { return arrayFrom(arrayToMultiMap(values, getGroupId).values(), resultSelector); } @@ -1596,7 +1640,7 @@ namespace ts { /** A version of `memoize` that supports a single primitive argument */ export function memoizeOne(callback: (arg: A) => T): (arg: A) => T { - const map = createMap(); + const map = new Map(); return (arg: A) => { const key = `${typeof arg}:${arg}`; let value = map.get(key); diff --git a/src/compiler/corePublic.ts b/src/compiler/corePublic.ts index 13ef3346709..dad59377900 100644 --- a/src/compiler/corePublic.ts +++ b/src/compiler/corePublic.ts @@ -45,7 +45,6 @@ namespace ts { /** * ES6 Map interface, only read methods included. - * @deprecated Use `ts.ReadonlyESMap` instead. */ export interface ReadonlyMap extends ReadonlyESMap { } @@ -57,7 +56,6 @@ namespace ts { /** * ES6 Map interface. - * @deprecated Use `ts.ESMap` instead. */ export interface Map extends ESMap { } diff --git a/src/compiler/emitter.ts b/src/compiler/emitter.ts index 8fec41fba5f..2040a4af642 100644 --- a/src/compiler/emitter.ts +++ b/src/compiler/emitter.ts @@ -682,9 +682,9 @@ namespace ts { function createSourceFilesFromBundleBuildInfo(bundle: BundleBuildInfo, buildInfoDirectory: string, host: EmitUsingBuildInfoHost): readonly SourceFile[] { const jsBundle = Debug.checkDefined(bundle.js); - const prologueMap = jsBundle.sources?.prologues && arrayToMap(jsBundle.sources.prologues, prologueInfo => "" + prologueInfo.file); + const prologueMap = jsBundle.sources?.prologues && arrayToMap(jsBundle.sources.prologues, prologueInfo => prologueInfo.file); return bundle.sourceFiles.map((fileName, index) => { - const prologueInfo = prologueMap?.get("" + index); + const prologueInfo = prologueMap?.get(index); const statements = prologueInfo?.directives.map(directive => { const literal = setTextRange(factory.createStringLiteral(directive.expression.text), directive.expression); const statement = setTextRange(factory.createExpressionStatement(literal), directive); @@ -834,7 +834,7 @@ namespace ts { const extendedDiagnostics = !!printerOptions.extendedDiagnostics; const newLine = getNewLineCharacter(printerOptions); const moduleKind = getEmitModuleKind(printerOptions); - const bundledHelpers = createMap(); + const bundledHelpers = new Map(); let currentSourceFile: SourceFile | undefined; let nodeIdToGeneratedName: string[]; // Map of generated names for specific nodes. @@ -1682,7 +1682,7 @@ namespace ts { if (moduleKind === ModuleKind.None || printerOptions.noEmitHelpers) { return undefined; } - const bundledHelpers = createMap(); + const bundledHelpers = new Map(); for (const sourceFile of bundle.sourceFiles) { const shouldSkip = getExternalHelpersModuleName(sourceFile) !== undefined; const helpers = getSortedEmitHelpers(sourceFile); diff --git a/src/compiler/factory/emitHelpers.ts b/src/compiler/factory/emitHelpers.ts index f45931d9b2b..15f86bf5a43 100644 --- a/src/compiler/factory/emitHelpers.ts +++ b/src/compiler/factory/emitHelpers.ts @@ -580,7 +580,7 @@ namespace ts { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; @@ -810,7 +810,7 @@ namespace ts { var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; };` @@ -836,7 +836,7 @@ namespace ts { priority: 2, text: ` var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); };` }; diff --git a/src/compiler/factory/nodeFactory.ts b/src/compiler/factory/nodeFactory.ts index ef019d3df30..a9679f453fe 100644 --- a/src/compiler/factory/nodeFactory.ts +++ b/src/compiler/factory/nodeFactory.ts @@ -5654,7 +5654,7 @@ namespace ts { left.splice(0, 0, ...declarations.slice(0, rightStandardPrologueEnd)); } else { - const leftPrologues = createMap(); + const leftPrologues = new Map(); for (let i = 0; i < leftStandardPrologueEnd; i++) { const leftPrologue = statements[i] as PrologueDirective; leftPrologues.set(leftPrologue.expression.text, true); @@ -6159,7 +6159,7 @@ namespace ts { ): InputFiles { const node = parseNodeFactory.createInputFiles(); if (!isString(javascriptTextOrReadFileText)) { - const cache = createMap(); + const cache = new Map(); const textGetter = (path: string | undefined) => { if (path === undefined) return undefined; let value = cache.get(path); diff --git a/src/compiler/moduleNameResolver.ts b/src/compiler/moduleNameResolver.ts index 5109bb56c86..ad331c60be7 100644 --- a/src/compiler/moduleNameResolver.ts +++ b/src/compiler/moduleNameResolver.ts @@ -482,7 +482,7 @@ namespace ts { /*@internal*/ export function createCacheWithRedirects(options?: CompilerOptions): CacheWithRedirects { - let ownMap: ESMap = createMap(); + let ownMap: ESMap = new Map(); const redirectsMap = new Map>(); return { ownMap, @@ -509,7 +509,7 @@ namespace ts { let redirects = redirectsMap.get(path); if (!redirects) { // Reuse map if redirected reference map uses same resolution - redirects = !options || optionsHaveModuleResolutionChanges(options, redirectedReference.commandLine.options) ? createMap() : ownMap; + redirects = !options || optionsHaveModuleResolutionChanges(options, redirectedReference.commandLine.options) ? new Map() : ownMap; redirectsMap.set(path, redirects); } return redirects; @@ -532,7 +532,7 @@ namespace ts { function getOrCreateCacheForDirectory(directoryName: string, redirectedReference?: ResolvedProjectReference) { const path = toPath(directoryName, currentDirectory, getCanonicalFileName); - return getOrCreateCache>(directoryToModuleNameMap, redirectedReference, path, createMap); + return getOrCreateCache>(directoryToModuleNameMap, redirectedReference, path, () => new Map()); } function getOrCreateCacheForModuleName(nonRelativeModuleName: string, redirectedReference?: ResolvedProjectReference): PerModuleNameCache { @@ -551,7 +551,7 @@ namespace ts { } function createPerModuleNameCache(): PerModuleNameCache { - const directoryPathMap = createMap(); + const directoryPathMap = new Map(); return { get, set }; diff --git a/src/compiler/moduleSpecifiers.ts b/src/compiler/moduleSpecifiers.ts index b173bb13364..96925b838e4 100644 --- a/src/compiler/moduleSpecifiers.ts +++ b/src/compiler/moduleSpecifiers.ts @@ -216,7 +216,7 @@ namespace ts.moduleSpecifiers { function getAllModulePaths(importingFileName: string, importedFileName: string, host: ModuleSpecifierResolutionHost): readonly string[] { const cwd = host.getCurrentDirectory(); const getCanonicalFileName = hostGetCanonicalFileName(host); - const allFileNames = createMap(); + const allFileNames = new Map(); let importedFileFromNodeModules = false; forEachFileNameOfModule( importingFileName, diff --git a/src/compiler/parser.ts b/src/compiler/parser.ts index 8f7ea52ebe9..52d5ac671c0 100644 --- a/src/compiler/parser.ts +++ b/src/compiler/parser.ts @@ -820,7 +820,7 @@ namespace ts { result.libReferenceDirectives = emptyArray; result.amdDependencies = emptyArray; result.hasNoDefaultLib = false; - result.pragmas = emptyMap; + result.pragmas = emptyMap as ReadonlyPragmaMap; return result; } @@ -929,8 +929,8 @@ namespace ts { parseDiagnostics = []; parsingContext = 0; - identifiers = createMap(); - privateIdentifiers = createMap(); + identifiers = new Map(); + privateIdentifiers = new Map(); identifierCount = 0; nodeCount = 0; sourceFlags = 0; @@ -8669,7 +8669,7 @@ namespace ts { extractPragmas(pragmas, range, comment); } - context.pragmas = createMap() as PragmaMap; + context.pragmas = new Map() as PragmaMap; for (const pragma of pragmas) { if (context.pragmas.has(pragma.name)) { const currentValue = context.pragmas.get(pragma.name); @@ -8767,7 +8767,7 @@ namespace ts { }); } - const namedArgRegExCache = createMap(); + const namedArgRegExCache = new Map(); function getNamedArgRegEx(name: string): RegExp { if (namedArgRegExCache.has(name)) { return namedArgRegExCache.get(name)!; diff --git a/src/compiler/performance.ts b/src/compiler/performance.ts index 86526ce8f38..dcee41c2d2c 100644 --- a/src/compiler/performance.ts +++ b/src/compiler/performance.ts @@ -108,9 +108,9 @@ namespace ts.performance { /** Enables (and resets) performance measurements for the compiler. */ export function enable() { - counts = createMap(); - marks = createMap(); - measures = createMap(); + counts = new Map(); + marks = new Map(); + measures = new Map(); enabled = true; profilerStart = timestamp(); } diff --git a/src/compiler/program.ts b/src/compiler/program.ts index 006ef647583..0bfbd381792 100644 --- a/src/compiler/program.ts +++ b/src/compiler/program.ts @@ -71,7 +71,7 @@ namespace ts { /*@internal*/ // TODO(shkamat): update this after reworking ts build API export function createCompilerHostWorker(options: CompilerOptions, setParentNodes?: boolean, system = sys): CompilerHost { - const existingDirectories = createMap(); + const existingDirectories = new Map(); const getCanonicalFileName = createGetCanonicalFileName(system.useCaseSensitiveFileNames); function getSourceFile(fileName: string, languageVersion: ScriptTarget, onError?: (message: string) => void): SourceFile | undefined { let text: string | undefined; @@ -134,7 +134,7 @@ namespace ts { } if (!outputFingerprints) { - outputFingerprints = createMap(); + outputFingerprints = new Map(); } const hash = system.createHash(data); @@ -211,10 +211,10 @@ namespace ts { const originalDirectoryExists = host.directoryExists; const originalCreateDirectory = host.createDirectory; const originalWriteFile = host.writeFile; - const readFileCache = createMap(); - const fileExistsCache = createMap(); - const directoryExistsCache = createMap(); - const sourceFileCache = createMap(); + const readFileCache = new Map(); + const fileExistsCache = new Map(); + const directoryExistsCache = new Map(); + const sourceFileCache = new Map(); const readFileWithCache = (fileName: string): string | undefined => { const key = toPath(fileName); @@ -515,7 +515,7 @@ namespace ts { return []; } const resolutions: T[] = []; - const cache = createMap(); + const cache = new Map(); for (const name of names) { let result: T; if (cache.has(name)) { @@ -706,15 +706,15 @@ namespace ts { let commonSourceDirectory: string; let diagnosticsProducingTypeChecker: TypeChecker; let noDiagnosticsTypeChecker: TypeChecker; - let classifiableNames: UnderscoreEscapedMap; - const ambientModuleNameToUnmodifiedFileName = createMap(); + let classifiableNames: Set<__String>; + const ambientModuleNameToUnmodifiedFileName = new Map(); // Todo:: Use this to report why file was included in --extendedDiagnostics let refFileMap: MultiMap | undefined; const cachedBindAndCheckDiagnosticsForFile: DiagnosticCache = {}; const cachedDeclarationDiagnosticsForFile: DiagnosticCache = {}; - let resolvedTypeReferenceDirectives = createMap(); + let resolvedTypeReferenceDirectives = new Map(); let fileProcessingDiagnostics = createDiagnosticCollection(); // The below settings are to track if a .js file should be add to the program if loaded via searching under node_modules. @@ -729,10 +729,10 @@ namespace ts { // If a module has some of its imports skipped due to being at the depth limit under node_modules, then track // this, as it may be imported at a shallower depth later, and then it will need its skipped imports processed. - const modulesWithElidedImports = createMap(); + const modulesWithElidedImports = new Map(); // Track source files that are source files found by searching under node_modules, as these shouldn't be compiled. - const sourceFilesFoundSearchingNodeModules = createMap(); + const sourceFilesFoundSearchingNodeModules = new Map(); performance.mark("beforeProgram"); @@ -748,7 +748,7 @@ namespace ts { const supportedExtensionsWithJsonIfResolveJsonModule = getSuppoertedExtensionsWithJsonIfResolveJsonModule(options, supportedExtensions); // Map storing if there is emit blocking diagnostics for given input - const hasEmitBlockingDiagnostics = createMap(); + const hasEmitBlockingDiagnostics = new Map(); let _compilerOptionsObjectLiteralSyntax: ObjectLiteralExpression | null | undefined; let moduleResolutionCache: ModuleResolutionCache | undefined; @@ -783,9 +783,9 @@ namespace ts { // Map from a stringified PackageId to the source file with that id. // Only one source file may have a given packageId. Others become redirects (see createRedirectSourceFile). // `packageIdToSourceFile` is only used while building the program, while `sourceFileToPackageName` and `isSourceFileTargetOfRedirect` are kept around. - const packageIdToSourceFile = createMap(); + const packageIdToSourceFile = new Map(); // Maps from a SourceFile's `.path` to the name of the package it was imported with. - let sourceFileToPackageName = createMap(); + let sourceFileToPackageName = new Map(); // Key is a file name. Value is the (non-empty, or undefined) list of files that redirect to it. let redirectTargetsMap = createMultiMap(); @@ -795,11 +795,11 @@ namespace ts { * - false if sourceFile missing for source of project reference redirect * - undefined otherwise */ - const filesByName = createMap(); + const filesByName = new Map(); let missingFilePaths: readonly Path[] | undefined; // stores 'filename -> file association' ignoring case // used to track cases when two file names differ only in casing - const filesByNameIgnoreCase = host.useCaseSensitiveFileNames() ? createMap() : undefined; + const filesByNameIgnoreCase = host.useCaseSensitiveFileNames() ? new Map() : undefined; // A parallel array to projectReferences storing the results of reading in the referenced tsconfig files let resolvedProjectReferences: readonly (ResolvedProjectReference | undefined)[] | undefined; @@ -1051,10 +1051,10 @@ namespace ts { if (!classifiableNames) { // Initialize a checker so that all our files are bound. getTypeChecker(); - classifiableNames = createUnderscoreEscapedMap(); + classifiableNames = new Set(); for (const sourceFile of files) { - copyEntries(sourceFile.classifiableNames!, classifiableNames); + sourceFile.classifiableNames?.forEach(value => classifiableNames.add(value)); } } @@ -1236,8 +1236,6 @@ namespace ts { return oldProgram.structureIsReused = StructureIsReused.Not; } - Debug.assert(!(oldProgram.structureIsReused! & (StructureIsReused.Completely | StructureIsReused.SafeModules))); - // there is an old program, check if we can reuse its structure const oldRootNames = oldProgram.getRootFileNames(); if (!arrayIsEqualTo(oldRootNames, rootNames)) { @@ -1270,7 +1268,7 @@ namespace ts { const oldSourceFiles = oldProgram.getSourceFiles(); const enum SeenPackageName { Exists, Modified } - const seenPackageNames = createMap(); + const seenPackageNames = new Map(); for (const oldSourceFile of oldSourceFiles) { let newSourceFile = host.getSourceFileByPath @@ -2571,7 +2569,7 @@ namespace ts { function getSourceOfProjectReferenceRedirect(file: string) { if (!isDeclarationFileName(file)) return undefined; if (mapFromToProjectReferenceRedirectSource === undefined) { - mapFromToProjectReferenceRedirectSource = createMap(); + mapFromToProjectReferenceRedirectSource = new Map(); forEachResolvedProjectReference(resolvedRef => { if (resolvedRef) { const out = outFile(resolvedRef.commandLine.options); diff --git a/src/compiler/resolutionCache.ts b/src/compiler/resolutionCache.ts index 6ad1f9a29c7..9e82ab0e137 100644 --- a/src/compiler/resolutionCache.ts +++ b/src/compiler/resolutionCache.ts @@ -181,15 +181,15 @@ namespace ts { * Note that .d.ts file also has .d.ts extension hence will be part of default extensions */ const failedLookupDefaultExtensions = [Extension.Ts, Extension.Tsx, Extension.Js, Extension.Jsx, Extension.Json]; - const customFailedLookupPaths = createMap(); + const customFailedLookupPaths = new Map(); - const directoryWatchesOfFailedLookups = createMap(); + const directoryWatchesOfFailedLookups = new Map(); const rootDir = rootDirForResolution && removeTrailingDirectorySeparator(getNormalizedAbsolutePath(rootDirForResolution, getCurrentDirectory())); const rootPath = (rootDir && resolutionHost.toPath(rootDir)) as Path; // TODO: GH#18217 const rootSplitLength = rootPath !== undefined ? rootPath.split(directorySeparator).length : 0; // TypeRoot watches for the types that get added as part of getAutomaticTypeDirectiveNames - const typeRootsWatches = createMap(); + const typeRootsWatches = new Map(); return { startRecordingFilesWithChangedResolutions, @@ -349,12 +349,12 @@ namespace ts { shouldRetryResolution, reusedNames, logChanges }: ResolveNamesWithLocalCacheInput): (R | undefined)[] { const path = resolutionHost.toPath(containingFile); - const resolutionsInFile = cache.get(path) || cache.set(path, createMap()).get(path)!; + const resolutionsInFile = cache.get(path) || cache.set(path, new Map()).get(path)!; const dirPath = getDirectoryPath(path); const perDirectoryCache = perDirectoryCacheWithRedirects.getOrCreateMapOfCacheRedirects(redirectedReference); let perDirectoryResolution = perDirectoryCache.get(dirPath); if (!perDirectoryResolution) { - perDirectoryResolution = createMap(); + perDirectoryResolution = new Map(); perDirectoryCache.set(dirPath, perDirectoryResolution); } const resolvedModules: (R | undefined)[] = []; @@ -368,7 +368,7 @@ namespace ts { !redirectedReference || redirectedReference.sourceFile.path !== oldRedirect.sourceFile.path : !!redirectedReference; - const seenNamesInFile = createMap(); + const seenNamesInFile = new Map(); for (const name of names) { let resolution = resolutionsInFile.get(name); // Resolution is valid if it is present and not invalidated diff --git a/src/compiler/scanner.ts b/src/compiler/scanner.ts index 0a4e5126987..77ec82ffef7 100644 --- a/src/compiler/scanner.ts +++ b/src/compiler/scanner.ts @@ -154,9 +154,9 @@ namespace ts { of: SyntaxKind.OfKeyword, }; - const textToKeyword = createMapFromTemplate(textToKeywordObj); + const textToKeyword = new Map(getEntries(textToKeywordObj)); - const textToToken = createMapFromTemplate({ + const textToToken = new Map(getEntries({ ...textToKeywordObj, "{": SyntaxKind.OpenBraceToken, "}": SyntaxKind.CloseBraceToken, @@ -218,7 +218,7 @@ namespace ts { "??=": SyntaxKind.QuestionQuestionEqualsToken, "@": SyntaxKind.AtToken, "`": SyntaxKind.BacktickToken - }); + })); /* As per ECMAScript Language Specification 3th Edition, Section 7.6: Identifiers diff --git a/src/compiler/sourcemap.ts b/src/compiler/sourcemap.ts index c698acf2f25..0db89a5830f 100644 --- a/src/compiler/sourcemap.ts +++ b/src/compiler/sourcemap.ts @@ -12,7 +12,7 @@ namespace ts { // Current source map file and its index in the sources list const rawSources: string[] = []; const sources: string[] = []; - const sourceToSourceIndexMap = createMap(); + const sourceToSourceIndexMap = new Map(); let sourcesContent: (string | null)[] | undefined; const names: string[] = []; @@ -84,7 +84,7 @@ namespace ts { function addName(name: string) { enter(); - if (!nameToNameIndexMap) nameToNameIndexMap = createMap(); + if (!nameToNameIndexMap) nameToNameIndexMap = new Map(); let nameIndex = nameToNameIndexMap.get(name); if (nameIndex === undefined) { nameIndex = names.length; diff --git a/src/compiler/transformers/classFields.ts b/src/compiler/transformers/classFields.ts index 774ded70dfe..01e3d7c7896 100644 --- a/src/compiler/transformers/classFields.ts +++ b/src/compiler/transformers/classFields.ts @@ -890,7 +890,7 @@ namespace ts { } function getPrivateIdentifierEnvironment() { - return currentPrivateIdentifierEnvironment || (currentPrivateIdentifierEnvironment = createUnderscoreEscapedMap()); + return currentPrivateIdentifierEnvironment || (currentPrivateIdentifierEnvironment = new Map()); } function getPendingExpressions() { diff --git a/src/compiler/transformers/declarations.ts b/src/compiler/transformers/declarations.ts index 5e154661fa3..477ccef9437 100644 --- a/src/compiler/transformers/declarations.ts +++ b/src/compiler/transformers/declarations.ts @@ -60,7 +60,7 @@ namespace ts { let enclosingDeclaration: Node; let necessaryTypeReferences: Set | undefined; let lateMarkedStatements: LateVisibilityPaintedStatement[] | undefined; - let lateStatementReplacementMap: ESMap>; + let lateStatementReplacementMap: ESMap>; let suppressNewDiagnosticContexts: boolean; let exportedModulesFromDeclarationEmit: Symbol[] | undefined; @@ -81,7 +81,7 @@ namespace ts { let errorNameNode: DeclarationName | undefined; let currentSourceFile: SourceFile; - let refs: ESMap; + let refs: ESMap; let libs: ESMap; let emittedImports: readonly AnyImportSyntax[] | undefined; // must be declared in container so it can be `undefined` while transformer's first pass const resolver = context.getEmitResolver(); @@ -107,7 +107,7 @@ namespace ts { } // Otherwise we should emit a path-based reference const container = getSourceFileOfNode(node); - refs.set("" + getOriginalNodeId(container), container); + refs.set(getOriginalNodeId(container), container); } function handleSymbolAccessibilityError(symbolAccessibilityResult: SymbolAccessibilityResult) { @@ -231,8 +231,8 @@ namespace ts { if (node.kind === SyntaxKind.Bundle) { isBundledEmit = true; - refs = createMap(); - libs = createMap(); + refs = new Map(); + libs = new Map(); let hasNoDefaultLib = false; const bundle = factory.createBundle(map(node.sourceFiles, sourceFile => { @@ -242,7 +242,7 @@ namespace ts { enclosingDeclaration = sourceFile; lateMarkedStatements = undefined; suppressNewDiagnosticContexts = false; - lateStatementReplacementMap = createMap(); + lateStatementReplacementMap = new Map(); getSymbolAccessibilityDiagnostic = throwDiagnostic; needsScopeFixMarker = false; resultHasScopeMarker = false; @@ -296,10 +296,10 @@ namespace ts { resultHasExternalModuleIndicator = false; suppressNewDiagnosticContexts = false; lateMarkedStatements = undefined; - lateStatementReplacementMap = createMap(); + lateStatementReplacementMap = new Map(); necessaryTypeReferences = undefined; - refs = collectReferences(currentSourceFile, createMap()); - libs = collectLibs(currentSourceFile, createMap()); + refs = collectReferences(currentSourceFile, new Map()); + libs = collectLibs(currentSourceFile, new Map()); const references: FileReference[] = []; const outputFilePath = getDirectoryPath(normalizeSlashes(getOutputPathsFor(node, host, /*forceDtsPaths*/ true).declarationFilePath!)); const referenceVisitor = mapReferencesIntoArray(references, outputFilePath); @@ -402,12 +402,12 @@ namespace ts { } } - function collectReferences(sourceFile: SourceFile | UnparsedSource, ret: ESMap) { + function collectReferences(sourceFile: SourceFile | UnparsedSource, ret: ESMap) { if (noResolve || (!isUnparsedSource(sourceFile) && isSourceFileJS(sourceFile))) return ret; forEach(sourceFile.referencedFiles, f => { const elem = host.getSourceFileFromReference(sourceFile, f); if (elem) { - ret.set("" + getOriginalNodeId(elem), elem); + ret.set(getOriginalNodeId(elem), elem); } }); return ret; @@ -772,7 +772,7 @@ namespace ts { needsDeclare = i.parent && isSourceFile(i.parent) && !(isExternalModule(i.parent) && isBundledEmit); const result = transformTopLevelDeclaration(i); needsDeclare = priorNeedsDeclare; - lateStatementReplacementMap.set("" + getOriginalNodeId(i), result); + lateStatementReplacementMap.set(getOriginalNodeId(i), result); } // And lastly, we need to get the final form of all those indetermine import declarations from before and add them to the output list @@ -781,7 +781,7 @@ namespace ts { function visitLateVisibilityMarkedStatements(statement: Statement) { if (isLateVisibilityPaintedStatement(statement)) { - const key = "" + getOriginalNodeId(statement); + const key = getOriginalNodeId(statement); if (lateStatementReplacementMap.has(key)) { const result = lateStatementReplacementMap.get(key); lateStatementReplacementMap.delete(key); @@ -1103,7 +1103,7 @@ namespace ts { const result = transformTopLevelDeclaration(input); // Don't actually transform yet; just leave as original node - will be elided/swapped by late pass - lateStatementReplacementMap.set("" + getOriginalNodeId(input), result); + lateStatementReplacementMap.set(getOriginalNodeId(input), result); return input; } @@ -1305,7 +1305,7 @@ namespace ts { needsDeclare = false; visitNode(inner, visitDeclarationStatements); // eagerly transform nested namespaces (the nesting doesn't need any elision or painting done) - const id = "" + getOriginalNodeId(inner!); // TODO: GH#18217 + const id = getOriginalNodeId(inner!); // TODO: GH#18217 const body = lateStatementReplacementMap.get(id); lateStatementReplacementMap.delete(id); return cleanup(factory.updateModuleDeclaration( diff --git a/src/compiler/transformers/es2015.ts b/src/compiler/transformers/es2015.ts index 4c20c28ffcc..02ff2c261e5 100644 --- a/src/compiler/transformers/es2015.ts +++ b/src/compiler/transformers/es2015.ts @@ -2242,7 +2242,7 @@ namespace ts { function visitLabeledStatement(node: LabeledStatement): VisitResult { if (convertedLoopState && !convertedLoopState.labels) { - convertedLoopState.labels = createMap(); + convertedLoopState.labels = new Map(); } const statement = unwrapInnermostStatementOfLabel(node, convertedLoopState && recordLabel); return isIterationStatement(statement, /*lookInLabeledStatements*/ false) @@ -3279,13 +3279,13 @@ namespace ts { function setLabeledJump(state: ConvertedLoopState, isBreak: boolean, labelText: string, labelMarker: string): void { if (isBreak) { if (!state.labeledNonLocalBreaks) { - state.labeledNonLocalBreaks = createMap(); + state.labeledNonLocalBreaks = new Map(); } state.labeledNonLocalBreaks.set(labelText, labelMarker); } else { if (!state.labeledNonLocalContinues) { - state.labeledNonLocalContinues = createMap(); + state.labeledNonLocalContinues = new Map(); } state.labeledNonLocalContinues.set(labelText, labelMarker); } diff --git a/src/compiler/transformers/es2017.ts b/src/compiler/transformers/es2017.ts index 64971fffe63..6c3c8c1332a 100644 --- a/src/compiler/transformers/es2017.ts +++ b/src/compiler/transformers/es2017.ts @@ -37,12 +37,12 @@ namespace ts { */ let enclosingSuperContainerFlags: NodeCheckFlags = 0; - let enclosingFunctionParameterNames: UnderscoreEscapedMap; + let enclosingFunctionParameterNames: Set<__String>; /** * Keeps track of property names accessed on super (`super.x`) within async functions. */ - let capturedSuperProperties: UnderscoreEscapedMap; + let capturedSuperProperties: Set<__String>; /** Whether the async function contains an element access on super (`super[x]`). */ let hasSuperElementAccess: boolean; /** A set of node IDs for generated super accessors (variable statements). */ @@ -129,7 +129,7 @@ namespace ts { case SyntaxKind.PropertyAccessExpression: if (capturedSuperProperties && isPropertyAccessExpression(node) && node.expression.kind === SyntaxKind.SuperKeyword) { - capturedSuperProperties.set(node.name.escapedText, true); + capturedSuperProperties.add(node.name.escapedText); } return visitEachChild(node, visitor, context); @@ -184,15 +184,15 @@ namespace ts { } function visitCatchClauseInAsyncBody(node: CatchClause) { - const catchClauseNames = createUnderscoreEscapedMap(); + const catchClauseNames = new Set<__String>(); recordDeclarationName(node.variableDeclaration!, catchClauseNames); // TODO: GH#18217 // names declared in a catch variable are block scoped - let catchClauseUnshadowedNames: UnderscoreEscapedMap | undefined; + let catchClauseUnshadowedNames: Set<__String> | undefined; catchClauseNames.forEach((_, escapedName) => { if (enclosingFunctionParameterNames.has(escapedName)) { if (!catchClauseUnshadowedNames) { - catchClauseUnshadowedNames = cloneMap(enclosingFunctionParameterNames); + catchClauseUnshadowedNames = new Set(enclosingFunctionParameterNames); } catchClauseUnshadowedNames.delete(escapedName); } @@ -372,9 +372,9 @@ namespace ts { ); } - function recordDeclarationName({ name }: ParameterDeclaration | VariableDeclaration | BindingElement, names: UnderscoreEscapedMap) { + function recordDeclarationName({ name }: ParameterDeclaration | VariableDeclaration | BindingElement, names: Set<__String>) { if (isIdentifier(name)) { - names.set(name.escapedText, true); + names.add(name.escapedText); } else { for (const element of name.elements) { @@ -466,7 +466,7 @@ namespace ts { // promise constructor. const savedEnclosingFunctionParameterNames = enclosingFunctionParameterNames; - enclosingFunctionParameterNames = createUnderscoreEscapedMap(); + enclosingFunctionParameterNames = new Set(); for (const parameter of node.parameters) { recordDeclarationName(parameter, enclosingFunctionParameterNames); } @@ -474,7 +474,7 @@ namespace ts { const savedCapturedSuperProperties = capturedSuperProperties; const savedHasSuperElementAccess = hasSuperElementAccess; if (!isArrowFunction) { - capturedSuperProperties = createUnderscoreEscapedMap(); + capturedSuperProperties = new Set(); hasSuperElementAccess = false; } @@ -501,7 +501,7 @@ namespace ts { if (emitSuperHelpers) { enableSubstitutionForAsyncMethodsWithSuper(); - if (hasEntries(capturedSuperProperties)) { + if (capturedSuperProperties.size) { const variableStatement = createSuperAccessVariableStatement(factory, resolver, node, capturedSuperProperties); substitutedSuperAccessors[getNodeId(variableStatement)] = true; insertStatementsAfterStandardPrologue(statements, [variableStatement]); @@ -727,7 +727,7 @@ namespace ts { } /** Creates a variable named `_super` with accessor properties for the given property names. */ - export function createSuperAccessVariableStatement(factory: NodeFactory, resolver: EmitResolver, node: FunctionLikeDeclaration, names: UnderscoreEscapedMap) { + export function createSuperAccessVariableStatement(factory: NodeFactory, resolver: EmitResolver, node: FunctionLikeDeclaration, names: Set<__String>) { // Create a variable declaration with a getter/setter (if binding) definition for each name: // const _super = Object.create(null, { x: { get: () => super.x, set: (v) => super.x = v }, ... }); const hasBinding = (resolver.getNodeCheckFlags(node) & NodeCheckFlags.AsyncMethodWithSuperBinding) !== 0; diff --git a/src/compiler/transformers/es2018.ts b/src/compiler/transformers/es2018.ts index 143a864edb4..f6c3ae66354 100644 --- a/src/compiler/transformers/es2018.ts +++ b/src/compiler/transformers/es2018.ts @@ -66,7 +66,7 @@ namespace ts { let taggedTemplateStringDeclarations: VariableDeclaration[]; /** Keeps track of property names accessed on super (`super.x`) within async functions. */ - let capturedSuperProperties: UnderscoreEscapedMap; + let capturedSuperProperties: Set<__String>; /** Whether the async function contains an element access on super (`super[x]`). */ let hasSuperElementAccess: boolean; /** A set of node IDs for generated super accessors. */ @@ -240,7 +240,7 @@ namespace ts { return visitTaggedTemplateExpression(node as TaggedTemplateExpression); case SyntaxKind.PropertyAccessExpression: if (capturedSuperProperties && isPropertyAccessExpression(node) && node.expression.kind === SyntaxKind.SuperKeyword) { - capturedSuperProperties.set(node.name.escapedText, true); + capturedSuperProperties.add(node.name.escapedText); } return visitEachChild(node, visitor, context); case SyntaxKind.ElementAccessExpression: @@ -911,7 +911,7 @@ namespace ts { const savedCapturedSuperProperties = capturedSuperProperties; const savedHasSuperElementAccess = hasSuperElementAccess; - capturedSuperProperties = createUnderscoreEscapedMap(); + capturedSuperProperties = new Set(); hasSuperElementAccess = false; const returnStatement = factory.createReturnStatement( diff --git a/src/compiler/transformers/generators.ts b/src/compiler/transformers/generators.ts index a49122a3bae..e988100903b 100644 --- a/src/compiler/transformers/generators.ts +++ b/src/compiler/transformers/generators.ts @@ -2111,7 +2111,7 @@ namespace ts { const text = idText(variable.name); name = declareLocal(text); if (!renamedCatchVariables) { - renamedCatchVariables = createMap(); + renamedCatchVariables = new Map(); renamedCatchVariableDeclarations = []; context.enableSubstitution(SyntaxKind.Identifier); } diff --git a/src/compiler/transformers/jsx.ts b/src/compiler/transformers/jsx.ts index cc000666143..d399408fbe4 100644 --- a/src/compiler/transformers/jsx.ts +++ b/src/compiler/transformers/jsx.ts @@ -315,7 +315,7 @@ namespace ts { } } - const entities = createMapFromTemplate({ + const entities = new Map(getEntries({ quot: 0x0022, amp: 0x0026, apos: 0x0027, @@ -569,5 +569,5 @@ namespace ts { clubs: 0x2663, hearts: 0x2665, diams: 0x2666 - }); + })); } diff --git a/src/compiler/transformers/module/esnextAnd2015.ts b/src/compiler/transformers/module/esnextAnd2015.ts index eafc595e31a..2d0ee26ebce 100644 --- a/src/compiler/transformers/module/esnextAnd2015.ts +++ b/src/compiler/transformers/module/esnextAnd2015.ts @@ -124,7 +124,7 @@ namespace ts { function onEmitNode(hint: EmitHint, node: Node, emitCallback: (hint: EmitHint, node: Node) => void): void { if (isSourceFile(node)) { if ((isExternalModule(node) || compilerOptions.isolatedModules) && compilerOptions.importHelpers) { - helperNameSubstitutions = createMap(); + helperNameSubstitutions = new Map(); } previousOnEmitNode(hint, node, emitCallback); helperNameSubstitutions = undefined; diff --git a/src/compiler/transformers/module/system.ts b/src/compiler/transformers/module/system.ts index 26590fbb5d9..07e99ed1261 100644 --- a/src/compiler/transformers/module/system.ts +++ b/src/compiler/transformers/module/system.ts @@ -144,7 +144,7 @@ namespace ts { * @param externalImports The imports for the file. */ function collectDependencyGroups(externalImports: (ImportDeclaration | ImportEqualsDeclaration | ExportDeclaration)[]) { - const groupIndices = createMap(); + const groupIndices = new Map(); const dependencyGroups: DependencyGroup[] = []; for (const externalImport of externalImports) { const externalModuleName = getExternalModuleNameLiteral(factory, externalImport, currentSourceFile, host, resolver, compilerOptions); diff --git a/src/compiler/transformers/ts.ts b/src/compiler/transformers/ts.ts index 1eb4ddb7779..3e2e7892599 100644 --- a/src/compiler/transformers/ts.ts +++ b/src/compiler/transformers/ts.ts @@ -1531,6 +1531,7 @@ namespace ts { case SyntaxKind.LiteralType: switch ((node).literal.kind) { case SyntaxKind.StringLiteral: + case SyntaxKind.NoSubstitutionTemplateLiteral: return factory.createIdentifier("String"); case SyntaxKind.PrefixUnaryExpression: @@ -2528,7 +2529,7 @@ namespace ts { */ function recordEmittedDeclarationInScope(node: FunctionDeclaration | ClassDeclaration | ModuleDeclaration | EnumDeclaration) { if (!currentScopeFirstDeclarationsOfName) { - currentScopeFirstDeclarationsOfName = createUnderscoreEscapedMap(); + currentScopeFirstDeclarationsOfName = new Map(); } const name = declaredNameInScope(node); diff --git a/src/compiler/transformers/utilities.ts b/src/compiler/transformers/utilities.ts index 61facb7ebcf..a52cf7c68cd 100644 --- a/src/compiler/transformers/utilities.ts +++ b/src/compiler/transformers/utilities.ts @@ -69,7 +69,7 @@ namespace ts { const externalImports: (ImportDeclaration | ImportEqualsDeclaration | ExportDeclaration)[] = []; const exportSpecifiers = createMultiMap(); const exportedBindings: Identifier[][] = []; - const uniqueExports = createMap(); + const uniqueExports = new Map(); let exportedNames: Identifier[] | undefined; let hasExportDefault = false; let exportEquals: ExportAssignment | undefined; diff --git a/src/compiler/tsbuildPublic.ts b/src/compiler/tsbuildPublic.ts index 4afcab961a8..a9e2c9a4a95 100644 --- a/src/compiler/tsbuildPublic.ts +++ b/src/compiler/tsbuildPublic.ts @@ -63,7 +63,7 @@ namespace ts { } function getOrCreateValueMapFromConfigFileMap(configFileMap: ESMap>, resolved: ResolvedConfigFilePath): ESMap { - return getOrCreateValueFromConfigFileMap>(configFileMap, resolved, createMap); + return getOrCreateValueFromConfigFileMap>(configFileMap, resolved, () => new Map()); } function newer(date1: Date, date2: Date): Date { @@ -439,10 +439,12 @@ namespace ts { // Clear all to ResolvedConfigFilePaths cache to start fresh state.resolvedConfigFilePaths.clear(); - const currentProjects = arrayToSet( - getBuildOrderFromAnyBuildOrder(buildOrder), - resolved => toResolvedConfigFilePath(state, resolved) - ) as ESMap; + + // TODO(rbuckton): Should be a `Set`, but that requires changing the code below that uses `mutateMapSkippingNewValues` + const currentProjects = new Map( + getBuildOrderFromAnyBuildOrder(buildOrder).map( + resolved => [toResolvedConfigFilePath(state, resolved), true as true]) + ); const noopOnDelete = { onDeleteValue: noop }; // Config file cache @@ -1796,7 +1798,7 @@ namespace ts { if (!state.watch) return; updateWatchingWildcardDirectories( getOrCreateValueMapFromConfigFileMap(state.allWatchedWildcardDirectories, resolvedPath), - createMapFromTemplate(parsed.configFileSpecs!.wildcardDirectories), + new Map(getEntries(parsed.configFileSpecs!.wildcardDirectories)), (dir, flags) => state.watchDirectory( state.hostWithWatch, dir, diff --git a/src/compiler/types.ts b/src/compiler/types.ts index 4519670c963..1b96ff3c1ed 100644 --- a/src/compiler/types.ts +++ b/src/compiler/types.ts @@ -822,6 +822,9 @@ namespace ts { ReportsMask = ReportsUnmeasurable | ReportsUnreliable } + /* @internal */ + export type NodeId = number; + export interface Node extends ReadonlyTextRange { readonly kind: SyntaxKind; readonly flags: NodeFlags; @@ -829,7 +832,7 @@ namespace ts { /* @internal */ readonly transformFlags: TransformFlags; // Flags for transforms readonly decorators?: NodeArray; // Array of decorators (in document order) readonly modifiers?: ModifiersArray; // Array of modifiers - /* @internal */ id?: number; // Unique id (used to look up NodeLinks) + /* @internal */ id?: NodeId; // Unique id (used to look up NodeLinks) readonly parent: Node; // Parent node (initialized by binding) /* @internal */ original?: Node; // The original node if this is an updated node. /* @internal */ symbol: Symbol; // Symbol declared by node (initialized by binding) @@ -3445,7 +3448,7 @@ namespace ts { // Stores a line map for the file. // This field should never be used directly to obtain line map, use getLineMap function instead. /* @internal */ lineMap: readonly number[]; - /* @internal */ classifiableNames?: ReadonlyUnderscoreEscapedMap; + /* @internal */ classifiableNames?: ReadonlySet<__String>; // Comments containing @ts-* directives, in order. /* @internal */ commentDirectives?: CommentDirective[]; // Stores a mapping 'external module reference text' -> 'resolved file name' | undefined @@ -3724,7 +3727,7 @@ namespace ts { /* @internal */ getDiagnosticsProducingTypeChecker(): TypeChecker; /* @internal */ dropDiagnosticsProducingTypeChecker(): void; - /* @internal */ getClassifiableNames(): UnderscoreEscapedMap; + /* @internal */ getClassifiableNames(): Set<__String>; getNodeCount(): number; getIdentifierCount(): number; @@ -4160,6 +4163,7 @@ namespace ts { UseAliasDefinedOutsideCurrentScope = 1 << 14, // Allow non-visible aliases UseSingleQuotesForStringLiteralType = 1 << 28, // Use single quotes for string literal type NoTypeReduction = 1 << 29, // Don't call getReducedType + NoUndefinedOptionalParameterType = 1 << 30, // Do not add undefined to optional parameter type // Error handling AllowThisInObjectLiteral = 1 << 15, @@ -4336,6 +4340,9 @@ namespace ts { /* @internal */ export type AnyImportOrRequire = AnyImportSyntax | RequireVariableDeclaration; + /* @internal */ + export type AnyImportOrRequireStatement = AnyImportSyntax | RequireVariableStatement; + /* @internal */ export type AnyImportOrReExport = AnyImportSyntax | ExportDeclaration; @@ -4357,8 +4364,17 @@ namespace ts { /* @internal */ export interface RequireVariableDeclaration extends VariableDeclaration { + readonly initializer: RequireOrImportCall; + } - initializer: RequireOrImportCall; + /* @internal */ + export interface RequireVariableStatement extends VariableStatement { + readonly declarationList: RequireVariableDeclarationList; + } + + /* @internal */ + export interface RequireVariableDeclarationList extends VariableDeclarationList { + readonly declarations: NodeArray; } /* @internal */ @@ -4574,6 +4590,9 @@ namespace ts { LateBindingContainer = Class | Interface | TypeLiteral | ObjectLiteral | Function, } + /* @internal */ + export type SymbolId = number; + export interface Symbol { flags: SymbolFlags; // Symbol flags escapedName: __String; // Name of symbol @@ -4582,7 +4601,7 @@ namespace ts { members?: SymbolTable; // Class, interface or object literal instance members exports?: SymbolTable; // Module exports globalExports?: SymbolTable; // Conditional global UMD exports - /* @internal */ id?: number; // Unique id (used to look up SymbolLinks) + /* @internal */ id?: SymbolId; // Unique id (used to look up SymbolLinks) /* @internal */ mergeId?: number; // Merge id (used to look up merged symbol) /* @internal */ parent?: Symbol; // Parent symbol /* @internal */ exportSymbol?: Symbol; // Exported symbol associated with this symbol @@ -4603,8 +4622,8 @@ namespace ts { declaredType?: Type; // Type of class, interface, enum, type alias, or type parameter typeParameters?: TypeParameter[]; // Type parameters of type alias (undefined if non-generic) outerTypeParameters?: TypeParameter[]; // Outer type parameters of anonymous object type - instantiations?: ESMap; // Instantiations of generic type alias (undefined if non-generic) - inferredClassSymbol?: ESMap; // Symbol of an inferred ES5 constructor function + instantiations?: ESMap; // Instantiations of generic type alias (undefined if non-generic) + inferredClassSymbol?: ESMap; // Symbol of an inferred ES5 constructor function mapper?: TypeMapper; // Type mapper for instantiation alias referenced?: boolean; // True if alias symbol has been referenced as a value that can be emitted constEnumReferenced?: boolean; // True if alias symbol resolves to a const enum and is referenced as a value ('referenced' will be false) @@ -4622,16 +4641,16 @@ namespace ts { exportsSomeValue?: boolean; // True if module exports some value (not just types) enumKind?: EnumKind; // Enum declaration classification originatingImport?: ImportDeclaration | ImportCall; // Import declaration which produced the symbol, present if the symbol is marked as uncallable but had call signatures in `resolveESModuleSymbol` - lateSymbol?: Symbol; // Late-bound symbol for a computed property + lateSymbol?: Symbol; // Late-bound symbol for a computed property specifierCache?: ESMap; // For symbols corresponding to external modules, a cache of incoming path -> module specifier name mappings - extendedContainers?: Symbol[]; // Containers (other than the parent) which this symbol is aliased in - extendedContainersByFile?: ESMap; // Containers (other than the parent) which this symbol is aliased in - variances?: VarianceFlags[]; // Alias symbol type argument variance cache - deferralConstituents?: Type[]; // Calculated list of constituents for a deferred type - deferralParent?: Type; // Source union/intersection of a deferred type - cjsExportMerged?: Symbol; // Version of the symbol with all non export= exports merged with the export= target + extendedContainers?: Symbol[]; // Containers (other than the parent) which this symbol is aliased in + extendedContainersByFile?: ESMap; // Containers (other than the parent) which this symbol is aliased in + variances?: VarianceFlags[]; // Alias symbol type argument variance cache + deferralConstituents?: Type[]; // Calculated list of constituents for a deferred type + deferralParent?: Type; // Source union/intersection of a deferred type + cjsExportMerged?: Symbol; // Version of the symbol with all non export= exports merged with the export= target typeOnlyDeclaration?: TypeOnlyCompatibleAliasDeclaration | false; // First resolved alias declaration that makes the symbol only usable in type constructs - isConstructorDeclaredProperty?: boolean; // Property declared through 'this.x = ...' assignment in constructor + isConstructorDeclaredProperty?: boolean; // Property declared through 'this.x = ...' assignment in constructor tupleLabelDeclaration?: NamedTupleMember | ParameterDeclaration; // Declaration associated with the tuple's label } @@ -4714,7 +4733,7 @@ namespace ts { * with a normal string (which is good, it cannot be misused on assignment or on usage), * while still being comparable with a normal string via === (also good) and castable from a string. */ - export type __String = (string & { __escapedIdentifier: void }) | (void & { __escapedIdentifier: void }) | InternalSymbolName; + export type __String = (string & { __escapedIdentifier: void }) | (void & { __escapedIdentifier: void }) | InternalSymbolName; // eslint-disable-line @typescript-eslint/naming-convention /** ReadonlyMap where keys are `__String`s. */ export interface ReadonlyUnderscoreEscapedMap extends ReadonlyESMap<__String, T> { @@ -4763,31 +4782,31 @@ namespace ts { /* @internal */ export interface NodeLinks { - flags: NodeCheckFlags; // Set of flags specific to Node - resolvedType?: Type; // Cached type of type node - resolvedEnumType?: Type; // Cached constraint type from enum jsdoc tag - resolvedSignature?: Signature; // Cached signature of signature node or call expression - resolvedSymbol?: Symbol; // Cached name resolution result - resolvedIndexInfo?: IndexInfo; // Cached indexing info resolution result - effectsSignature?: Signature; // Signature with possible control flow effects + flags: NodeCheckFlags; // Set of flags specific to Node + resolvedType?: Type; // Cached type of type node + resolvedEnumType?: Type; // Cached constraint type from enum jsdoc tag + resolvedSignature?: Signature; // Cached signature of signature node or call expression + resolvedSymbol?: Symbol; // Cached name resolution result + resolvedIndexInfo?: IndexInfo; // Cached indexing info resolution result + effectsSignature?: Signature; // Signature with possible control flow effects enumMemberValue?: string | number; // Constant value of enum member - isVisible?: boolean; // Is this node visible + isVisible?: boolean; // Is this node visible containsArgumentsReference?: boolean; // Whether a function-like declaration contains an 'arguments' reference - hasReportedStatementInAmbientContext?: boolean; // Cache boolean if we report statements in ambient context - jsxFlags: JsxFlags; // flags for knowing what kind of element/attributes we're dealing with - resolvedJsxElementAttributesType?: Type; // resolved element attributes type of a JSX openinglike element - resolvedJsxElementAllAttributesType?: Type; // resolved all element attributes type of a JSX openinglike element - resolvedJSDocType?: Type; // Resolved type of a JSDoc type reference - switchTypes?: Type[]; // Cached array of switch case expression types - jsxNamespace?: Symbol | false; // Resolved jsx namespace symbol for this node - contextFreeType?: Type; // Cached context-free type used by the first pass of inference; used when a function's return is partially contextually sensitive - deferredNodes?: ESMap; // Set of nodes whose checking has been deferred + hasReportedStatementInAmbientContext?: boolean; // Cache boolean if we report statements in ambient context + jsxFlags: JsxFlags; // flags for knowing what kind of element/attributes we're dealing with + resolvedJsxElementAttributesType?: Type; // resolved element attributes type of a JSX openinglike element + resolvedJsxElementAllAttributesType?: Type; // resolved all element attributes type of a JSX openinglike element + resolvedJSDocType?: Type; // Resolved type of a JSDoc type reference + switchTypes?: Type[]; // Cached array of switch case expression types + jsxNamespace?: Symbol | false; // Resolved jsx namespace symbol for this node + contextFreeType?: Type; // Cached context-free type used by the first pass of inference; used when a function's return is partially contextually sensitive + deferredNodes?: ESMap; // Set of nodes whose checking has been deferred capturedBlockScopeBindings?: Symbol[]; // Block-scoped bindings captured beneath this part of an IterationStatement - outerTypeParameters?: TypeParameter[]; // Outer type parameters of anonymous object type - instantiations?: ESMap; // Instantiations of generic type alias (undefined if non-generic) - isExhaustive?: boolean; // Is node an exhaustive switch statement + outerTypeParameters?: TypeParameter[]; // Outer type parameters of anonymous object type + instantiations?: ESMap; // Instantiations of generic type alias (undefined if non-generic) + isExhaustive?: boolean; // Is node an exhaustive switch statement skipDirectInference?: true; // Flag set by the API `getContextualType` call on a node when `Completions` is passed to force the checker to skip making inferences to a node's type - declarationRequiresScopeChange?: boolean; // Set by `useOuterVariableScopeInParameter` in checker when downlevel emit would change the name resolution scope inside of a parameter. + declarationRequiresScopeChange?: boolean; // Set by `useOuterVariableScopeInParameter` in checker when downlevel emit would change the name resolution scope inside of a parameter. } export const enum TypeFlags { @@ -4878,16 +4897,19 @@ namespace ts { export type DestructuringPattern = BindingPattern | ObjectLiteralExpression | ArrayLiteralExpression; + /* @internal */ + export type TypeId = number; + // Properties common to all types export interface Type { flags: TypeFlags; // Flags - /* @internal */ id: number; // Unique ID + /* @internal */ id: TypeId; // Unique ID /* @internal */ checker: TypeChecker; symbol: Symbol; // Symbol associated with type (if any) pattern?: DestructuringPattern; // Destructuring pattern represented by type (if any) aliasSymbol?: Symbol; // Alias associated with type - aliasTypeArguments?: readonly Type[]; // Alias type arguments (if any) - /* @internal */ aliasTypeArgumentsContainsMarker?: boolean; // Alias type arguments (if any) + aliasTypeArguments?: readonly Type[]; // Alias type arguments (if any) + /* @internal */ aliasTypeArgumentsContainsMarker?: boolean; // Alias type arguments (if any) /* @internal */ permissiveInstantiation?: Type; // Instantiation with type parameters mapped to wildcard type /* @internal */ diff --git a/src/compiler/utilities.ts b/src/compiler/utilities.ts index 732630d7d9f..e3c3e279ab8 100644 --- a/src/compiler/utilities.ts +++ b/src/compiler/utilities.ts @@ -1,8 +1,6 @@ /* @internal */ namespace ts { - export const resolvingEmptyArray: never[] = [] as never[]; - export const emptyMap = createMap() as ReadonlyESMap & ReadonlyPragmaMap; - export const emptyUnderscoreEscapedMap: ReadonlyUnderscoreEscapedMap = emptyMap as ReadonlyUnderscoreEscapedMap; + export const resolvingEmptyArray: never[] = []; export const externalHelpersModuleNameText = "tslib"; @@ -22,17 +20,23 @@ namespace ts { return undefined; } - /** Create a new escaped identifier map. */ + /** + * Create a new escaped identifier map. + * @deprecated Use `new Map<__String, T>()` instead. + */ export function createUnderscoreEscapedMap(): UnderscoreEscapedMap { - return new Map() as UnderscoreEscapedMap; + return new Map<__String, T>(); } - export function hasEntries(map: ReadonlyUnderscoreEscapedMap | undefined): map is ReadonlyUnderscoreEscapedMap { + /** + * @deprecated Use `!!map?.size` instead + */ + export function hasEntries(map: ReadonlyCollection | undefined): map is ReadonlyCollection { return !!map && !!map.size; } export function createSymbolTable(symbols?: readonly Symbol[]): SymbolTable { - const result = createMap() as SymbolTable; + const result = new Map<__String, Symbol>(); if (symbols) { for (const symbol of symbols) { result.set(symbol.escapedName, symbol); @@ -163,27 +167,6 @@ namespace ts { }); } - /** - * Creates a set from the elements of an array. - * - * @param array the array of input elements. - */ - export function arrayToSet(array: readonly string[]): ESMap; - export function arrayToSet(array: readonly T[], makeKey: (value: T) => string | undefined): ESMap; - export function arrayToSet(array: readonly T[], makeKey: (value: T) => __String | undefined): UnderscoreEscapedMap; - export function arrayToSet(array: readonly any[], makeKey?: (value: any) => string | __String | undefined): ESMap | UnderscoreEscapedMap { - return arrayToMap(array, makeKey || (s => s), returnTrue); - } - - export function cloneMap(map: SymbolTable): SymbolTable; - export function cloneMap(map: ReadonlyUnderscoreEscapedMap): UnderscoreEscapedMap; - export function cloneMap(map: ReadonlyESMap): ESMap; - export function cloneMap(map: ReadonlyESMap): ESMap { - const clone = createMap(); - copyEntries(map, clone); - return clone; - } - export function usingSingleLineStringWriter(action: (writer: EmitTextWriter) => void): string { const oldString = stringWriter.getText(); try { @@ -206,7 +189,7 @@ namespace ts { export function setResolvedModule(sourceFile: SourceFile, moduleNameText: string, resolvedModule: ResolvedModuleFull): void { if (!sourceFile.resolvedModules) { - sourceFile.resolvedModules = createMap(); + sourceFile.resolvedModules = new Map(); } sourceFile.resolvedModules.set(moduleNameText, resolvedModule); @@ -214,7 +197,7 @@ namespace ts { export function setResolvedTypeReferenceDirective(sourceFile: SourceFile, typeReferenceDirectiveName: string, resolvedTypeReferenceDirective?: ResolvedTypeReferenceDirective): void { if (!sourceFile.resolvedTypeReferenceDirectiveNames) { - sourceFile.resolvedTypeReferenceDirectiveNames = createMap(); + sourceFile.resolvedTypeReferenceDirectiveNames = new Map(); } sourceFile.resolvedTypeReferenceDirectiveNames.set(typeReferenceDirectiveName, resolvedTypeReferenceDirective); @@ -473,7 +456,7 @@ namespace ts { ])) ); - const usedLines = createMap(); + const usedLines = new Map(); return { getUnusedExpectations, markUsed }; @@ -1934,8 +1917,10 @@ namespace ts { return isVariableDeclaration(node) && !!node.initializer && isRequireCall(node.initializer, requireStringLiteralLikeArgument); } - export function isRequireVariableDeclarationStatement(node: Node, requireStringLiteralLikeArgument = true): node is VariableStatement { - return isVariableStatement(node) && every(node.declarationList.declarations, decl => isRequireVariableDeclaration(decl, requireStringLiteralLikeArgument)); + export function isRequireVariableStatement(node: Node, requireStringLiteralLikeArgument = true): node is RequireVariableStatement { + return isVariableStatement(node) + && node.declarationList.declarations.length > 0 + && every(node.declarationList.declarations, decl => isRequireVariableDeclaration(decl, requireStringLiteralLikeArgument)); } export function isSingleOrDoubleQuote(charCode: number) { @@ -3590,7 +3575,7 @@ namespace ts { export function createDiagnosticCollection(): DiagnosticCollection { let nonFileDiagnostics = [] as Diagnostic[] as SortedArray; // See GH#19873 const filesWithDiagnostics = [] as string[] as SortedArray; - const fileDiagnostics = createMap>(); + const fileDiagnostics = new Map>(); let hasReadNonFileDiagnostics = false; return { @@ -3688,7 +3673,7 @@ namespace ts { const singleQuoteEscapedCharsRegExp = /[\\\'\u0000-\u001f\t\v\f\b\r\n\u2028\u2029\u0085]/g; // Template strings should be preserved as much as possible const backtickQuoteEscapedCharsRegExp = /[\\`]/g; - const escapedCharsMap = createMapFromTemplate({ + const escapedCharsMap = new Map(getEntries({ "\t": "\\t", "\v": "\\v", "\f": "\\f", @@ -3702,7 +3687,7 @@ namespace ts { "\u2028": "\\u2028", // lineSeparator "\u2029": "\\u2029", // paragraphSeparator "\u0085": "\\u0085" // nextLine - }); + })); function encodeUtf16EscapeSequence(charCode: number): string { const hexCharCode = charCode.toString(16).toUpperCase(); @@ -3752,10 +3737,10 @@ namespace ts { // the map below must be updated. const jsxDoubleQuoteEscapedCharsRegExp = /[\"\u0000-\u001f\u2028\u2029\u0085]/g; const jsxSingleQuoteEscapedCharsRegExp = /[\'\u0000-\u001f\u2028\u2029\u0085]/g; - const jsxEscapedCharsMap = createMapFromTemplate({ + const jsxEscapedCharsMap = new Map(getEntries({ "\"": """, "\'": "'" - }); + })); function encodeJsxCharacterEntity(charCode: number): string { const hexCharCode = charCode.toString(16).toUpperCase(); @@ -4755,7 +4740,7 @@ namespace ts { if (isPropertyAccessExpression(expr)) { const baseStr = tryGetPropertyAccessOrIdentifierToString(expr.expression); if (baseStr !== undefined) { - return baseStr + "." + expr.name; + return baseStr + "." + entityNameToString(expr.name); } } else if (isIdentifier(expr)) { @@ -5942,7 +5927,7 @@ namespace ts { } export function discoverProbableSymlinks(files: readonly SourceFile[], getCanonicalFileName: GetCanonicalFileName, cwd: string): ReadonlyESMap { - const result = createMap(); + const result = new Map(); const symlinks = flatten(mapDefined(files, sf => sf.resolvedModules && compact(arrayFrom(mapIterator(sf.resolvedModules.values(), res => res && res.originalPath && res.resolvedFileName !== res.originalPath ? [res.resolvedFileName, res.originalPath] as const : undefined))))); @@ -6200,7 +6185,7 @@ namespace ts { // Associate an array of results with each include regex. This keeps results in order of the "include" order. // If there are no "includes", then just put everything in results[0]. const results: string[][] = includeFileRegexes ? includeFileRegexes.map(() => []) : [[]]; - const visited = createMap(); + const visited = new Map(); const toCanonical = createGetCanonicalFileName(useCaseSensitiveFileNames); for (const basePath of patterns.basePaths) { visitDirectory(basePath, combinePaths(currentDirectory, basePath), depth); @@ -6564,67 +6549,17 @@ namespace ts { return { min, max }; } - export interface ReadonlyNodeSet { - has(node: TNode): boolean; - forEach(cb: (node: TNode) => void): void; - some(pred: (node: TNode) => boolean): boolean; - } + /** @deprecated Use `ReadonlySet` instead. */ + export type ReadonlyNodeSet = ReadonlySet; - export class NodeSet implements ReadonlyNodeSet { - private map = createMap(); + /** @deprecated Use `Set` instead. */ + export type NodeSet = Set; - add(node: TNode): void { - this.map.set(String(getNodeId(node)), node); - } - tryAdd(node: TNode): boolean { - if (this.has(node)) return false; - this.add(node); - return true; - } - has(node: TNode): boolean { - return this.map.has(String(getNodeId(node))); - } - forEach(cb: (node: TNode) => void): void { - this.map.forEach(cb); - } - some(pred: (node: TNode) => boolean): boolean { - return forEachEntry(this.map, pred) || false; - } - } + /** @deprecated Use `ReadonlyMap` instead. */ + export type ReadonlyNodeMap = ReadonlyESMap; - export interface ReadonlyNodeMap { - get(node: TNode): TValue | undefined; - has(node: TNode): boolean; - } - - export class NodeMap implements ReadonlyNodeMap { - private map = createMap<{ node: TNode, value: TValue }>(); - - get(node: TNode): TValue | undefined { - const res = this.map.get(String(getNodeId(node))); - return res && res.value; - } - - getOrUpdate(node: TNode, setValue: () => TValue): TValue { - const res = this.get(node); - if (res) return res; - const value = setValue(); - this.set(node, value); - return value; - } - - set(node: TNode, value: TValue): void { - this.map.set(String(getNodeId(node)), { node, value }); - } - - has(node: TNode): boolean { - return this.map.has(String(getNodeId(node))); - } - - forEach(cb: (value: TValue, node: TNode) => void): void { - this.map.forEach(({ node, value }) => cb(value, node)); - } - } + /** @deprecated Use `Map` instead. */ + export type NodeMap = ESMap; export function rangeOfNode(node: Node): TextRange { return { pos: getTokenPosOfNode(node), end: node.end }; @@ -6652,18 +6587,6 @@ namespace ts { return a === b || typeof a === "object" && a !== null && typeof b === "object" && b !== null && equalOwnProperties(a as MapLike, b as MapLike, isJsonEqual); } - export function getOrUpdate(map: ESMap, key: string, getDefault: () => T): T { - const got = map.get(key); - if (got === undefined) { - const value = getDefault(); - map.set(key, value); - return value; - } - else { - return got; - } - } - /** * Converts a bigint literal string, e.g. `0x1234n`, * to its decimal string representation, e.g. `4660`. diff --git a/src/compiler/watchPublic.ts b/src/compiler/watchPublic.ts index 778b7907f0a..2673b116810 100644 --- a/src/compiler/watchPublic.ts +++ b/src/compiler/watchPublic.ts @@ -252,7 +252,7 @@ namespace ts { let timerToInvalidateFailedLookupResolutions: any; // timer callback to invalidate resolutions for changes in failed lookup locations - const sourceFilesCache = createMap(); // Cache that stores the source file and version info + const sourceFilesCache = new Map(); // Cache that stores the source file and version info let missingFilePathsRequestedForRelease: Path[] | undefined; // These paths are held temparirly so that we can remove the entry from source file cache if the file is not tracked by missing files let hasChangedCompilerOptions = false; // True if the compiler options have changed between compilations @@ -717,8 +717,8 @@ namespace ts { function watchConfigFileWildCardDirectories() { if (configFileSpecs) { updateWatchingWildcardDirectories( - watchedWildcardDirectories || (watchedWildcardDirectories = createMap()), - createMapFromTemplate(configFileSpecs.wildcardDirectories), + watchedWildcardDirectories || (watchedWildcardDirectories = new Map()), + new Map(getEntries(configFileSpecs.wildcardDirectories)), watchWildcardDirectory ); } diff --git a/src/compiler/watchUtilities.ts b/src/compiler/watchUtilities.ts index bd57c539b45..6d4f02c1f38 100644 --- a/src/compiler/watchUtilities.ts +++ b/src/compiler/watchUtilities.ts @@ -44,7 +44,7 @@ namespace ts { return undefined; } - const cachedReadDirectoryResult = createMap(); + const cachedReadDirectoryResult = new Map(); const getCanonicalFileName = createGetCanonicalFileName(useCaseSensitiveFileNames); return { useCaseSensitiveFileNames, @@ -266,7 +266,8 @@ namespace ts { createMissingFileWatch: (missingFilePath: Path) => FileWatcher, ) { const missingFilePaths = program.getMissingFilePaths(); - const newMissingFilePathMap = arrayToSet(missingFilePaths); + // TODO(rbuckton): Should be a `Set` but that requires changing the below code that uses `mutateMap` + const newMissingFilePathMap = arrayToMap(missingFilePaths, identity, returnTrue); // Update the missing file paths watcher mutateMap( missingFileWatches, diff --git a/src/executeCommandLine/executeCommandLine.ts b/src/executeCommandLine/executeCommandLine.ts index e67734841fa..9d1ecc7c666 100644 --- a/src/executeCommandLine/executeCommandLine.ts +++ b/src/executeCommandLine/executeCommandLine.ts @@ -75,7 +75,7 @@ namespace ts { const usageColumn: string[] = []; // Things like "-d, --declaration" go in here. const descriptionColumn: string[] = []; - const optionsDescriptionMap = createMap(); // Map between option.description and list of option.type if it is a kind + const optionsDescriptionMap = new Map(); // Map between option.description and list of option.type if it is a kind for (const option of optionsList) { // If an option lacks a description, diff --git a/src/harness/client.ts b/src/harness/client.ts index bd8a1b256ff..c040ee60ae5 100644 --- a/src/harness/client.ts +++ b/src/harness/client.ts @@ -35,7 +35,7 @@ namespace ts.server { export class SessionClient implements LanguageService { private sequence = 0; - private lineMaps: ESMap = createMap(); + private lineMaps = new Map(); private messages: string[] = []; private lastRenameEntry: RenameEntry | undefined; diff --git a/src/harness/fourslashImpl.ts b/src/harness/fourslashImpl.ts index f012c7830c6..ca95ff34ebb 100644 --- a/src/harness/fourslashImpl.ts +++ b/src/harness/fourslashImpl.ts @@ -177,7 +177,7 @@ namespace FourSlash { public formatCodeSettings: ts.FormatCodeSettings; - private inputFiles = ts.createMap(); // Map between inputFile's fileName and its content for easily looking up when resolving references + private inputFiles = new ts.Map(); // Map between inputFile's fileName and its content for easily looking up when resolving references private static getDisplayPartsJson(displayParts: ts.SymbolDisplayPart[] | undefined) { let result = ""; @@ -830,7 +830,7 @@ namespace FourSlash { this.raiseError(`Expected 'isGlobalCompletion to be ${options.isGlobalCompletion}, got ${actualCompletions.isGlobalCompletion}`); } - const nameToEntries = ts.createMap(); + const nameToEntries = new ts.Map(); for (const entry of actualCompletions.entries) { const entries = nameToEntries.get(entry.name); if (!entries) { @@ -995,7 +995,7 @@ namespace FourSlash { } public setTypesRegistry(map: ts.MapLike): void { - this.languageServiceAdapterHost.typesRegistry = ts.createMapFromTemplate(map); + this.languageServiceAdapterHost.typesRegistry = new ts.Map(ts.getEntries(map)); } public verifyTypeOfSymbolAtLocation(range: Range, symbol: ts.Symbol, expected: string): void { @@ -2889,7 +2889,7 @@ namespace FourSlash { public verifyBraceCompletionAtPosition(negative: boolean, openingBrace: string) { - const openBraceMap = ts.createMapFromTemplate({ + const openBraceMap = new ts.Map(ts.getEntries({ "(": ts.CharacterCodes.openParen, "{": ts.CharacterCodes.openBrace, "[": ts.CharacterCodes.openBracket, @@ -2897,7 +2897,7 @@ namespace FourSlash { '"': ts.CharacterCodes.doubleQuote, "`": ts.CharacterCodes.backtick, "<": ts.CharacterCodes.lessThan - }); + })); const charCode = openBraceMap.get(openingBrace); @@ -3510,7 +3510,7 @@ namespace FourSlash { let text = ""; if (callHierarchyItem) { const file = this.findFile(callHierarchyItem.file); - text += this.formatCallHierarchyItem(file, callHierarchyItem, CallHierarchyItemDirection.Root, ts.createMap(), ""); + text += this.formatCallHierarchyItem(file, callHierarchyItem, CallHierarchyItemDirection.Root, new ts.Map(), ""); } return text; } @@ -3806,7 +3806,7 @@ namespace FourSlash { const lines = contents.split("\n"); let i = 0; - const markerPositions = ts.createMap(); + const markerPositions = new ts.Map(); const markers: Marker[] = []; const ranges: Range[] = []; @@ -4195,7 +4195,7 @@ namespace FourSlash { /** Collects an array of unique outputs. */ function unique(inputs: readonly T[], getOutput: (t: T) => string): string[] { - const set = ts.createMap(); + const set = new ts.Map(); for (const input of inputs) { const out = getOutput(input); set.set(out, true); diff --git a/src/harness/harnessIO.ts b/src/harness/harnessIO.ts index c1d68896d4a..c7f04cf277d 100644 --- a/src/harness/harnessIO.ts +++ b/src/harness/harnessIO.ts @@ -251,9 +251,9 @@ namespace Harness { } if (!libFileNameSourceFileMap) { - libFileNameSourceFileMap = ts.createMapFromTemplate({ + libFileNameSourceFileMap = new ts.Map(ts.getEntries({ [defaultLibFileName]: createSourceFileAndAssertInvariants(defaultLibFileName, IO.readFile(libFolder + "lib.es5.d.ts")!, /*languageVersion*/ ts.ScriptTarget.Latest) - }); + })); } let sourceFile = libFileNameSourceFileMap.get(fileName); @@ -316,7 +316,7 @@ namespace Harness { let optionsIndex: ts.ESMap; function getCommandLineOption(name: string): ts.CommandLineOption | undefined { if (!optionsIndex) { - optionsIndex = ts.createMap(); + optionsIndex = new ts.Map(); const optionDeclarations = harnessOptionDeclarations.concat(ts.optionDeclarations); for (const option of optionDeclarations) { optionsIndex.set(option.name.toLowerCase(), option); @@ -595,7 +595,7 @@ namespace Harness { errorsReported = 0; // 'merge' the lines of each input file with any errors associated with it - const dupeCase = ts.createMap(); + const dupeCase = new ts.Map(); for (const inputFile of inputFiles.filter(f => f.content !== undefined)) { // Filter down to the errors in the file const fileErrors = diagnostics.filter((e): e is ts.DiagnosticWithLocation => { @@ -775,7 +775,7 @@ namespace Harness { if (skipBaseline) { return; } - const dupeCase = ts.createMap(); + const dupeCase = new ts.Map(); for (const file of allFiles) { const { unitName } = file; @@ -946,7 +946,7 @@ namespace Harness { // Collect, test, and sort the fileNames const files = Array.from(outputFiles); files.slice().sort((a, b) => ts.compareStringsCaseSensitive(cleanName(a.file), cleanName(b.file))); - const dupeCase = ts.createMap(); + const dupeCase = new ts.Map(); // Yield them for (const outputFile of files) { yield [checkDuplicatedFileName(outputFile.file, dupeCase), "/*====== " + outputFile.file + " ======*/\r\n" + Utils.removeByteOrderMark(outputFile.text)]; @@ -1075,10 +1075,10 @@ namespace Harness { return option.type; } if (option.type === "boolean") { - return booleanVaryByStarSettingValues || (booleanVaryByStarSettingValues = ts.createMapFromTemplate({ + return booleanVaryByStarSettingValues || (booleanVaryByStarSettingValues = new ts.Map(ts.getEntries({ true: 1, false: 0 - })); + }))); } } } @@ -1403,7 +1403,7 @@ namespace Harness { export function runMultifileBaseline(relativeFileBase: string, extension: string, generateContent: () => IterableIterator<[string, string, number]> | IterableIterator<[string, string]> | null, opts?: BaselineOptions, referencedExtensions?: string[]): void { const gen = generateContent(); - const writtenFiles = ts.createMap(); + const writtenFiles = new ts.Map(); const errors: Error[] = []; // eslint-disable-next-line no-null/no-null diff --git a/src/harness/harnessUtils.ts b/src/harness/harnessUtils.ts index c63afb323a9..d9f410c9945 100644 --- a/src/harness/harnessUtils.ts +++ b/src/harness/harnessUtils.ts @@ -52,7 +52,7 @@ namespace Utils { } export function memoize(f: T, memoKey: (...anything: any[]) => string): T { - const cache = ts.createMap(); + const cache = new ts.Map(); return (function (this: any, ...args: any[]) { const key = memoKey(...args); diff --git a/src/harness/loggedIO.ts b/src/harness/loggedIO.ts index a7a75b123a4..f9d8806a6b7 100644 --- a/src/harness/loggedIO.ts +++ b/src/harness/loggedIO.ts @@ -219,7 +219,7 @@ namespace Playback { replayLog = log; // Remove non-found files from the log (shouldn't really need them, but we still record them for diagnostic purposes) replayLog.filesRead = replayLog.filesRead.filter(f => f.result!.contents !== undefined); - replayFilesRead = ts.createMap(); + replayFilesRead = new ts.Map(); for (const file of replayLog.filesRead) { replayFilesRead.set(ts.normalizeSlashes(file.path).toLowerCase(), file); } diff --git a/src/harness/sourceMapRecorder.ts b/src/harness/sourceMapRecorder.ts index 668c7812366..0d9fd7a1aab 100644 --- a/src/harness/sourceMapRecorder.ts +++ b/src/harness/sourceMapRecorder.ts @@ -325,7 +325,7 @@ namespace Harness.SourceMapRecorder { export function getSourceMapRecordWithSystem(sys: ts.System, sourceMapFile: string) { const sourceMapRecorder = new Compiler.WriterAggregator(); let prevSourceFile: documents.TextDocument | undefined; - const files = ts.createMap(); + const files = new ts.Map(); const sourceMap = ts.tryParseRawSourceMap(sys.readFile(sourceMapFile, "utf8")!); if (sourceMap) { const mapDirectory = ts.getDirectoryPath(sourceMapFile); diff --git a/src/harness/virtualFileSystemWithWatch.ts b/src/harness/virtualFileSystemWithWatch.ts index 1d0071a6f15..c0e66430e9a 100644 --- a/src/harness/virtualFileSystemWithWatch.ts +++ b/src/harness/virtualFileSystemWithWatch.ts @@ -133,7 +133,7 @@ interface Array { length: number; [n: number]: T; }` } const notInActual: string[] = []; const duplicates: string[] = []; - const seen = createMap(); + const seen = new Map(); forEach(expectedKeys, expectedKey => { if (seen.has(expectedKey)) { duplicates.push(expectedKey); @@ -260,20 +260,20 @@ interface Array { length: number; [n: number]: T; }` } export function checkOutputContains(host: TestServerHost, expected: readonly string[]) { - const mapExpected = arrayToSet(expected); - const mapSeen = createMap(); + const mapExpected = new Set(expected); + const mapSeen = new Set(); for (const f of host.getOutput()) { - assert.isUndefined(mapSeen.get(f), `Already found ${f} in ${JSON.stringify(host.getOutput())}`); + assert.isFalse(mapSeen.has(f), `Already found ${f} in ${JSON.stringify(host.getOutput())}`); if (mapExpected.has(f)) { mapExpected.delete(f); - mapSeen.set(f, true); + mapSeen.add(f); } } assert.equal(mapExpected.size, 0, `Output has missing ${JSON.stringify(arrayFrom(mapExpected.keys()))} in ${JSON.stringify(host.getOutput())}`); } export function checkOutputDoesNotContain(host: TestServerHost, expectedToBeAbsent: string[] | readonly string[]) { - const mapExpectedToBeAbsent = arrayToSet(expectedToBeAbsent); + const mapExpectedToBeAbsent = new Set(expectedToBeAbsent); for (const f of host.getOutput()) { assert.isFalse(mapExpectedToBeAbsent.has(f), `Contains ${f} in ${JSON.stringify(host.getOutput())}`); } diff --git a/src/jsTyping/jsTyping.ts b/src/jsTyping/jsTyping.ts index bf6d46b8fc9..ca765bd776f 100644 --- a/src/jsTyping/jsTyping.ts +++ b/src/jsTyping/jsTyping.ts @@ -68,7 +68,7 @@ namespace ts.JsTyping { "zlib" ]; - export const nodeCoreModules = arrayToSet(nodeCoreModuleList); + export const nodeCoreModules = new Set(nodeCoreModuleList); export function nonRelativeModuleNameForTypingCache(moduleName: string) { return nodeCoreModules.has(moduleName) ? "node" : moduleName; @@ -81,13 +81,13 @@ namespace ts.JsTyping { export function loadSafeList(host: TypingResolutionHost, safeListPath: Path): SafeList { const result = readConfigFile(safeListPath, path => host.readFile(path)); - return createMapFromTemplate(result.config); + return new Map(getEntries(result.config)); } export function loadTypesMap(host: TypingResolutionHost, typesMapPath: Path): SafeList | undefined { const result = readConfigFile(typesMapPath, path => host.readFile(path)); if (result.config) { - return createMapFromTemplate(result.config.simpleMap); + return new Map(getEntries(result.config.simpleMap)); } return undefined; } @@ -118,7 +118,7 @@ namespace ts.JsTyping { } // A typing name to typing file path mapping - const inferredTypings = createMap(); + const inferredTypings = new Map(); // Only infer typings for .js and .jsx files fileNames = mapDefined(fileNames, fileName => { @@ -134,9 +134,9 @@ namespace ts.JsTyping { const exclude = typeAcquisition.exclude || []; // Directories to search for package.json, bower.json and other typing information - const possibleSearchDirs = arrayToSet(fileNames, getDirectoryPath); - possibleSearchDirs.set(projectRootPath, true); - possibleSearchDirs.forEach((_true, searchDir) => { + const possibleSearchDirs = new Set(fileNames.map(getDirectoryPath)); + possibleSearchDirs.add(projectRootPath); + possibleSearchDirs.forEach((searchDir) => { const packageJsonPath = combinePaths(searchDir, "package.json"); getTypingNamesFromJson(packageJsonPath, filesToWatch); diff --git a/src/loc/lcl/cht/diagnosticMessages/diagnosticMessages.generated.json.lcl b/src/loc/lcl/cht/diagnosticMessages/diagnosticMessages.generated.json.lcl index de3b5b3d8cf..d0cc8686749 100644 --- a/src/loc/lcl/cht/diagnosticMessages/diagnosticMessages.generated.json.lcl +++ b/src/loc/lcl/cht/diagnosticMessages/diagnosticMessages.generated.json.lcl @@ -4068,11 +4068,11 @@ - + - + - + diff --git a/src/loc/lcl/csy/diagnosticMessages/diagnosticMessages.generated.json.lcl b/src/loc/lcl/csy/diagnosticMessages/diagnosticMessages.generated.json.lcl index af468581cb1..0828ca494f8 100644 --- a/src/loc/lcl/csy/diagnosticMessages/diagnosticMessages.generated.json.lcl +++ b/src/loc/lcl/csy/diagnosticMessages/diagnosticMessages.generated.json.lcl @@ -4077,11 +4077,11 @@ - + - + - + diff --git a/src/loc/lcl/deu/diagnosticMessages/diagnosticMessages.generated.json.lcl b/src/loc/lcl/deu/diagnosticMessages/diagnosticMessages.generated.json.lcl index be93c7d7098..2f49c14009b 100644 --- a/src/loc/lcl/deu/diagnosticMessages/diagnosticMessages.generated.json.lcl +++ b/src/loc/lcl/deu/diagnosticMessages/diagnosticMessages.generated.json.lcl @@ -4065,11 +4065,11 @@ - + - + - + diff --git a/src/loc/lcl/esn/diagnosticMessages/diagnosticMessages.generated.json.lcl b/src/loc/lcl/esn/diagnosticMessages/diagnosticMessages.generated.json.lcl index a1e4a83bef8..c33d53f7534 100644 --- a/src/loc/lcl/esn/diagnosticMessages/diagnosticMessages.generated.json.lcl +++ b/src/loc/lcl/esn/diagnosticMessages/diagnosticMessages.generated.json.lcl @@ -4080,11 +4080,11 @@ - + - + - + diff --git a/src/loc/lcl/fra/diagnosticMessages/diagnosticMessages.generated.json.lcl b/src/loc/lcl/fra/diagnosticMessages/diagnosticMessages.generated.json.lcl index c9deb643841..8c96e820e2d 100644 --- a/src/loc/lcl/fra/diagnosticMessages/diagnosticMessages.generated.json.lcl +++ b/src/loc/lcl/fra/diagnosticMessages/diagnosticMessages.generated.json.lcl @@ -4080,11 +4080,11 @@ - + - + - + diff --git a/src/loc/lcl/ita/diagnosticMessages/diagnosticMessages.generated.json.lcl b/src/loc/lcl/ita/diagnosticMessages/diagnosticMessages.generated.json.lcl index 3d7f1f2e903..ca652f03e6a 100644 --- a/src/loc/lcl/ita/diagnosticMessages/diagnosticMessages.generated.json.lcl +++ b/src/loc/lcl/ita/diagnosticMessages/diagnosticMessages.generated.json.lcl @@ -4068,11 +4068,11 @@ - + - + - + diff --git a/src/loc/lcl/jpn/diagnosticMessages/diagnosticMessages.generated.json.lcl b/src/loc/lcl/jpn/diagnosticMessages/diagnosticMessages.generated.json.lcl index 8ab32789f0d..91641a1b9f8 100644 --- a/src/loc/lcl/jpn/diagnosticMessages/diagnosticMessages.generated.json.lcl +++ b/src/loc/lcl/jpn/diagnosticMessages/diagnosticMessages.generated.json.lcl @@ -4068,11 +4068,11 @@ - + - + - + diff --git a/src/loc/lcl/kor/diagnosticMessages/diagnosticMessages.generated.json.lcl b/src/loc/lcl/kor/diagnosticMessages/diagnosticMessages.generated.json.lcl index 0753386ed00..5343f95b25b 100644 --- a/src/loc/lcl/kor/diagnosticMessages/diagnosticMessages.generated.json.lcl +++ b/src/loc/lcl/kor/diagnosticMessages/diagnosticMessages.generated.json.lcl @@ -4068,11 +4068,11 @@ - + - + - + diff --git a/src/loc/lcl/plk/diagnosticMessages/diagnosticMessages.generated.json.lcl b/src/loc/lcl/plk/diagnosticMessages/diagnosticMessages.generated.json.lcl index c3eb08758fb..724757bfb9a 100644 --- a/src/loc/lcl/plk/diagnosticMessages/diagnosticMessages.generated.json.lcl +++ b/src/loc/lcl/plk/diagnosticMessages/diagnosticMessages.generated.json.lcl @@ -4058,11 +4058,11 @@ - + - + - + diff --git a/src/loc/lcl/ptb/diagnosticMessages/diagnosticMessages.generated.json.lcl b/src/loc/lcl/ptb/diagnosticMessages/diagnosticMessages.generated.json.lcl index 3478f608261..aae8694a00a 100644 --- a/src/loc/lcl/ptb/diagnosticMessages/diagnosticMessages.generated.json.lcl +++ b/src/loc/lcl/ptb/diagnosticMessages/diagnosticMessages.generated.json.lcl @@ -4061,11 +4061,11 @@ - + - + - + diff --git a/src/loc/lcl/rus/diagnosticMessages/diagnosticMessages.generated.json.lcl b/src/loc/lcl/rus/diagnosticMessages/diagnosticMessages.generated.json.lcl index 5ae3fdb64ee..1fb77c996e4 100644 --- a/src/loc/lcl/rus/diagnosticMessages/diagnosticMessages.generated.json.lcl +++ b/src/loc/lcl/rus/diagnosticMessages/diagnosticMessages.generated.json.lcl @@ -4067,11 +4067,11 @@ - + - + - + diff --git a/src/loc/lcl/trk/diagnosticMessages/diagnosticMessages.generated.json.lcl b/src/loc/lcl/trk/diagnosticMessages/diagnosticMessages.generated.json.lcl index 3ee93af1607..1a954a5afef 100644 --- a/src/loc/lcl/trk/diagnosticMessages/diagnosticMessages.generated.json.lcl +++ b/src/loc/lcl/trk/diagnosticMessages/diagnosticMessages.generated.json.lcl @@ -4061,11 +4061,11 @@ - + - + - + diff --git a/src/server/editorServices.ts b/src/server/editorServices.ts index 2ea24134f28..0c0dd41f351 100644 --- a/src/server/editorServices.ts +++ b/src/server/editorServices.ts @@ -158,7 +158,7 @@ namespace ts.server { } function prepareConvertersForEnumLikeCompilerOptions(commandLineOptions: CommandLineOption[]): ESMap> { - const map: ESMap> = createMap>(); + const map = new Map>(); for (const option of commandLineOptions) { if (typeof option.type === "object") { const optionMap = >option.type; @@ -174,11 +174,11 @@ namespace ts.server { const compilerOptionConverters = prepareConvertersForEnumLikeCompilerOptions(optionDeclarations); const watchOptionsConverters = prepareConvertersForEnumLikeCompilerOptions(optionsForWatch); - const indentStyle = createMapFromTemplate({ + const indentStyle = new Map(getEntries({ none: IndentStyle.None, block: IndentStyle.Block, smart: IndentStyle.Smart - }); + })); export interface TypesMapFile { typesMap: SafeList; @@ -571,16 +571,16 @@ namespace ts.server { * Container of all known scripts */ /*@internal*/ - readonly filenameToScriptInfo = createMap(); - private readonly scriptInfoInNodeModulesWatchers = createMap (); + readonly filenameToScriptInfo = new Map(); + private readonly scriptInfoInNodeModulesWatchers = new Map(); /** * Contains all the deleted script info's version information so that * it does not reset when creating script info again * (and could have potentially collided with version where contents mismatch) */ - private readonly filenameToScriptInfoVersion = createMap(); + private readonly filenameToScriptInfoVersion = new Map(); // Set of all '.js' files ever opened. - private readonly allJsFilesForOpenFileTelemetry = createMap(); + private readonly allJsFilesForOpenFileTelemetry = new Map(); /** * Map to the real path of the infos @@ -590,7 +590,7 @@ namespace ts.server { /** * maps external project file name to list of config files that were the part of this project */ - private readonly externalProjectToConfiguredProjectMap: ESMap = createMap(); + private readonly externalProjectToConfiguredProjectMap = new Map(); /** * external projects (configuration and list of root files is not controlled by tsserver) @@ -603,7 +603,7 @@ namespace ts.server { /** * projects specified by a tsconfig.json file */ - readonly configuredProjects: Map = createMap(); + readonly configuredProjects: Map = new Map(); /** * Open files: with value being project root path, and key being Path of the file that is open */ @@ -611,16 +611,16 @@ namespace ts.server { /** * Map of open files that are opened without complete path but have projectRoot as current directory */ - private readonly openFilesWithNonRootedDiskPath = createMap(); + private readonly openFilesWithNonRootedDiskPath = new Map(); private compilerOptionsForInferredProjects: CompilerOptions | undefined; - private compilerOptionsForInferredProjectsPerProjectRoot = createMap(); + private compilerOptionsForInferredProjectsPerProjectRoot = new Map(); private watchOptionsForInferredProjects: WatchOptions | undefined; - private watchOptionsForInferredProjectsPerProjectRoot = createMap(); + private watchOptionsForInferredProjectsPerProjectRoot = new Map(); /** * Project size for configured or external projects */ - private readonly projectToSizeMap: ESMap = createMap(); + private readonly projectToSizeMap = new Map(); /** * This is a map of config file paths existence that doesnt need query to disk * - The entry can be present because there is inferred project that needs to watch addition of config file to directory @@ -628,14 +628,14 @@ namespace ts.server { * - Or it is present if we have configured project open with config file at that location * In this case the exists property is always true */ - private readonly configFileExistenceInfoCache = createMap(); + private readonly configFileExistenceInfoCache = new Map(); /*@internal*/ readonly throttledOperations: ThrottledOperations; private readonly hostConfiguration: HostConfiguration; private safelist: SafeList = defaultTypeSafeList; - private readonly legacySafelist = createMap(); + private readonly legacySafelist = new Map(); - private pendingProjectUpdates = createMap(); + private pendingProjectUpdates = new Map(); /* @internal */ pendingEnsureProjectForOpenFiles = false; @@ -663,7 +663,7 @@ namespace ts.server { public readonly syntaxOnly?: boolean; /** Tracks projects that we have already sent telemetry for. */ - private readonly seenProjects = createMap(); + private readonly seenProjects = new Map(); /*@internal*/ readonly watchFactory: WatchFactory; @@ -2039,7 +2039,7 @@ namespace ts.server { project.setCompilerOptions(compilerOptions); project.setWatchOptions(parsedCommandLine.watchOptions); project.enableLanguageService(); - project.watchWildcards(createMapFromTemplate(parsedCommandLine.wildcardDirectories!)); // TODO: GH#18217 + project.watchWildcards(new Map(getEntries(parsedCommandLine.wildcardDirectories!))); // TODO: GH#18217 } project.enablePluginsWithOptions(compilerOptions, this.currentPluginConfigOverrides); const filesToAdd = parsedCommandLine.fileNames.concat(project.getExternalFiles()); @@ -2048,7 +2048,7 @@ namespace ts.server { private updateNonInferredProjectFiles(project: ExternalProject | ConfiguredProject | AutoImportProviderProject, files: T[], propertyReader: FilePropertyReader) { const projectRootFilesMap = project.getRootFilesMap(); - const newRootScriptInfoMap = createMap(); + const newRootScriptInfoMap = new Map(); for (const f of files) { const newRootFile = propertyReader.getFileName(f); @@ -2772,7 +2772,7 @@ namespace ts.server { * reloadForInfo provides a way to filter out files to reload configured project for */ private reloadConfiguredProjectForFiles(openFiles: ESMap, delayReload: boolean, shouldReloadProjectFor: (openFileValue: T) => boolean, reason: string) { - const updatedProjects = createMap(); + const updatedProjects = new Map(); // try to reload config file for all open files openFiles.forEach((openFileValue, path) => { // Filter out the files that need to be ignored @@ -3153,7 +3153,7 @@ namespace ts.server { } private removeOrphanConfiguredProjects(toRetainConfiguredProjects: readonly ConfiguredProject[] | ConfiguredProject | undefined) { - const toRemoveConfiguredProjects = cloneMap(this.configuredProjects); + const toRemoveConfiguredProjects = new Map(this.configuredProjects); const markOriginalProjectsAsUsed = (project: Project) => { if (!project.isOrphan() && project.originalConfiguredProjects) { project.originalConfiguredProjects.forEach( @@ -3208,7 +3208,7 @@ namespace ts.server { } private removeOrphanScriptInfos() { - const toRemoveScriptInfos = cloneMap(this.filenameToScriptInfo); + const toRemoveScriptInfos = new Map(this.filenameToScriptInfo); this.filenameToScriptInfo.forEach(info => { // If script info is open or orphan, retain it and its dependencies if (!info.isScriptOpen() && info.isOrphan() && !info.isContainedByAutoImportProvider()) { @@ -3686,7 +3686,7 @@ namespace ts.server { // Also save the current configuration to pass on to any projects that are yet to be loaded. // If a plugin is configured twice, only the latest configuration will be remembered. - this.currentPluginConfigOverrides = this.currentPluginConfigOverrides || createMap(); + this.currentPluginConfigOverrides = this.currentPluginConfigOverrides || new Map(); this.currentPluginConfigOverrides.set(args.pluginName, args.configuration); } @@ -3721,7 +3721,7 @@ namespace ts.server { /*@internal*/ private watchPackageJsonFile(path: Path) { - const watchers = this.packageJsonFilesMap || (this.packageJsonFilesMap = createMap()); + const watchers = this.packageJsonFilesMap || (this.packageJsonFilesMap = new Map()); if (!watchers.has(path)) { this.invalidateProjectAutoImports(path); watchers.set(path, this.watchFactory.watchFile( diff --git a/src/server/packageJsonCache.ts b/src/server/packageJsonCache.ts index 18a4a8a36bf..8c09ebda2c4 100644 --- a/src/server/packageJsonCache.ts +++ b/src/server/packageJsonCache.ts @@ -11,8 +11,8 @@ namespace ts.server { } export function createPackageJsonCache(host: ProjectService): PackageJsonCache { - const packageJsons = createMap(); - const directoriesWithoutPackageJson = createMap(); + const packageJsons = new Map(); + const directoriesWithoutPackageJson = new Map(); return { addOrUpdate, forEach: packageJsons.forEach.bind(packageJsons), diff --git a/src/server/project.ts b/src/server/project.ts index 2edb225fee7..7742a416d9d 100644 --- a/src/server/project.ts +++ b/src/server/project.ts @@ -127,7 +127,7 @@ namespace ts.server { export abstract class Project implements LanguageServiceHost, ModuleResolutionHost { private rootFiles: ScriptInfo[] = []; - private rootFilesMap = createMap(); + private rootFilesMap = new Map(); private program: Program | undefined; private externalFiles: SortedReadonlyArray | undefined; private missingFilesMap: ESMap | undefined; @@ -1282,7 +1282,7 @@ namespace ts.server { if (this.generatedFilesMap.has(path)) return; } else { - this.generatedFilesMap = createMap(); + this.generatedFilesMap = new Map(); } this.generatedFilesMap.set(path, this.createGeneratedFileWatcher(generatedFile)); } @@ -1948,7 +1948,7 @@ namespace ts.server { * Otherwise it will create an InferredProject. */ export class ConfiguredProject extends Project { - private typeAcquisition!: TypeAcquisition; // TODO: GH#18217 + private typeAcquisition: TypeAcquisition | undefined; /* @internal */ configFileWatcher: FileWatcher | undefined; private directoriesWatchedForWildcards: ESMap | undefined; @@ -1960,7 +1960,7 @@ namespace ts.server { pendingReloadReason: string | undefined; /* @internal */ - openFileWatchTriggered = createMap(); + openFileWatchTriggered = new Map(); /*@internal*/ configFileSpecs: ConfigFileSpecs | undefined; @@ -2164,13 +2164,13 @@ namespace ts.server { } getTypeAcquisition() { - return this.typeAcquisition; + return this.typeAcquisition || {}; } /*@internal*/ watchWildcards(wildcardDirectories: ESMap) { updateWatchingWildcardDirectories( - this.directoriesWatchedForWildcards || (this.directoriesWatchedForWildcards = createMap()), + this.directoriesWatchedForWildcards || (this.directoriesWatchedForWildcards = new Map()), wildcardDirectories, // Create new directory watcher (directory, flags) => this.projectService.watchWildcardDirectory(directory as Path, flags, this), @@ -2282,7 +2282,7 @@ namespace ts.server { */ export class ExternalProject extends Project { excludedFiles: readonly NormalizedPath[] = []; - private typeAcquisition!: TypeAcquisition; // TODO: GH#18217 + private typeAcquisition: TypeAcquisition | undefined; /*@internal*/ constructor(public externalProjectName: string, projectService: ProjectService, @@ -2318,7 +2318,7 @@ namespace ts.server { } getTypeAcquisition() { - return this.typeAcquisition; + return this.typeAcquisition || {}; } setTypeAcquisition(newTypeAcquisition: TypeAcquisition): void { diff --git a/src/server/session.ts b/src/server/session.ts index d02b8dd0e85..d8c35c7924c 100644 --- a/src/server/session.ts +++ b/src/server/session.ts @@ -1434,7 +1434,7 @@ namespace ts.server { } private toSpanGroups(locations: readonly RenameLocation[]): readonly protocol.SpanGroup[] { - const map = createMap(); + const map = new Map(); for (const { fileName, textSpan, contextSpan, originalContextSpan: _2, originalTextSpan: _, originalFileName: _1, ...prefixSuffixText } of locations) { let group = map.get(fileName); if (!group) map.set(fileName, group = { file: fileName, locs: [] }); @@ -2338,7 +2338,7 @@ namespace ts.server { return { response, responseRequired: true }; } - private handlers = createMapFromTemplate<(request: protocol.Request) => HandlerResponse>({ + private handlers = new Map(getEntries<(request: protocol.Request) => HandlerResponse>({ [CommandNames.Status]: () => { const response: protocol.StatusResponseBody = { version: ts.version }; // eslint-disable-line @typescript-eslint/no-unnecessary-qualifier return this.requiredResponse(response); @@ -2697,7 +2697,7 @@ namespace ts.server { [CommandNames.ProvideCallHierarchyOutgoingCalls]: (request: protocol.ProvideCallHierarchyOutgoingCallsRequest) => { return this.requiredResponse(this.provideCallHierarchyOutgoingCalls(request.arguments)); }, - }); + })); public addProtocolHandler(command: string, handler: (request: protocol.Request) => HandlerResponse) { if (this.handlers.has(command)) { diff --git a/src/server/typingsCache.ts b/src/server/typingsCache.ts index 88154e4ccee..1d63a6df6ae 100644 --- a/src/server/typingsCache.ts +++ b/src/server/typingsCache.ts @@ -41,7 +41,7 @@ namespace ts.server { if ((arr1 || emptyArray).length === 0 && (arr2 || emptyArray).length === 0) { return true; } - const set: ESMap = createMap(); + const set = new Map(); let unique = 0; for (const v of arr1!) { @@ -83,7 +83,7 @@ namespace ts.server { /*@internal*/ export class TypingsCache { - private readonly perProjectCache: ESMap = createMap(); + private readonly perProjectCache = new Map(); constructor(private readonly installer: ITypingsInstaller) { } diff --git a/src/server/utilities.ts b/src/server/utilities.ts index f8437a45f03..c5a6489b667 100644 --- a/src/server/utilities.ts +++ b/src/server/utilities.ts @@ -1,7 +1,7 @@ /* @internal */ namespace ts.server { export class ThrottledOperations { - private readonly pendingTimeouts: ESMap = createMap(); + private readonly pendingTimeouts = new Map(); private readonly logger?: Logger | undefined; constructor(private readonly host: ServerHost, logger: Logger) { this.logger = logger.hasLevel(LogLevel.verbose) ? logger : undefined; diff --git a/src/server/utilitiesPublic.ts b/src/server/utilitiesPublic.ts index 5e9ba6b9732..42f97a435f5 100644 --- a/src/server/utilitiesPublic.ts +++ b/src/server/utilitiesPublic.ts @@ -80,7 +80,7 @@ namespace ts.server { } export function createNormalizedPathMap(): NormalizedPathMap { - const map = createMap(); + const map = new Map(); return { get(path) { return map.get(path); diff --git a/src/services/callHierarchy.ts b/src/services/callHierarchy.ts index 2718c76963a..9934c91c88e 100644 --- a/src/services/callHierarchy.ts +++ b/src/services/callHierarchy.ts @@ -304,7 +304,7 @@ namespace ts.CallHierarchy { } function getCallSiteGroupKey(entry: CallSite) { - return "" + getNodeId(entry.declaration); + return getNodeId(entry.declaration); } function createCallHierarchyIncomingCall(from: CallHierarchyItem, fromSpans: TextSpan[]): CallHierarchyIncomingCall { diff --git a/src/services/classifier.ts b/src/services/classifier.ts index d10f67e0e94..fc9cad9c5a7 100644 --- a/src/services/classifier.ts +++ b/src/services/classifier.ts @@ -452,7 +452,7 @@ namespace ts { } /* @internal */ - export function getSemanticClassifications(typeChecker: TypeChecker, cancellationToken: CancellationToken, sourceFile: SourceFile, classifiableNames: UnderscoreEscapedMap, span: TextSpan): ClassifiedSpan[] { + export function getSemanticClassifications(typeChecker: TypeChecker, cancellationToken: CancellationToken, sourceFile: SourceFile, classifiableNames: ReadonlySet<__String>, span: TextSpan): ClassifiedSpan[] { return convertClassificationsToSpans(getEncodedSemanticClassifications(typeChecker, cancellationToken, sourceFile, classifiableNames, span)); } @@ -472,12 +472,15 @@ namespace ts { case SyntaxKind.ClassDeclaration: case SyntaxKind.InterfaceDeclaration: case SyntaxKind.FunctionDeclaration: + case SyntaxKind.ClassExpression: + case SyntaxKind.FunctionExpression: + case SyntaxKind.ArrowFunction: cancellationToken.throwIfCancellationRequested(); } } /* @internal */ - export function getEncodedSemanticClassifications(typeChecker: TypeChecker, cancellationToken: CancellationToken, sourceFile: SourceFile, classifiableNames: UnderscoreEscapedMap, span: TextSpan): Classifications { + export function getEncodedSemanticClassifications(typeChecker: TypeChecker, cancellationToken: CancellationToken, sourceFile: SourceFile, classifiableNames: ReadonlySet<__String>, span: TextSpan): Classifications { const spans: number[] = []; sourceFile.forEachChild(function cb(node: Node): void { // Only walk into nodes that intersect the requested span. diff --git a/src/services/codeFixProvider.ts b/src/services/codeFixProvider.ts index ab88aa97a3d..aee5a199fad 100644 --- a/src/services/codeFixProvider.ts +++ b/src/services/codeFixProvider.ts @@ -1,7 +1,7 @@ /* @internal */ namespace ts.codefix { const errorCodeToFixes = createMultiMap(); - const fixIdToRegistration = createMap(); + const fixIdToRegistration = new Map(); export type DiagnosticAndArguments = DiagnosticMessage | [DiagnosticMessage, string] | [DiagnosticMessage, string, string]; function diagnosticToString(diag: DiagnosticAndArguments): string { diff --git a/src/services/codefixes/addMissingConst.ts b/src/services/codefixes/addMissingConst.ts index 1c819cafe0f..5f15572c978 100644 --- a/src/services/codefixes/addMissingConst.ts +++ b/src/services/codefixes/addMissingConst.ts @@ -16,12 +16,12 @@ namespace ts.codefix { }, fixIds: [fixId], getAllCodeActions: context => { - const fixedNodes = new NodeSet(); + const fixedNodes = new Set(); return codeFixAll(context, errorCodes, (changes, diag) => makeChange(changes, diag.file, diag.start, context.program, fixedNodes)); }, }); - function makeChange(changeTracker: textChanges.ChangeTracker, sourceFile: SourceFile, pos: number, program: Program, fixedNodes?: NodeSet) { + function makeChange(changeTracker: textChanges.ChangeTracker, sourceFile: SourceFile, pos: number, program: Program, fixedNodes?: Set) { const token = getTokenAtPosition(sourceFile, pos); const forInitializer = findAncestor(token, node => isForInOrOfStatement(node.parent) ? node.parent.initializer === node : @@ -57,8 +57,8 @@ namespace ts.codefix { } } - function applyChange(changeTracker: textChanges.ChangeTracker, initializer: Node, sourceFile: SourceFile, fixedNodes?: NodeSet) { - if (!fixedNodes || fixedNodes.tryAdd(initializer)) { + function applyChange(changeTracker: textChanges.ChangeTracker, initializer: Node, sourceFile: SourceFile, fixedNodes?: Set) { + if (!fixedNodes || tryAddToSet(fixedNodes, initializer)) { changeTracker.insertModifierBefore(sourceFile, SyntaxKind.ConstKeyword, initializer); } } diff --git a/src/services/codefixes/addMissingDeclareProperty.ts b/src/services/codefixes/addMissingDeclareProperty.ts index e08929b9dd1..f7b9369f957 100644 --- a/src/services/codefixes/addMissingDeclareProperty.ts +++ b/src/services/codefixes/addMissingDeclareProperty.ts @@ -15,19 +15,19 @@ namespace ts.codefix { }, fixIds: [fixId], getAllCodeActions: context => { - const fixedNodes = new NodeSet(); + const fixedNodes = new Set(); return codeFixAll(context, errorCodes, (changes, diag) => makeChange(changes, diag.file, diag.start, fixedNodes)); }, }); - function makeChange(changeTracker: textChanges.ChangeTracker, sourceFile: SourceFile, pos: number, fixedNodes?: NodeSet) { + function makeChange(changeTracker: textChanges.ChangeTracker, sourceFile: SourceFile, pos: number, fixedNodes?: Set) { const token = getTokenAtPosition(sourceFile, pos); if (!isIdentifier(token)) { return; } const declaration = token.parent; if (declaration.kind === SyntaxKind.PropertyDeclaration && - (!fixedNodes || fixedNodes.tryAdd(declaration))) { + (!fixedNodes || tryAddToSet(fixedNodes, declaration))) { changeTracker.insertModifierBefore(sourceFile, SyntaxKind.DeclareKeyword, declaration); } } diff --git a/src/services/codefixes/convertToAsyncFunction.ts b/src/services/codefixes/convertToAsyncFunction.ts index 26f6212cf2b..a01d3613198 100644 --- a/src/services/codefixes/convertToAsyncFunction.ts +++ b/src/services/codefixes/convertToAsyncFunction.ts @@ -61,7 +61,7 @@ namespace ts.codefix { return; } - const synthNamesMap: ESMap = createMap(); + const synthNamesMap = new Map(); const isInJavascript = isInJSFile(functionToConvert); const setOfExpressionsToReturn = getAllPromiseExpressionsToReturn(functionToConvert, checker); const functionToConvertRenamed = renameCollidingVarNames(functionToConvert, checker, synthNamesMap, context.sourceFile); @@ -149,7 +149,7 @@ namespace ts.codefix { It then checks for any collisions and renames them through getSynthesizedDeepClone */ function renameCollidingVarNames(nodeToRename: FunctionLikeDeclaration, checker: TypeChecker, synthNamesMap: ESMap, sourceFile: SourceFile): FunctionLikeDeclaration { - const identsToRenameMap = createMap(); // key is the symbol id + const identsToRenameMap = new Map(); // key is the symbol id const collidingSymbolMap = createMultiMap(); forEachChild(nodeToRename, function visit(node: Node) { if (!isIdentifier(node)) { diff --git a/src/services/codefixes/convertToEs6Module.ts b/src/services/codefixes/convertToEs6Module.ts index 883390e8a01..34522f127d2 100644 --- a/src/services/codefixes/convertToEs6Module.ts +++ b/src/services/codefixes/convertToEs6Module.ts @@ -63,7 +63,7 @@ namespace ts.codefix { type ExportRenames = ReadonlyESMap; function collectExportRenames(sourceFile: SourceFile, checker: TypeChecker, identifiers: Identifiers): ExportRenames { - const res = createMap(); + const res = new Map(); forEachExportReference(sourceFile, node => { const { text, originalKeywordKind } = node.name; if (!res.has(text) && (originalKeywordKind !== undefined && isNonContextualKeyword(originalKeywordKind) @@ -274,9 +274,9 @@ namespace ts.codefix { // `module.exports = require("x");` ==> `export * from "x"; export { default } from "x";` const moduleSpecifier = reExported.text; const moduleSymbol = checker.getSymbolAtLocation(reExported); - const exports = moduleSymbol ? moduleSymbol.exports! : emptyUnderscoreEscapedMap; - return exports.has("export=" as __String) ? [[reExportDefault(moduleSpecifier)], true] : - !exports.has("default" as __String) ? [[reExportStar(moduleSpecifier)], false] : + const exports = moduleSymbol ? moduleSymbol.exports! : emptyMap as ReadonlyCollection<__String>; + return exports.has(InternalSymbolName.ExportEquals) ? [[reExportDefault(moduleSpecifier)], true] : + !exports.has(InternalSymbolName.Default) ? [[reExportStar(moduleSpecifier)], false] : // If there's some non-default export, must include both `export *` and `export default`. exports.size > 1 ? [[reExportStar(moduleSpecifier), reExportDefault(moduleSpecifier)], true] : [[reExportDefault(moduleSpecifier)], true]; } @@ -388,7 +388,7 @@ namespace ts.codefix { function convertSingleIdentifierImport(file: SourceFile, name: Identifier, moduleSpecifier: StringLiteralLike, changes: textChanges.ChangeTracker, checker: TypeChecker, identifiers: Identifiers, quotePreference: QuotePreference): readonly Node[] { const nameSymbol = checker.getSymbolAtLocation(name); // Maps from module property name to name actually used. (The same if there isn't shadowing.) - const namedBindingsNames = createMap(); + const namedBindingsNames = new Map(); // True if there is some non-property use like `x()` or `f(x)`. let needDefaultImport = false; diff --git a/src/services/codefixes/convertToTypeOnlyExport.ts b/src/services/codefixes/convertToTypeOnlyExport.ts index 35510249927..cc36a7e7a86 100644 --- a/src/services/codefixes/convertToTypeOnlyExport.ts +++ b/src/services/codefixes/convertToTypeOnlyExport.ts @@ -12,7 +12,7 @@ namespace ts.codefix { }, fixIds: [fixId], getAllCodeActions: context => { - const fixedExportDeclarations = createMap(); + const fixedExportDeclarations = new Map(); return codeFixAll(context, errorCodes, (changes, diag) => { const exportSpecifier = getExportSpecifierForDiagnosticSpan(diag, context.sourceFile); if (exportSpecifier && !addToSeen(fixedExportDeclarations, getNodeId(exportSpecifier.parent.parent))) { diff --git a/src/services/codefixes/fixAddMissingMember.ts b/src/services/codefixes/fixAddMissingMember.ts index 9d48f054226..28bc1da2d6b 100644 --- a/src/services/codefixes/fixAddMissingMember.ts +++ b/src/services/codefixes/fixAddMissingMember.ts @@ -27,9 +27,9 @@ namespace ts.codefix { getAllCodeActions: context => { const { program } = context; const checker = program.getTypeChecker(); - const seen = createMap(); + const seen = new Map(); - const typeDeclToMembers = new NodeMap(); + const typeDeclToMembers = new Map(); return createCombinedCodeActions(textChanges.ChangeTracker.with(context, changes => { eachDiagnostic(context, errorCodes, diag => { @@ -44,7 +44,7 @@ namespace ts.codefix { } else { const { parentDeclaration, token } = info; - const infos = typeDeclToMembers.getOrUpdate(parentDeclaration, () => []); + const infos = getOrUpdate(typeDeclToMembers, parentDeclaration, () => []); if (!infos.some(i => i.token.text === token.text)) infos.push(info); } }); diff --git a/src/services/codefixes/fixAwaitInSyncFunction.ts b/src/services/codefixes/fixAwaitInSyncFunction.ts index f09b204de64..c47ff6e7165 100644 --- a/src/services/codefixes/fixAwaitInSyncFunction.ts +++ b/src/services/codefixes/fixAwaitInSyncFunction.ts @@ -16,7 +16,7 @@ namespace ts.codefix { }, fixIds: [fixId], getAllCodeActions: context => { - const seen = createMap(); + const seen = new Map(); return codeFixAll(context, errorCodes, (changes, diag) => { const nodes = getNodes(diag.file, diag.start); if (!nodes || !addToSeen(seen, getNodeId(nodes.insertBefore))) return; diff --git a/src/services/codefixes/fixClassDoesntImplementInheritedAbstractMember.ts b/src/services/codefixes/fixClassDoesntImplementInheritedAbstractMember.ts index 7fe14313945..ae1a2448560 100644 --- a/src/services/codefixes/fixClassDoesntImplementInheritedAbstractMember.ts +++ b/src/services/codefixes/fixClassDoesntImplementInheritedAbstractMember.ts @@ -15,7 +15,7 @@ namespace ts.codefix { }, fixIds: [fixId], getAllCodeActions: context => { - const seenClassDeclarations = createMap(); + const seenClassDeclarations = new Map(); return codeFixAll(context, errorCodes, (changes, diag) => { const classDeclaration = getClass(diag.file, diag.start); if (addToSeen(seenClassDeclarations, getNodeId(classDeclaration))) { diff --git a/src/services/codefixes/fixClassIncorrectlyImplementsInterface.ts b/src/services/codefixes/fixClassIncorrectlyImplementsInterface.ts index fb00d2477dc..2ae9f1b94a9 100644 --- a/src/services/codefixes/fixClassIncorrectlyImplementsInterface.ts +++ b/src/services/codefixes/fixClassIncorrectlyImplementsInterface.ts @@ -17,7 +17,7 @@ namespace ts.codefix { }, fixIds: [fixId], getAllCodeActions(context) { - const seenClassDeclarations = createMap(); + const seenClassDeclarations = new Map(); return codeFixAll(context, errorCodes, (changes, diag) => { const classDeclaration = getClass(diag.file, diag.start); if (addToSeen(seenClassDeclarations, getNodeId(classDeclaration))) { diff --git a/src/services/codefixes/fixClassSuperMustPrecedeThisAccess.ts b/src/services/codefixes/fixClassSuperMustPrecedeThisAccess.ts index 1c26c39b10c..dc8f261cc26 100644 --- a/src/services/codefixes/fixClassSuperMustPrecedeThisAccess.ts +++ b/src/services/codefixes/fixClassSuperMustPrecedeThisAccess.ts @@ -15,7 +15,7 @@ namespace ts.codefix { fixIds: [fixId], getAllCodeActions(context) { const { sourceFile } = context; - const seenClasses = createMap(); // Ensure we only do this once per class. + const seenClasses = new Map(); // Ensure we only do this once per class. return codeFixAll(context, errorCodes, (changes, diag) => { const nodes = getNodes(diag.file, diag.start); if (!nodes) return; diff --git a/src/services/codefixes/fixImplicitThis.ts b/src/services/codefixes/fixImplicitThis.ts index bfff6fe21f1..91758428c8b 100644 --- a/src/services/codefixes/fixImplicitThis.ts +++ b/src/services/codefixes/fixImplicitThis.ts @@ -52,10 +52,5 @@ namespace ts.codefix { return [Diagnostics.Convert_function_declaration_0_to_arrow_function, name!.text]; } } - // No outer 'this', add a @class tag if in a JS constructor function - else if (isSourceFileJS(sourceFile) && isPropertyAccessExpression(token.parent) && isAssignmentExpression(token.parent.parent)) { - addJSDocTags(changes, sourceFile, fn, [factory.createJSDocClassTag(/*tagName*/ undefined)]); - return Diagnostics.Add_class_tag; - } } } diff --git a/src/services/codefixes/helpers.ts b/src/services/codefixes/helpers.ts index 12e8bb18645..3c5669cb20c 100644 --- a/src/services/codefixes/helpers.ts +++ b/src/services/codefixes/helpers.ts @@ -164,7 +164,7 @@ namespace ts.codefix { const program = context.program; const checker = program.getTypeChecker(); const scriptTarget = getEmitScriptTarget(program.getCompilerOptions()); - const flags = NodeBuilderFlags.NoTruncation | NodeBuilderFlags.SuppressAnyReturnType | (quotePreference === QuotePreference.Single ? NodeBuilderFlags.UseSingleQuotesForStringLiteralType : 0); + const flags = NodeBuilderFlags.NoTruncation | NodeBuilderFlags.NoUndefinedOptionalParameterType | NodeBuilderFlags.SuppressAnyReturnType | (quotePreference === QuotePreference.Single ? NodeBuilderFlags.UseSingleQuotesForStringLiteralType : 0); const signatureDeclaration = checker.signatureToSignatureDeclaration(signature, SyntaxKind.MethodDeclaration, enclosingDeclaration, flags, getNoopSymbolTrackerWithResolver(context)); if (!signatureDeclaration) { return undefined; diff --git a/src/services/codefixes/importFixes.ts b/src/services/codefixes/importFixes.ts index 5825eb4456c..6d94711b43b 100644 --- a/src/services/codefixes/importFixes.ts +++ b/src/services/codefixes/importFixes.ts @@ -47,8 +47,8 @@ namespace ts.codefix { const addToNamespace: FixUseNamespaceImport[] = []; const importType: FixUseImportType[] = []; // Keys are import clause node IDs. - const addToExisting = createMap<{ readonly importClauseOrBindingPattern: ImportClause | ObjectBindingPattern, defaultImport: string | undefined; readonly namedImports: string[], canUseTypeOnlyImport: boolean }>(); - const newImports = createMap>(); + const addToExisting = new Map(); + const newImports = new Map>(); return { addImportFromDiagnostic, addImportFromExportedSymbol, writeFixes }; function addImportFromDiagnostic(diagnostic: DiagnosticWithLocation, context: CodeFixContextBase) { @@ -138,7 +138,7 @@ namespace ts.codefix { doAddExistingFix(changeTracker, sourceFile, importClauseOrBindingPattern, defaultImport, namedImports, canUseTypeOnlyImport); }); - let newDeclarations: Statement | readonly Statement[] | undefined; + let newDeclarations: AnyImportOrRequireStatement | readonly AnyImportOrRequireStatement[] | undefined; newImports.forEach(({ useRequire, ...imports }, moduleSpecifier) => { const getDeclarations = useRequire ? getNewRequires : getNewImports; newDeclarations = combine(newDeclarations, getDeclarations(moduleSpecifier, quotePreference, imports)); @@ -671,15 +671,35 @@ namespace ts.codefix { } if (namedImports.length) { - const specifiers = namedImports.map(name => factory.createImportSpecifier(/*propertyName*/ undefined, factory.createIdentifier(name))); - if (clause.namedBindings && cast(clause.namedBindings, isNamedImports).elements.length) { - for (const spec of specifiers) { - changes.insertNodeInListAfter(sourceFile, last(cast(clause.namedBindings, isNamedImports).elements), spec); + const existingSpecifiers = clause.namedBindings && cast(clause.namedBindings, isNamedImports).elements; + const newSpecifiers = stableSort( + namedImports.map(name => factory.createImportSpecifier(/*propertyName*/ undefined, factory.createIdentifier(name))), + OrganizeImports.compareImportOrExportSpecifiers); + + if (existingSpecifiers?.length && OrganizeImports.importSpecifiersAreSorted(existingSpecifiers)) { + for (const spec of newSpecifiers) { + const insertionIndex = OrganizeImports.getImportSpecifierInsertionIndex(existingSpecifiers, spec); + const prevSpecifier = (clause.namedBindings as NamedImports).elements[insertionIndex - 1]; + if (prevSpecifier) { + changes.insertNodeInListAfter(sourceFile, prevSpecifier, spec); + } + else { + changes.insertNodeBefore( + sourceFile, + existingSpecifiers[0], + spec, + !positionsAreOnSameLine(existingSpecifiers[0].getStart(), clause.parent.getStart(), sourceFile)); + } + } + } + else if (existingSpecifiers?.length) { + for (const spec of newSpecifiers) { + changes.insertNodeAtEndOfList(sourceFile, existingSpecifiers, spec); } } else { - if (specifiers.length) { - const namedImports = factory.createNamedImports(specifiers); + if (newSpecifiers.length) { + const namedImports = factory.createNamedImports(newSpecifiers); if (clause.namedBindings) { changes.replaceNode(sourceFile, clause.namedBindings, namedImports); } @@ -727,9 +747,9 @@ namespace ts.codefix { readonly name: string; }; } - function getNewImports(moduleSpecifier: string, quotePreference: QuotePreference, imports: ImportsCollection): Statement | readonly Statement[] { + function getNewImports(moduleSpecifier: string, quotePreference: QuotePreference, imports: ImportsCollection): AnyImportSyntax | readonly AnyImportSyntax[] { const quotedModuleSpecifier = makeStringLiteral(moduleSpecifier, quotePreference); - let statements: Statement | readonly Statement[] | undefined; + let statements: AnyImportSyntax | readonly AnyImportSyntax[] | undefined; if (imports.defaultImport !== undefined || imports.namedImports?.length) { statements = combine(statements, makeImport( imports.defaultImport === undefined ? undefined : factory.createIdentifier(imports.defaultImport), @@ -756,9 +776,9 @@ namespace ts.codefix { return Debug.checkDefined(statements); } - function getNewRequires(moduleSpecifier: string, quotePreference: QuotePreference, imports: ImportsCollection): Statement | readonly Statement[] { + function getNewRequires(moduleSpecifier: string, quotePreference: QuotePreference, imports: ImportsCollection): RequireVariableStatement | readonly RequireVariableStatement[] { const quotedModuleSpecifier = makeStringLiteral(moduleSpecifier, quotePreference); - let statements: Statement | readonly Statement[] | undefined; + let statements: RequireVariableStatement | readonly RequireVariableStatement[] | undefined; // const { default: foo, bar, etc } = require('./mod'); if (imports.defaultImport || imports.namedImports?.length) { const bindingElements = imports.namedImports?.map(name => factory.createBindingElement(/*dotDotDotToken*/ undefined, /*propertyName*/ undefined, name)) || []; @@ -776,7 +796,7 @@ namespace ts.codefix { return Debug.checkDefined(statements); } - function createConstEqualsRequireDeclaration(name: string | ObjectBindingPattern, quotedModuleSpecifier: StringLiteral): VariableStatement { + function createConstEqualsRequireDeclaration(name: string | ObjectBindingPattern, quotedModuleSpecifier: StringLiteral): RequireVariableStatement { return factory.createVariableStatement( /*modifiers*/ undefined, factory.createVariableDeclarationList([ @@ -785,7 +805,7 @@ namespace ts.codefix { /*exclamationToken*/ undefined, /*type*/ undefined, factory.createCallExpression(factory.createIdentifier("require"), /*typeArguments*/ undefined, [quotedModuleSpecifier]))], - NodeFlags.Const)); + NodeFlags.Const)) as RequireVariableStatement; } function symbolHasMeaning({ declarations }: Symbol, meaning: SemanticMeaning): boolean { diff --git a/src/services/codefixes/inferFromUsage.ts b/src/services/codefixes/inferFromUsage.ts index 220a4268802..a07153378f5 100644 --- a/src/services/codefixes/inferFromUsage.ts +++ b/src/services/codefixes/inferFromUsage.ts @@ -500,7 +500,7 @@ namespace ts.codefix { } function combineUsages(usages: Usage[]): Usage { - const combinedProperties = createUnderscoreEscapedMap(); + const combinedProperties = new Map<__String, Usage[]>(); for (const u of usages) { if (u.properties) { u.properties.forEach((p, name) => { @@ -511,7 +511,7 @@ namespace ts.codefix { }); } } - const properties = createUnderscoreEscapedMap(); + const properties = new Map<__String, Usage>(); combinedProperties.forEach((ps, name) => { properties.set(name, combineUsages(ps)); }); @@ -820,7 +820,7 @@ namespace ts.codefix { function inferTypeFromPropertyAccessExpression(parent: PropertyAccessExpression, usage: Usage): void { const name = escapeLeadingUnderscores(parent.name.text); if (!usage.properties) { - usage.properties = createUnderscoreEscapedMap(); + usage.properties = new Map(); } const propertyUsage = usage.properties.get(name) || createEmptyUsage(); calculateUsageOfNode(parent, propertyUsage); @@ -974,7 +974,7 @@ namespace ts.codefix { } function inferStructuralType(usage: Usage) { - const members = createUnderscoreEscapedMap(); + const members = new Map<__String, Symbol>(); if (usage.properties) { usage.properties.forEach((u, name) => { const symbol = checker.createSymbol(SymbolFlags.Property, name); diff --git a/src/services/completions.ts b/src/services/completions.ts index 8708fc26fa2..c7310e0c8b3 100644 --- a/src/services/completions.ts +++ b/src/services/completions.ts @@ -293,7 +293,7 @@ namespace ts.Completions { } if (keywordFilters !== KeywordCompletionFilters.None) { - const entryNames = arrayToSet(entries, e => e.name); + const entryNames = new Set(entries.map(e => e.name)); for (const keywordEntry of getKeywordCompletions(keywordFilters, !insideJsDocTagTypeExpression && isSourceFileJS(sourceFile))) { if (!entryNames.has(keywordEntry.name)) { entries.push(keywordEntry); @@ -491,7 +491,7 @@ namespace ts.Completions { // Value is set to false for global variables or completions from external module exports, because we can have multiple of those; // true otherwise. Based on the order we add things we will always see locals first, then globals, then module exports. // So adding a completion for a local will prevent us from adding completions for external module exports sharing the same name. - const uniques = createMap(); + const uniques = new Map(); for (const symbol of symbols) { const origin = symbolToOriginInfoMap ? symbolToOriginInfoMap[getSymbolId(symbol)] : undefined; const info = getCompletionEntryDisplayNameForSymbol(symbol, target, origin, kind, !!jsxIdentifierExpected); @@ -549,7 +549,7 @@ namespace ts.Completions { function getLabelStatementCompletions(node: Node): CompletionEntry[] { const entries: CompletionEntry[] = []; - const uniques = createMap(); + const uniques = new Map(); let current = node; while (current) { @@ -1537,7 +1537,7 @@ namespace ts.Completions { } /** True if symbol is a type or a module containing at least one type. */ - function symbolCanBeReferencedAtTypeLocation(symbol: Symbol, seenModules = createMap()): boolean { + function symbolCanBeReferencedAtTypeLocation(symbol: Symbol, seenModules = new Map()): boolean { const sym = skipAlias(symbol.exportSymbol || symbol, typeChecker); return !!(sym.flags & SymbolFlags.Type) || !!(sym.flags & SymbolFlags.Module) && @@ -1605,16 +1605,16 @@ namespace ts.Completions { const startTime = timestamp(); log(`getSymbolsFromOtherSourceFileExports: Recomputing list${detailsEntryId ? " for details entry" : ""}`); - const seenResolvedModules = createMap(); - const seenExports = createMap(); + const seenResolvedModules = new Map(); + const seenExports = new Map(); /** Bucket B */ - const aliasesToAlreadyIncludedSymbols = createMap(); + const aliasesToAlreadyIncludedSymbols = new Map(); /** Bucket C */ - const aliasesToReturnIfOriginalsAreMissing = createMap<{ alias: Symbol, moduleSymbol: Symbol, isFromPackageJson: boolean }>(); + const aliasesToReturnIfOriginalsAreMissing = new Map(); /** Bucket A */ const results: AutoImportSuggestion[] = []; /** Ids present in `results` for faster lookup */ - const resultSymbolIds = createMap(); + const resultSymbolIds = new Map(); codefix.forEachExternalModuleToImportFrom(program, host, sourceFile, !detailsEntryId, /*useAutoImportProvider*/ true, (moduleSymbol, _, program, isFromPackageJson) => { // Perf -- ignore other modules if this is a request for details @@ -1940,8 +1940,8 @@ namespace ts.Completions { completionKind = CompletionKind.MemberLike; isNewIdentifierLocation = false; const exports = typeChecker.getExportsAndPropertiesOfModule(moduleSpecifierSymbol); - const existing = arrayToSet(namedImportsOrExports.elements, n => isCurrentlyEditingNode(n) ? undefined : (n.propertyName || n.name).escapedText); - symbols = exports.filter(e => e.escapedName !== InternalSymbolName.Default && !existing.get(e.escapedName)); + const existing = new Set((namedImportsOrExports.elements as NodeArray).filter(n => !isCurrentlyEditingNode(n)).map(n => (n.propertyName || n.name).escapedText)); + symbols = exports.filter(e => e.escapedName !== InternalSymbolName.Default && !existing.has(e.escapedName)); return GlobalsSearch.Success; } @@ -2312,7 +2312,7 @@ namespace ts.Completions { } const membersDeclaredBySpreadAssignment = new Set(); - const existingMemberNames = createUnderscoreEscapedMap(); + const existingMemberNames = new Set<__String>(); for (const m of existingMembers) { // Ignore omitted expressions for missing members if (m.kind !== SyntaxKind.PropertyAssignment && @@ -2349,10 +2349,12 @@ namespace ts.Completions { existingName = name && isPropertyNameLiteral(name) ? getEscapedTextOfIdentifierOrLiteral(name) : undefined; } - existingMemberNames.set(existingName!, true); // TODO: GH#18217 + if (existingName !== undefined) { + existingMemberNames.add(existingName); + } } - const filteredSymbols = contextualMemberSymbols.filter(m => !existingMemberNames.get(m.escapedName)); + const filteredSymbols = contextualMemberSymbols.filter(m => !existingMemberNames.has(m.escapedName)); setSortTextToMemberDeclaredBySpreadAssignment(membersDeclaredBySpreadAssignment, filteredSymbols); return filteredSymbols; @@ -2397,7 +2399,7 @@ namespace ts.Completions { * @returns Symbols to be suggested in an class element depending on existing memebers and symbol flags */ function filterClassMembersList(baseSymbols: readonly Symbol[], existingMembers: readonly ClassElement[], currentClassElementModifierFlags: ModifierFlags): Symbol[] { - const existingMemberNames = createUnderscoreEscapedMap(); + const existingMemberNames = new Set<__String>(); for (const m of existingMembers) { // Ignore omitted expressions for missing members if (m.kind !== SyntaxKind.PropertyDeclaration && @@ -2424,7 +2426,7 @@ namespace ts.Completions { const existingName = getPropertyNameForPropertyNameNode(m.name!); if (existingName) { - existingMemberNames.set(existingName, true); + existingMemberNames.add(existingName); } } @@ -2442,7 +2444,7 @@ namespace ts.Completions { * do not occur at the current position and have not otherwise been typed. */ function filterJsxAttributes(symbols: Symbol[], attributes: NodeArray): Symbol[] { - const seenNames = createUnderscoreEscapedMap(); + const seenNames = new Set<__String>(); const membersDeclaredBySpreadAssignment = new Set(); for (const attr of attributes) { // If this is the current item we are editing right now, do not filter it out @@ -2451,13 +2453,13 @@ namespace ts.Completions { } if (attr.kind === SyntaxKind.JsxAttribute) { - seenNames.set(attr.name.escapedText, true); + seenNames.add(attr.name.escapedText); } else if (isJsxSpreadAttribute(attr)) { setMembersDeclaredBySpreadAssignment(attr, membersDeclaredBySpreadAssignment); } } - const filteredSymbols = symbols.filter(a => !seenNames.get(a.escapedName)); + const filteredSymbols = symbols.filter(a => !seenNames.has(a.escapedName)); setSortTextToMemberDeclaredBySpreadAssignment(membersDeclaredBySpreadAssignment, filteredSymbols); diff --git a/src/services/documentRegistry.ts b/src/services/documentRegistry.ts index b4777c83e63..19fd476d87d 100644 --- a/src/services/documentRegistry.ts +++ b/src/services/documentRegistry.ts @@ -170,7 +170,7 @@ namespace ts { acquiring: boolean, scriptKind?: ScriptKind): SourceFile { - const bucket = getOrUpdate>(buckets, key, createMap); + const bucket = getOrUpdate(buckets, key, () => new Map()); let entry = bucket.get(path); const scriptTarget = scriptKind === ScriptKind.JSON ? ScriptTarget.JSON : compilationSettings.target || ScriptTarget.ES5; if (!entry && externalCache) { diff --git a/src/services/findAllReferences.ts b/src/services/findAllReferences.ts index 820af277b7d..1d7dbb8d669 100644 --- a/src/services/findAllReferences.ts +++ b/src/services/findAllReferences.ts @@ -132,6 +132,7 @@ namespace ts.FindAllReferences { return node.parent.parent; case SyntaxKind.ImportClause: + case SyntaxKind.NamespaceExport: return node.parent; case SyntaxKind.BinaryExpression: @@ -229,7 +230,7 @@ namespace ts.FindAllReferences { } else { const queue = entries && [...entries]; - const seenNodes = createMap(); + const seenNodes = new Map(); while (queue && queue.length) { const entry = queue.shift() as NodeEntry; if (!addToSeen(seenNodes, getNodeId(entry.node))) { @@ -402,7 +403,7 @@ namespace ts.FindAllReferences { const parent = node.parent; const name = originalNode.text; const isShorthandAssignment = isShorthandPropertyAssignment(parent); - if (isShorthandAssignment || isObjectBindingElementWithoutPropertyName(parent) && parent.name === node) { + if (isShorthandAssignment || (isObjectBindingElementWithoutPropertyName(parent) && parent.name === node && parent.dotDotDotToken === undefined)) { const prefixColon: PrefixAndSuffix = { prefixText: name + ": " }; const suffixColon: PrefixAndSuffix = { suffixText: ": " + name }; if (kind === EntryKind.SearchedLocalFoundProperty) { @@ -946,7 +947,7 @@ namespace ts.FindAllReferences { */ class State { /** Cache for `explicitlyinheritsFrom`. */ - readonly inheritsFromCache = createMap(); + readonly inheritsFromCache = new Map(); /** * Type nodes can contain multiple references to the same type. For example: @@ -1906,13 +1907,28 @@ namespace ts.FindAllReferences { function populateSearchSymbolSet(symbol: Symbol, location: Node, checker: TypeChecker, isForRename: boolean, providePrefixAndSuffixText: boolean, implementations: boolean): Symbol[] { const result: Symbol[] = []; forEachRelatedSymbol(symbol, location, checker, isForRename, !(isForRename && providePrefixAndSuffixText), - (sym, root, base) => { result.push(base || root || sym); }, - /*allowBaseTypes*/ () => !implementations); + (sym, root, base) => { + // static method/property and instance method/property might have the same name. Only include static or only include instance. + if (base) { + if (isStatic(symbol) !== isStatic(base)) { + base = undefined; + } + } + result.push(base || root || sym); + }, + // when try to find implementation, implementations is true, and not allowed to find base class + /*allowBaseTypes*/() => !implementations); return result; } + /** + * @param allowBaseTypes return true means it would try to find in base class or interface. + */ function forEachRelatedSymbol( symbol: Symbol, location: Node, checker: TypeChecker, isForRenamePopulateSearchSymbolSet: boolean, onlyIncludeBindingElementAtReferenceLocation: boolean, + /** + * @param baseSymbol This symbol means one property/mehtod from base class or interface when it is not null or undefined, + */ cbSymbol: (symbol: Symbol, rootSymbol?: Symbol, baseSymbol?: Symbol, kind?: NodeEntryKind) => T | undefined, allowBaseTypes: (rootSymbol: Symbol) => boolean, ): T | undefined { @@ -2031,16 +2047,33 @@ namespace ts.FindAllReferences { readonly symbol: Symbol; readonly kind: NodeEntryKind | undefined; } + + function isStatic(symbol: Symbol): boolean { + if (!symbol.valueDeclaration) { return false; } + const modifierFlags = getEffectiveModifierFlags(symbol.valueDeclaration); + return !!(modifierFlags & ModifierFlags.Static); + } + function getRelatedSymbol(search: Search, referenceSymbol: Symbol, referenceLocation: Node, state: State): RelatedSymbol | undefined { const { checker } = state; return forEachRelatedSymbol(referenceSymbol, referenceLocation, checker, /*isForRenamePopulateSearchSymbolSet*/ false, /*onlyIncludeBindingElementAtReferenceLocation*/ state.options.use !== FindReferencesUse.Rename || !!state.options.providePrefixAndSuffixTextForRename, - (sym, rootSymbol, baseSymbol, kind): RelatedSymbol | undefined => search.includes(baseSymbol || rootSymbol || sym) - // For a base type, use the symbol for the derived type. For a synthetic (e.g. union) property, use the union symbol. - ? { symbol: rootSymbol && !(getCheckFlags(sym) & CheckFlags.Synthetic) ? rootSymbol : sym, kind } - : undefined, + (sym, rootSymbol, baseSymbol, kind): RelatedSymbol | undefined => { + // check whether the symbol used to search itself is just the searched one. + if (baseSymbol) { + // static method/property and instance method/property might have the same name. Only check static or only check instance. + if (isStatic(referenceSymbol) !== isStatic(baseSymbol)) { + baseSymbol = undefined; + } + } + return search.includes(baseSymbol || rootSymbol || sym) + // For a base type, use the symbol for the derived type. For a synthetic (e.g. union) property, use the union symbol. + ? { symbol: rootSymbol && !(getCheckFlags(sym) & CheckFlags.Synthetic) ? rootSymbol : sym, kind } + : undefined; + }, /*allowBaseTypes*/ rootSymbol => - !(search.parents && !search.parents.some(parent => explicitlyInheritsFrom(rootSymbol.parent!, parent, state.inheritsFromCache, checker)))); + !(search.parents && !search.parents.some(parent => explicitlyInheritsFrom(rootSymbol.parent!, parent, state.inheritsFromCache, checker))) + ); } /** diff --git a/src/services/formatting/rules.ts b/src/services/formatting/rules.ts index f623da53992..fd2251b8353 100644 --- a/src/services/formatting/rules.ts +++ b/src/services/formatting/rules.ts @@ -52,7 +52,7 @@ namespace ts.formatting { rule("NotSpaceBeforeColon", anyToken, SyntaxKind.ColonToken, [isNonJsxSameLineTokenContext, isNotBinaryOpContext, isNotTypeAnnotationContext], RuleAction.DeleteSpace), rule("SpaceAfterColon", SyntaxKind.ColonToken, anyToken, [isNonJsxSameLineTokenContext, isNotBinaryOpContext], RuleAction.InsertSpace), - rule("NoSpaceBeforeQuestionMark", anyToken, SyntaxKind.QuestionToken, [isNonJsxSameLineTokenContext, isNotBinaryOpContext], RuleAction.DeleteSpace), + rule("NoSpaceBeforeQuestionMark", anyToken, SyntaxKind.QuestionToken, [isNonJsxSameLineTokenContext, isNotBinaryOpContext, isNotTypeAnnotationContext], RuleAction.DeleteSpace), // insert space after '?' only when it is used in conditional operator rule("SpaceAfterQuestionMarkInConditionalOperator", SyntaxKind.QuestionToken, anyToken, [isNonJsxSameLineTokenContext, isConditionalOperatorContext], RuleAction.InsertSpace), @@ -315,8 +315,9 @@ namespace ts.formatting { rule("SpaceAfterTypeAssertion", SyntaxKind.GreaterThanToken, anyToken, [isOptionEnabled("insertSpaceAfterTypeAssertion"), isNonJsxSameLineTokenContext, isTypeAssertionContext], RuleAction.InsertSpace), rule("NoSpaceAfterTypeAssertion", SyntaxKind.GreaterThanToken, anyToken, [isOptionDisabledOrUndefined("insertSpaceAfterTypeAssertion"), isNonJsxSameLineTokenContext, isTypeAssertionContext], RuleAction.DeleteSpace), - rule("SpaceBeforeTypeAnnotation", anyToken, SyntaxKind.ColonToken, [isOptionEnabled("insertSpaceBeforeTypeAnnotation"), isNonJsxSameLineTokenContext, isTypeAnnotationContext], RuleAction.InsertSpace), - rule("NoSpaceBeforeTypeAnnotation", anyToken, SyntaxKind.ColonToken, [isOptionDisabledOrUndefined("insertSpaceBeforeTypeAnnotation"), isNonJsxSameLineTokenContext, isTypeAnnotationContext], RuleAction.DeleteSpace), + rule("SpaceBeforeTypeAnnotation", anyToken, [SyntaxKind.QuestionToken, SyntaxKind.ColonToken], [isOptionEnabled("insertSpaceBeforeTypeAnnotation"), isNonJsxSameLineTokenContext, isTypeAnnotationContext], RuleAction.InsertSpace), + rule("NoSpaceBeforeTypeAnnotation", anyToken, [SyntaxKind.QuestionToken, SyntaxKind.ColonToken], [isOptionDisabledOrUndefined("insertSpaceBeforeTypeAnnotation"), isNonJsxSameLineTokenContext, isTypeAnnotationContext], RuleAction.DeleteSpace), + rule("NoOptionalSemicolon", SyntaxKind.SemicolonToken, anyTokenIncludingEOF, [optionEquals("semicolons", SemicolonPreference.Remove), isSemicolonDeletionContext], RuleAction.DeleteToken), rule("OptionalSemicolon", anyToken, anyTokenIncludingEOF, [optionEquals("semicolons", SemicolonPreference.Insert), isSemicolonInsertionContext], RuleAction.InsertTrailingSemicolon), ]; diff --git a/src/services/importTracker.ts b/src/services/importTracker.ts index 5396459584d..59c7e8c2745 100644 --- a/src/services/importTracker.ts +++ b/src/services/importTracker.ts @@ -122,6 +122,10 @@ namespace ts.FindAllReferences { // This is `export * from "foo"`, so imports of this module may import the export too. handleDirectImports(getContainingModuleSymbol(direct, checker)); } + else if (direct.exportClause.kind === SyntaxKind.NamespaceExport) { + // `export * as foo from "foo"` add to indirect uses + addIndirectUsers(getSourceFileLikeForImportDeclaration(direct)); + } else { // This is `export { foo } from "foo"` and creates an alias symbol, so recursive search will get handle re-exports. directImports.push(direct); @@ -369,7 +373,7 @@ namespace ts.FindAllReferences { /** Returns a map from a module symbol Id to all import statements that directly reference the module. */ function getDirectImportsMap(sourceFiles: readonly SourceFile[], checker: TypeChecker, cancellationToken: CancellationToken | undefined): ESMap { - const map = createMap(); + const map = new Map(); for (const sourceFile of sourceFiles) { if (cancellationToken) cancellationToken.throwIfCancellationRequested(); @@ -477,6 +481,9 @@ namespace ts.FindAllReferences { return exportInfo(symbol, getExportKindForDeclaration(exportNode)); } } + else if (isNamespaceExport(parent)) { + return exportInfo(symbol, ExportKind.Named); + } // If we are in `export = a;` or `export default a;`, `parent` is the export assignment. else if (isExportAssignment(parent)) { return getExportAssignmentExport(parent); diff --git a/src/services/navigationBar.ts b/src/services/navigationBar.ts index d843c4474cf..4f757be676c 100644 --- a/src/services/navigationBar.ts +++ b/src/services/navigationBar.ts @@ -128,7 +128,7 @@ namespace ts.NavigationBar { function addTrackedEs5Class(name: string) { if (!trackedEs5Classes) { - trackedEs5Classes = createMap(); + trackedEs5Classes = new Map(); } trackedEs5Classes.set(name, true); } @@ -443,7 +443,7 @@ namespace ts.NavigationBar { /** Merge declarations of the same kind. */ function mergeChildren(children: NavigationBarNode[], node: NavigationBarNode): void { - const nameToItems = createMap(); + const nameToItems = new Map(); filterMutate(children, (child, index) => { const declName = child.name || getNameOfDeclaration(child.node); const name = declName && nodeText(declName); diff --git a/src/services/organizeImports.ts b/src/services/organizeImports.ts index 566b0ebdd7b..46eda4b00a9 100644 --- a/src/services/organizeImports.ts +++ b/src/services/organizeImports.ts @@ -17,7 +17,9 @@ namespace ts.OrganizeImports { const changeTracker = textChanges.ChangeTracker.fromContext({ host, formatContext, preferences }); - const coalesceAndOrganizeImports = (importGroup: readonly ImportDeclaration[]) => coalesceImports(removeUnusedImports(importGroup, sourceFile, program)); + const coalesceAndOrganizeImports = (importGroup: readonly ImportDeclaration[]) => stableSort( + coalesceImports(removeUnusedImports(importGroup, sourceFile, program)), + (s1, s2) => compareImportsOrRequireStatements(s1, s2)); // All of the old ImportDeclarations in the file, in syntactic order. const topLevelImportDecls = sourceFile.statements.filter(isImportDeclaration); @@ -55,7 +57,7 @@ namespace ts.OrganizeImports { suppressLeadingTrivia(oldImportDecls[0]); const oldImportGroups = group(oldImportDecls, importDecl => getExternalModuleName(importDecl.moduleSpecifier!)!); - const sortedImportGroups = stableSort(oldImportGroups, (group1, group2) => compareModuleSpecifiers(group1[0].moduleSpecifier!, group2[0].moduleSpecifier!)); + const sortedImportGroups = stableSort(oldImportGroups, (group1, group2) => compareModuleSpecifiers(group1[0].moduleSpecifier, group2[0].moduleSpecifier)); const newImportDecls = flatMap(sortedImportGroups, importGroup => getExternalModuleName(importGroup[0].moduleSpecifier!) ? coalesce(importGroup) @@ -395,15 +397,18 @@ namespace ts.OrganizeImports { } function sortSpecifiers(specifiers: readonly T[]) { - return stableSort(specifiers, (s1, s2) => - compareIdentifiers(s1.propertyName || s1.name, s2.propertyName || s2.name) || - compareIdentifiers(s1.name, s2.name)); + return stableSort(specifiers, compareImportOrExportSpecifiers); + } + + export function compareImportOrExportSpecifiers(s1: T, s2: T) { + return compareIdentifiers(s1.propertyName || s1.name, s2.propertyName || s2.name) + || compareIdentifiers(s1.name, s2.name); } /* internal */ // Exported for testing - export function compareModuleSpecifiers(m1: Expression, m2: Expression) { - const name1 = getExternalModuleName(m1); - const name2 = getExternalModuleName(m2); + export function compareModuleSpecifiers(m1: Expression | undefined, m2: Expression | undefined) { + const name1 = m1 === undefined ? undefined : getExternalModuleName(m1); + const name2 = m2 === undefined ? undefined : getExternalModuleName(m2); return compareBooleans(name1 === undefined, name2 === undefined) || compareBooleans(isExternalModuleNameRelative(name1!), isExternalModuleNameRelative(name2!)) || compareStringsCaseInsensitive(name1!, name2!); @@ -412,4 +417,63 @@ namespace ts.OrganizeImports { function compareIdentifiers(s1: Identifier, s2: Identifier) { return compareStringsCaseInsensitive(s1.text, s2.text); } + + function getModuleSpecifierExpression(declaration: AnyImportOrRequireStatement): Expression | undefined { + switch (declaration.kind) { + case SyntaxKind.ImportEqualsDeclaration: + return tryCast(declaration.moduleReference, isExternalModuleReference)?.expression; + case SyntaxKind.ImportDeclaration: + return declaration.moduleSpecifier; + case SyntaxKind.VariableStatement: + return declaration.declarationList.declarations[0].initializer.arguments[0]; + } + } + + export function importsAreSorted(imports: readonly AnyImportOrRequireStatement[]): imports is SortedReadonlyArray { + return arrayIsSorted(imports, compareImportsOrRequireStatements); + } + + export function importSpecifiersAreSorted(imports: readonly ImportSpecifier[]): imports is SortedReadonlyArray { + return arrayIsSorted(imports, compareImportOrExportSpecifiers); + } + + export function getImportDeclarationInsertionIndex(sortedImports: SortedReadonlyArray, newImport: AnyImportOrRequireStatement) { + const index = binarySearch(sortedImports, newImport, identity, compareImportsOrRequireStatements); + return index < 0 ? ~index : index; + } + + export function getImportSpecifierInsertionIndex(sortedImports: SortedReadonlyArray, newImport: ImportSpecifier) { + const index = binarySearch(sortedImports, newImport, identity, compareImportOrExportSpecifiers); + return index < 0 ? ~index : index; + } + + export function compareImportsOrRequireStatements(s1: AnyImportOrRequireStatement, s2: AnyImportOrRequireStatement) { + return compareModuleSpecifiers(getModuleSpecifierExpression(s1), getModuleSpecifierExpression(s2)) || compareImportKind(s1, s2); + } + + function compareImportKind(s1: AnyImportOrRequireStatement, s2: AnyImportOrRequireStatement) { + return compareValues(getImportKindOrder(s1), getImportKindOrder(s2)); + } + + // 1. Side-effect imports + // 2. Type-only imports + // 3. Namespace imports + // 4. Default imports + // 5. Named imports + // 6. ImportEqualsDeclarations + // 7. Require variable statements + function getImportKindOrder(s1: AnyImportOrRequireStatement) { + switch (s1.kind) { + case SyntaxKind.ImportDeclaration: + if (!s1.importClause) return 0; + if (s1.importClause.isTypeOnly) return 1; + if (s1.importClause.namedBindings?.kind === SyntaxKind.NamespaceImport) return 2; + if (s1.importClause.name) return 3; + return 4; + case SyntaxKind.ImportEqualsDeclaration: + return 5; + case SyntaxKind.VariableStatement: + return 6; + } + } } diff --git a/src/services/patternMatcher.ts b/src/services/patternMatcher.ts index 7c53e09232d..b0071f71240 100644 --- a/src/services/patternMatcher.ts +++ b/src/services/patternMatcher.ts @@ -102,7 +102,7 @@ namespace ts { // we see the name of a module that is used everywhere, or the name of an overload). As // such, we cache the information we compute about the candidate for the life of this // pattern matcher so we don't have to compute it multiple times. - const stringToWordSpans = createMap(); + const stringToWordSpans = new Map(); const dotSeparatedSegments = pattern.trim().split(".").map(p => createSegment(p.trim())); // A segment is considered invalid if we couldn't find any words in it. diff --git a/src/services/refactorProvider.ts b/src/services/refactorProvider.ts index b71e806d18e..42bda231be6 100644 --- a/src/services/refactorProvider.ts +++ b/src/services/refactorProvider.ts @@ -2,7 +2,7 @@ namespace ts.refactor { // A map with the refactor code as key, the refactor itself as value // e.g. nonSuggestableRefactors[refactorCode] -> the refactor you want - const refactors: ESMap = createMap(); + const refactors = new Map(); /** @param name An unique code associated with each refactor. Does not have to be human-readable. */ export function registerRefactor(name: string, refactor: Refactor) { diff --git a/src/services/refactors/convertImport.ts b/src/services/refactors/convertImport.ts index 5ab2b316d5c..1ad43126d5d 100644 --- a/src/services/refactors/convertImport.ts +++ b/src/services/refactors/convertImport.ts @@ -74,7 +74,7 @@ namespace ts.refactor { let usedAsNamespaceOrDefault = false; const nodesToReplace: PropertyAccessExpression[] = []; - const conflictingNames = createMap(); + const conflictingNames = new Map(); FindAllReferences.Core.eachSymbolReferenceInFile(toConvert.name, checker, sourceFile, id => { if (!isPropertyAccessExpression(id.parent)) { @@ -92,7 +92,7 @@ namespace ts.refactor { }); // We may need to change `mod.x` to `_x` to avoid a name conflict. - const exportNameToImportName = createMap(); + const exportNameToImportName = new Map(); for (const propertyAccess of nodesToReplace) { const exportName = propertyAccess.name.text; diff --git a/src/services/refactors/extractSymbol.ts b/src/services/refactors/extractSymbol.ts index 8035c5fbb18..c2234a891dd 100644 --- a/src/services/refactors/extractSymbol.ts +++ b/src/services/refactors/extractSymbol.ts @@ -43,11 +43,11 @@ namespace ts.refactor.extractSymbol { } const functionActions: RefactorActionInfo[] = []; - const usedFunctionNames: ESMap = createMap(); + const usedFunctionNames = new Map(); let innermostErrorFunctionAction: RefactorActionInfo | undefined; const constantActions: RefactorActionInfo[] = []; - const usedConstantNames: ESMap = createMap(); + const usedConstantNames = new Map(); let innermostErrorConstantAction: RefactorActionInfo | undefined; let i = 0; @@ -1546,13 +1546,13 @@ namespace ts.refactor.extractSymbol { checker: TypeChecker, cancellationToken: CancellationToken): ReadsAndWrites { - const allTypeParameterUsages = createMap(); // Key is type ID + const allTypeParameterUsages = new Map(); // Key is type ID const usagesPerScope: ScopeUsages[] = []; const substitutionsPerScope: ESMap[] = []; const functionErrorsPerScope: Diagnostic[][] = []; const constantErrorsPerScope: Diagnostic[][] = []; const visibleDeclarationsInExtractedRange: NamedDeclaration[] = []; - const exposedVariableSymbolSet = createMap(); // Key is symbol ID + const exposedVariableSymbolSet = new Map(); // Key is symbol ID const exposedVariableDeclarations: VariableDeclaration[] = []; let firstExposedNonVariableDeclaration: NamedDeclaration | undefined; @@ -1575,8 +1575,8 @@ namespace ts.refactor.extractSymbol { // initialize results for (const scope of scopes) { - usagesPerScope.push({ usages: createMap(), typeParameterUsages: createMap(), substitutions: createMap() }); - substitutionsPerScope.push(createMap()); + usagesPerScope.push({ usages: new Map(), typeParameterUsages: new Map(), substitutions: new Map() }); + substitutionsPerScope.push(new Map()); functionErrorsPerScope.push( isFunctionLikeDeclaration(scope) && scope.kind !== SyntaxKind.FunctionDeclaration @@ -1597,7 +1597,7 @@ namespace ts.refactor.extractSymbol { constantErrorsPerScope.push(constantErrors); } - const seenUsages = createMap(); + const seenUsages = new Map(); const target = isReadonlyArray(targetRange.range) ? factory.createBlock(targetRange.range) : targetRange.range; const unmodifiedNode = isReadonlyArray(targetRange.range) ? first(targetRange.range) : targetRange.range; @@ -1614,7 +1614,7 @@ namespace ts.refactor.extractSymbol { } if (allTypeParameterUsages.size > 0) { - const seenTypeParameterUsages = createMap(); // Key is type ID + const seenTypeParameterUsages = new Map(); // Key is type ID let i = 0; for (let curr: Node = unmodifiedNode; curr !== undefined && i < scopes.length; curr = curr.parent) { diff --git a/src/services/refactors/extractType.ts b/src/services/refactors/extractType.ts index ef922bce633..6f144cfe40b 100644 --- a/src/services/refactors/extractType.ts +++ b/src/services/refactors/extractType.ts @@ -105,7 +105,7 @@ namespace ts.refactor { if (!node) return undefined; if (isIntersectionTypeNode(node)) { const result: TypeElement[] = []; - const seen = createMap(); + const seen = new Map(); for (const type of node.types) { const flattenedTypeMembers = flattenTypeLiteralNodeReference(checker, type); if (!flattenedTypeMembers || !flattenedTypeMembers.every(type => type.name && addToSeen(seen, getNameFromPropertyName(type.name) as string))) { diff --git a/src/services/refactors/moveToNewFile.ts b/src/services/refactors/moveToNewFile.ts index f4984fe18bd..fd0cf852da3 100644 --- a/src/services/refactors/moveToNewFile.ts +++ b/src/services/refactors/moveToNewFile.ts @@ -269,7 +269,7 @@ namespace ts.refactor { | ImportEqualsDeclaration | VariableStatement; - function createOldFileImportsFromNewFile(newFileNeedExport: ReadonlySymbolSet, newFileNameWithExtension: string, useEs6Imports: boolean, quotePreference: QuotePreference): Statement | undefined { + function createOldFileImportsFromNewFile(newFileNeedExport: ReadonlySymbolSet, newFileNameWithExtension: string, useEs6Imports: boolean, quotePreference: QuotePreference): AnyImportOrRequireStatement | undefined { let defaultImport: Identifier | undefined; const imports: string[] = []; newFileNeedExport.forEach(symbol => { @@ -283,7 +283,7 @@ namespace ts.refactor { return makeImportOrRequire(defaultImport, imports, newFileNameWithExtension, useEs6Imports, quotePreference); } - function makeImportOrRequire(defaultImport: Identifier | undefined, imports: readonly string[], path: string, useEs6Imports: boolean, quotePreference: QuotePreference): Statement | undefined { + function makeImportOrRequire(defaultImport: Identifier | undefined, imports: readonly string[], path: string, useEs6Imports: boolean, quotePreference: QuotePreference): AnyImportOrRequireStatement | undefined { path = ensurePathIsNonModuleName(path); if (useEs6Imports) { const specifiers = imports.map(i => factory.createImportSpecifier(/*propertyName*/ undefined, factory.createIdentifier(i))); @@ -293,7 +293,7 @@ namespace ts.refactor { Debug.assert(!defaultImport, "No default import should exist"); // If there's a default export, it should have been an es6 module. const bindingElements = imports.map(i => factory.createBindingElement(/*dotDotDotToken*/ undefined, /*propertyName*/ undefined, i)); return bindingElements.length - ? makeVariableStatement(factory.createObjectBindingPattern(bindingElements), /*type*/ undefined, createRequireCall(factory.createStringLiteral(path))) + ? makeVariableStatement(factory.createObjectBindingPattern(bindingElements), /*type*/ undefined, createRequireCall(factory.createStringLiteral(path))) as RequireVariableStatement : undefined; } } @@ -610,7 +610,7 @@ namespace ts.refactor { forEachEntry(cb: (symbol: Symbol) => T | undefined): T | undefined; } class SymbolSet implements ReadonlySymbolSet { - private map = createMap(); + private map = new Map(); add(symbol: Symbol): void { this.map.set(String(getSymbolId(symbol)), symbol); } diff --git a/src/services/services.ts b/src/services/services.ts index dba76568019..eb1e9659648 100644 --- a/src/services/services.ts +++ b/src/services/services.ts @@ -1408,7 +1408,7 @@ namespace ts { // // Each LS has a reference to file 'foo.ts' at version 1. LS2 then updates // it's version of 'foo.ts' to version 2. This will cause LS2 and the - // DocumentRegistry to have version 2 of the document. HOwever, LS1 will + // DocumentRegistry to have version 2 of the document. However, LS1 will // have version 1. And *importantly* this source file will be *corrupt*. // The act of creating version 2 of the file irrevocably damages the version // 1 file. @@ -1451,7 +1451,7 @@ namespace ts { function dispose(): void { if (program) { - // Use paths to ensure we are using correct key and paths as document registry could bre created with different current directory than host + // Use paths to ensure we are using correct key and paths as document registry could be created with different current directory than host const key = documentRegistry.getKeyForCompilationSettings(program.getCompilerOptions()); forEach(program.getSourceFiles(), f => documentRegistry.releaseDocumentWithKey(f.resolvedPath, key)); @@ -1831,12 +1831,12 @@ namespace ts { return OutliningElementsCollector.collectElements(sourceFile, cancellationToken); } - const braceMatching = createMapFromTemplate({ + const braceMatching = new Map(getEntries({ [SyntaxKind.OpenBraceToken]: SyntaxKind.CloseBraceToken, [SyntaxKind.OpenParenToken]: SyntaxKind.CloseParenToken, [SyntaxKind.OpenBracketToken]: SyntaxKind.CloseBracketToken, [SyntaxKind.GreaterThanToken]: SyntaxKind.LessThanToken, - }); + })); braceMatching.forEach((value, key) => braceMatching.set(value.toString(), Number(key) as SyntaxKind)); function getBraceMatchingAtPosition(fileName: string, position: number): TextSpan[] { @@ -2299,7 +2299,7 @@ namespace ts { } function initializeNameTable(sourceFile: SourceFile): void { - const nameTable = sourceFile.nameTable = createUnderscoreEscapedMap(); + const nameTable = sourceFile.nameTable = new Map(); sourceFile.forEachChild(function walk(node) { if (isIdentifier(node) && !isTagName(node) && node.escapedText || isStringOrNumericLiteralLike(node) && literalIsName(node)) { const text = getEscapedTextOfIdentifierOrLiteral(node); diff --git a/src/services/sourcemaps.ts b/src/services/sourcemaps.ts index e095708ed94..ed4bb7c8928 100644 --- a/src/services/sourcemaps.ts +++ b/src/services/sourcemaps.ts @@ -23,8 +23,8 @@ namespace ts { export function getSourceMapper(host: SourceMapperHost): SourceMapper { const getCanonicalFileName = createGetCanonicalFileName(host.useCaseSensitiveFileNames()); const currentDirectory = host.getCurrentDirectory(); - const sourceFileLike = createMap(); - const documentPositionMappers = createMap(); + const sourceFileLike = new Map(); + const documentPositionMappers = new Map(); return { tryGetSourcePosition, tryGetGeneratedPosition, toLineColumnOffset, clearCache }; function toPath(fileName: string) { diff --git a/src/services/stringCompletions.ts b/src/services/stringCompletions.ts index 27db312c521..c3473b6251e 100644 --- a/src/services/stringCompletions.ts +++ b/src/services/stringCompletions.ts @@ -207,7 +207,7 @@ namespace ts.Completions.StringCompletions { function getStringLiteralCompletionsFromSignature(argumentInfo: SignatureHelp.ArgumentInfoForCompletions, checker: TypeChecker): StringLiteralCompletionsFromTypes { let isNewIdentifier = false; - const uniques = createMap(); + const uniques = new Map(); const candidates: Signature[] = []; checker.getResolvedSignature(argumentInfo.invocation, candidates, argumentInfo.argumentCount); const types = flatMap(candidates, candidate => { @@ -228,7 +228,7 @@ namespace ts.Completions.StringCompletions { }; } - function getStringLiteralTypes(type: Type | undefined, uniques = createMap()): readonly StringLiteralType[] { + function getStringLiteralTypes(type: Type | undefined, uniques = new Map()): readonly StringLiteralType[] { if (!type) return emptyArray; type = skipConstraint(type); return type.isUnion() ? flatMap(type.types, t => getStringLiteralTypes(t, uniques)) : @@ -363,7 +363,7 @@ namespace ts.Completions.StringCompletions { * * both foo.ts and foo.tsx become foo */ - const foundFiles = createMap(); // maps file to its extension + const foundFiles = new Map(); // maps file to its extension for (let filePath of files) { filePath = normalizePath(filePath); if (exclude && comparePaths(filePath, exclude, scriptPath, ignoreCase) === Comparison.EqualTo) { @@ -595,7 +595,7 @@ namespace ts.Completions.StringCompletions { function getCompletionEntriesFromTypings(host: LanguageServiceHost, options: CompilerOptions, scriptPath: string, fragmentDirectory: string | undefined, extensionOptions: ExtensionOptions, result: NameAndKind[] = []): readonly NameAndKind[] { // Check for typings specified in compiler options - const seen = createMap(); + const seen = new Map(); const typeRoots = tryAndIgnoreErrors(() => getEffectiveTypeRoots(options, host)) || emptyArray; diff --git a/src/services/suggestionDiagnostics.ts b/src/services/suggestionDiagnostics.ts index 09607d8ab8a..a8c50322522 100644 --- a/src/services/suggestionDiagnostics.ts +++ b/src/services/suggestionDiagnostics.ts @@ -1,6 +1,6 @@ /* @internal */ namespace ts { - const visitedNestedConvertibleFunctions = createMap(); + const visitedNestedConvertibleFunctions = new Map(); export function computeSuggestionDiagnostics(sourceFile: SourceFile, program: Program, cancellationToken: CancellationToken): DiagnosticWithLocation[] { program.getSemanticDiagnostics(sourceFile, cancellationToken); diff --git a/src/services/textChanges.ts b/src/services/textChanges.ts index 1acce25574b..0448be77e99 100644 --- a/src/services/textChanges.ts +++ b/src/services/textChanges.ts @@ -250,7 +250,7 @@ namespace ts.textChanges { export class ChangeTracker { private readonly changes: Change[] = []; private readonly newFiles: { readonly oldFile: SourceFile | undefined, readonly fileName: string, readonly statements: readonly Statement[] }[] = []; - private readonly classesWithNodesInsertedAtStart = createMap<{ readonly node: ClassDeclaration | InterfaceDeclaration | ObjectLiteralExpression, readonly sourceFile: SourceFile }>(); // Set implemented as Map + private readonly classesWithNodesInsertedAtStart = new Map(); // Set implemented as Map private readonly deletedNodes: { readonly sourceFile: SourceFile, readonly node: Node | NodeArray }[] = []; public static fromContext(context: TextChangesContext): ChangeTracker { @@ -472,9 +472,9 @@ namespace ts.textChanges { this.insertNodesAt(sourceFile, start, typeParameters, { prefix: "<", suffix: ">" }); } - private getOptionsForInsertNodeBefore(before: Node, inserted: Node, doubleNewlines: boolean): InsertNodeOptions { + private getOptionsForInsertNodeBefore(before: Node, inserted: Node, blankLineBetween: boolean): InsertNodeOptions { if (isStatement(before) || isClassElement(before)) { - return { suffix: doubleNewlines ? this.newLineCharacter + this.newLineCharacter : this.newLineCharacter }; + return { suffix: blankLineBetween ? this.newLineCharacter + this.newLineCharacter : this.newLineCharacter }; } else if (isVariableDeclaration(before)) { // insert `x = 1, ` into `const x = 1, y = 2; return { suffix: ", " }; @@ -485,6 +485,9 @@ namespace ts.textChanges { else if (isStringLiteral(before) && isImportDeclaration(before.parent) || isNamedImports(before)) { return { suffix: ", " }; } + else if (isImportSpecifier(before)) { + return { suffix: "," + (blankLineBetween ? this.newLineCharacter : " ") }; + } return Debug.failBadSyntaxKind(before); // We haven't handled this kind of node yet -- add it } @@ -824,7 +827,7 @@ namespace ts.textChanges { } private finishDeleteDeclarations(): void { - const deletedNodesInLists = new NodeSet(); // Stores nodes in lists that we already deleted. Used to avoid deleting `, ` twice in `a, b`. + const deletedNodesInLists = new Set(); // Stores nodes in lists that we already deleted. Used to avoid deleting `, ` twice in `a, b`. for (const { sourceFile, node } of this.deletedNodes) { if (!this.deletedNodes.some(d => d.sourceFile === sourceFile && rangeContainsRangeExclusive(d.node, node))) { if (isArray(node)) { @@ -1275,7 +1278,7 @@ namespace ts.textChanges { } namespace deleteDeclaration { - export function deleteDeclaration(changes: ChangeTracker, deletedNodesInLists: NodeSet, sourceFile: SourceFile, node: Node): void { + export function deleteDeclaration(changes: ChangeTracker, deletedNodesInLists: Set, sourceFile: SourceFile, node: Node): void { switch (node.kind) { case SyntaxKind.Parameter: { const oldFunction = node.parent; @@ -1397,7 +1400,7 @@ namespace ts.textChanges { } } - function deleteVariableDeclaration(changes: ChangeTracker, deletedNodesInLists: NodeSet, sourceFile: SourceFile, node: VariableDeclaration): void { + function deleteVariableDeclaration(changes: ChangeTracker, deletedNodesInLists: Set, sourceFile: SourceFile, node: VariableDeclaration): void { const { parent } = node; if (parent.kind === SyntaxKind.CatchClause) { @@ -1440,7 +1443,7 @@ namespace ts.textChanges { changes.deleteRange(sourceFile, { pos: startPosition, end: endPosition }); } - function deleteNodeInList(changes: ChangeTracker, deletedNodesInLists: NodeSet, sourceFile: SourceFile, node: Node): void { + function deleteNodeInList(changes: ChangeTracker, deletedNodesInLists: Set, sourceFile: SourceFile, node: Node): void { const containingList = Debug.checkDefined(formatting.SmartIndenter.getContainingList(node, sourceFile)); const index = indexOfNode(containingList, node); Debug.assert(index !== -1); diff --git a/src/services/transpile.ts b/src/services/transpile.ts index c739c8394f2..103c7dc503b 100644 --- a/src/services/transpile.ts +++ b/src/services/transpile.ts @@ -54,7 +54,7 @@ namespace ts { } if (transpileOptions.renamedDependencies) { - sourceFile.renamedDependencies = createMapFromTemplate(transpileOptions.renamedDependencies); + sourceFile.renamedDependencies = new Map(getEntries(transpileOptions.renamedDependencies)); } const newLine = getNewLineCharacter(options); diff --git a/src/services/utilities.ts b/src/services/utilities.ts index 591766a6b2e..d89a68c96ed 100644 --- a/src/services/utilities.ts +++ b/src/services/utilities.ts @@ -1828,7 +1828,7 @@ namespace ts { * The value of previousIterationSymbol is undefined when the function is first called. */ export function getPropertySymbolsFromBaseTypes(symbol: Symbol, propertyName: string, checker: TypeChecker, cb: (symbol: Symbol) => T | undefined): T | undefined { - const seen = createMap(); + const seen = new Map(); return recur(symbol); function recur(symbol: Symbol): T | undefined { @@ -1872,23 +1872,34 @@ namespace ts { return node.modifiers && find(node.modifiers, m => m.kind === kind); } - export function insertImports(changes: textChanges.ChangeTracker, sourceFile: SourceFile, imports: Statement | readonly Statement[], blankLineBetween: boolean): void { + export function insertImports(changes: textChanges.ChangeTracker, sourceFile: SourceFile, imports: AnyImportOrRequireStatement | readonly AnyImportOrRequireStatement[], blankLineBetween: boolean): void { const decl = isArray(imports) ? imports[0] : imports; - const importKindPredicate = decl.kind === SyntaxKind.VariableStatement ? isRequireVariableDeclarationStatement : isAnyImportSyntax; - const lastImportDeclaration = findLast(sourceFile.statements, statement => importKindPredicate(statement)); - if (lastImportDeclaration) { - if (isArray(imports)) { - changes.insertNodesAfter(sourceFile, lastImportDeclaration, imports); - } - else { - changes.insertNodeAfter(sourceFile, lastImportDeclaration, imports); - } + const importKindPredicate: (node: Node) => node is AnyImportOrRequireStatement = decl.kind === SyntaxKind.VariableStatement ? isRequireVariableStatement : isAnyImportSyntax; + const existingImportStatements = filter(sourceFile.statements, importKindPredicate); + const sortedNewImports = isArray(imports) ? stableSort(imports, OrganizeImports.compareImportsOrRequireStatements) : [imports]; + if (!existingImportStatements.length) { + changes.insertNodesAtTopOfFile(sourceFile, sortedNewImports, blankLineBetween); } - else if (isArray(imports)) { - changes.insertNodesAtTopOfFile(sourceFile, imports, blankLineBetween); + else if (existingImportStatements && OrganizeImports.importsAreSorted(existingImportStatements)) { + for (const newImport of sortedNewImports) { + const insertionIndex = OrganizeImports.getImportDeclarationInsertionIndex(existingImportStatements, newImport); + if (insertionIndex === 0) { + changes.insertNodeBefore(sourceFile, existingImportStatements[0], newImport, /*blankLineBetween*/ false); + } + else { + const prevImport = existingImportStatements[insertionIndex - 1]; + changes.insertNodeAfter(sourceFile, prevImport, newImport); + } + } } else { - changes.insertNodeAtTopOfFile(sourceFile, imports, blankLineBetween); + const lastExistingImport = lastOrUndefined(existingImportStatements); + if (lastExistingImport) { + changes.insertNodesAfter(sourceFile, lastExistingImport, sortedNewImports); + } + else { + changes.insertNodesAtTopOfFile(sourceFile, sortedNewImports, blankLineBetween); + } } } @@ -2696,7 +2707,7 @@ namespace ts { if (!dependencies) { continue; } - const dependencyMap = createMap(); + const dependencyMap = new Map(); for (const packageName in dependencies) { dependencyMap.set(packageName, dependencies[packageName]); } diff --git a/src/testRunner/externalCompileRunner.ts b/src/testRunner/externalCompileRunner.ts index b720ba61f2c..4f2cd9e4770 100644 --- a/src/testRunner/externalCompileRunner.ts +++ b/src/testRunner/externalCompileRunner.ts @@ -30,7 +30,7 @@ namespace Harness { // eslint-disable-next-line @typescript-eslint/no-this-alias const cls = this; - describe(`${this.kind()} code samples`, function (this: Mocha.ISuiteCallbackContext) { + describe(`${this.kind()} code samples`, function (this: Mocha.Suite) { this.timeout(600_000); // 10 minutes for (const test of testList) { cls.runTest(typeof test === "string" ? test : test.file); @@ -41,7 +41,7 @@ namespace Harness { // eslint-disable-next-line @typescript-eslint/no-this-alias const cls = this; const timeout = 600_000; // 10 minutes - describe(directoryName, function (this: Mocha.ISuiteCallbackContext) { + describe(directoryName, function (this: Mocha.Suite) { this.timeout(timeout); const cp: typeof import("child_process") = require("child_process"); @@ -127,7 +127,7 @@ ${stripAbsoluteImportPaths(result.stderr.toString().replace(/\r\n/g, "\n"))}`; // eslint-disable-next-line @typescript-eslint/no-this-alias const cls = this; - describe(`${this.kind()} code samples`, function (this: Mocha.ISuiteCallbackContext) { + describe(`${this.kind()} code samples`, function (this: Mocha.Suite) { this.timeout(cls.timeout); // 20 minutes before(() => { cls.exec("docker", ["build", ".", "-t", "typescript/typescript"], { cwd: IO.getWorkspaceRoot() }); // cached because workspace is hashed to determine cacheability diff --git a/src/testRunner/parallel/host.ts b/src/testRunner/parallel/host.ts index bb4b31b9f05..d1db63e2f5a 100644 --- a/src/testRunner/parallel/host.ts +++ b/src/testRunner/parallel/host.ts @@ -24,7 +24,7 @@ namespace Harness.Parallel.Host { let totalCost = 0; class RemoteSuite extends Mocha.Suite { - suiteMap = ts.createMap(); + suiteMap = new ts.Map(); constructor(title: string) { super(title); this.pending = false; diff --git a/src/testRunner/parallel/worker.ts b/src/testRunner/parallel/worker.ts index 64d09a85d45..dd8add3050d 100644 --- a/src/testRunner/parallel/worker.ts +++ b/src/testRunner/parallel/worker.ts @@ -146,13 +146,13 @@ namespace Harness.Parallel.Worker { function executeUnitTests(task: UnitTestTask, fn: (payload: TaskResult) => void) { if (!unitTestSuiteMap && unitTestSuite.suites.length) { - unitTestSuiteMap = ts.createMap(); + unitTestSuiteMap = new ts.Map(); for (const suite of unitTestSuite.suites) { unitTestSuiteMap.set(suite.title, suite); } } if (!unitTestTestMap && unitTestSuite.tests.length) { - unitTestTestMap = ts.createMap(); + unitTestTestMap = new ts.Map(); for (const test of unitTestSuite.tests) { unitTestTestMap.set(test.title, test); } @@ -297,7 +297,7 @@ namespace Harness.Parallel.Worker { } // A cache of test harness Runner instances. - const runners = ts.createMap(); + const runners = new ts.Map(); // The root suite for all unit tests. let unitTestSuite: Suite; diff --git a/src/testRunner/rwcRunner.ts b/src/testRunner/rwcRunner.ts index a50447b2d00..29e86382aff 100644 --- a/src/testRunner/rwcRunner.ts +++ b/src/testRunner/rwcRunner.ts @@ -47,7 +47,7 @@ namespace RWC { caseSensitive = false; }); - it("can compile", function (this: Mocha.ITestCallbackContext) { + it("can compile", function (this: Mocha.Context) { this.timeout(800_000); // Allow long timeouts for RWC compilations let opts!: ts.ParsedCommandLine; @@ -83,7 +83,7 @@ namespace RWC { } // Deduplicate files so they are only printed once in baselines (they are deduplicated within the compiler already) - const uniqueNames = ts.createMap(); + const uniqueNames = new ts.Map(); for (const fileName of fileNames) { // Must maintain order, build result list while checking map const normalized = ts.normalizeSlashes(Harness.IO.resolvePath(fileName)!); @@ -145,7 +145,7 @@ namespace RWC { }); - it("has the expected emitted code", function (this: Mocha.ITestCallbackContext) { + it("has the expected emitted code", function (this: Mocha.Context) { this.timeout(100_000); // Allow longer timeouts for RWC js verification Harness.Baseline.runMultifileBaseline(baseName, "", () => { return Harness.Compiler.iterateOutputs(compilerResult.js.values()); diff --git a/src/testRunner/unittests/config/commandLineParsing.ts b/src/testRunner/unittests/config/commandLineParsing.ts index f0582bce0e2..4c1331ca430 100644 --- a/src/testRunner/unittests/config/commandLineParsing.ts +++ b/src/testRunner/unittests/config/commandLineParsing.ts @@ -571,10 +571,10 @@ namespace ts { describe("option of type Map", () => { verifyNullNonIncludedOption({ - type: () => createMapFromTemplate({ + type: () => new Map(getEntries({ node: ModuleResolutionKind.NodeJs, classic: ModuleResolutionKind.Classic, - }), + })), nonNullValue: "node" }); }); diff --git a/src/testRunner/unittests/config/projectReferences.ts b/src/testRunner/unittests/config/projectReferences.ts index 6f9d3b3b249..a70329a8db8 100644 --- a/src/testRunner/unittests/config/projectReferences.ts +++ b/src/testRunner/unittests/config/projectReferences.ts @@ -43,7 +43,7 @@ namespace ts { } function testProjectReferences(spec: TestSpecification, entryPointConfigFileName: string, checkResult: (prog: Program, host: fakes.CompilerHost) => void) { - const files = createMap(); + const files = new Map(); for (const key in spec) { const sp = spec[key]; const configFileName = combineAllPaths("/", key, sp.configFileName || "tsconfig.json"); diff --git a/src/testRunner/unittests/createMapShim.ts b/src/testRunner/unittests/createMapShim.ts index da433fe21d2..db7d4614e52 100644 --- a/src/testRunner/unittests/createMapShim.ts +++ b/src/testRunner/unittests/createMapShim.ts @@ -139,11 +139,11 @@ namespace ts { const expectedResult = "1:1;3:3;2:Y2;4:X4;0:X0;3:Y3;999:999;A:A;Z:Z;X:X;Y:Y;"; // First, ensure the test actually has the same behavior as a native Map. - let nativeMap = createMap(); + let nativeMap = new Map(); const nativeMapForEachResult = testMapIterationAddedValues(stringKeys, nativeMap, /* useForEach */ true); assert.equal(nativeMapForEachResult, expectedResult, "nativeMap-forEach"); - nativeMap = createMap(); + nativeMap = new Map(); const nativeMapIteratorResult = testMapIterationAddedValues(stringKeys, nativeMap, /* useForEach */ false); assert.equal(nativeMapIteratorResult, expectedResult, "nativeMap-iterator"); @@ -161,11 +161,11 @@ namespace ts { const expectedResult = "true:1;3:3;2:Y2;4:X4;false:X0;3:Y3;null:999;undefined:A;Z:Z;X:X;Y:Y;"; // First, ensure the test actually has the same behavior as a native Map. - let nativeMap = createMap(); + let nativeMap = new Map(); const nativeMapForEachResult = testMapIterationAddedValues(mixedKeys, nativeMap, /* useForEach */ true); assert.equal(nativeMapForEachResult, expectedResult, "nativeMap-forEach"); - nativeMap = createMap(); + nativeMap = new Map(); const nativeMapIteratorResult = testMapIterationAddedValues(mixedKeys, nativeMap, /* useForEach */ false); assert.equal(nativeMapIteratorResult, expectedResult, "nativeMap-iterator"); diff --git a/src/testRunner/unittests/customTransforms.ts b/src/testRunner/unittests/customTransforms.ts index f346ea47dd6..7992f8a9c55 100644 --- a/src/testRunner/unittests/customTransforms.ts +++ b/src/testRunner/unittests/customTransforms.ts @@ -4,7 +4,7 @@ namespace ts { it(name, () => { const roots = sources.map(source => createSourceFile(source.file, source.text, ScriptTarget.ES2015)); const fileMap = arrayToMap(roots, file => file.fileName); - const outputs = createMap(); + const outputs = new Map(); const host: CompilerHost = { getSourceFile: (fileName) => fileMap.get(fileName), getDefaultLibFileName: () => "lib.d.ts", diff --git a/src/testRunner/unittests/moduleResolution.ts b/src/testRunner/unittests/moduleResolution.ts index 32f05c6fd5e..477952cc400 100644 --- a/src/testRunner/unittests/moduleResolution.ts +++ b/src/testRunner/unittests/moduleResolution.ts @@ -35,7 +35,7 @@ namespace ts { } function createModuleResolutionHost(hasDirectoryExists: boolean, ...files: File[]): ModuleResolutionHost { - const map = createMap(); + const map = new Map(); for (const file of files) { map.set(file.name, file); if (file.symlinks) { @@ -46,7 +46,7 @@ namespace ts { } if (hasDirectoryExists) { - const directories = createMap(); + const directories = new Map(); for (const f of files) { let name = getDirectoryPath(f.name); while (true) { @@ -495,7 +495,7 @@ namespace ts { } it("should find all modules", () => { - const files = createMapFromTemplate({ + const files = new Map(getEntries({ "/a/b/c/first/shared.ts": ` class A {} export = A`, @@ -509,23 +509,23 @@ import Shared = require('../first/shared'); class C {} export = C; ` - }); + })); test(files, "/a/b/c/first/second", ["class_a.ts"], 3, ["../../../c/third/class_c.ts"]); }); it("should find modules in node_modules", () => { - const files = createMapFromTemplate({ + const files = new Map(getEntries({ "/parent/node_modules/mod/index.d.ts": "export var x", "/parent/app/myapp.ts": `import {x} from "mod"` - }); + })); test(files, "/parent/app", ["myapp.ts"], 2, []); }); it("should find file referenced via absolute and relative names", () => { - const files = createMapFromTemplate({ + const files = new Map(getEntries({ "/a/b/c.ts": `/// `, "/a/b/b.ts": "var x" - }); + })); test(files, "/a/b", ["c.ts", "/a/b/b.ts"], 2, []); }); }); @@ -543,7 +543,7 @@ export = C; const getCanonicalFileName = createGetCanonicalFileName(useCaseSensitiveFileNames); if (!useCaseSensitiveFileNames) { const oldFiles = files; - files = createMap(); + files = new Map(); oldFiles.forEach((file, fileName) => { files.set(getCanonicalFileName(fileName), file); }); @@ -580,10 +580,10 @@ export = C; } it("should succeed when the same file is referenced using absolute and relative names", () => { - const files = createMapFromTemplate({ + const files = new Map(getEntries({ "/a/b/c.ts": `/// `, "/a/b/d.ts": "var x" - }); + })); test( files, { module: ModuleKind.AMD }, @@ -595,10 +595,10 @@ export = C; }); it("should fail when two files used in program differ only in casing (tripleslash references)", () => { - const files = createMapFromTemplate({ + const files = new Map(getEntries({ "/a/b/c.ts": `/// `, "/a/b/d.ts": "var x" - }); + })); test( files, { module: ModuleKind.AMD, forceConsistentCasingInFileNames: true }, @@ -622,10 +622,10 @@ export = C; }); it("should fail when two files used in program differ only in casing (imports)", () => { - const files = createMapFromTemplate({ + const files = new Map(getEntries({ "/a/b/c.ts": `import {x} from "D"`, "/a/b/d.ts": "export var x" - }); + })); test( files, { module: ModuleKind.AMD, forceConsistentCasingInFileNames: true }, @@ -649,10 +649,10 @@ export = C; }); it("should fail when two files used in program differ only in casing (imports, relative module names)", () => { - const files = createMapFromTemplate({ + const files = new Map(getEntries({ "moduleA.ts": `import {x} from "./ModuleB"`, "moduleB.ts": "export var x" - }); + })); test( files, { module: ModuleKind.CommonJS, forceConsistentCasingInFileNames: true }, @@ -676,11 +676,11 @@ export = C; }); it("should fail when two files exist on disk that differs only in casing", () => { - const files = createMapFromTemplate({ + const files = new Map(getEntries({ "/a/b/c.ts": `import {x} from "D"`, "/a/b/D.ts": "export var x", "/a/b/d.ts": "export var y" - }); + })); test( files, { module: ModuleKind.AMD }, @@ -704,11 +704,11 @@ export = C; }); it("should fail when module name in 'require' calls has inconsistent casing", () => { - const files = createMapFromTemplate({ + const files = new Map(getEntries({ "moduleA.ts": `import a = require("./ModuleC")`, "moduleB.ts": `import a = require("./moduleC")`, "moduleC.ts": "export var x" - }); + })); test( files, { module: ModuleKind.CommonJS, forceConsistentCasingInFileNames: true }, @@ -747,7 +747,7 @@ export = C; }); it("should fail when module names in 'require' calls has inconsistent casing and current directory has uppercase chars", () => { - const files = createMapFromTemplate({ + const files = new Map(getEntries({ "/a/B/c/moduleA.ts": `import a = require("./ModuleC")`, "/a/B/c/moduleB.ts": `import a = require("./moduleC")`, "/a/B/c/moduleC.ts": "export var x", @@ -755,7 +755,7 @@ export = C; import a = require("./moduleA"); import b = require("./moduleB"); ` - }); + })); test( files, { module: ModuleKind.CommonJS, forceConsistentCasingInFileNames: true }, @@ -778,7 +778,7 @@ import b = require("./moduleB"); ); }); it("should not fail when module names in 'require' calls has consistent casing and current directory has uppercase chars", () => { - const files = createMapFromTemplate({ + const files = new Map(getEntries({ "/a/B/c/moduleA.ts": `import a = require("./moduleC")`, "/a/B/c/moduleB.ts": `import a = require("./moduleC")`, "/a/B/c/moduleC.ts": "export var x", @@ -786,7 +786,7 @@ import b = require("./moduleB"); import a = require("./moduleA"); import b = require("./moduleB"); ` - }); + })); test( files, { module: ModuleKind.CommonJS, forceConsistentCasingInFileNames: true }, @@ -798,11 +798,11 @@ import b = require("./moduleB"); }); it("should succeed when the two files in program differ only in drive letter in their names", () => { - const files = createMapFromTemplate({ + const files = new Map(getEntries({ "d:/someFolder/moduleA.ts": `import a = require("D:/someFolder/moduleC")`, "d:/someFolder/moduleB.ts": `import a = require("./moduleC")`, "D:/someFolder/moduleC.ts": "export const x = 10", - }); + })); test( files, { module: ModuleKind.CommonJS, forceConsistentCasingInFileNames: true }, diff --git a/src/testRunner/unittests/programApi.ts b/src/testRunner/unittests/programApi.ts index 5694345af24..63c33deb595 100644 --- a/src/testRunner/unittests/programApi.ts +++ b/src/testRunner/unittests/programApi.ts @@ -1,13 +1,13 @@ namespace ts { function verifyMissingFilePaths(missingPaths: readonly Path[], expected: readonly string[]) { assert.isDefined(missingPaths); - const map = arrayToSet(expected) as ESMap; + const map = new Set(expected); for (const missing of missingPaths) { - const value = map.get(missing); + const value = map.has(missing); assert.isTrue(value, `${missing} to be ${value === undefined ? "not present" : "present only once"}, in actual: ${missingPaths} expected: ${expected}`); - map.set(missing, false); + map.delete(missing); } - const notFound = arrayFrom(mapDefinedIterator(map.keys(), k => map.get(k) === true ? k : undefined)); + const notFound = arrayFrom(mapDefinedIterator(map.keys(), k => map.has(k) ? k : undefined)); assert.equal(notFound.length, 0, `Not found ${notFound} in actual: ${missingPaths} expected: ${expected}`); } diff --git a/src/testRunner/unittests/publicApi.ts b/src/testRunner/unittests/publicApi.ts index 7104662d033..cbb7e1b536a 100644 --- a/src/testRunner/unittests/publicApi.ts +++ b/src/testRunner/unittests/publicApi.ts @@ -77,3 +77,31 @@ describe("unittests:: Public APIs:: isPropertyName", () => { assert.isTrue(ts.isPropertyName(prop), "PrivateIdentifier must be a valid property name."); }); }); + +describe("unittests:: Public APIs:: getTypeAtLocation", () => { + it("works on PropertyAccessExpression in implements clause", () => { + const content = `namespace Test { + export interface Test {} + } + class Foo implements Test.Test {}`; + + const host = new fakes.CompilerHost(vfs.createFromFileSystem( + Harness.IO, + /*ignoreCase*/ true, + { documents: [new documents.TextDocument("/file.ts", content)], cwd: "/" })); + + const program = ts.createProgram({ + host, + rootNames: ["/file.ts"], + options: { noLib: true } + }); + + const checker = program.getTypeChecker(); + const file = program.getSourceFile("/file.ts")!; + const classDeclaration = file.statements.find(ts.isClassDeclaration)!; + const propertyAccess = classDeclaration.heritageClauses![0].types[0].expression as ts.PropertyAccessExpression; + const type = checker.getTypeAtLocation(propertyAccess); + assert.ok(!(type.flags & ts.TypeFlags.Any)); + assert.equal(type, checker.getTypeAtLocation(propertyAccess.name)); + }); +}); diff --git a/src/testRunner/unittests/reuseProgramStructure.ts b/src/testRunner/unittests/reuseProgramStructure.ts index fa7e5a3bfe5..8c3f9d6a94f 100644 --- a/src/testRunner/unittests/reuseProgramStructure.ts +++ b/src/testRunner/unittests/reuseProgramStructure.ts @@ -344,7 +344,7 @@ namespace ts { const options: CompilerOptions = { target }; const program1 = newProgram(files, ["a.ts"], options); - checkResolvedModulesCache(program1, "a.ts", createMapFromTemplate({ b: createResolvedModule("b.ts") })); + checkResolvedModulesCache(program1, "a.ts", new Map(getEntries({ b: createResolvedModule("b.ts") }))); checkResolvedModulesCache(program1, "b.ts", /*expectedContent*/ undefined); const program2 = updateProgram(program1, ["a.ts"], options, files => { @@ -353,7 +353,7 @@ namespace ts { assert.equal(program1.structureIsReused, StructureIsReused.Completely); // content of resolution cache should not change - checkResolvedModulesCache(program1, "a.ts", createMapFromTemplate({ b: createResolvedModule("b.ts") })); + checkResolvedModulesCache(program1, "a.ts", new Map(getEntries({ b: createResolvedModule("b.ts") }))); checkResolvedModulesCache(program1, "b.ts", /*expectedContent*/ undefined); // imports has changed - program is not reused @@ -370,7 +370,7 @@ namespace ts { files[0].text = files[0].text.updateImportsAndExports(newImports); }); assert.equal(program3.structureIsReused, StructureIsReused.SafeModules); - checkResolvedModulesCache(program4, "a.ts", createMapFromTemplate({ b: createResolvedModule("b.ts"), c: undefined })); + checkResolvedModulesCache(program4, "a.ts", new Map(getEntries({ b: createResolvedModule("b.ts"), c: undefined }))); }); it("set the resolvedImports after re-using an ambient external module declaration", () => { @@ -418,7 +418,7 @@ namespace ts { const options: CompilerOptions = { target, typeRoots: ["/types"] }; const program1 = newProgram(files, ["/a.ts"], options); - checkResolvedTypeDirectivesCache(program1, "/a.ts", createMapFromTemplate({ typedefs: { resolvedFileName: "/types/typedefs/index.d.ts", primary: true } })); + checkResolvedTypeDirectivesCache(program1, "/a.ts", new Map(getEntries({ typedefs: { resolvedFileName: "/types/typedefs/index.d.ts", primary: true } }))); checkResolvedTypeDirectivesCache(program1, "/types/typedefs/index.d.ts", /*expectedContent*/ undefined); const program2 = updateProgram(program1, ["/a.ts"], options, files => { @@ -427,7 +427,7 @@ namespace ts { assert.equal(program1.structureIsReused, StructureIsReused.Completely); // content of resolution cache should not change - checkResolvedTypeDirectivesCache(program1, "/a.ts", createMapFromTemplate({ typedefs: { resolvedFileName: "/types/typedefs/index.d.ts", primary: true } })); + checkResolvedTypeDirectivesCache(program1, "/a.ts", new Map(getEntries({ typedefs: { resolvedFileName: "/types/typedefs/index.d.ts", primary: true } }))); checkResolvedTypeDirectivesCache(program1, "/types/typedefs/index.d.ts", /*expectedContent*/ undefined); // type reference directives has changed - program is not reused @@ -445,7 +445,7 @@ namespace ts { files[0].text = files[0].text.updateReferences(newReferences); }); assert.equal(program3.structureIsReused, StructureIsReused.SafeModules); - checkResolvedTypeDirectivesCache(program1, "/a.ts", createMapFromTemplate({ typedefs: { resolvedFileName: "/types/typedefs/index.d.ts", primary: true } })); + checkResolvedTypeDirectivesCache(program1, "/a.ts", new Map(getEntries({ typedefs: { resolvedFileName: "/types/typedefs/index.d.ts", primary: true } }))); }); it("fetches imports after npm install", () => { diff --git a/src/testRunner/unittests/services/extract/helpers.ts b/src/testRunner/unittests/services/extract/helpers.ts index b4c61cccac2..9e86a96c617 100644 --- a/src/testRunner/unittests/services/extract/helpers.ts +++ b/src/testRunner/unittests/services/extract/helpers.ts @@ -15,7 +15,7 @@ namespace ts { let text = ""; let lastPos = 0; let pos = 0; - const ranges = createMap(); + const ranges = new Map(); while (pos < source.length) { if (source.charCodeAt(pos) === CharacterCodes.openBracket && diff --git a/src/testRunner/unittests/services/languageService.ts b/src/testRunner/unittests/services/languageService.ts index 0cc4d1acd29..6aba1018062 100644 --- a/src/testRunner/unittests/services/languageService.ts +++ b/src/testRunner/unittests/services/languageService.ts @@ -86,7 +86,7 @@ export function Component(x: Config): any;` describe("detects program upto date correctly", () => { function verifyProgramUptoDate(useProjectVersion: boolean) { let projectVersion = "1"; - const files = createMap<{ version: string, text: string; }>(); + const files = new Map(); files.set("/project/root.ts", { version: "1", text: `import { foo } from "./other"` }); files.set("/project/other.ts", { version: "1", text: `export function foo() { }` }); files.set("/lib/lib.d.ts", { version: "1", text: projectSystem.libFile.content }); diff --git a/src/testRunner/unittests/tsbuild/sample.ts b/src/testRunner/unittests/tsbuild/sample.ts index 4550595ded2..42dc6eaef6d 100644 --- a/src/testRunner/unittests/tsbuild/sample.ts +++ b/src/testRunner/unittests/tsbuild/sample.ts @@ -316,7 +316,7 @@ namespace ts { tick(); appendText(fs, "/src/logic/index.ts", "function foo() {}"); const originalWriteFile = fs.writeFileSync; - const writtenFiles = createMap(); + const writtenFiles = new Map(); fs.writeFileSync = (path, data, encoding) => { writtenFiles.set(path, true); originalWriteFile.call(fs, path, data, encoding); diff --git a/src/testRunner/unittests/tscWatch/watchEnvironment.ts b/src/testRunner/unittests/tscWatch/watchEnvironment.ts index 20dabc41947..ff33daefa30 100644 --- a/src/testRunner/unittests/tscWatch/watchEnvironment.ts +++ b/src/testRunner/unittests/tscWatch/watchEnvironment.ts @@ -12,7 +12,7 @@ namespace ts.tscWatch { path: `${projectFolder}/typescript.ts`, content: "var z = 10;" }; - const environmentVariables = createMap(); + const environmentVariables = new Map(); environmentVariables.set("TSC_WATCHFILE", TestFSWithWatch.Tsc_WatchFile.DynamicPolling); return createWatchedSystem([file1, libFile], { environmentVariables }); }, @@ -88,7 +88,7 @@ namespace ts.tscWatch { commandLineArgs: ["--w", "-p", configFile.path], sys: () => { const files = [file, configFile, libFile]; - const environmentVariables = createMap(); + const environmentVariables = new Map(); environmentVariables.set("TSC_WATCHDIRECTORY", tscWatchDirectory); return createWatchedSystem(files, { environmentVariables }); }, @@ -156,7 +156,7 @@ namespace ts.tscWatch { symLink: `${cwd}/node_modules/a` }; const files = [libFile, file1, tsconfig, realA, realB, symLinkA, symLinkB, symLinkBInA, symLinkAInB]; - const environmentVariables = createMap(); + const environmentVariables = new Map(); environmentVariables.set("TSC_WATCHDIRECTORY", Tsc_WatchDirectory.NonRecursiveWatchDirectory); return createWatchedSystem(files, { environmentVariables, currentDirectory: cwd }); }, diff --git a/src/testRunner/unittests/tsserver/cachingFileSystemInformation.ts b/src/testRunner/unittests/tsserver/cachingFileSystemInformation.ts index 7b1c1c93248..e554ee4219c 100644 --- a/src/testRunner/unittests/tsserver/cachingFileSystemInformation.ts +++ b/src/testRunner/unittests/tsserver/cachingFileSystemInformation.ts @@ -204,7 +204,7 @@ namespace ts.projectSystem { } function getLocationsForDirectoryLookup() { - const result = createMap(); + const result = new Map(); forEachAncestorDirectory(getDirectoryPath(root.path), ancestor => { // To resolve modules result.set(ancestor, 2); diff --git a/src/testRunner/unittests/tsserver/events/projectUpdatedInBackground.ts b/src/testRunner/unittests/tsserver/events/projectUpdatedInBackground.ts index 918c817857c..0ac5ffdb5f5 100644 --- a/src/testRunner/unittests/tsserver/events/projectUpdatedInBackground.ts +++ b/src/testRunner/unittests/tsserver/events/projectUpdatedInBackground.ts @@ -2,7 +2,7 @@ namespace ts.projectSystem { describe("unittests:: tsserver:: events:: ProjectsUpdatedInBackground", () => { function verifyFiles(caption: string, actual: readonly string[], expected: readonly string[]) { assert.equal(actual.length, expected.length, `Incorrect number of ${caption}. Actual: ${actual} Expected: ${expected}`); - const seen = createMap(); + const seen = new Map(); forEach(actual, f => { assert.isFalse(seen.has(f), `${caption}: Found duplicate ${f}. Actual: ${actual} Expected: ${expected}`); seen.set(f, true); diff --git a/src/testRunner/unittests/tsserver/helpers.ts b/src/testRunner/unittests/tsserver/helpers.ts index b626603fc0a..c79eee0b422 100644 --- a/src/testRunner/unittests/tsserver/helpers.ts +++ b/src/testRunner/unittests/tsserver/helpers.ts @@ -101,7 +101,7 @@ namespace ts.projectSystem { readonly globalTypingsCacheLocation: string, throttleLimit: number, installTypingHost: server.ServerHost, - readonly typesRegistry = createMap>(), + readonly typesRegistry = new Map>(), log?: TI.Log) { super(installTypingHost, globalTypingsCacheLocation, TestFSWithWatch.safeList.path, customTypesMap.path, throttleLimit, log); } @@ -177,7 +177,7 @@ namespace ts.projectSystem { "ts2.6": "1.3.0", "ts2.7": "1.3.0" }; - const map = createMap>(); + const map = new Map>(); for (const l of list) { map.set(l, versionMap); } diff --git a/src/testRunner/unittests/tsserver/inferredProjects.ts b/src/testRunner/unittests/tsserver/inferredProjects.ts index 57689637dbd..8676e2a6279 100644 --- a/src/testRunner/unittests/tsserver/inferredProjects.ts +++ b/src/testRunner/unittests/tsserver/inferredProjects.ts @@ -365,8 +365,8 @@ namespace ts.projectSystem { const projectService = createProjectService(host); const originalSet = projectService.configuredProjects.set; const originalDelete = projectService.configuredProjects.delete; - const configuredCreated = createMap(); - const configuredRemoved = createMap(); + const configuredCreated = new Map(); + const configuredRemoved = new Map(); projectService.configuredProjects.set = (key, value) => { assert.isFalse(configuredCreated.has(key)); configuredCreated.set(key, true); diff --git a/src/testRunner/unittests/tsserver/resolutionCache.ts b/src/testRunner/unittests/tsserver/resolutionCache.ts index 73a2467aa21..7a88d42da05 100644 --- a/src/testRunner/unittests/tsserver/resolutionCache.ts +++ b/src/testRunner/unittests/tsserver/resolutionCache.ts @@ -551,7 +551,7 @@ namespace ts.projectSystem { } function verifyWatchesWithConfigFile(host: TestServerHost, files: File[], openFile: File, extraExpectedDirectories?: readonly string[]) { - const expectedRecursiveDirectories = arrayToSet([tscWatch.projectRoot, `${tscWatch.projectRoot}/${nodeModulesAtTypes}`, ...(extraExpectedDirectories || emptyArray)]); + const expectedRecursiveDirectories = new Set([tscWatch.projectRoot, `${tscWatch.projectRoot}/${nodeModulesAtTypes}`, ...(extraExpectedDirectories || emptyArray)]); checkWatchedFiles(host, mapDefined(files, f => { if (f === openFile) { return undefined; @@ -560,11 +560,11 @@ namespace ts.projectSystem { if (indexOfNodeModules === -1) { return f.path; } - expectedRecursiveDirectories.set(f.path.substr(0, indexOfNodeModules + "/node_modules".length), true); + expectedRecursiveDirectories.add(f.path.substr(0, indexOfNodeModules + "/node_modules".length)); return undefined; })); checkWatchedDirectories(host, [], /*recursive*/ false); - checkWatchedDirectories(host, arrayFrom(expectedRecursiveDirectories.keys()), /*recursive*/ true); + checkWatchedDirectories(host, arrayFrom(expectedRecursiveDirectories.values()), /*recursive*/ true); } describe("from files in same folder", () => { @@ -850,7 +850,7 @@ export const x = 10;` else { checkWatchedDirectoriesDetailed(host, [`${tscWatch.projectRoot}`, `${tscWatch.projectRoot}/src`], 1, /*recursive*/ false); // failed lookup for fs } - const expectedWatchedDirectories = createMap(); + const expectedWatchedDirectories = new Map(); expectedWatchedDirectories.set(`${tscWatch.projectRoot}/src`, 1); // Wild card expectedWatchedDirectories.set(`${tscWatch.projectRoot}/src/somefolder`, 1); // failedLookup for somefolder/module2 expectedWatchedDirectories.set(`${tscWatch.projectRoot}/src/node_modules`, 1); // failed lookup for somefolder/module2 diff --git a/src/testRunner/unittests/tsserver/session.ts b/src/testRunner/unittests/tsserver/session.ts index b41df99f4a2..7a144945340 100644 --- a/src/testRunner/unittests/tsserver/session.ts +++ b/src/testRunner/unittests/tsserver/session.ts @@ -621,7 +621,7 @@ namespace ts.server { private server: InProcSession | undefined; private seq = 0; private callbacks: ((resp: protocol.Response) => void)[] = []; - private eventHandlers = createMap<(args: any) => void>(); + private eventHandlers = new Map void>(); handle(msg: protocol.Message): void { if (msg.type === "response") { diff --git a/src/testRunner/unittests/tsserver/symLinks.ts b/src/testRunner/unittests/tsserver/symLinks.ts index 69c2f94c768..2320fc59593 100644 --- a/src/testRunner/unittests/tsserver/symLinks.ts +++ b/src/testRunner/unittests/tsserver/symLinks.ts @@ -188,7 +188,7 @@ new C();` if (!withPathMapping) { watchedDirectoriesWithResolvedModule.set(`${recognizersDateTime}/node_modules`, 1); // failed lookups } - const watchedDirectoriesWithUnresolvedModule = cloneMap(watchedDirectoriesWithResolvedModule); + const watchedDirectoriesWithUnresolvedModule = new Map(watchedDirectoriesWithResolvedModule); watchedDirectoriesWithUnresolvedModule.set(`${recognizersDateTime}/src`, 2); // wild card + failed lookups [`${recognizersDateTime}/node_modules`, ...(withPathMapping ? [recognizersText] : emptyArray), ...getNodeModuleDirectories(packages)].forEach(d => { watchedDirectoriesWithUnresolvedModule.set(d, 1); diff --git a/src/testRunner/unittests/tsserver/typingsInstaller.ts b/src/testRunner/unittests/tsserver/typingsInstaller.ts index 6016821e741..1ca1ce143a7 100644 --- a/src/testRunner/unittests/tsserver/typingsInstaller.ts +++ b/src/testRunner/unittests/tsserver/typingsInstaller.ts @@ -137,7 +137,7 @@ namespace ts.projectSystem { const p = configuredProjectAt(projectService, 0); checkProjectActualFiles(p, [file1.path, tsconfig.path]); - const expectedWatchedFiles = createMap(); + const expectedWatchedFiles = new Map(); expectedWatchedFiles.set(tsconfig.path, 1); // tsserver expectedWatchedFiles.set(libFile.path, 1); // tsserver expectedWatchedFiles.set(packageJson.path, 1); // typing installer @@ -145,7 +145,7 @@ namespace ts.projectSystem { checkWatchedDirectories(host, emptyArray, /*recursive*/ false); - const expectedWatchedDirectoriesRecursive = createMap(); + const expectedWatchedDirectoriesRecursive = new Map(); expectedWatchedDirectoriesRecursive.set("/a/b", 1); // wild card expectedWatchedDirectoriesRecursive.set("/a/b/node_modules/@types", 1); // type root watch expectedWatchedDirectoriesRecursive.set("/a/b/node_modules", 1); // TypingInstaller @@ -838,7 +838,7 @@ namespace ts.projectSystem { const p = configuredProjectAt(projectService, 0); checkProjectActualFiles(p, [app.path, jsconfig.path]); - const watchedFilesExpected = createMap(); + const watchedFilesExpected = new Map(); watchedFilesExpected.set(jsconfig.path, 1); // project files watchedFilesExpected.set(libFile.path, 1); // project files watchedFilesExpected.set(combinePaths(installer.globalTypingsCacheLocation, "package.json"), 1); @@ -1361,7 +1361,7 @@ namespace ts.projectSystem { content: "" }; - const safeList = createMapFromTemplate({ jquery: "jquery", chroma: "chroma-js" }); + const safeList = new Map(getEntries({ jquery: "jquery", chroma: "chroma-js" })); const host = createServerHost([app, jquery, chroma]); const logger = trackingLogger(); @@ -1381,7 +1381,7 @@ namespace ts.projectSystem { content: "" }; const host = createServerHost([f]); - const cache = createMap(); + const cache = new Map(); for (const name of JsTyping.nodeCoreModuleList) { const logger = trackingLogger(); @@ -1404,7 +1404,7 @@ namespace ts.projectSystem { content: "" }; const host = createServerHost([f, node]); - const cache = createMapFromTemplate({ node: { typingLocation: node.path, version: new Version("1.3.0") } }); + const cache = new Map(getEntries({ node: { typingLocation: node.path, version: new Version("1.3.0") } })); const registry = createTypesRegistry("node"); const logger = trackingLogger(); const result = JsTyping.discoverTypings(host, logger.log, [f.path], getDirectoryPath(f.path), emptySafeList, cache, { enable: true }, ["fs", "bar"], registry); @@ -1426,7 +1426,7 @@ namespace ts.projectSystem { content: "" }; const host = createServerHost([f, node]); - const cache = createMapFromTemplate({ node: { typingLocation: node.path, version: new Version("1.3.0") } }); + const cache = new Map(getEntries({ node: { typingLocation: node.path, version: new Version("1.3.0") } })); const logger = trackingLogger(); const result = JsTyping.discoverTypings(host, logger.log, [f.path], getDirectoryPath(f.path), emptySafeList, cache, { enable: true }, ["fs", "bar"], emptyMap); assert.deepEqual(logger.finish(), [ @@ -1451,7 +1451,7 @@ namespace ts.projectSystem { content: JSON.stringify({ name: "b" }), }; const host = createServerHost([app, a, b]); - const cache = createMap(); + const cache = new Map(); const logger = trackingLogger(); const result = JsTyping.discoverTypings(host, logger.log, [app.path], getDirectoryPath(app.path), emptySafeList, cache, { enable: true }, /*unresolvedImports*/ [], emptyMap); assert.deepEqual(logger.finish(), [ @@ -1482,10 +1482,10 @@ namespace ts.projectSystem { content: "export let y: number" }; const host = createServerHost([app]); - const cache = createMapFromTemplate({ + const cache = new Map(getEntries({ node: { typingLocation: node.path, version: new Version("1.3.0") }, commander: { typingLocation: commander.path, version: new Version("1.0.0") } - }); + })); const registry = createTypesRegistry("node", "commander"); const logger = trackingLogger(); const result = JsTyping.discoverTypings(host, logger.log, [app.path], getDirectoryPath(app.path), emptySafeList, cache, { enable: true }, ["http", "commander"], registry); @@ -1508,9 +1508,9 @@ namespace ts.projectSystem { content: "export let y: number" }; const host = createServerHost([app]); - const cache = createMapFromTemplate({ + const cache = new Map(getEntries({ node: { typingLocation: node.path, version: new Version("1.0.0") } - }); + })); const registry = createTypesRegistry("node"); registry.delete(`ts${versionMajorMinor}`); const logger = trackingLogger(); @@ -1539,10 +1539,10 @@ namespace ts.projectSystem { content: "export let y: number" }; const host = createServerHost([app]); - const cache = createMapFromTemplate({ + const cache = new Map(getEntries({ node: { typingLocation: node.path, version: new Version("1.3.0-next.0") }, commander: { typingLocation: commander.path, version: new Version("1.3.0-next.0") } - }); + })); const registry = createTypesRegistry("node", "commander"); registry.get("node")![`ts${versionMajorMinor}`] = "1.3.0-next.1"; const logger = trackingLogger(); diff --git a/src/testRunner/unittests/tsserver/watchEnvironment.ts b/src/testRunner/unittests/tsserver/watchEnvironment.ts index 1bda2884950..49fc0b237f6 100644 --- a/src/testRunner/unittests/tsserver/watchEnvironment.ts +++ b/src/testRunner/unittests/tsserver/watchEnvironment.ts @@ -25,12 +25,12 @@ namespace ts.projectSystem { const fileNames = files.map(file => file.path); // All closed files(files other than index), project folder, project/src folder and project/node_modules/@types folder const expectedWatchedFiles = arrayToMap(fileNames.slice(1), s => s, () => 1); - const expectedWatchedDirectories = createMap(); + const expectedWatchedDirectories = new Map(); const mapOfDirectories = tscWatchDirectory === Tsc_WatchDirectory.NonRecursiveWatchDirectory ? expectedWatchedDirectories : tscWatchDirectory === Tsc_WatchDirectory.WatchFile ? expectedWatchedFiles : - createMap(); + new Map(); // For failed resolution lookup and tsconfig files => cached so only watched only once mapOfDirectories.set(projectFolder, 1); // Through above recursive watches @@ -39,7 +39,7 @@ namespace ts.projectSystem { mapOfDirectories.set(`${projectFolder}/${nodeModulesAtTypes}`, 1); const expectedCompletions = ["file1"]; const completionPosition = index.content.lastIndexOf('"'); - const environmentVariables = createMap(); + const environmentVariables = new Map(); environmentVariables.set("TSC_WATCHDIRECTORY", tscWatchDirectory); const host = createServerHost(files, { environmentVariables }); const projectService = createProjectService(host); @@ -161,7 +161,7 @@ namespace ts.projectSystem { const expectedWatchedFiles = arrayToMap(fileNames.slice(1), identity, () => 1); const expectedWatchedDirectories = arrayToMap([projectFolder, projectSrcFolder, `${projectFolder}/${nodeModules}`, `${projectFolder}/${nodeModulesAtTypes}`], identity, () => 1); - const environmentVariables = createMap(); + const environmentVariables = new Map(); environmentVariables.set("TSC_WATCHDIRECTORY", Tsc_WatchDirectory.NonRecursiveWatchDirectory); const host = createServerHost([index, file1, configFile, libFile, nodeModulesExistingUnusedFile], { environmentVariables }); const projectService = createProjectService(host); diff --git a/src/tsserver/server.ts b/src/tsserver/server.ts index bf671e8cfeb..da0d9be9ddb 100644 --- a/src/tsserver/server.ts +++ b/src/tsserver/server.ts @@ -230,7 +230,7 @@ namespace ts.server { private projectService!: ProjectService; private activeRequestCount = 0; private requestQueue: QueuedOperation[] = []; - private requestMap = createMap(); // Maps operation ID to newest requestQueue entry with that ID + private requestMap = new Map(); // Maps operation ID to newest requestQueue entry with that ID /** We will lazily request the types registry on the first call to `isKnownTypesPackageName` and store it in `typesRegistryCache`. */ private requestedRegistry = false; private typesRegistryCache: ESMap> | undefined; @@ -374,7 +374,7 @@ namespace ts.server { switch (response.kind) { case EventTypesRegistry: - this.typesRegistryCache = createMapFromTemplate(response.typesRegistry); + this.typesRegistryCache = new Map(getEntries(response.typesRegistry)); break; case ActionPackageInstalled: { const { success, message } = response; @@ -838,7 +838,7 @@ namespace ts.server { if (useWatchGuard) { const currentDrive = extractWatchDirectoryCacheKey(sys.resolvePath(sys.getCurrentDirectory()), /*currentDriveKey*/ undefined); - const statusCache = createMap(); + const statusCache = new Map(); sys.watchDirectory = (path, callback, recursive, options) => { const cacheKey = extractWatchDirectoryCacheKey(path, currentDrive); let status = cacheKey && statusCache.get(cacheKey); diff --git a/src/typingsInstaller/nodeTypingsInstaller.ts b/src/typingsInstaller/nodeTypingsInstaller.ts index c2ac253dd01..9645471e16f 100644 --- a/src/typingsInstaller/nodeTypingsInstaller.ts +++ b/src/typingsInstaller/nodeTypingsInstaller.ts @@ -51,17 +51,17 @@ namespace ts.server.typingsInstaller { if (log.isEnabled()) { log.writeLine(`Types registry file '${typesRegistryFilePath}' does not exist`); } - return createMap>(); + return new Map>(); } try { const content = JSON.parse(host.readFile(typesRegistryFilePath)!); - return createMapFromTemplate(content.entries); + return new Map(getEntries(content.entries)); } catch (e) { if (log.isEnabled()) { log.writeLine(`Error when loading types registry file '${typesRegistryFilePath}': ${(e).message}, ${(e).stack}`); } - return createMap>(); + return new Map>(); } } diff --git a/src/typingsInstallerCore/typingsInstaller.ts b/src/typingsInstallerCore/typingsInstaller.ts index 9be34114469..7966a78e467 100644 --- a/src/typingsInstallerCore/typingsInstaller.ts +++ b/src/typingsInstallerCore/typingsInstaller.ts @@ -87,10 +87,10 @@ namespace ts.server.typingsInstaller { type ProjectWatchers = ESMap & { isInvoked?: boolean; }; export abstract class TypingsInstaller { - private readonly packageNameToTypingLocation: ESMap = createMap(); + private readonly packageNameToTypingLocation = new Map(); private readonly missingTypingsSet = new Set(); private readonly knownCachesSet = new Set(); - private readonly projectWatchers = createMap(); + private readonly projectWatchers = new Map(); private safeList: JsTyping.SafeList | undefined; readonly pendingRunRequests: PendingRequest[] = []; private readonly toCanonicalFileName: GetCanonicalFileName; @@ -407,9 +407,9 @@ namespace ts.server.typingsInstaller { } let watchers = this.projectWatchers.get(projectName)!; - const toRemove = createMap(); + const toRemove = new Map(); if (!watchers) { - watchers = createMap(); + watchers = new Map(); this.projectWatchers.set(projectName, watchers); } else { diff --git a/tests/baselines/reference/ExportClassWithAccessibleTypesInTypeParameterConstraintsClassHeritageListMemberTypeAnnotations.js b/tests/baselines/reference/ExportClassWithAccessibleTypesInTypeParameterConstraintsClassHeritageListMemberTypeAnnotations.js index 9074e2ad4c8..9a16ee2710f 100644 --- a/tests/baselines/reference/ExportClassWithAccessibleTypesInTypeParameterConstraintsClassHeritageListMemberTypeAnnotations.js +++ b/tests/baselines/reference/ExportClassWithAccessibleTypesInTypeParameterConstraintsClassHeritageListMemberTypeAnnotations.js @@ -25,7 +25,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/ExportClassWithInaccessibleTypeInTypeParameterConstraint.js b/tests/baselines/reference/ExportClassWithInaccessibleTypeInTypeParameterConstraint.js index 7ffab769794..abb2205edc3 100644 --- a/tests/baselines/reference/ExportClassWithInaccessibleTypeInTypeParameterConstraint.js +++ b/tests/baselines/reference/ExportClassWithInaccessibleTypeInTypeParameterConstraint.js @@ -29,7 +29,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/abstractClassInLocalScope.js b/tests/baselines/reference/abstractClassInLocalScope.js index 4e7b9f87095..5c62cb66989 100644 --- a/tests/baselines/reference/abstractClassInLocalScope.js +++ b/tests/baselines/reference/abstractClassInLocalScope.js @@ -12,7 +12,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/abstractClassInLocalScopeIsAbstract.js b/tests/baselines/reference/abstractClassInLocalScopeIsAbstract.js index 60af14e625b..31ebc0a500b 100644 --- a/tests/baselines/reference/abstractClassInLocalScopeIsAbstract.js +++ b/tests/baselines/reference/abstractClassInLocalScopeIsAbstract.js @@ -12,7 +12,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/abstractProperty.js b/tests/baselines/reference/abstractProperty.js index 5fc7f19d7c6..1642b178b85 100644 --- a/tests/baselines/reference/abstractProperty.js +++ b/tests/baselines/reference/abstractProperty.js @@ -26,7 +26,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/abstractPropertyInConstructor.js b/tests/baselines/reference/abstractPropertyInConstructor.js index ab830664d51..91ec9dcd8cd 100644 --- a/tests/baselines/reference/abstractPropertyInConstructor.js +++ b/tests/baselines/reference/abstractPropertyInConstructor.js @@ -76,7 +76,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/abstractPropertyNegative.js b/tests/baselines/reference/abstractPropertyNegative.js index a26369108ab..ef0fbda7b13 100644 --- a/tests/baselines/reference/abstractPropertyNegative.js +++ b/tests/baselines/reference/abstractPropertyNegative.js @@ -48,7 +48,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/accessOverriddenBaseClassMember1.js b/tests/baselines/reference/accessOverriddenBaseClassMember1.js index 6512ba01d67..71c716ea90c 100644 --- a/tests/baselines/reference/accessOverriddenBaseClassMember1.js +++ b/tests/baselines/reference/accessOverriddenBaseClassMember1.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/accessorsOverrideProperty7.js b/tests/baselines/reference/accessorsOverrideProperty7.js index 938bae03374..206f8611b7f 100644 --- a/tests/baselines/reference/accessorsOverrideProperty7.js +++ b/tests/baselines/reference/accessorsOverrideProperty7.js @@ -12,7 +12,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/accessors_spec_section-4.5_inference.js b/tests/baselines/reference/accessors_spec_section-4.5_inference.js index 9d0a9689e05..04990fef32c 100644 --- a/tests/baselines/reference/accessors_spec_section-4.5_inference.js +++ b/tests/baselines/reference/accessors_spec_section-4.5_inference.js @@ -29,7 +29,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/aliasUsageInAccessorsOfClass.js b/tests/baselines/reference/aliasUsageInAccessorsOfClass.js index 8f9b50367df..e420dcd7e42 100644 --- a/tests/baselines/reference/aliasUsageInAccessorsOfClass.js +++ b/tests/baselines/reference/aliasUsageInAccessorsOfClass.js @@ -43,7 +43,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/aliasUsageInArray.js b/tests/baselines/reference/aliasUsageInArray.js index 5c695af5101..931d7db6a2b 100644 --- a/tests/baselines/reference/aliasUsageInArray.js +++ b/tests/baselines/reference/aliasUsageInArray.js @@ -37,7 +37,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/aliasUsageInFunctionExpression.js b/tests/baselines/reference/aliasUsageInFunctionExpression.js index d47b38d7122..eab1cc78bb9 100644 --- a/tests/baselines/reference/aliasUsageInFunctionExpression.js +++ b/tests/baselines/reference/aliasUsageInFunctionExpression.js @@ -36,7 +36,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/aliasUsageInGenericFunction.js b/tests/baselines/reference/aliasUsageInGenericFunction.js index 27e4106b46e..e779d6a3fbf 100644 --- a/tests/baselines/reference/aliasUsageInGenericFunction.js +++ b/tests/baselines/reference/aliasUsageInGenericFunction.js @@ -40,7 +40,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/aliasUsageInIndexerOfClass.js b/tests/baselines/reference/aliasUsageInIndexerOfClass.js index 847bc0fcb0a..aacdf66057d 100644 --- a/tests/baselines/reference/aliasUsageInIndexerOfClass.js +++ b/tests/baselines/reference/aliasUsageInIndexerOfClass.js @@ -42,7 +42,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/aliasUsageInObjectLiteral.js b/tests/baselines/reference/aliasUsageInObjectLiteral.js index b2a06fc061a..4145c43e57c 100644 --- a/tests/baselines/reference/aliasUsageInObjectLiteral.js +++ b/tests/baselines/reference/aliasUsageInObjectLiteral.js @@ -37,7 +37,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/aliasUsageInOrExpression.js b/tests/baselines/reference/aliasUsageInOrExpression.js index d65977dd09e..7f00fd85833 100644 --- a/tests/baselines/reference/aliasUsageInOrExpression.js +++ b/tests/baselines/reference/aliasUsageInOrExpression.js @@ -40,7 +40,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/aliasUsageInTypeArgumentOfExtendsClause.js b/tests/baselines/reference/aliasUsageInTypeArgumentOfExtendsClause.js index fa5fa26384d..e8232242735 100644 --- a/tests/baselines/reference/aliasUsageInTypeArgumentOfExtendsClause.js +++ b/tests/baselines/reference/aliasUsageInTypeArgumentOfExtendsClause.js @@ -40,7 +40,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { @@ -66,7 +66,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/aliasUsageInVarAssignment.js b/tests/baselines/reference/aliasUsageInVarAssignment.js index 2d570d3cccc..bf0ce68a056 100644 --- a/tests/baselines/reference/aliasUsageInVarAssignment.js +++ b/tests/baselines/reference/aliasUsageInVarAssignment.js @@ -36,7 +36,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/ambientShorthand_reExport.js b/tests/baselines/reference/ambientShorthand_reExport.js index 426b2a0d63c..03117f531ae 100644 --- a/tests/baselines/reference/ambientShorthand_reExport.js +++ b/tests/baselines/reference/ambientShorthand_reExport.js @@ -39,7 +39,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("jquery"), exports); diff --git a/tests/baselines/reference/ambiguousOverloadResolution.js b/tests/baselines/reference/ambiguousOverloadResolution.js index 56bef268fb4..0ae9d9238e1 100644 --- a/tests/baselines/reference/ambiguousOverloadResolution.js +++ b/tests/baselines/reference/ambiguousOverloadResolution.js @@ -13,7 +13,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/amdDeclarationEmitNoExtraDeclare.js b/tests/baselines/reference/amdDeclarationEmitNoExtraDeclare.js index f8f25a4e1aa..8670fbe53fb 100644 --- a/tests/baselines/reference/amdDeclarationEmitNoExtraDeclare.js +++ b/tests/baselines/reference/amdDeclarationEmitNoExtraDeclare.js @@ -26,7 +26,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/anonClassDeclarationEmitIsAnon.js b/tests/baselines/reference/anonClassDeclarationEmitIsAnon.js index 50090286ffa..e7ec768f681 100644 --- a/tests/baselines/reference/anonClassDeclarationEmitIsAnon.js +++ b/tests/baselines/reference/anonClassDeclarationEmitIsAnon.js @@ -40,7 +40,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { @@ -80,7 +80,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/anonymousClassDeclarationDoesntPrintWithReadonly.js b/tests/baselines/reference/anonymousClassDeclarationDoesntPrintWithReadonly.js index 606f33724d0..69c7cf836ab 100644 --- a/tests/baselines/reference/anonymousClassDeclarationDoesntPrintWithReadonly.js +++ b/tests/baselines/reference/anonymousClassDeclarationDoesntPrintWithReadonly.js @@ -13,7 +13,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/api/tsserverlibrary.d.ts b/tests/baselines/reference/api/tsserverlibrary.d.ts index 83b03093da4..c0a87752b8c 100644 --- a/tests/baselines/reference/api/tsserverlibrary.d.ts +++ b/tests/baselines/reference/api/tsserverlibrary.d.ts @@ -51,7 +51,6 @@ declare namespace ts { } /** * ES6 Map interface, only read methods included. - * @deprecated Use `ts.ReadonlyESMap` instead. */ interface ReadonlyMap extends ReadonlyESMap { } @@ -61,7 +60,6 @@ declare namespace ts { } /** * ES6 Map interface. - * @deprecated Use `ts.ESMap` instead. */ interface Map extends ESMap { } @@ -2232,6 +2230,7 @@ declare namespace ts { UseAliasDefinedOutsideCurrentScope = 16384, UseSingleQuotesForStringLiteralType = 268435456, NoTypeReduction = 536870912, + NoUndefinedOptionalParameterType = 1073741824, AllowThisInObjectLiteral = 32768, AllowQualifedNameInPlaceOfIdentifier = 65536, AllowAnonymousIdentifier = 131072, @@ -10672,6 +10671,16 @@ declare namespace ts { const getMutableClone: (node: T) => T; /** @deprecated Use `isTypeAssertionExpression` instead. */ const isTypeAssertion: (node: Node) => node is TypeAssertion; + /** + * @deprecated Use `ts.ReadonlyESMap` instead. + */ + interface ReadonlyMap extends ReadonlyESMap { + } + /** + * @deprecated Use `ts.ESMap` instead. + */ + interface Map extends ESMap { + } } export = ts; diff --git a/tests/baselines/reference/api/typescript.d.ts b/tests/baselines/reference/api/typescript.d.ts index e85e4a8bf70..9a549e1ffa4 100644 --- a/tests/baselines/reference/api/typescript.d.ts +++ b/tests/baselines/reference/api/typescript.d.ts @@ -51,7 +51,6 @@ declare namespace ts { } /** * ES6 Map interface, only read methods included. - * @deprecated Use `ts.ReadonlyESMap` instead. */ interface ReadonlyMap extends ReadonlyESMap { } @@ -61,7 +60,6 @@ declare namespace ts { } /** * ES6 Map interface. - * @deprecated Use `ts.ESMap` instead. */ interface Map extends ESMap { } @@ -2232,6 +2230,7 @@ declare namespace ts { UseAliasDefinedOutsideCurrentScope = 16384, UseSingleQuotesForStringLiteralType = 268435456, NoTypeReduction = 536870912, + NoUndefinedOptionalParameterType = 1073741824, AllowThisInObjectLiteral = 32768, AllowQualifedNameInPlaceOfIdentifier = 65536, AllowAnonymousIdentifier = 131072, @@ -7092,6 +7091,16 @@ declare namespace ts { const getMutableClone: (node: T) => T; /** @deprecated Use `isTypeAssertionExpression` instead. */ const isTypeAssertion: (node: Node) => node is TypeAssertion; + /** + * @deprecated Use `ts.ReadonlyESMap` instead. + */ + interface ReadonlyMap extends ReadonlyESMap { + } + /** + * @deprecated Use `ts.ESMap` instead. + */ + interface Map extends ESMap { + } } export = ts; \ No newline at end of file diff --git a/tests/baselines/reference/apparentTypeSubtyping.js b/tests/baselines/reference/apparentTypeSubtyping.js index 2e9987f1e0d..3dc0f8dffc8 100644 --- a/tests/baselines/reference/apparentTypeSubtyping.js +++ b/tests/baselines/reference/apparentTypeSubtyping.js @@ -28,7 +28,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/apparentTypeSupertype.js b/tests/baselines/reference/apparentTypeSupertype.js index 82443d22197..45c0b8e488b 100644 --- a/tests/baselines/reference/apparentTypeSupertype.js +++ b/tests/baselines/reference/apparentTypeSupertype.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/arrayAssignmentTest1.js b/tests/baselines/reference/arrayAssignmentTest1.js index baf1e8bfa3a..339589030e1 100644 --- a/tests/baselines/reference/arrayAssignmentTest1.js +++ b/tests/baselines/reference/arrayAssignmentTest1.js @@ -90,7 +90,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/arrayAssignmentTest2.js b/tests/baselines/reference/arrayAssignmentTest2.js index 5b1a655d781..43a293fb23a 100644 --- a/tests/baselines/reference/arrayAssignmentTest2.js +++ b/tests/baselines/reference/arrayAssignmentTest2.js @@ -64,7 +64,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/arrayBestCommonTypes.js b/tests/baselines/reference/arrayBestCommonTypes.js index 7b8da4f7970..53368bfc1e6 100644 --- a/tests/baselines/reference/arrayBestCommonTypes.js +++ b/tests/baselines/reference/arrayBestCommonTypes.js @@ -112,7 +112,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/arrayLiteralTypeInference.js b/tests/baselines/reference/arrayLiteralTypeInference.js index fcd8a62ce0b..7349a604470 100644 --- a/tests/baselines/reference/arrayLiteralTypeInference.js +++ b/tests/baselines/reference/arrayLiteralTypeInference.js @@ -56,7 +56,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/arrayLiterals.js b/tests/baselines/reference/arrayLiterals.js index c4d257dd546..a832a921d5a 100644 --- a/tests/baselines/reference/arrayLiterals.js +++ b/tests/baselines/reference/arrayLiterals.js @@ -42,7 +42,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/arrayLiteralsWithRecursiveGenerics.js b/tests/baselines/reference/arrayLiteralsWithRecursiveGenerics.js index 25a76bec5c7..6c210c9fcf9 100644 --- a/tests/baselines/reference/arrayLiteralsWithRecursiveGenerics.js +++ b/tests/baselines/reference/arrayLiteralsWithRecursiveGenerics.js @@ -30,7 +30,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/arrayOfSubtypeIsAssignableToReadonlyArray.js b/tests/baselines/reference/arrayOfSubtypeIsAssignableToReadonlyArray.js index 45b587c0e62..984f5e693b6 100644 --- a/tests/baselines/reference/arrayOfSubtypeIsAssignableToReadonlyArray.js +++ b/tests/baselines/reference/arrayOfSubtypeIsAssignableToReadonlyArray.js @@ -24,7 +24,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/arrowFunctionContexts.js b/tests/baselines/reference/arrowFunctionContexts.js index 466131ea206..223d1270228 100644 --- a/tests/baselines/reference/arrowFunctionContexts.js +++ b/tests/baselines/reference/arrowFunctionContexts.js @@ -100,7 +100,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/assertionTypePredicates1.js b/tests/baselines/reference/assertionTypePredicates1.js index 24afd9f6644..3f8b4d3ec9c 100644 --- a/tests/baselines/reference/assertionTypePredicates1.js +++ b/tests/baselines/reference/assertionTypePredicates1.js @@ -202,7 +202,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/assignmentCompatWithCallSignatures3.js b/tests/baselines/reference/assignmentCompatWithCallSignatures3.js index a051b4e5194..b4a9b5bc4cf 100644 --- a/tests/baselines/reference/assignmentCompatWithCallSignatures3.js +++ b/tests/baselines/reference/assignmentCompatWithCallSignatures3.js @@ -105,7 +105,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/assignmentCompatWithCallSignatures4.js b/tests/baselines/reference/assignmentCompatWithCallSignatures4.js index fc83877023b..3bc0af841ab 100644 --- a/tests/baselines/reference/assignmentCompatWithCallSignatures4.js +++ b/tests/baselines/reference/assignmentCompatWithCallSignatures4.js @@ -104,7 +104,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/assignmentCompatWithCallSignatures5.js b/tests/baselines/reference/assignmentCompatWithCallSignatures5.js index fb6d0be1be1..0c546cde84c 100644 --- a/tests/baselines/reference/assignmentCompatWithCallSignatures5.js +++ b/tests/baselines/reference/assignmentCompatWithCallSignatures5.js @@ -71,7 +71,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/assignmentCompatWithCallSignatures6.js b/tests/baselines/reference/assignmentCompatWithCallSignatures6.js index 9e752a43a17..8e7ff3c057b 100644 --- a/tests/baselines/reference/assignmentCompatWithCallSignatures6.js +++ b/tests/baselines/reference/assignmentCompatWithCallSignatures6.js @@ -48,7 +48,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/assignmentCompatWithConstructSignatures3.js b/tests/baselines/reference/assignmentCompatWithConstructSignatures3.js index 932f9bb5d66..8cdbc17f88c 100644 --- a/tests/baselines/reference/assignmentCompatWithConstructSignatures3.js +++ b/tests/baselines/reference/assignmentCompatWithConstructSignatures3.js @@ -105,7 +105,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/assignmentCompatWithConstructSignatures4.js b/tests/baselines/reference/assignmentCompatWithConstructSignatures4.js index 4dad18cea8f..e2cc9e997e6 100644 --- a/tests/baselines/reference/assignmentCompatWithConstructSignatures4.js +++ b/tests/baselines/reference/assignmentCompatWithConstructSignatures4.js @@ -104,7 +104,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/assignmentCompatWithConstructSignatures5.js b/tests/baselines/reference/assignmentCompatWithConstructSignatures5.js index 5f16895caf2..966f76e2a9d 100644 --- a/tests/baselines/reference/assignmentCompatWithConstructSignatures5.js +++ b/tests/baselines/reference/assignmentCompatWithConstructSignatures5.js @@ -71,7 +71,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/assignmentCompatWithConstructSignatures6.js b/tests/baselines/reference/assignmentCompatWithConstructSignatures6.js index dfce487fff1..4d381ca543a 100644 --- a/tests/baselines/reference/assignmentCompatWithConstructSignatures6.js +++ b/tests/baselines/reference/assignmentCompatWithConstructSignatures6.js @@ -48,7 +48,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/assignmentCompatWithNumericIndexer.js b/tests/baselines/reference/assignmentCompatWithNumericIndexer.js index 6cdab6f3bed..95db5f72f56 100644 --- a/tests/baselines/reference/assignmentCompatWithNumericIndexer.js +++ b/tests/baselines/reference/assignmentCompatWithNumericIndexer.js @@ -49,7 +49,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/assignmentCompatWithNumericIndexer3.js b/tests/baselines/reference/assignmentCompatWithNumericIndexer3.js index 54eb5e3ac9b..984cbdf4875 100644 --- a/tests/baselines/reference/assignmentCompatWithNumericIndexer3.js +++ b/tests/baselines/reference/assignmentCompatWithNumericIndexer3.js @@ -46,7 +46,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/assignmentCompatWithObjectMembers4.js b/tests/baselines/reference/assignmentCompatWithObjectMembers4.js index dd8d9d1bf46..831d6f245b3 100644 --- a/tests/baselines/reference/assignmentCompatWithObjectMembers4.js +++ b/tests/baselines/reference/assignmentCompatWithObjectMembers4.js @@ -97,7 +97,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/assignmentCompatWithObjectMembersOptionality.js b/tests/baselines/reference/assignmentCompatWithObjectMembersOptionality.js index fa8ca3f7ad8..10964ff61c5 100644 --- a/tests/baselines/reference/assignmentCompatWithObjectMembersOptionality.js +++ b/tests/baselines/reference/assignmentCompatWithObjectMembersOptionality.js @@ -94,7 +94,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/assignmentCompatWithObjectMembersOptionality2.js b/tests/baselines/reference/assignmentCompatWithObjectMembersOptionality2.js index 918c2739ace..bc5bff6b203 100644 --- a/tests/baselines/reference/assignmentCompatWithObjectMembersOptionality2.js +++ b/tests/baselines/reference/assignmentCompatWithObjectMembersOptionality2.js @@ -97,7 +97,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/assignmentCompatWithStringIndexer.js b/tests/baselines/reference/assignmentCompatWithStringIndexer.js index 9a67a00bac0..fa9eb5cec0b 100644 --- a/tests/baselines/reference/assignmentCompatWithStringIndexer.js +++ b/tests/baselines/reference/assignmentCompatWithStringIndexer.js @@ -59,7 +59,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/assignmentLHSIsValue.js b/tests/baselines/reference/assignmentLHSIsValue.js index dd7f28cb003..363a9dfb0c2 100644 --- a/tests/baselines/reference/assignmentLHSIsValue.js +++ b/tests/baselines/reference/assignmentLHSIsValue.js @@ -75,7 +75,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/assignmentToVoidZero2.errors.txt b/tests/baselines/reference/assignmentToVoidZero2.errors.txt index b9da759c092..b6e30bda5c9 100644 --- a/tests/baselines/reference/assignmentToVoidZero2.errors.txt +++ b/tests/baselines/reference/assignmentToVoidZero2.errors.txt @@ -1,11 +1,12 @@ tests/cases/conformance/salsa/assignmentToVoidZero2.js(2,9): error TS2339: Property 'k' does not exist on type 'typeof import("tests/cases/conformance/salsa/assignmentToVoidZero2")'. tests/cases/conformance/salsa/assignmentToVoidZero2.js(5,3): error TS2339: Property 'y' does not exist on type 'typeof o'. tests/cases/conformance/salsa/assignmentToVoidZero2.js(6,9): error TS2339: Property 'y' does not exist on type 'typeof o'. +tests/cases/conformance/salsa/assignmentToVoidZero2.js(10,10): error TS2339: Property 'q' does not exist on type 'C'. tests/cases/conformance/salsa/assignmentToVoidZero2.js(13,9): error TS2339: Property 'q' does not exist on type 'C'. tests/cases/conformance/salsa/importer.js(1,13): error TS2305: Module '"./assignmentToVoidZero2"' has no exported member 'k'. -==== tests/cases/conformance/salsa/assignmentToVoidZero2.js (4 errors) ==== +==== tests/cases/conformance/salsa/assignmentToVoidZero2.js (5 errors) ==== exports.j = 1; exports.k = void 0; ~ @@ -22,6 +23,8 @@ tests/cases/conformance/salsa/importer.js(1,13): error TS2305: Module '"./assign function C() { this.p = 1 this.q = void 0 + ~ +!!! error TS2339: Property 'q' does not exist on type 'C'. } var c = new C() c.p + c.q diff --git a/tests/baselines/reference/assignmentToVoidZero2.symbols b/tests/baselines/reference/assignmentToVoidZero2.symbols index b5a93872fa8..cbb59820234 100644 --- a/tests/baselines/reference/assignmentToVoidZero2.symbols +++ b/tests/baselines/reference/assignmentToVoidZero2.symbols @@ -28,9 +28,12 @@ function C() { >C : Symbol(C, Decl(assignmentToVoidZero2.js, 5, 9)) this.p = 1 +>this.p : Symbol(C.p, Decl(assignmentToVoidZero2.js, 7, 14)) +>this : Symbol(C, Decl(assignmentToVoidZero2.js, 5, 9)) >p : Symbol(C.p, Decl(assignmentToVoidZero2.js, 7, 14)) this.q = void 0 +>this : Symbol(C, Decl(assignmentToVoidZero2.js, 5, 9)) } var c = new C() >c : Symbol(c, Decl(assignmentToVoidZero2.js, 11, 3)) diff --git a/tests/baselines/reference/assignmentToVoidZero2.types b/tests/baselines/reference/assignmentToVoidZero2.types index 0b24811f957..e67f0ce8302 100644 --- a/tests/baselines/reference/assignmentToVoidZero2.types +++ b/tests/baselines/reference/assignmentToVoidZero2.types @@ -48,14 +48,14 @@ function C() { this.p = 1 >this.p = 1 : 1 >this.p : any ->this : any +>this : this >p : any >1 : 1 this.q = void 0 >this.q = void 0 : undefined >this.q : any ->this : any +>this : this >q : any >void 0 : undefined >0 : 0 diff --git a/tests/baselines/reference/asyncImportedPromise_es5.js b/tests/baselines/reference/asyncImportedPromise_es5.js index 7e8b5990238..d399d836b1c 100644 --- a/tests/baselines/reference/asyncImportedPromise_es5.js +++ b/tests/baselines/reference/asyncImportedPromise_es5.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/autolift4.js b/tests/baselines/reference/autolift4.js index 53ce6dc9dc3..c2fa9f2cc9a 100644 --- a/tests/baselines/reference/autolift4.js +++ b/tests/baselines/reference/autolift4.js @@ -28,7 +28,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/baseCheck.js b/tests/baselines/reference/baseCheck.js index 114bbf655e4..f036f533040 100644 --- a/tests/baselines/reference/baseCheck.js +++ b/tests/baselines/reference/baseCheck.js @@ -34,7 +34,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/baseClassImprovedMismatchErrors.js b/tests/baselines/reference/baseClassImprovedMismatchErrors.js index 2b864807570..2b19c56d311 100644 --- a/tests/baselines/reference/baseClassImprovedMismatchErrors.js +++ b/tests/baselines/reference/baseClassImprovedMismatchErrors.js @@ -23,7 +23,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/baseConstraintOfDecorator.js b/tests/baselines/reference/baseConstraintOfDecorator.js index 8b496c83a03..8f4413b7547 100644 --- a/tests/baselines/reference/baseConstraintOfDecorator.js +++ b/tests/baselines/reference/baseConstraintOfDecorator.js @@ -25,7 +25,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/baseExpressionTypeParameters.js b/tests/baselines/reference/baseExpressionTypeParameters.js index aa16fcebf55..a2f9b45b688 100644 --- a/tests/baselines/reference/baseExpressionTypeParameters.js +++ b/tests/baselines/reference/baseExpressionTypeParameters.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/baseIndexSignatureResolution.js b/tests/baselines/reference/baseIndexSignatureResolution.js index 09aabe21ac4..abf5b620627 100644 --- a/tests/baselines/reference/baseIndexSignatureResolution.js +++ b/tests/baselines/reference/baseIndexSignatureResolution.js @@ -29,7 +29,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/baseTypeOrderChecking.js b/tests/baselines/reference/baseTypeOrderChecking.js index 31fa3391af5..955816d3d86 100644 --- a/tests/baselines/reference/baseTypeOrderChecking.js +++ b/tests/baselines/reference/baseTypeOrderChecking.js @@ -41,7 +41,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/baseTypeWrappingInstantiationChain.js b/tests/baselines/reference/baseTypeWrappingInstantiationChain.js index de50a58205d..260d296d9e5 100644 --- a/tests/baselines/reference/baseTypeWrappingInstantiationChain.js +++ b/tests/baselines/reference/baseTypeWrappingInstantiationChain.js @@ -32,7 +32,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/bases.js b/tests/baselines/reference/bases.js index 25cf4073d5c..2a753743434 100644 --- a/tests/baselines/reference/bases.js +++ b/tests/baselines/reference/bases.js @@ -25,7 +25,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/bestCommonTypeOfConditionalExpressions.js b/tests/baselines/reference/bestCommonTypeOfConditionalExpressions.js index b755bf200a5..0d5754c2240 100644 --- a/tests/baselines/reference/bestCommonTypeOfConditionalExpressions.js +++ b/tests/baselines/reference/bestCommonTypeOfConditionalExpressions.js @@ -33,7 +33,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/bestCommonTypeOfConditionalExpressions2.js b/tests/baselines/reference/bestCommonTypeOfConditionalExpressions2.js index b7afc3eee41..3a5fd197fc9 100644 --- a/tests/baselines/reference/bestCommonTypeOfConditionalExpressions2.js +++ b/tests/baselines/reference/bestCommonTypeOfConditionalExpressions2.js @@ -31,7 +31,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/bestCommonTypeOfTuple2.js b/tests/baselines/reference/bestCommonTypeOfTuple2.js index a3672a76423..d44a43674e8 100644 --- a/tests/baselines/reference/bestCommonTypeOfTuple2.js +++ b/tests/baselines/reference/bestCommonTypeOfTuple2.js @@ -27,7 +27,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/callChainWithSuper(target=es5).js b/tests/baselines/reference/callChainWithSuper(target=es5).js index 5487991bc29..e4f387b0404 100644 --- a/tests/baselines/reference/callChainWithSuper(target=es5).js +++ b/tests/baselines/reference/callChainWithSuper(target=es5).js @@ -12,7 +12,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/callSignatureAssignabilityInInheritance2.js b/tests/baselines/reference/callSignatureAssignabilityInInheritance2.js index e139bcca598..cd48becfa01 100644 --- a/tests/baselines/reference/callSignatureAssignabilityInInheritance2.js +++ b/tests/baselines/reference/callSignatureAssignabilityInInheritance2.js @@ -75,7 +75,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/callSignatureAssignabilityInInheritance3.js b/tests/baselines/reference/callSignatureAssignabilityInInheritance3.js index b8a024a8a09..452511dc705 100644 --- a/tests/baselines/reference/callSignatureAssignabilityInInheritance3.js +++ b/tests/baselines/reference/callSignatureAssignabilityInInheritance3.js @@ -120,7 +120,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/callSignatureAssignabilityInInheritance4.js b/tests/baselines/reference/callSignatureAssignabilityInInheritance4.js index a969d77fb03..dd10effafcd 100644 --- a/tests/baselines/reference/callSignatureAssignabilityInInheritance4.js +++ b/tests/baselines/reference/callSignatureAssignabilityInInheritance4.js @@ -55,7 +55,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/callSignatureAssignabilityInInheritance5.js b/tests/baselines/reference/callSignatureAssignabilityInInheritance5.js index cf8889cbf27..4eef3f6c92d 100644 --- a/tests/baselines/reference/callSignatureAssignabilityInInheritance5.js +++ b/tests/baselines/reference/callSignatureAssignabilityInInheritance5.js @@ -55,7 +55,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/callSignatureAssignabilityInInheritance6.js b/tests/baselines/reference/callSignatureAssignabilityInInheritance6.js index baa98cb72d5..c126c12db41 100644 --- a/tests/baselines/reference/callSignatureAssignabilityInInheritance6.js +++ b/tests/baselines/reference/callSignatureAssignabilityInInheritance6.js @@ -58,7 +58,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/callWithSpread.js b/tests/baselines/reference/callWithSpread.js index ee0ab6fe8a7..a6023e05cb3 100644 --- a/tests/baselines/reference/callWithSpread.js +++ b/tests/baselines/reference/callWithSpread.js @@ -63,7 +63,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/callbackCrossModule.symbols b/tests/baselines/reference/callbackCrossModule.symbols index 7c094d4f936..9de5c8ffbf3 100644 --- a/tests/baselines/reference/callbackCrossModule.symbols +++ b/tests/baselines/reference/callbackCrossModule.symbols @@ -13,6 +13,8 @@ function C() { >C : Symbol(C, Decl(mod1.js, 4, 18)) this.p = 1 +>this.p : Symbol(C.p, Decl(mod1.js, 5, 14)) +>this : Symbol(C, Decl(mod1.js, 4, 18)) >p : Symbol(C.p, Decl(mod1.js, 5, 14)) } diff --git a/tests/baselines/reference/callbackCrossModule.types b/tests/baselines/reference/callbackCrossModule.types index 27e28e7ae09..5138fca3471 100644 --- a/tests/baselines/reference/callbackCrossModule.types +++ b/tests/baselines/reference/callbackCrossModule.types @@ -16,7 +16,7 @@ function C() { this.p = 1 >this.p = 1 : 1 >this.p : any ->this : any +>this : this >p : any >1 : 1 } diff --git a/tests/baselines/reference/captureSuperPropertyAccessInSuperCall01.js b/tests/baselines/reference/captureSuperPropertyAccessInSuperCall01.js index dd433fc1db7..116dd3446a4 100644 --- a/tests/baselines/reference/captureSuperPropertyAccessInSuperCall01.js +++ b/tests/baselines/reference/captureSuperPropertyAccessInSuperCall01.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/captureThisInSuperCall.js b/tests/baselines/reference/captureThisInSuperCall.js index 919f8491114..1d6b2d4c0d7 100644 --- a/tests/baselines/reference/captureThisInSuperCall.js +++ b/tests/baselines/reference/captureThisInSuperCall.js @@ -13,7 +13,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/castingTuple.js b/tests/baselines/reference/castingTuple.js index ac21b229a3c..445ab000793 100644 --- a/tests/baselines/reference/castingTuple.js +++ b/tests/baselines/reference/castingTuple.js @@ -39,7 +39,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/chainedAssignment3.js b/tests/baselines/reference/chainedAssignment3.js index c3e73310188..4e95452a34a 100644 --- a/tests/baselines/reference/chainedAssignment3.js +++ b/tests/baselines/reference/chainedAssignment3.js @@ -27,7 +27,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/chainedCallsWithTypeParameterConstrainedToOtherTypeParameter.js b/tests/baselines/reference/chainedCallsWithTypeParameterConstrainedToOtherTypeParameter.js index 69ecf8cd52d..eaab9240ccb 100644 --- a/tests/baselines/reference/chainedCallsWithTypeParameterConstrainedToOtherTypeParameter.js +++ b/tests/baselines/reference/chainedCallsWithTypeParameterConstrainedToOtherTypeParameter.js @@ -24,7 +24,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/chainedPrototypeAssignment.symbols b/tests/baselines/reference/chainedPrototypeAssignment.symbols index a37ce9f01db..64211c83d02 100644 --- a/tests/baselines/reference/chainedPrototypeAssignment.symbols +++ b/tests/baselines/reference/chainedPrototypeAssignment.symbols @@ -42,6 +42,8 @@ var A = function A() { >A : Symbol(A, Decl(mod.js, 1, 7)) this.a = 1 +>this.a : Symbol(A.a, Decl(mod.js, 1, 22)) +>this : Symbol(A, Decl(mod.js, 1, 7)) >a : Symbol(A.a, Decl(mod.js, 1, 22)) } var B = function B() { @@ -49,6 +51,8 @@ var B = function B() { >B : Symbol(B, Decl(mod.js, 4, 7)) this.b = 2 +>this.b : Symbol(B.b, Decl(mod.js, 4, 22)) +>this : Symbol(B, Decl(mod.js, 4, 7)) >b : Symbol(B.b, Decl(mod.js, 4, 22)) } exports.A = A diff --git a/tests/baselines/reference/chainedPrototypeAssignment.types b/tests/baselines/reference/chainedPrototypeAssignment.types index 0e86f9e4049..d3754807da6 100644 --- a/tests/baselines/reference/chainedPrototypeAssignment.types +++ b/tests/baselines/reference/chainedPrototypeAssignment.types @@ -52,7 +52,7 @@ var A = function A() { this.a = 1 >this.a = 1 : 1 >this.a : any ->this : any +>this : this >a : any >1 : 1 } @@ -64,7 +64,7 @@ var B = function B() { this.b = 2 >this.b = 2 : 2 >this.b : any ->this : any +>this : this >b : any >2 : 2 } diff --git a/tests/baselines/reference/checkForObjectTooStrict.js b/tests/baselines/reference/checkForObjectTooStrict.js index d03127eaa7d..7c1289ab988 100644 --- a/tests/baselines/reference/checkForObjectTooStrict.js +++ b/tests/baselines/reference/checkForObjectTooStrict.js @@ -36,7 +36,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/checkJsxChildrenCanBeTupleType.js b/tests/baselines/reference/checkJsxChildrenCanBeTupleType.js index 30e59613eb9..6e5471d3554 100644 --- a/tests/baselines/reference/checkJsxChildrenCanBeTupleType.js +++ b/tests/baselines/reference/checkJsxChildrenCanBeTupleType.js @@ -28,7 +28,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/checkJsxChildrenProperty12.js b/tests/baselines/reference/checkJsxChildrenProperty12.js index 44fe4e1053d..473e8c3db05 100644 --- a/tests/baselines/reference/checkJsxChildrenProperty12.js +++ b/tests/baselines/reference/checkJsxChildrenProperty12.js @@ -38,7 +38,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/checkJsxChildrenProperty13.js b/tests/baselines/reference/checkJsxChildrenProperty13.js index dcdf7ac1e88..d00090827cd 100644 --- a/tests/baselines/reference/checkJsxChildrenProperty13.js +++ b/tests/baselines/reference/checkJsxChildrenProperty13.js @@ -33,7 +33,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/checkJsxChildrenProperty14.js b/tests/baselines/reference/checkJsxChildrenProperty14.js index 12051095b6a..1a899273628 100644 --- a/tests/baselines/reference/checkJsxChildrenProperty14.js +++ b/tests/baselines/reference/checkJsxChildrenProperty14.js @@ -48,7 +48,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/checkJsxChildrenProperty3.js b/tests/baselines/reference/checkJsxChildrenProperty3.js index 7ebf2ec717a..a516fa4e7ca 100644 --- a/tests/baselines/reference/checkJsxChildrenProperty3.js +++ b/tests/baselines/reference/checkJsxChildrenProperty3.js @@ -45,7 +45,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/checkJsxChildrenProperty4.js b/tests/baselines/reference/checkJsxChildrenProperty4.js index 02480bc17c9..b070f529c3a 100644 --- a/tests/baselines/reference/checkJsxChildrenProperty4.js +++ b/tests/baselines/reference/checkJsxChildrenProperty4.js @@ -50,7 +50,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/checkJsxChildrenProperty5.js b/tests/baselines/reference/checkJsxChildrenProperty5.js index 2e29ee2a2fb..ecef158f7df 100644 --- a/tests/baselines/reference/checkJsxChildrenProperty5.js +++ b/tests/baselines/reference/checkJsxChildrenProperty5.js @@ -36,7 +36,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/checkJsxChildrenProperty6.js b/tests/baselines/reference/checkJsxChildrenProperty6.js index 825f38b92ac..79806db7d13 100644 --- a/tests/baselines/reference/checkJsxChildrenProperty6.js +++ b/tests/baselines/reference/checkJsxChildrenProperty6.js @@ -49,7 +49,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/checkJsxChildrenProperty7.js b/tests/baselines/reference/checkJsxChildrenProperty7.js index a8b5e4e9fa4..d8a7eda58d8 100644 --- a/tests/baselines/reference/checkJsxChildrenProperty7.js +++ b/tests/baselines/reference/checkJsxChildrenProperty7.js @@ -34,7 +34,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/checkJsxChildrenProperty8.js b/tests/baselines/reference/checkJsxChildrenProperty8.js index f085c94f5ed..df8481201d9 100644 --- a/tests/baselines/reference/checkJsxChildrenProperty8.js +++ b/tests/baselines/reference/checkJsxChildrenProperty8.js @@ -35,7 +35,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/checkJsxIntersectionElementPropsType.js b/tests/baselines/reference/checkJsxIntersectionElementPropsType.js index cbdf2835c0b..c03b09776a1 100644 --- a/tests/baselines/reference/checkJsxIntersectionElementPropsType.js +++ b/tests/baselines/reference/checkJsxIntersectionElementPropsType.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/checkJsxSubtleSkipContextSensitiveBug.js b/tests/baselines/reference/checkJsxSubtleSkipContextSensitiveBug.js index d1d6dd7eeec..3ec9c4748f3 100644 --- a/tests/baselines/reference/checkJsxSubtleSkipContextSensitiveBug.js +++ b/tests/baselines/reference/checkJsxSubtleSkipContextSensitiveBug.js @@ -30,7 +30,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/checkSuperCallBeforeThisAccessing1.js b/tests/baselines/reference/checkSuperCallBeforeThisAccessing1.js index e507ddaecc1..e2a0b9fd974 100644 --- a/tests/baselines/reference/checkSuperCallBeforeThisAccessing1.js +++ b/tests/baselines/reference/checkSuperCallBeforeThisAccessing1.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/checkSuperCallBeforeThisAccessing2.js b/tests/baselines/reference/checkSuperCallBeforeThisAccessing2.js index 74a40ba6f29..ad952eaef93 100644 --- a/tests/baselines/reference/checkSuperCallBeforeThisAccessing2.js +++ b/tests/baselines/reference/checkSuperCallBeforeThisAccessing2.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/checkSuperCallBeforeThisAccessing3.js b/tests/baselines/reference/checkSuperCallBeforeThisAccessing3.js index 199ab08d993..4e82c02289a 100644 --- a/tests/baselines/reference/checkSuperCallBeforeThisAccessing3.js +++ b/tests/baselines/reference/checkSuperCallBeforeThisAccessing3.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/checkSuperCallBeforeThisAccessing4.js b/tests/baselines/reference/checkSuperCallBeforeThisAccessing4.js index fcb45365bfc..2e7362011ea 100644 --- a/tests/baselines/reference/checkSuperCallBeforeThisAccessing4.js +++ b/tests/baselines/reference/checkSuperCallBeforeThisAccessing4.js @@ -24,7 +24,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/checkSuperCallBeforeThisAccessing5.js b/tests/baselines/reference/checkSuperCallBeforeThisAccessing5.js index c6372d5a436..9892036498c 100644 --- a/tests/baselines/reference/checkSuperCallBeforeThisAccessing5.js +++ b/tests/baselines/reference/checkSuperCallBeforeThisAccessing5.js @@ -12,7 +12,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/checkSuperCallBeforeThisAccessing6.js b/tests/baselines/reference/checkSuperCallBeforeThisAccessing6.js index 5e0e9000e7d..e6d470d18ab 100644 --- a/tests/baselines/reference/checkSuperCallBeforeThisAccessing6.js +++ b/tests/baselines/reference/checkSuperCallBeforeThisAccessing6.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/checkSuperCallBeforeThisAccessing7.js b/tests/baselines/reference/checkSuperCallBeforeThisAccessing7.js index 2c32bc82248..e2d928e274a 100644 --- a/tests/baselines/reference/checkSuperCallBeforeThisAccessing7.js +++ b/tests/baselines/reference/checkSuperCallBeforeThisAccessing7.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/checkSuperCallBeforeThisAccessing8.js b/tests/baselines/reference/checkSuperCallBeforeThisAccessing8.js index 74bd178a888..fc9947922be 100644 --- a/tests/baselines/reference/checkSuperCallBeforeThisAccessing8.js +++ b/tests/baselines/reference/checkSuperCallBeforeThisAccessing8.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/circularConstraintYieldsAppropriateError.js b/tests/baselines/reference/circularConstraintYieldsAppropriateError.js index 175f48d4bca..c70256dc0ee 100644 --- a/tests/baselines/reference/circularConstraintYieldsAppropriateError.js +++ b/tests/baselines/reference/circularConstraintYieldsAppropriateError.js @@ -22,7 +22,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/circularImportAlias.js b/tests/baselines/reference/circularImportAlias.js index 11049041b18..61714903f27 100644 --- a/tests/baselines/reference/circularImportAlias.js +++ b/tests/baselines/reference/circularImportAlias.js @@ -25,7 +25,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/circularTypeofWithFunctionModule.js b/tests/baselines/reference/circularTypeofWithFunctionModule.js index 97dec519a99..cad38269608 100644 --- a/tests/baselines/reference/circularTypeofWithFunctionModule.js +++ b/tests/baselines/reference/circularTypeofWithFunctionModule.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classAbstractConstructorAssignability.js b/tests/baselines/reference/classAbstractConstructorAssignability.js index b19f6788fed..6271ffbe3b8 100644 --- a/tests/baselines/reference/classAbstractConstructorAssignability.js +++ b/tests/baselines/reference/classAbstractConstructorAssignability.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classAbstractCrashedOnce.js b/tests/baselines/reference/classAbstractCrashedOnce.js index ec0680fe873..79359ab4465 100644 --- a/tests/baselines/reference/classAbstractCrashedOnce.js +++ b/tests/baselines/reference/classAbstractCrashedOnce.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classAbstractExtends.js b/tests/baselines/reference/classAbstractExtends.js index 24357c0bdc6..b0502d1273b 100644 --- a/tests/baselines/reference/classAbstractExtends.js +++ b/tests/baselines/reference/classAbstractExtends.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classAbstractFactoryFunction.js b/tests/baselines/reference/classAbstractFactoryFunction.js index 002b065c641..0d4625d09ff 100644 --- a/tests/baselines/reference/classAbstractFactoryFunction.js +++ b/tests/baselines/reference/classAbstractFactoryFunction.js @@ -21,7 +21,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classAbstractGeneric.js b/tests/baselines/reference/classAbstractGeneric.js index e7e77bd47df..9911f0b28ff 100644 --- a/tests/baselines/reference/classAbstractGeneric.js +++ b/tests/baselines/reference/classAbstractGeneric.js @@ -30,7 +30,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classAbstractInAModule.js b/tests/baselines/reference/classAbstractInAModule.js index ff2103d78ac..145012421d7 100644 --- a/tests/baselines/reference/classAbstractInAModule.js +++ b/tests/baselines/reference/classAbstractInAModule.js @@ -12,7 +12,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classAbstractInheritance.js b/tests/baselines/reference/classAbstractInheritance.js index 478c2f5979d..401eea03d4e 100644 --- a/tests/baselines/reference/classAbstractInheritance.js +++ b/tests/baselines/reference/classAbstractInheritance.js @@ -26,7 +26,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classAbstractInstantiations1.js b/tests/baselines/reference/classAbstractInstantiations1.js index fc3a2448346..6537cb7b5f8 100644 --- a/tests/baselines/reference/classAbstractInstantiations1.js +++ b/tests/baselines/reference/classAbstractInstantiations1.js @@ -31,7 +31,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classAbstractInstantiations2.js b/tests/baselines/reference/classAbstractInstantiations2.js index 4beafc415f7..ccf19cf6ec0 100644 --- a/tests/baselines/reference/classAbstractInstantiations2.js +++ b/tests/baselines/reference/classAbstractInstantiations2.js @@ -56,7 +56,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classAbstractOverrideWithAbstract.js b/tests/baselines/reference/classAbstractOverrideWithAbstract.js index 1765b8958c8..e8eaf3f23fb 100644 --- a/tests/baselines/reference/classAbstractOverrideWithAbstract.js +++ b/tests/baselines/reference/classAbstractOverrideWithAbstract.js @@ -28,7 +28,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classAbstractSuperCalls.js b/tests/baselines/reference/classAbstractSuperCalls.js index f812c4425a8..500bc204745 100644 --- a/tests/baselines/reference/classAbstractSuperCalls.js +++ b/tests/baselines/reference/classAbstractSuperCalls.js @@ -31,7 +31,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classAbstractUsingAbstractMethod1.js b/tests/baselines/reference/classAbstractUsingAbstractMethod1.js index 9f855223f17..8dea56e1139 100644 --- a/tests/baselines/reference/classAbstractUsingAbstractMethod1.js +++ b/tests/baselines/reference/classAbstractUsingAbstractMethod1.js @@ -22,7 +22,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classAbstractUsingAbstractMethods2.js b/tests/baselines/reference/classAbstractUsingAbstractMethods2.js index 0a8e4893496..32b633e38c6 100644 --- a/tests/baselines/reference/classAbstractUsingAbstractMethods2.js +++ b/tests/baselines/reference/classAbstractUsingAbstractMethods2.js @@ -32,7 +32,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classCanExtendConstructorFunction.symbols b/tests/baselines/reference/classCanExtendConstructorFunction.symbols index c1c8be92725..1fa2b597486 100644 --- a/tests/baselines/reference/classCanExtendConstructorFunction.symbols +++ b/tests/baselines/reference/classCanExtendConstructorFunction.symbols @@ -193,6 +193,8 @@ function Soup(flavour) { >flavour : Symbol(flavour, Decl(generic.js, 4, 14)) this.flavour = flavour +>this.flavour : Symbol(Soup.flavour, Decl(generic.js, 4, 24)) +>this : Symbol(Soup, Decl(generic.js, 0, 0)) >flavour : Symbol(Soup.flavour, Decl(generic.js, 4, 24)) >flavour : Symbol(flavour, Decl(generic.js, 4, 14)) } diff --git a/tests/baselines/reference/classCanExtendConstructorFunction.types b/tests/baselines/reference/classCanExtendConstructorFunction.types index f667ce4b150..a060d27e54d 100644 --- a/tests/baselines/reference/classCanExtendConstructorFunction.types +++ b/tests/baselines/reference/classCanExtendConstructorFunction.types @@ -238,7 +238,7 @@ function Soup(flavour) { this.flavour = flavour >this.flavour = flavour : T >this.flavour : any ->this : any +>this : this >flavour : any >flavour : T } diff --git a/tests/baselines/reference/classConstructorAccessibility2.js b/tests/baselines/reference/classConstructorAccessibility2.js index 1868df64fd8..acd33e4b424 100644 --- a/tests/baselines/reference/classConstructorAccessibility2.js +++ b/tests/baselines/reference/classConstructorAccessibility2.js @@ -50,7 +50,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classConstructorAccessibility4.js b/tests/baselines/reference/classConstructorAccessibility4.js index 412f4f95bca..3793df8cffa 100644 --- a/tests/baselines/reference/classConstructorAccessibility4.js +++ b/tests/baselines/reference/classConstructorAccessibility4.js @@ -34,7 +34,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classConstructorAccessibility5.js b/tests/baselines/reference/classConstructorAccessibility5.js index ec950634e11..5c80f776cc3 100644 --- a/tests/baselines/reference/classConstructorAccessibility5.js +++ b/tests/baselines/reference/classConstructorAccessibility5.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classConstructorParametersAccessibility.js b/tests/baselines/reference/classConstructorParametersAccessibility.js index 2bb0f49a481..982ea31c60b 100644 --- a/tests/baselines/reference/classConstructorParametersAccessibility.js +++ b/tests/baselines/reference/classConstructorParametersAccessibility.js @@ -31,7 +31,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classConstructorParametersAccessibility2.js b/tests/baselines/reference/classConstructorParametersAccessibility2.js index de647fc282a..4985a4f998f 100644 --- a/tests/baselines/reference/classConstructorParametersAccessibility2.js +++ b/tests/baselines/reference/classConstructorParametersAccessibility2.js @@ -31,7 +31,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classConstructorParametersAccessibility3.js b/tests/baselines/reference/classConstructorParametersAccessibility3.js index bf034cde19b..d498ec60658 100644 --- a/tests/baselines/reference/classConstructorParametersAccessibility3.js +++ b/tests/baselines/reference/classConstructorParametersAccessibility3.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classDeclarationMergedInModuleWithContinuation.js b/tests/baselines/reference/classDeclarationMergedInModuleWithContinuation.js index 53ed374116f..16f450c58fe 100644 --- a/tests/baselines/reference/classDeclarationMergedInModuleWithContinuation.js +++ b/tests/baselines/reference/classDeclarationMergedInModuleWithContinuation.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classDeclaredBeforeClassFactory.js b/tests/baselines/reference/classDeclaredBeforeClassFactory.js index 78fee53c66c..3e3157abf90 100644 --- a/tests/baselines/reference/classDeclaredBeforeClassFactory.js +++ b/tests/baselines/reference/classDeclaredBeforeClassFactory.js @@ -12,7 +12,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classDoesNotDependOnBaseTypes.js b/tests/baselines/reference/classDoesNotDependOnBaseTypes.js index 0a3e6698f3c..dd59dc871d5 100644 --- a/tests/baselines/reference/classDoesNotDependOnBaseTypes.js +++ b/tests/baselines/reference/classDoesNotDependOnBaseTypes.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExpression2.js b/tests/baselines/reference/classExpression2.js index 3ad11c2b731..4d255bd2522 100644 --- a/tests/baselines/reference/classExpression2.js +++ b/tests/baselines/reference/classExpression2.js @@ -7,7 +7,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExpression3.js b/tests/baselines/reference/classExpression3.js index a87515f3f2f..bce9b608857 100644 --- a/tests/baselines/reference/classExpression3.js +++ b/tests/baselines/reference/classExpression3.js @@ -11,7 +11,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExpressionExtendingAbstractClass.js b/tests/baselines/reference/classExpressionExtendingAbstractClass.js index fe8e4ce19df..6437f90e348 100644 --- a/tests/baselines/reference/classExpressionExtendingAbstractClass.js +++ b/tests/baselines/reference/classExpressionExtendingAbstractClass.js @@ -13,7 +13,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExpressionInClassStaticDeclarations.js b/tests/baselines/reference/classExpressionInClassStaticDeclarations.js index cb635f9eee2..46af4ab6644 100644 --- a/tests/baselines/reference/classExpressionInClassStaticDeclarations.js +++ b/tests/baselines/reference/classExpressionInClassStaticDeclarations.js @@ -8,7 +8,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendingBuiltinType.js b/tests/baselines/reference/classExtendingBuiltinType.js index 8d2c2dfdd31..79a28548374 100644 --- a/tests/baselines/reference/classExtendingBuiltinType.js +++ b/tests/baselines/reference/classExtendingBuiltinType.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendingClass.js b/tests/baselines/reference/classExtendingClass.js index cd462784c4f..45d3c636065 100644 --- a/tests/baselines/reference/classExtendingClass.js +++ b/tests/baselines/reference/classExtendingClass.js @@ -36,7 +36,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendingClassLikeType.js b/tests/baselines/reference/classExtendingClassLikeType.js index 016454073ec..b86cdb08868 100644 --- a/tests/baselines/reference/classExtendingClassLikeType.js +++ b/tests/baselines/reference/classExtendingClassLikeType.js @@ -63,7 +63,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendingNonConstructor.js b/tests/baselines/reference/classExtendingNonConstructor.js index c83ea16696e..e130e5b4c78 100644 --- a/tests/baselines/reference/classExtendingNonConstructor.js +++ b/tests/baselines/reference/classExtendingNonConstructor.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendingNull.js b/tests/baselines/reference/classExtendingNull.js index 99c8fb76501..cc647aa93a8 100644 --- a/tests/baselines/reference/classExtendingNull.js +++ b/tests/baselines/reference/classExtendingNull.js @@ -9,7 +9,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendingPrimitive.js b/tests/baselines/reference/classExtendingPrimitive.js index 8ad1eb89c1b..d208606cfa1 100644 --- a/tests/baselines/reference/classExtendingPrimitive.js +++ b/tests/baselines/reference/classExtendingPrimitive.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendingPrimitive2.js b/tests/baselines/reference/classExtendingPrimitive2.js index b6524e2bd04..f21f0c0297d 100644 --- a/tests/baselines/reference/classExtendingPrimitive2.js +++ b/tests/baselines/reference/classExtendingPrimitive2.js @@ -10,7 +10,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendingQualifiedName.js b/tests/baselines/reference/classExtendingQualifiedName.js index 1465af9739a..95fb0188eac 100644 --- a/tests/baselines/reference/classExtendingQualifiedName.js +++ b/tests/baselines/reference/classExtendingQualifiedName.js @@ -12,7 +12,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendingQualifiedName2.js b/tests/baselines/reference/classExtendingQualifiedName2.js index 20e9994ea2e..4be2ff4e4dd 100644 --- a/tests/baselines/reference/classExtendingQualifiedName2.js +++ b/tests/baselines/reference/classExtendingQualifiedName2.js @@ -12,7 +12,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendsAcrossFiles.js b/tests/baselines/reference/classExtendsAcrossFiles.js index 16b8095cc45..bf9cac5b864 100644 --- a/tests/baselines/reference/classExtendsAcrossFiles.js +++ b/tests/baselines/reference/classExtendsAcrossFiles.js @@ -25,7 +25,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { @@ -60,7 +60,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendsClauseClassMergedWithModuleNotReferingConstructor.js b/tests/baselines/reference/classExtendsClauseClassMergedWithModuleNotReferingConstructor.js index 18dd63364b6..62a0d7515f8 100644 --- a/tests/baselines/reference/classExtendsClauseClassMergedWithModuleNotReferingConstructor.js +++ b/tests/baselines/reference/classExtendsClauseClassMergedWithModuleNotReferingConstructor.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendsClauseClassNotReferringConstructor.js b/tests/baselines/reference/classExtendsClauseClassNotReferringConstructor.js index f746f36daef..cb445a38154 100644 --- a/tests/baselines/reference/classExtendsClauseClassNotReferringConstructor.js +++ b/tests/baselines/reference/classExtendsClauseClassNotReferringConstructor.js @@ -11,7 +11,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendsEveryObjectType.js b/tests/baselines/reference/classExtendsEveryObjectType.js index 7fcb678fc65..2b650f3e5ba 100644 --- a/tests/baselines/reference/classExtendsEveryObjectType.js +++ b/tests/baselines/reference/classExtendsEveryObjectType.js @@ -21,7 +21,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendsEveryObjectType2.js b/tests/baselines/reference/classExtendsEveryObjectType2.js index f8c5f110389..38441aa1294 100644 --- a/tests/baselines/reference/classExtendsEveryObjectType2.js +++ b/tests/baselines/reference/classExtendsEveryObjectType2.js @@ -8,7 +8,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendsInterface.js b/tests/baselines/reference/classExtendsInterface.js index 047e6161354..1d962816bad 100644 --- a/tests/baselines/reference/classExtendsInterface.js +++ b/tests/baselines/reference/classExtendsInterface.js @@ -13,7 +13,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendsInterfaceInExpression.js b/tests/baselines/reference/classExtendsInterfaceInExpression.js index a930feed6cf..80f4a4110c4 100644 --- a/tests/baselines/reference/classExtendsInterfaceInExpression.js +++ b/tests/baselines/reference/classExtendsInterfaceInExpression.js @@ -13,7 +13,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendsInterfaceInModule.js b/tests/baselines/reference/classExtendsInterfaceInModule.js index 7aa057a9227..97f4f0b53c8 100644 --- a/tests/baselines/reference/classExtendsInterfaceInModule.js +++ b/tests/baselines/reference/classExtendsInterfaceInModule.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendsInterface_not.js b/tests/baselines/reference/classExtendsInterface_not.js index 238a00bbbd2..2f6312bea84 100644 --- a/tests/baselines/reference/classExtendsInterface_not.js +++ b/tests/baselines/reference/classExtendsInterface_not.js @@ -7,7 +7,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendsItself.js b/tests/baselines/reference/classExtendsItself.js index ba71ae1df91..eb93feb46c4 100644 --- a/tests/baselines/reference/classExtendsItself.js +++ b/tests/baselines/reference/classExtendsItself.js @@ -10,7 +10,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendsItselfIndirectly.js b/tests/baselines/reference/classExtendsItselfIndirectly.js index 04d5a9879d5..9b7f4a4b97d 100644 --- a/tests/baselines/reference/classExtendsItselfIndirectly.js +++ b/tests/baselines/reference/classExtendsItselfIndirectly.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendsItselfIndirectly2.js b/tests/baselines/reference/classExtendsItselfIndirectly2.js index 310d96ee7ab..96a2753dfa0 100644 --- a/tests/baselines/reference/classExtendsItselfIndirectly2.js +++ b/tests/baselines/reference/classExtendsItselfIndirectly2.js @@ -27,7 +27,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendsItselfIndirectly3.js b/tests/baselines/reference/classExtendsItselfIndirectly3.js index af882e651d0..e94d4a2d95a 100644 --- a/tests/baselines/reference/classExtendsItselfIndirectly3.js +++ b/tests/baselines/reference/classExtendsItselfIndirectly3.js @@ -23,7 +23,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { @@ -44,7 +44,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { @@ -65,7 +65,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { @@ -86,7 +86,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { @@ -107,7 +107,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { @@ -128,7 +128,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendsMultipleBaseClasses.js b/tests/baselines/reference/classExtendsMultipleBaseClasses.js index 1727a582238..c14195c7528 100644 --- a/tests/baselines/reference/classExtendsMultipleBaseClasses.js +++ b/tests/baselines/reference/classExtendsMultipleBaseClasses.js @@ -8,7 +8,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendsNull.js b/tests/baselines/reference/classExtendsNull.js index 2fef0e405f1..66854df5be5 100644 --- a/tests/baselines/reference/classExtendsNull.js +++ b/tests/baselines/reference/classExtendsNull.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendsShadowedConstructorFunction.js b/tests/baselines/reference/classExtendsShadowedConstructorFunction.js index 3b86d7739cd..fb4d3a1a92e 100644 --- a/tests/baselines/reference/classExtendsShadowedConstructorFunction.js +++ b/tests/baselines/reference/classExtendsShadowedConstructorFunction.js @@ -13,7 +13,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtendsValidConstructorFunction.js b/tests/baselines/reference/classExtendsValidConstructorFunction.js index 6570beaf8c9..b38dba23f8e 100644 --- a/tests/baselines/reference/classExtendsValidConstructorFunction.js +++ b/tests/baselines/reference/classExtendsValidConstructorFunction.js @@ -10,7 +10,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classExtensionNameOutput.js b/tests/baselines/reference/classExtensionNameOutput.js index e2c80c242e4..42a14957248 100644 --- a/tests/baselines/reference/classExtensionNameOutput.js +++ b/tests/baselines/reference/classExtensionNameOutput.js @@ -13,7 +13,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classHeritageWithTrailingSeparator.js b/tests/baselines/reference/classHeritageWithTrailingSeparator.js index 993a8c37afb..c83c40f316e 100644 --- a/tests/baselines/reference/classHeritageWithTrailingSeparator.js +++ b/tests/baselines/reference/classHeritageWithTrailingSeparator.js @@ -8,7 +8,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classImplementsClass2.js b/tests/baselines/reference/classImplementsClass2.js index ac9348b90a2..c4e9c251ec2 100644 --- a/tests/baselines/reference/classImplementsClass2.js +++ b/tests/baselines/reference/classImplementsClass2.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classImplementsClass3.js b/tests/baselines/reference/classImplementsClass3.js index e06c47c60cf..c6defc03dba 100644 --- a/tests/baselines/reference/classImplementsClass3.js +++ b/tests/baselines/reference/classImplementsClass3.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classImplementsClass4.js b/tests/baselines/reference/classImplementsClass4.js index dfba80d1543..da252102405 100644 --- a/tests/baselines/reference/classImplementsClass4.js +++ b/tests/baselines/reference/classImplementsClass4.js @@ -21,7 +21,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classImplementsClass5.js b/tests/baselines/reference/classImplementsClass5.js index 0ab2ff23fdd..367909e3886 100644 --- a/tests/baselines/reference/classImplementsClass5.js +++ b/tests/baselines/reference/classImplementsClass5.js @@ -22,7 +22,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classImplementsClass6.js b/tests/baselines/reference/classImplementsClass6.js index 28e8b574403..09c270f3b74 100644 --- a/tests/baselines/reference/classImplementsClass6.js +++ b/tests/baselines/reference/classImplementsClass6.js @@ -26,7 +26,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classIndexer3.js b/tests/baselines/reference/classIndexer3.js index 217bfa7958e..f90534fc351 100644 --- a/tests/baselines/reference/classIndexer3.js +++ b/tests/baselines/reference/classIndexer3.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classInheritence.js b/tests/baselines/reference/classInheritence.js index 99206a1e8ff..867620d49bf 100644 --- a/tests/baselines/reference/classInheritence.js +++ b/tests/baselines/reference/classInheritence.js @@ -7,7 +7,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classIsSubtypeOfBaseType.js b/tests/baselines/reference/classIsSubtypeOfBaseType.js index c185c546ad9..9c8c759031b 100644 --- a/tests/baselines/reference/classIsSubtypeOfBaseType.js +++ b/tests/baselines/reference/classIsSubtypeOfBaseType.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classMergedWithInterfaceMultipleBasesNoError.js b/tests/baselines/reference/classMergedWithInterfaceMultipleBasesNoError.js index 16eb43631c9..b2343d7c92a 100644 --- a/tests/baselines/reference/classMergedWithInterfaceMultipleBasesNoError.js +++ b/tests/baselines/reference/classMergedWithInterfaceMultipleBasesNoError.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classOrder2.js b/tests/baselines/reference/classOrder2.js index 27a8d9091dd..d8a5f67e92d 100644 --- a/tests/baselines/reference/classOrder2.js +++ b/tests/baselines/reference/classOrder2.js @@ -23,7 +23,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classOrderBug.js b/tests/baselines/reference/classOrderBug.js index 6660407f8ad..5592ce91fba 100644 --- a/tests/baselines/reference/classOrderBug.js +++ b/tests/baselines/reference/classOrderBug.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classSideInheritance1.js b/tests/baselines/reference/classSideInheritance1.js index 0cce6704987..3ed58d51b80 100644 --- a/tests/baselines/reference/classSideInheritance1.js +++ b/tests/baselines/reference/classSideInheritance1.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classSideInheritance2.js b/tests/baselines/reference/classSideInheritance2.js index 0794de5d946..8ef339c9572 100644 --- a/tests/baselines/reference/classSideInheritance2.js +++ b/tests/baselines/reference/classSideInheritance2.js @@ -25,7 +25,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classSideInheritance3.js b/tests/baselines/reference/classSideInheritance3.js index e407b85ecfb..9a06c6a9698 100644 --- a/tests/baselines/reference/classSideInheritance3.js +++ b/tests/baselines/reference/classSideInheritance3.js @@ -23,7 +23,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classUpdateTests.js b/tests/baselines/reference/classUpdateTests.js index 916ac9baa47..9e85b741461 100644 --- a/tests/baselines/reference/classUpdateTests.js +++ b/tests/baselines/reference/classUpdateTests.js @@ -118,7 +118,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classUsedBeforeInitializedVariables.js b/tests/baselines/reference/classUsedBeforeInitializedVariables.js index eb3e7908ea5..e989de04dd1 100644 --- a/tests/baselines/reference/classUsedBeforeInitializedVariables.js +++ b/tests/baselines/reference/classUsedBeforeInitializedVariables.js @@ -44,7 +44,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classWithBaseClassButNoConstructor.js b/tests/baselines/reference/classWithBaseClassButNoConstructor.js index 54b0fd482e5..c01bacfc460 100644 --- a/tests/baselines/reference/classWithBaseClassButNoConstructor.js +++ b/tests/baselines/reference/classWithBaseClassButNoConstructor.js @@ -45,7 +45,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classWithConstructors.js b/tests/baselines/reference/classWithConstructors.js index db3fcb05a34..6a3d9ebf846 100644 --- a/tests/baselines/reference/classWithConstructors.js +++ b/tests/baselines/reference/classWithConstructors.js @@ -54,7 +54,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classWithProtectedProperty.js b/tests/baselines/reference/classWithProtectedProperty.js index 91d4564a5d3..5858da7f92c 100644 --- a/tests/baselines/reference/classWithProtectedProperty.js +++ b/tests/baselines/reference/classWithProtectedProperty.js @@ -33,7 +33,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classWithStaticMembers.js b/tests/baselines/reference/classWithStaticMembers.js index d2a181c5b8d..703b5a9d74e 100644 --- a/tests/baselines/reference/classWithStaticMembers.js +++ b/tests/baselines/reference/classWithStaticMembers.js @@ -24,7 +24,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/classdecl.js b/tests/baselines/reference/classdecl.js index a3506a88035..724d634444c 100644 --- a/tests/baselines/reference/classdecl.js +++ b/tests/baselines/reference/classdecl.js @@ -98,7 +98,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/cloduleGenericOnSelfMember.js b/tests/baselines/reference/cloduleGenericOnSelfMember.js index fbd431d4709..7e20d4a1b13 100644 --- a/tests/baselines/reference/cloduleGenericOnSelfMember.js +++ b/tests/baselines/reference/cloduleGenericOnSelfMember.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/clodulesDerivedClasses.js b/tests/baselines/reference/clodulesDerivedClasses.js index 1d522b86089..5ad9e844032 100644 --- a/tests/baselines/reference/clodulesDerivedClasses.js +++ b/tests/baselines/reference/clodulesDerivedClasses.js @@ -27,7 +27,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/collisionSuperAndLocalFunctionInAccessors.js b/tests/baselines/reference/collisionSuperAndLocalFunctionInAccessors.js index 2814b7dc2b4..c2c3acf4f48 100644 --- a/tests/baselines/reference/collisionSuperAndLocalFunctionInAccessors.js +++ b/tests/baselines/reference/collisionSuperAndLocalFunctionInAccessors.js @@ -44,7 +44,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/collisionSuperAndLocalFunctionInConstructor.js b/tests/baselines/reference/collisionSuperAndLocalFunctionInConstructor.js index abb43068394..743ce5b44b3 100644 --- a/tests/baselines/reference/collisionSuperAndLocalFunctionInConstructor.js +++ b/tests/baselines/reference/collisionSuperAndLocalFunctionInConstructor.js @@ -29,7 +29,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/collisionSuperAndLocalFunctionInMethod.js b/tests/baselines/reference/collisionSuperAndLocalFunctionInMethod.js index 30bd47f7cdc..1089eb7ff65 100644 --- a/tests/baselines/reference/collisionSuperAndLocalFunctionInMethod.js +++ b/tests/baselines/reference/collisionSuperAndLocalFunctionInMethod.js @@ -33,7 +33,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/collisionSuperAndLocalFunctionInProperty.js b/tests/baselines/reference/collisionSuperAndLocalFunctionInProperty.js index 7f1f6d38c95..0f0015ac2ec 100644 --- a/tests/baselines/reference/collisionSuperAndLocalFunctionInProperty.js +++ b/tests/baselines/reference/collisionSuperAndLocalFunctionInProperty.js @@ -23,7 +23,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/collisionSuperAndLocalVarInAccessors.js b/tests/baselines/reference/collisionSuperAndLocalVarInAccessors.js index 7aa17672460..51af3694bd5 100644 --- a/tests/baselines/reference/collisionSuperAndLocalVarInAccessors.js +++ b/tests/baselines/reference/collisionSuperAndLocalVarInAccessors.js @@ -37,7 +37,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/collisionSuperAndLocalVarInConstructor.js b/tests/baselines/reference/collisionSuperAndLocalVarInConstructor.js index ffd052dfe75..708a8801ab7 100644 --- a/tests/baselines/reference/collisionSuperAndLocalVarInConstructor.js +++ b/tests/baselines/reference/collisionSuperAndLocalVarInConstructor.js @@ -25,7 +25,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/collisionSuperAndLocalVarInMethod.js b/tests/baselines/reference/collisionSuperAndLocalVarInMethod.js index 110323d4973..84dcd93b0c2 100644 --- a/tests/baselines/reference/collisionSuperAndLocalVarInMethod.js +++ b/tests/baselines/reference/collisionSuperAndLocalVarInMethod.js @@ -23,7 +23,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/collisionSuperAndLocalVarInProperty.js b/tests/baselines/reference/collisionSuperAndLocalVarInProperty.js index e1330ff822a..994eff30945 100644 --- a/tests/baselines/reference/collisionSuperAndLocalVarInProperty.js +++ b/tests/baselines/reference/collisionSuperAndLocalVarInProperty.js @@ -22,7 +22,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/collisionSuperAndNameResolution.js b/tests/baselines/reference/collisionSuperAndNameResolution.js index e3df51d1f99..9c2ece1e9bc 100644 --- a/tests/baselines/reference/collisionSuperAndNameResolution.js +++ b/tests/baselines/reference/collisionSuperAndNameResolution.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/collisionSuperAndParameter.js b/tests/baselines/reference/collisionSuperAndParameter.js index 8b85ad6b9c5..4d5417c2b8b 100644 --- a/tests/baselines/reference/collisionSuperAndParameter.js +++ b/tests/baselines/reference/collisionSuperAndParameter.js @@ -67,7 +67,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/collisionSuperAndParameter1.js b/tests/baselines/reference/collisionSuperAndParameter1.js index e06489e356a..b4c24b826e8 100644 --- a/tests/baselines/reference/collisionSuperAndParameter1.js +++ b/tests/baselines/reference/collisionSuperAndParameter1.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/collisionSuperAndPropertyNameAsConstuctorParameter.js b/tests/baselines/reference/collisionSuperAndPropertyNameAsConstuctorParameter.js index 5e066b7ad09..543b4b7a770 100644 --- a/tests/baselines/reference/collisionSuperAndPropertyNameAsConstuctorParameter.js +++ b/tests/baselines/reference/collisionSuperAndPropertyNameAsConstuctorParameter.js @@ -35,7 +35,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/collisionThisExpressionAndLocalVarWithSuperExperssion.js b/tests/baselines/reference/collisionThisExpressionAndLocalVarWithSuperExperssion.js index 0c952a75e2c..7ea936b2825 100644 --- a/tests/baselines/reference/collisionThisExpressionAndLocalVarWithSuperExperssion.js +++ b/tests/baselines/reference/collisionThisExpressionAndLocalVarWithSuperExperssion.js @@ -23,7 +23,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/commentsInheritance.js b/tests/baselines/reference/commentsInheritance.js index 0ea3bbbe422..e64605dbfb3 100644 --- a/tests/baselines/reference/commentsInheritance.js +++ b/tests/baselines/reference/commentsInheritance.js @@ -155,7 +155,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/commonjsAccessExports.symbols b/tests/baselines/reference/commonjsAccessExports.symbols index e98817b6f9e..eda1d943dc3 100644 --- a/tests/baselines/reference/commonjsAccessExports.symbols +++ b/tests/baselines/reference/commonjsAccessExports.symbols @@ -18,6 +18,8 @@ exports.x; >Cls : Symbol(Cls, Decl(a.js, 4, 1)) this.x = 0; +>this.x : Symbol(Cls.x, Decl(a.js, 6, 30)) +>this : Symbol(Cls, Decl(a.js, 6, 17)) >x : Symbol(Cls.x, Decl(a.js, 6, 30)) } } diff --git a/tests/baselines/reference/commonjsAccessExports.types b/tests/baselines/reference/commonjsAccessExports.types index c5578993fe3..d3325854789 100644 --- a/tests/baselines/reference/commonjsAccessExports.types +++ b/tests/baselines/reference/commonjsAccessExports.types @@ -24,7 +24,7 @@ exports.x; this.x = 0; >this.x = 0 : 0 >this.x : any ->this : any +>this : this >x : any >0 : 0 } diff --git a/tests/baselines/reference/comparisonOperatorWithIdenticalObjects.js b/tests/baselines/reference/comparisonOperatorWithIdenticalObjects.js index ca1da60a4a1..00fcdf35c92 100644 --- a/tests/baselines/reference/comparisonOperatorWithIdenticalObjects.js +++ b/tests/baselines/reference/comparisonOperatorWithIdenticalObjects.js @@ -199,7 +199,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/comparisonOperatorWithNoRelationshipObjectsOnCallSignature.js b/tests/baselines/reference/comparisonOperatorWithNoRelationshipObjectsOnCallSignature.js index aa6a690d944..6fcb9fc0929 100644 --- a/tests/baselines/reference/comparisonOperatorWithNoRelationshipObjectsOnCallSignature.js +++ b/tests/baselines/reference/comparisonOperatorWithNoRelationshipObjectsOnCallSignature.js @@ -173,7 +173,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/comparisonOperatorWithNoRelationshipObjectsOnConstructorSignature.js b/tests/baselines/reference/comparisonOperatorWithNoRelationshipObjectsOnConstructorSignature.js index 899dd0ef869..9cabb0eb459 100644 --- a/tests/baselines/reference/comparisonOperatorWithNoRelationshipObjectsOnConstructorSignature.js +++ b/tests/baselines/reference/comparisonOperatorWithNoRelationshipObjectsOnConstructorSignature.js @@ -173,7 +173,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/comparisonOperatorWithNoRelationshipObjectsOnIndexSignature.js b/tests/baselines/reference/comparisonOperatorWithNoRelationshipObjectsOnIndexSignature.js index 767cdeb8fa1..b7f57a7fd9f 100644 --- a/tests/baselines/reference/comparisonOperatorWithNoRelationshipObjectsOnIndexSignature.js +++ b/tests/baselines/reference/comparisonOperatorWithNoRelationshipObjectsOnIndexSignature.js @@ -116,7 +116,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/comparisonOperatorWithNoRelationshipObjectsOnInstantiatedCallSignature.js b/tests/baselines/reference/comparisonOperatorWithNoRelationshipObjectsOnInstantiatedCallSignature.js index 86f331fe7f8..41359728c97 100644 --- a/tests/baselines/reference/comparisonOperatorWithNoRelationshipObjectsOnInstantiatedCallSignature.js +++ b/tests/baselines/reference/comparisonOperatorWithNoRelationshipObjectsOnInstantiatedCallSignature.js @@ -154,7 +154,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/comparisonOperatorWithNoRelationshipObjectsOnInstantiatedConstructorSignature.js b/tests/baselines/reference/comparisonOperatorWithNoRelationshipObjectsOnInstantiatedConstructorSignature.js index 47b05d80160..682ca7e9ab6 100644 --- a/tests/baselines/reference/comparisonOperatorWithNoRelationshipObjectsOnInstantiatedConstructorSignature.js +++ b/tests/baselines/reference/comparisonOperatorWithNoRelationshipObjectsOnInstantiatedConstructorSignature.js @@ -154,7 +154,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnCallSignature.js b/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnCallSignature.js index 2ae8047795a..29d0b08ed76 100644 --- a/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnCallSignature.js +++ b/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnCallSignature.js @@ -264,7 +264,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnConstructorSignature.js b/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnConstructorSignature.js index 9cb62f69f60..dd2d6164263 100644 --- a/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnConstructorSignature.js +++ b/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnConstructorSignature.js @@ -226,7 +226,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnIndexSignature.js b/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnIndexSignature.js index b66a68fe3d7..5abc3dde4f1 100644 --- a/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnIndexSignature.js +++ b/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnIndexSignature.js @@ -112,7 +112,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnInstantiatedCallSignature.js b/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnInstantiatedCallSignature.js index 84743940cf3..51c795ffacb 100644 --- a/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnInstantiatedCallSignature.js +++ b/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnInstantiatedCallSignature.js @@ -169,7 +169,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnInstantiatedConstructorSignature.js b/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnInstantiatedConstructorSignature.js index 4a6566b993f..6c6fa0f4e1a 100644 --- a/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnInstantiatedConstructorSignature.js +++ b/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnInstantiatedConstructorSignature.js @@ -169,7 +169,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnProperty.js b/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnProperty.js index 4bef13950ad..a140c4c8090 100644 --- a/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnProperty.js +++ b/tests/baselines/reference/comparisonOperatorWithSubtypeObjectOnProperty.js @@ -83,7 +83,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/complexClassRelationships.js b/tests/baselines/reference/complexClassRelationships.js index cf2133f765c..147b6bb245d 100644 --- a/tests/baselines/reference/complexClassRelationships.js +++ b/tests/baselines/reference/complexClassRelationships.js @@ -52,7 +52,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/complicatedGenericRecursiveBaseClassReference.js b/tests/baselines/reference/complicatedGenericRecursiveBaseClassReference.js index 96293dafa59..51738a7deda 100644 --- a/tests/baselines/reference/complicatedGenericRecursiveBaseClassReference.js +++ b/tests/baselines/reference/complicatedGenericRecursiveBaseClassReference.js @@ -10,7 +10,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/compoundAssignmentLHSIsValue.js b/tests/baselines/reference/compoundAssignmentLHSIsValue.js index 0cd13bc7fff..815b9f671c7 100644 --- a/tests/baselines/reference/compoundAssignmentLHSIsValue.js +++ b/tests/baselines/reference/compoundAssignmentLHSIsValue.js @@ -127,7 +127,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/compoundExponentiationAssignmentLHSIsValue.js b/tests/baselines/reference/compoundExponentiationAssignmentLHSIsValue.js index b3e1312cd69..6f04fba17d0 100644 --- a/tests/baselines/reference/compoundExponentiationAssignmentLHSIsValue.js +++ b/tests/baselines/reference/compoundExponentiationAssignmentLHSIsValue.js @@ -90,7 +90,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/computedPropertyNames24_ES5.js b/tests/baselines/reference/computedPropertyNames24_ES5.js index 7dc995ad72e..1bbcd39b36c 100644 --- a/tests/baselines/reference/computedPropertyNames24_ES5.js +++ b/tests/baselines/reference/computedPropertyNames24_ES5.js @@ -13,7 +13,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/computedPropertyNames25_ES5.js b/tests/baselines/reference/computedPropertyNames25_ES5.js index bb728c8d6ad..eb9a200e83d 100644 --- a/tests/baselines/reference/computedPropertyNames25_ES5.js +++ b/tests/baselines/reference/computedPropertyNames25_ES5.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/computedPropertyNames26_ES5.js b/tests/baselines/reference/computedPropertyNames26_ES5.js index a8efb6fa5a7..51d7ede91ae 100644 --- a/tests/baselines/reference/computedPropertyNames26_ES5.js +++ b/tests/baselines/reference/computedPropertyNames26_ES5.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/computedPropertyNames27_ES5.js b/tests/baselines/reference/computedPropertyNames27_ES5.js index bafb780c3b1..2c1a8f9f665 100644 --- a/tests/baselines/reference/computedPropertyNames27_ES5.js +++ b/tests/baselines/reference/computedPropertyNames27_ES5.js @@ -10,7 +10,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/computedPropertyNames28_ES5.js b/tests/baselines/reference/computedPropertyNames28_ES5.js index ad5df468f13..d9c88696171 100644 --- a/tests/baselines/reference/computedPropertyNames28_ES5.js +++ b/tests/baselines/reference/computedPropertyNames28_ES5.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/computedPropertyNames30_ES5.js b/tests/baselines/reference/computedPropertyNames30_ES5.js index 8342b3db263..e2754e8fcd8 100644 --- a/tests/baselines/reference/computedPropertyNames30_ES5.js +++ b/tests/baselines/reference/computedPropertyNames30_ES5.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/computedPropertyNames31_ES5.js b/tests/baselines/reference/computedPropertyNames31_ES5.js index 1e0fe03a116..ba3f1287ce7 100644 --- a/tests/baselines/reference/computedPropertyNames31_ES5.js +++ b/tests/baselines/reference/computedPropertyNames31_ES5.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/computedPropertyNames43_ES5.js b/tests/baselines/reference/computedPropertyNames43_ES5.js index 4069ebc6d6a..12977c8e75a 100644 --- a/tests/baselines/reference/computedPropertyNames43_ES5.js +++ b/tests/baselines/reference/computedPropertyNames43_ES5.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/computedPropertyNames44_ES5.js b/tests/baselines/reference/computedPropertyNames44_ES5.js index 378fa73c217..a7e8b5885cc 100644 --- a/tests/baselines/reference/computedPropertyNames44_ES5.js +++ b/tests/baselines/reference/computedPropertyNames44_ES5.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/computedPropertyNames45_ES5.js b/tests/baselines/reference/computedPropertyNames45_ES5.js index e93fe496eee..972ffb426eb 100644 --- a/tests/baselines/reference/computedPropertyNames45_ES5.js +++ b/tests/baselines/reference/computedPropertyNames45_ES5.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/conditionalOperatorWithIdenticalBCT.js b/tests/baselines/reference/conditionalOperatorWithIdenticalBCT.js index 85c97190ade..85ac501937c 100644 --- a/tests/baselines/reference/conditionalOperatorWithIdenticalBCT.js +++ b/tests/baselines/reference/conditionalOperatorWithIdenticalBCT.js @@ -52,7 +52,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/conditionalOperatorWithoutIdenticalBCT.js b/tests/baselines/reference/conditionalOperatorWithoutIdenticalBCT.js index dd17f5b1967..fdc638bc9c4 100644 --- a/tests/baselines/reference/conditionalOperatorWithoutIdenticalBCT.js +++ b/tests/baselines/reference/conditionalOperatorWithoutIdenticalBCT.js @@ -28,7 +28,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/constantOverloadFunction.js b/tests/baselines/reference/constantOverloadFunction.js index 54b2686d904..9635e8d6409 100644 --- a/tests/baselines/reference/constantOverloadFunction.js +++ b/tests/baselines/reference/constantOverloadFunction.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/constantOverloadFunctionNoSubtypeError.js b/tests/baselines/reference/constantOverloadFunctionNoSubtypeError.js index b60a0714e3e..793bd82101f 100644 --- a/tests/baselines/reference/constantOverloadFunctionNoSubtypeError.js +++ b/tests/baselines/reference/constantOverloadFunctionNoSubtypeError.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/constraintCheckInGenericBaseTypeReference.js b/tests/baselines/reference/constraintCheckInGenericBaseTypeReference.js index 19cb064dd37..11a9b2217c8 100644 --- a/tests/baselines/reference/constraintCheckInGenericBaseTypeReference.js +++ b/tests/baselines/reference/constraintCheckInGenericBaseTypeReference.js @@ -24,7 +24,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/constructSignatureAssignabilityInInheritance2.js b/tests/baselines/reference/constructSignatureAssignabilityInInheritance2.js index 0fb1dcc3e54..aeff518a0de 100644 --- a/tests/baselines/reference/constructSignatureAssignabilityInInheritance2.js +++ b/tests/baselines/reference/constructSignatureAssignabilityInInheritance2.js @@ -75,7 +75,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/constructSignatureAssignabilityInInheritance3.js b/tests/baselines/reference/constructSignatureAssignabilityInInheritance3.js index 26207746fb8..1f388f4e901 100644 --- a/tests/baselines/reference/constructSignatureAssignabilityInInheritance3.js +++ b/tests/baselines/reference/constructSignatureAssignabilityInInheritance3.js @@ -118,7 +118,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/constructSignatureAssignabilityInInheritance4.js b/tests/baselines/reference/constructSignatureAssignabilityInInheritance4.js index 5a47d0327a7..064dddbaea4 100644 --- a/tests/baselines/reference/constructSignatureAssignabilityInInheritance4.js +++ b/tests/baselines/reference/constructSignatureAssignabilityInInheritance4.js @@ -65,7 +65,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/constructSignatureAssignabilityInInheritance5.js b/tests/baselines/reference/constructSignatureAssignabilityInInheritance5.js index f946ff88fc1..8c97b222d98 100644 --- a/tests/baselines/reference/constructSignatureAssignabilityInInheritance5.js +++ b/tests/baselines/reference/constructSignatureAssignabilityInInheritance5.js @@ -55,7 +55,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/constructSignatureAssignabilityInInheritance6.js b/tests/baselines/reference/constructSignatureAssignabilityInInheritance6.js index 427fa2f1b55..6bf2dfb8e60 100644 --- a/tests/baselines/reference/constructSignatureAssignabilityInInheritance6.js +++ b/tests/baselines/reference/constructSignatureAssignabilityInInheritance6.js @@ -58,7 +58,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/constructorArgs.js b/tests/baselines/reference/constructorArgs.js index 8384613193e..69468cc37d2 100644 --- a/tests/baselines/reference/constructorArgs.js +++ b/tests/baselines/reference/constructorArgs.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/constructorFunctionMergeWithClass.symbols b/tests/baselines/reference/constructorFunctionMergeWithClass.symbols index ecc45e94054..8e2c84568ea 100644 --- a/tests/baselines/reference/constructorFunctionMergeWithClass.symbols +++ b/tests/baselines/reference/constructorFunctionMergeWithClass.symbols @@ -3,6 +3,8 @@ var SomeClass = function () { >SomeClass : Symbol(SomeClass, Decl(file1.js, 0, 3), Decl(file2.js, 0, 0), Decl(file2.js, 0, 19)) this.otherProp = 0; +>this.otherProp : Symbol(SomeClass.otherProp, Decl(file1.js, 0, 29)) +>this : Symbol(SomeClass, Decl(file1.js, 0, 15)) >otherProp : Symbol(SomeClass.otherProp, Decl(file1.js, 0, 29)) }; diff --git a/tests/baselines/reference/constructorFunctionMergeWithClass.types b/tests/baselines/reference/constructorFunctionMergeWithClass.types index 7bed55aacce..7be3ff9ddbe 100644 --- a/tests/baselines/reference/constructorFunctionMergeWithClass.types +++ b/tests/baselines/reference/constructorFunctionMergeWithClass.types @@ -6,7 +6,7 @@ var SomeClass = function () { this.otherProp = 0; >this.otherProp = 0 : 0 >this.otherProp : any ->this : any +>this : this >otherProp : any >0 : 0 diff --git a/tests/baselines/reference/constructorFunctionTypeIsAssignableToBaseType.js b/tests/baselines/reference/constructorFunctionTypeIsAssignableToBaseType.js index f9a54a616a8..9c986128923 100644 --- a/tests/baselines/reference/constructorFunctionTypeIsAssignableToBaseType.js +++ b/tests/baselines/reference/constructorFunctionTypeIsAssignableToBaseType.js @@ -24,7 +24,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/constructorFunctionTypeIsAssignableToBaseType2.js b/tests/baselines/reference/constructorFunctionTypeIsAssignableToBaseType2.js index 542f9621bb8..ac627bc2359 100644 --- a/tests/baselines/reference/constructorFunctionTypeIsAssignableToBaseType2.js +++ b/tests/baselines/reference/constructorFunctionTypeIsAssignableToBaseType2.js @@ -38,7 +38,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/constructorFunctions.symbols b/tests/baselines/reference/constructorFunctions.symbols index 590d4b9b8db..f31c5936801 100644 --- a/tests/baselines/reference/constructorFunctions.symbols +++ b/tests/baselines/reference/constructorFunctions.symbols @@ -3,10 +3,13 @@ function C1() { >C1 : Symbol(C1, Decl(index.js, 0, 0)) if (!(this instanceof C1)) return new C1(); +>this : Symbol(C1, Decl(index.js, 0, 0)) >C1 : Symbol(C1, Decl(index.js, 0, 0)) >C1 : Symbol(C1, Decl(index.js, 0, 0)) this.x = 1; +>this.x : Symbol(C1.x, Decl(index.js, 1, 47)) +>this : Symbol(C1, Decl(index.js, 0, 0)) >x : Symbol(C1.x, Decl(index.js, 1, 47)) } @@ -22,10 +25,13 @@ var C2 = function () { >C2 : Symbol(C2, Decl(index.js, 8, 3)) if (!(this instanceof C2)) return new C2(); +>this : Symbol(C2, Decl(index.js, 8, 8)) >C2 : Symbol(C2, Decl(index.js, 8, 3)) >C2 : Symbol(C2, Decl(index.js, 8, 3)) this.x = 1; +>this.x : Symbol(C2.x, Decl(index.js, 9, 47)) +>this : Symbol(C2, Decl(index.js, 8, 8)) >x : Symbol(C2.x, Decl(index.js, 9, 47)) }; diff --git a/tests/baselines/reference/constructorFunctions.types b/tests/baselines/reference/constructorFunctions.types index 84ad439394d..cde305f3b0b 100644 --- a/tests/baselines/reference/constructorFunctions.types +++ b/tests/baselines/reference/constructorFunctions.types @@ -6,7 +6,7 @@ function C1() { >!(this instanceof C1) : boolean >(this instanceof C1) : boolean >this instanceof C1 : boolean ->this : any +>this : this >C1 : typeof C1 >new C1() : C1 >C1 : typeof C1 @@ -14,7 +14,7 @@ function C1() { this.x = 1; >this.x = 1 : 1 >this.x : any ->this : any +>this : this >x : any >1 : 1 } @@ -37,7 +37,7 @@ var C2 = function () { >!(this instanceof C2) : boolean >(this instanceof C2) : boolean >this instanceof C2 : boolean ->this : any +>this : this >C2 : typeof C2 >new C2() : C2 >C2 : typeof C2 @@ -45,7 +45,7 @@ var C2 = function () { this.x = 1; >this.x = 1 : 1 >this.x : any ->this : any +>this : this >x : any >1 : 1 diff --git a/tests/baselines/reference/constructorFunctions2.symbols b/tests/baselines/reference/constructorFunctions2.symbols index 033a428e6e5..d0b5b991cce 100644 --- a/tests/baselines/reference/constructorFunctions2.symbols +++ b/tests/baselines/reference/constructorFunctions2.symbols @@ -21,6 +21,8 @@ const a = new A().id; const B = function() { this.id = 1; } >B : Symbol(B, Decl(index.js, 3, 5)) +>this.id : Symbol(B.id, Decl(index.js, 3, 22)) +>this : Symbol(B, Decl(index.js, 3, 9)) >id : Symbol(B.id, Decl(index.js, 3, 22)) B.prototype.m = function() { this.x = 2; } @@ -49,6 +51,8 @@ b.x; === tests/cases/conformance/salsa/other.js === function A() { this.id = 1; } >A : Symbol(A, Decl(other.js, 0, 0)) +>this.id : Symbol(A.id, Decl(other.js, 0, 14)) +>this : Symbol(A, Decl(other.js, 0, 0)) >id : Symbol(A.id, Decl(other.js, 0, 14)) module.exports = A; diff --git a/tests/baselines/reference/constructorFunctions2.types b/tests/baselines/reference/constructorFunctions2.types index 2542ec7b5ec..0f5933e04f4 100644 --- a/tests/baselines/reference/constructorFunctions2.types +++ b/tests/baselines/reference/constructorFunctions2.types @@ -26,7 +26,7 @@ const B = function() { this.id = 1; } >function() { this.id = 1; } : typeof B >this.id = 1 : 1 >this.id : any ->this : any +>this : this >id : any >1 : 1 @@ -64,7 +64,7 @@ function A() { this.id = 1; } >A : typeof A >this.id = 1 : 1 >this.id : any ->this : any +>this : this >id : any >1 : 1 diff --git a/tests/baselines/reference/constructorFunctions3.symbols b/tests/baselines/reference/constructorFunctions3.symbols index 385ae3d1be2..4ac15758547 100644 --- a/tests/baselines/reference/constructorFunctions3.symbols +++ b/tests/baselines/reference/constructorFunctions3.symbols @@ -3,6 +3,8 @@ function Instance() { >Instance : Symbol(Instance, Decl(a.js, 0, 0)) this.i = 'simple' +>this.i : Symbol(Instance.i, Decl(a.js, 0, 21)) +>this : Symbol(Instance, Decl(a.js, 0, 0)) >i : Symbol(Instance.i, Decl(a.js, 0, 21)) } var i = new Instance(); @@ -19,6 +21,8 @@ function StaticToo() { >StaticToo : Symbol(StaticToo, Decl(a.js, 5, 2), Decl(a.js, 9, 1)) this.i = 'more complex' +>this.i : Symbol(StaticToo.i, Decl(a.js, 7, 22)) +>this : Symbol(StaticToo, Decl(a.js, 5, 2), Decl(a.js, 9, 1)) >i : Symbol(StaticToo.i, Decl(a.js, 7, 22)) } StaticToo.property = 'yep' @@ -41,10 +45,14 @@ function A () { >A : Symbol(A, Decl(a.js, 13, 10), Decl(a.js, 24, 1)) this.x = 1 +>this.x : Symbol(A.x, Decl(a.js, 16, 15)) +>this : Symbol(A, Decl(a.js, 13, 10), Decl(a.js, 24, 1)) >x : Symbol(A.x, Decl(a.js, 16, 15)) /** @type {1} */ this.second = 1 +>this.second : Symbol(A.second, Decl(a.js, 17, 14)) +>this : Symbol(A, Decl(a.js, 13, 10), Decl(a.js, 24, 1)) >second : Symbol(A.second, Decl(a.js, 17, 14)) } /** @param {number} n */ diff --git a/tests/baselines/reference/constructorFunctions3.types b/tests/baselines/reference/constructorFunctions3.types index d15681c1c86..16283876416 100644 --- a/tests/baselines/reference/constructorFunctions3.types +++ b/tests/baselines/reference/constructorFunctions3.types @@ -5,7 +5,7 @@ function Instance() { this.i = 'simple' >this.i = 'simple' : "simple" >this.i : any ->this : any +>this : this >i : any >'simple' : "simple" } @@ -26,7 +26,7 @@ function StaticToo() { this.i = 'more complex' >this.i = 'more complex' : "more complex" >this.i : any ->this : any +>this : this >i : any >'more complex' : "more complex" } @@ -55,16 +55,16 @@ function A () { this.x = 1 >this.x = 1 : 1 >this.x : any ->this : any +>this : this >x : any >1 : 1 /** @type {1} */ this.second = 1 >this.second = 1 : 1 ->this.second : any ->this : any ->second : any +>this.second : 1 +>this : this +>second : 1 >1 : 1 } /** @param {number} n */ diff --git a/tests/baselines/reference/constructorFunctionsStrict.symbols b/tests/baselines/reference/constructorFunctionsStrict.symbols index 74727d8088a..529770e2628 100644 --- a/tests/baselines/reference/constructorFunctionsStrict.symbols +++ b/tests/baselines/reference/constructorFunctionsStrict.symbols @@ -5,6 +5,8 @@ function C(x) { >x : Symbol(x, Decl(a.js, 1, 11)) this.x = x +>this.x : Symbol(C.x, Decl(a.js, 1, 15)) +>this : Symbol(C, Decl(a.js, 0, 0)) >x : Symbol(C.x, Decl(a.js, 1, 15)) >x : Symbol(x, Decl(a.js, 1, 11)) } @@ -41,6 +43,7 @@ function A(x) { >x : Symbol(x, Decl(a.js, 12, 11)) if (!(this instanceof A)) { +>this : Symbol(A, Decl(a.js, 9, 15)) >A : Symbol(A, Decl(a.js, 9, 15)) return new A(x) @@ -48,6 +51,8 @@ function A(x) { >x : Symbol(x, Decl(a.js, 12, 11)) } this.x = x +>this.x : Symbol(A.x, Decl(a.js, 15, 5)) +>this : Symbol(A, Decl(a.js, 9, 15)) >x : Symbol(A.x, Decl(a.js, 15, 5)) >x : Symbol(x, Decl(a.js, 12, 11)) } diff --git a/tests/baselines/reference/constructorFunctionsStrict.types b/tests/baselines/reference/constructorFunctionsStrict.types index a92024920b5..2a4cf843fe1 100644 --- a/tests/baselines/reference/constructorFunctionsStrict.types +++ b/tests/baselines/reference/constructorFunctionsStrict.types @@ -7,7 +7,7 @@ function C(x) { this.x = x >this.x = x : number >this.x : any ->this : any +>this : this >x : any >x : number } @@ -56,7 +56,7 @@ function A(x) { >!(this instanceof A) : boolean >(this instanceof A) : boolean >this instanceof A : boolean ->this : any +>this : this >A : typeof A return new A(x) @@ -67,7 +67,7 @@ function A(x) { this.x = x >this.x = x : number >this.x : any ->this : any +>this : this >x : any >x : number } diff --git a/tests/baselines/reference/constructorHasPrototypeProperty.js b/tests/baselines/reference/constructorHasPrototypeProperty.js index 739b240847e..9b5fc00896b 100644 --- a/tests/baselines/reference/constructorHasPrototypeProperty.js +++ b/tests/baselines/reference/constructorHasPrototypeProperty.js @@ -36,7 +36,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/constructorOverloads2.js b/tests/baselines/reference/constructorOverloads2.js index 8ee3a8126ce..dc3a4e051c0 100644 --- a/tests/baselines/reference/constructorOverloads2.js +++ b/tests/baselines/reference/constructorOverloads2.js @@ -30,7 +30,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/constructorOverloads3.js b/tests/baselines/reference/constructorOverloads3.js index dc1bdc2fe5f..b958569f536 100644 --- a/tests/baselines/reference/constructorOverloads3.js +++ b/tests/baselines/reference/constructorOverloads3.js @@ -27,7 +27,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/constructorTagWithThisTag.symbols b/tests/baselines/reference/constructorTagWithThisTag.symbols new file mode 100644 index 00000000000..309e9514a56 --- /dev/null +++ b/tests/baselines/reference/constructorTagWithThisTag.symbols @@ -0,0 +1,18 @@ +=== tests/cases/conformance/jsdoc/classthisboth.js === +/** + * @class + * @this {{ e: number, m: number }} + * this-tag should win, both 'e' and 'm' should be defined. + */ +function C() { +>C : Symbol(C, Decl(classthisboth.js, 0, 0)) + + this.e = this.m + 1 +>this.e : Symbol(e, Decl(classthisboth.js, 2, 11)) +>this : Symbol(__type, Decl(classthisboth.js, 2, 10)) +>e : Symbol(C.e, Decl(classthisboth.js, 5, 14)) +>this.m : Symbol(m, Decl(classthisboth.js, 2, 22)) +>this : Symbol(__type, Decl(classthisboth.js, 2, 10)) +>m : Symbol(m, Decl(classthisboth.js, 2, 22)) +} + diff --git a/tests/baselines/reference/constructorTagWithThisTag.types b/tests/baselines/reference/constructorTagWithThisTag.types new file mode 100644 index 00000000000..7b7c2c54072 --- /dev/null +++ b/tests/baselines/reference/constructorTagWithThisTag.types @@ -0,0 +1,21 @@ +=== tests/cases/conformance/jsdoc/classthisboth.js === +/** + * @class + * @this {{ e: number, m: number }} + * this-tag should win, both 'e' and 'm' should be defined. + */ +function C() { +>C : typeof C + + this.e = this.m + 1 +>this.e = this.m + 1 : number +>this.e : number +>this : { e: number; m: number; } +>e : number +>this.m + 1 : number +>this.m : number +>this : { e: number; m: number; } +>m : number +>1 : 1 +} + diff --git a/tests/baselines/reference/constructorWithCapturedSuper.js b/tests/baselines/reference/constructorWithCapturedSuper.js index 75030bccdf2..e8536c7e5f7 100644 --- a/tests/baselines/reference/constructorWithCapturedSuper.js +++ b/tests/baselines/reference/constructorWithCapturedSuper.js @@ -57,7 +57,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/constructorWithIncompleteTypeAnnotation.js b/tests/baselines/reference/constructorWithIncompleteTypeAnnotation.js index 3872e27c5f3..2c8fd577efd 100644 --- a/tests/baselines/reference/constructorWithIncompleteTypeAnnotation.js +++ b/tests/baselines/reference/constructorWithIncompleteTypeAnnotation.js @@ -284,7 +284,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/contextualTypingArrayOfLambdas.js b/tests/baselines/reference/contextualTypingArrayOfLambdas.js index 0ded7accd42..4529a63bcf2 100644 --- a/tests/baselines/reference/contextualTypingArrayOfLambdas.js +++ b/tests/baselines/reference/contextualTypingArrayOfLambdas.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/contextualTypingOfConditionalExpression.js b/tests/baselines/reference/contextualTypingOfConditionalExpression.js index c00f8ddfb53..8f2c67a3caf 100644 --- a/tests/baselines/reference/contextualTypingOfConditionalExpression.js +++ b/tests/baselines/reference/contextualTypingOfConditionalExpression.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/contextualTypingOfConditionalExpression2.js b/tests/baselines/reference/contextualTypingOfConditionalExpression2.js index 82f204bae6b..2d40d6b59ea 100644 --- a/tests/baselines/reference/contextualTypingOfConditionalExpression2.js +++ b/tests/baselines/reference/contextualTypingOfConditionalExpression2.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/controlFlowArrays.js b/tests/baselines/reference/controlFlowArrays.js index 73ac8932f7b..864f28e4f22 100644 --- a/tests/baselines/reference/controlFlowArrays.js +++ b/tests/baselines/reference/controlFlowArrays.js @@ -176,7 +176,16 @@ function f18() { x.unshift("hello"); x[2] = true; return x; // (string | number | boolean)[] -} +} + +// Repro from #39470 + +declare function foo(arg: { val: number }[]): void; + +let arr = [] +arr.push({ val: 1, bar: 2 }); +foo(arr); + //// [controlFlowArrays.js] function f1() { @@ -340,3 +349,6 @@ function f18() { x[2] = true; return x; // (string | number | boolean)[] } +var arr = []; +arr.push({ val: 1, bar: 2 }); +foo(arr); diff --git a/tests/baselines/reference/controlFlowArrays.symbols b/tests/baselines/reference/controlFlowArrays.symbols index 25e5ef01bcf..b36020031dd 100644 --- a/tests/baselines/reference/controlFlowArrays.symbols +++ b/tests/baselines/reference/controlFlowArrays.symbols @@ -467,3 +467,25 @@ function f18() { return x; // (string | number | boolean)[] >x : Symbol(x, Decl(controlFlowArrays.ts, 172, 7)) } + +// Repro from #39470 + +declare function foo(arg: { val: number }[]): void; +>foo : Symbol(foo, Decl(controlFlowArrays.ts, 177, 1)) +>arg : Symbol(arg, Decl(controlFlowArrays.ts, 181, 21)) +>val : Symbol(val, Decl(controlFlowArrays.ts, 181, 27)) + +let arr = [] +>arr : Symbol(arr, Decl(controlFlowArrays.ts, 183, 3)) + +arr.push({ val: 1, bar: 2 }); +>arr.push : Symbol(Array.push, Decl(lib.es5.d.ts, --, --)) +>arr : Symbol(arr, Decl(controlFlowArrays.ts, 183, 3)) +>push : Symbol(Array.push, Decl(lib.es5.d.ts, --, --)) +>val : Symbol(val, Decl(controlFlowArrays.ts, 184, 10)) +>bar : Symbol(bar, Decl(controlFlowArrays.ts, 184, 18)) + +foo(arr); +>foo : Symbol(foo, Decl(controlFlowArrays.ts, 177, 1)) +>arr : Symbol(arr, Decl(controlFlowArrays.ts, 183, 3)) + diff --git a/tests/baselines/reference/controlFlowArrays.types b/tests/baselines/reference/controlFlowArrays.types index 6dbddbda075..80d1e348477 100644 --- a/tests/baselines/reference/controlFlowArrays.types +++ b/tests/baselines/reference/controlFlowArrays.types @@ -612,3 +612,31 @@ function f18() { return x; // (string | number | boolean)[] >x : (string | number | boolean)[] } + +// Repro from #39470 + +declare function foo(arg: { val: number }[]): void; +>foo : (arg: { val: number;}[]) => void +>arg : { val: number; }[] +>val : number + +let arr = [] +>arr : any[] +>[] : never[] + +arr.push({ val: 1, bar: 2 }); +>arr.push({ val: 1, bar: 2 }) : number +>arr.push : (...items: any[]) => number +>arr : any[] +>push : (...items: any[]) => number +>{ val: 1, bar: 2 } : { val: number; bar: number; } +>val : number +>1 : 1 +>bar : number +>2 : 2 + +foo(arr); +>foo(arr) : void +>foo : (arg: { val: number; }[]) => void +>arr : { val: number; bar: number; }[] + diff --git a/tests/baselines/reference/controlFlowSuperPropertyAccess.js b/tests/baselines/reference/controlFlowSuperPropertyAccess.js index 5c33f22f877..cf07d70c998 100644 --- a/tests/baselines/reference/controlFlowSuperPropertyAccess.js +++ b/tests/baselines/reference/controlFlowSuperPropertyAccess.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/crashInsourcePropertyIsRelatableToTargetProperty.js b/tests/baselines/reference/crashInsourcePropertyIsRelatableToTargetProperty.js index 5ee99967e15..7c1c839e8b9 100644 --- a/tests/baselines/reference/crashInsourcePropertyIsRelatableToTargetProperty.js +++ b/tests/baselines/reference/crashInsourcePropertyIsRelatableToTargetProperty.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/declFileClassExtendsNull.js b/tests/baselines/reference/declFileClassExtendsNull.js index daf54d47ade..44a23615581 100644 --- a/tests/baselines/reference/declFileClassExtendsNull.js +++ b/tests/baselines/reference/declFileClassExtendsNull.js @@ -7,7 +7,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/declFileForFunctionTypeAsTypeParameter.js b/tests/baselines/reference/declFileForFunctionTypeAsTypeParameter.js index 5b55aeca977..132aa585814 100644 --- a/tests/baselines/reference/declFileForFunctionTypeAsTypeParameter.js +++ b/tests/baselines/reference/declFileForFunctionTypeAsTypeParameter.js @@ -13,7 +13,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/declFileGenericClassWithGenericExtendedClass.js b/tests/baselines/reference/declFileGenericClassWithGenericExtendedClass.js index 0116eccdeec..97055d908b9 100644 --- a/tests/baselines/reference/declFileGenericClassWithGenericExtendedClass.js +++ b/tests/baselines/reference/declFileGenericClassWithGenericExtendedClass.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/declFileGenericType.js b/tests/baselines/reference/declFileGenericType.js index 8e84a857d46..0365c113585 100644 --- a/tests/baselines/reference/declFileGenericType.js +++ b/tests/baselines/reference/declFileGenericType.js @@ -45,7 +45,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/declFileGenericType2.js b/tests/baselines/reference/declFileGenericType2.js index 9b08417109f..b32203659f3 100644 --- a/tests/baselines/reference/declFileGenericType2.js +++ b/tests/baselines/reference/declFileGenericType2.js @@ -46,7 +46,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/declFileWithClassNameConflictingWithClassReferredByExtendsClause.js b/tests/baselines/reference/declFileWithClassNameConflictingWithClassReferredByExtendsClause.js index 1a923471206..80cec970d8c 100644 --- a/tests/baselines/reference/declFileWithClassNameConflictingWithClassReferredByExtendsClause.js +++ b/tests/baselines/reference/declFileWithClassNameConflictingWithClassReferredByExtendsClause.js @@ -24,7 +24,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/declFileWithExtendsClauseThatHasItsContainerNameConflict.js b/tests/baselines/reference/declFileWithExtendsClauseThatHasItsContainerNameConflict.js index 1072b7fe1e5..a05be0a69c7 100644 --- a/tests/baselines/reference/declFileWithExtendsClauseThatHasItsContainerNameConflict.js +++ b/tests/baselines/reference/declFileWithExtendsClauseThatHasItsContainerNameConflict.js @@ -22,7 +22,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/declarationEmitAliasExportStar.js b/tests/baselines/reference/declarationEmitAliasExportStar.js index 8cd03b75e7c..ee06b84b16b 100644 --- a/tests/baselines/reference/declarationEmitAliasExportStar.js +++ b/tests/baselines/reference/declarationEmitAliasExportStar.js @@ -22,7 +22,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./thingB"), exports); diff --git a/tests/baselines/reference/declarationEmitExportAssignedNamespaceNoTripleSlashTypesReference.js b/tests/baselines/reference/declarationEmitExportAssignedNamespaceNoTripleSlashTypesReference.js index 1e6e0c58f64..57db447de59 100644 --- a/tests/baselines/reference/declarationEmitExportAssignedNamespaceNoTripleSlashTypesReference.js +++ b/tests/baselines/reference/declarationEmitExportAssignedNamespaceNoTripleSlashTypesReference.js @@ -65,7 +65,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("@emotion/core"), exports); diff --git a/tests/baselines/reference/declarationEmitExpressionInExtends.js b/tests/baselines/reference/declarationEmitExpressionInExtends.js index d3e82411976..258423592b8 100644 --- a/tests/baselines/reference/declarationEmitExpressionInExtends.js +++ b/tests/baselines/reference/declarationEmitExpressionInExtends.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/declarationEmitExpressionInExtends2.js b/tests/baselines/reference/declarationEmitExpressionInExtends2.js index 54ced8d3baf..46dd85b9890 100644 --- a/tests/baselines/reference/declarationEmitExpressionInExtends2.js +++ b/tests/baselines/reference/declarationEmitExpressionInExtends2.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/declarationEmitExpressionInExtends3.js b/tests/baselines/reference/declarationEmitExpressionInExtends3.js index 2c711f939f2..bc6a9adf860 100644 --- a/tests/baselines/reference/declarationEmitExpressionInExtends3.js +++ b/tests/baselines/reference/declarationEmitExpressionInExtends3.js @@ -48,7 +48,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/declarationEmitExpressionInExtends4.js b/tests/baselines/reference/declarationEmitExpressionInExtends4.js index 27c7b4350ca..b04d32b0522 100644 --- a/tests/baselines/reference/declarationEmitExpressionInExtends4.js +++ b/tests/baselines/reference/declarationEmitExpressionInExtends4.js @@ -21,7 +21,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/declarationEmitExpressionInExtends5.js b/tests/baselines/reference/declarationEmitExpressionInExtends5.js index f19d0c8862c..41917304e3c 100644 --- a/tests/baselines/reference/declarationEmitExpressionInExtends5.js +++ b/tests/baselines/reference/declarationEmitExpressionInExtends5.js @@ -25,7 +25,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/declarationEmitForDefaultExportClassExtendingExpression01.js b/tests/baselines/reference/declarationEmitForDefaultExportClassExtendingExpression01.js index 4d0006d52e6..ece9d72fc67 100644 --- a/tests/baselines/reference/declarationEmitForDefaultExportClassExtendingExpression01.js +++ b/tests/baselines/reference/declarationEmitForDefaultExportClassExtendingExpression01.js @@ -26,7 +26,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/declarationEmitLocalClassDeclarationMixin.js b/tests/baselines/reference/declarationEmitLocalClassDeclarationMixin.js index ae49a99d745..54b7fdae087 100644 --- a/tests/baselines/reference/declarationEmitLocalClassDeclarationMixin.js +++ b/tests/baselines/reference/declarationEmitLocalClassDeclarationMixin.js @@ -36,7 +36,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/declarationEmitNameConflicts3.js b/tests/baselines/reference/declarationEmitNameConflicts3.js index 6098f5c93e5..73121ebb65c 100644 --- a/tests/baselines/reference/declarationEmitNameConflicts3.js +++ b/tests/baselines/reference/declarationEmitNameConflicts3.js @@ -31,7 +31,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/declarationEmitPrivateNameCausesError.js b/tests/baselines/reference/declarationEmitPrivateNameCausesError.js index 63b4eafbc82..32f449f0c1f 100644 --- a/tests/baselines/reference/declarationEmitPrivateNameCausesError.js +++ b/tests/baselines/reference/declarationEmitPrivateNameCausesError.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/declarationEmitPrivateSymbolCausesVarDeclarationEmit2.js b/tests/baselines/reference/declarationEmitPrivateSymbolCausesVarDeclarationEmit2.js index 0569d6d291b..b3b050b67e8 100644 --- a/tests/baselines/reference/declarationEmitPrivateSymbolCausesVarDeclarationEmit2.js +++ b/tests/baselines/reference/declarationEmitPrivateSymbolCausesVarDeclarationEmit2.js @@ -44,7 +44,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/declarationEmitProtectedMembers.js b/tests/baselines/reference/declarationEmitProtectedMembers.js index ae696091aae..57b42c46510 100644 --- a/tests/baselines/reference/declarationEmitProtectedMembers.js +++ b/tests/baselines/reference/declarationEmitProtectedMembers.js @@ -54,7 +54,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/declarationEmitReexportedSymlinkReference.js b/tests/baselines/reference/declarationEmitReexportedSymlinkReference.js index 99ad86960e2..b658eff96a7 100644 --- a/tests/baselines/reference/declarationEmitReexportedSymlinkReference.js +++ b/tests/baselines/reference/declarationEmitReexportedSymlinkReference.js @@ -59,7 +59,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; Object.defineProperty(exports, "__esModule", { value: true }); __exportStar(require("./keys"), exports); diff --git a/tests/baselines/reference/declarationEmitReexportedSymlinkReference2.js b/tests/baselines/reference/declarationEmitReexportedSymlinkReference2.js index 50c0ddb6f96..01e6e13a563 100644 --- a/tests/baselines/reference/declarationEmitReexportedSymlinkReference2.js +++ b/tests/baselines/reference/declarationEmitReexportedSymlinkReference2.js @@ -62,7 +62,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; Object.defineProperty(exports, "__esModule", { value: true }); __exportStar(require("./keys"), exports); diff --git a/tests/baselines/reference/declarationEmitReexportedSymlinkReference3.js b/tests/baselines/reference/declarationEmitReexportedSymlinkReference3.js index f83c0e0daf3..e69ecceea66 100644 --- a/tests/baselines/reference/declarationEmitReexportedSymlinkReference3.js +++ b/tests/baselines/reference/declarationEmitReexportedSymlinkReference3.js @@ -59,7 +59,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; Object.defineProperty(exports, "__esModule", { value: true }); __exportStar(require("./keys"), exports); diff --git a/tests/baselines/reference/declarationEmitThisPredicates01.js b/tests/baselines/reference/declarationEmitThisPredicates01.js index 5c605ca60ab..3123eaef0fd 100644 --- a/tests/baselines/reference/declarationEmitThisPredicates01.js +++ b/tests/baselines/reference/declarationEmitThisPredicates01.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/declarationEmitThisPredicatesWithPrivateName01.js b/tests/baselines/reference/declarationEmitThisPredicatesWithPrivateName01.js index 5aa93e461c4..757da1020c0 100644 --- a/tests/baselines/reference/declarationEmitThisPredicatesWithPrivateName01.js +++ b/tests/baselines/reference/declarationEmitThisPredicatesWithPrivateName01.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/declarationNoDanglingGenerics.js b/tests/baselines/reference/declarationNoDanglingGenerics.js index 99aa165f5fb..9f7a6956635 100644 --- a/tests/baselines/reference/declarationNoDanglingGenerics.js +++ b/tests/baselines/reference/declarationNoDanglingGenerics.js @@ -38,7 +38,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/declarationsForFileShadowingGlobalNoError.js b/tests/baselines/reference/declarationsForFileShadowingGlobalNoError.js index 99226383835..561bed919c3 100644 --- a/tests/baselines/reference/declarationsForFileShadowingGlobalNoError.js +++ b/tests/baselines/reference/declarationsForFileShadowingGlobalNoError.js @@ -28,7 +28,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/declareDottedExtend.js b/tests/baselines/reference/declareDottedExtend.js index 4adc5fb3292..dd4b295b347 100644 --- a/tests/baselines/reference/declareDottedExtend.js +++ b/tests/baselines/reference/declareDottedExtend.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/decoratorOnClass9.js b/tests/baselines/reference/decoratorOnClass9.js index 71c56d00ee6..87f1fd3bdc9 100644 --- a/tests/baselines/reference/decoratorOnClass9.js +++ b/tests/baselines/reference/decoratorOnClass9.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/decoratorOnClassConstructor2.js b/tests/baselines/reference/decoratorOnClassConstructor2.js index 1ebdc5d1e69..1ecb54daa1f 100644 --- a/tests/baselines/reference/decoratorOnClassConstructor2.js +++ b/tests/baselines/reference/decoratorOnClassConstructor2.js @@ -31,7 +31,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/decoratorOnClassConstructor3.js b/tests/baselines/reference/decoratorOnClassConstructor3.js index 5e11c3d2a0c..9167f24a393 100644 --- a/tests/baselines/reference/decoratorOnClassConstructor3.js +++ b/tests/baselines/reference/decoratorOnClassConstructor3.js @@ -33,7 +33,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/decoratorOnClassConstructor4.js b/tests/baselines/reference/decoratorOnClassConstructor4.js index eddda104575..03465dd8ff8 100644 --- a/tests/baselines/reference/decoratorOnClassConstructor4.js +++ b/tests/baselines/reference/decoratorOnClassConstructor4.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/decoratorOnClassMethod12.js b/tests/baselines/reference/decoratorOnClassMethod12.js index 345f4c9aeee..4b430b15cc2 100644 --- a/tests/baselines/reference/decoratorOnClassMethod12.js +++ b/tests/baselines/reference/decoratorOnClassMethod12.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/defaultPropsEmptyCurlyBecomesAnyForJs.js b/tests/baselines/reference/defaultPropsEmptyCurlyBecomesAnyForJs.js index d3ce8ea25c4..a7c42f0b94f 100644 --- a/tests/baselines/reference/defaultPropsEmptyCurlyBecomesAnyForJs.js +++ b/tests/baselines/reference/defaultPropsEmptyCurlyBecomesAnyForJs.js @@ -31,7 +31,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { @@ -57,7 +57,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/defineProperty(target=es5).js b/tests/baselines/reference/defineProperty(target=es5).js index c7ef0c6d39c..72b1a1df4a4 100644 --- a/tests/baselines/reference/defineProperty(target=es5).js +++ b/tests/baselines/reference/defineProperty(target=es5).js @@ -29,7 +29,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassConstructorWithExplicitReturns01.js b/tests/baselines/reference/derivedClassConstructorWithExplicitReturns01.js index 7e8ee59f1a9..0597a4eac2c 100644 --- a/tests/baselines/reference/derivedClassConstructorWithExplicitReturns01.js +++ b/tests/baselines/reference/derivedClassConstructorWithExplicitReturns01.js @@ -38,7 +38,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassConstructorWithExplicitReturns01.js.map b/tests/baselines/reference/derivedClassConstructorWithExplicitReturns01.js.map index adbe62983b1..63d87aceca7 100644 --- a/tests/baselines/reference/derivedClassConstructorWithExplicitReturns01.js.map +++ b/tests/baselines/reference/derivedClassConstructorWithExplicitReturns01.js.map @@ -1,3 +1,3 @@ //// [derivedClassConstructorWithExplicitReturns01.js.map] {"version":3,"file":"derivedClassConstructorWithExplicitReturns01.js","sourceRoot":"","sources":["derivedClassConstructorWithExplicitReturns01.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA;IAKI,WAAY,KAAa;QAJzB,UAAK,GAAG,EAAE,CAAC;QAKP,OAAO;YACH,KAAK,EAAE,KAAK;YACZ,GAAG;gBACC,OAAO,8BAA8B,CAAC;YAC1C,CAAC;SACJ,CAAA;IACL,CAAC;IATD,eAAG,GAAH,cAAQ,OAAO,uBAAuB,CAAC,CAAC,CAAC;IAU7C,QAAC;AAAD,CAAC,AAbD,IAaC;AAED;IAAgB,qBAAC;IAGb,WAAY,CAAO;QAAP,kBAAA,EAAA,OAAO;QAAnB,YACI,kBAAM,CAAC,CAAC,SAYX;QAfD,WAAK,GAAG,cAAM,OAAA,KAAI,EAAJ,CAAI,CAAC;QAKf,IAAI,IAAI,CAAC,MAAM,EAAE,GAAG,GAAG,EAAE;YACrB,UAAU,CAAA;YACV,OAAO;gBACH,KAAK,EAAE,CAAC;gBACR,KAAK,EAAE,cAAM,OAAA,KAAI,EAAJ,CAAI;gBACjB,GAAG,gBAAK,OAAO,cAAc,CAAA,CAAC,CAAC;aAClC,CAAC;SACL;;YAEG,OAAO,IAAI,CAAC;IACpB,CAAC;IACL,QAAC;AAAD,CAAC,AAjBD,CAAgB,CAAC,GAiBhB"} -//// https://sokra.github.io/source-map-visualization#base64,dmFyIF9fZXh0ZW5kcyA9ICh0aGlzICYmIHRoaXMuX19leHRlbmRzKSB8fCAoZnVuY3Rpb24gKCkgew0KICAgIHZhciBleHRlbmRTdGF0aWNzID0gZnVuY3Rpb24gKGQsIGIpIHsNCiAgICAgICAgZXh0ZW5kU3RhdGljcyA9IE9iamVjdC5zZXRQcm90b3R5cGVPZiB8fA0KICAgICAgICAgICAgKHsgX19wcm90b19fOiBbXSB9IGluc3RhbmNlb2YgQXJyYXkgJiYgZnVuY3Rpb24gKGQsIGIpIHsgZC5fX3Byb3RvX18gPSBiOyB9KSB8fA0KICAgICAgICAgICAgZnVuY3Rpb24gKGQsIGIpIHsgZm9yICh2YXIgcCBpbiBiKSBpZiAoYi5oYXNPd25Qcm9wZXJ0eShwKSkgZFtwXSA9IGJbcF07IH07DQogICAgICAgIHJldHVybiBleHRlbmRTdGF0aWNzKGQsIGIpOw0KICAgIH07DQogICAgcmV0dXJuIGZ1bmN0aW9uIChkLCBiKSB7DQogICAgICAgIGV4dGVuZFN0YXRpY3MoZCwgYik7DQogICAgICAgIGZ1bmN0aW9uIF9fKCkgeyB0aGlzLmNvbnN0cnVjdG9yID0gZDsgfQ0KICAgICAgICBkLnByb3RvdHlwZSA9IGIgPT09IG51bGwgPyBPYmplY3QuY3JlYXRlKGIpIDogKF9fLnByb3RvdHlwZSA9IGIucHJvdG90eXBlLCBuZXcgX18oKSk7DQogICAgfTsNCn0pKCk7DQp2YXIgQyA9IC8qKiBAY2xhc3MgKi8gKGZ1bmN0aW9uICgpIHsNCiAgICBmdW5jdGlvbiBDKHZhbHVlKSB7DQogICAgICAgIHRoaXMuY1Byb3AgPSAxMDsNCiAgICAgICAgcmV0dXJuIHsNCiAgICAgICAgICAgIGNQcm9wOiB2YWx1ZSwNCiAgICAgICAgICAgIGZvbzogZnVuY3Rpb24gKCkgew0KICAgICAgICAgICAgICAgIHJldHVybiAid2VsbCB0aGlzIGxvb2tzIGtpbmRhIEMtaXNoLiI7DQogICAgICAgICAgICB9DQogICAgICAgIH07DQogICAgfQ0KICAgIEMucHJvdG90eXBlLmZvbyA9IGZ1bmN0aW9uICgpIHsgcmV0dXJuICJ0aGlzIG5ldmVyIGdldHMgdXNlZC4iOyB9Ow0KICAgIHJldHVybiBDOw0KfSgpKTsNCnZhciBEID0gLyoqIEBjbGFzcyAqLyAoZnVuY3Rpb24gKF9zdXBlcikgew0KICAgIF9fZXh0ZW5kcyhELCBfc3VwZXIpOw0KICAgIGZ1bmN0aW9uIEQoYSkgew0KICAgICAgICBpZiAoYSA9PT0gdm9pZCAwKSB7IGEgPSAxMDA7IH0NCiAgICAgICAgdmFyIF90aGlzID0gX3N1cGVyLmNhbGwodGhpcywgYSkgfHwgdGhpczsNCiAgICAgICAgX3RoaXMuZFByb3AgPSBmdW5jdGlvbiAoKSB7IHJldHVybiBfdGhpczsgfTsNCiAgICAgICAgaWYgKE1hdGgucmFuZG9tKCkgPCAwLjUpIHsNCiAgICAgICAgICAgICJZb3Ugd2luISI7DQogICAgICAgICAgICByZXR1cm4gew0KICAgICAgICAgICAgICAgIGNQcm9wOiAxLA0KICAgICAgICAgICAgICAgIGRQcm9wOiBmdW5jdGlvbiAoKSB7IHJldHVybiBfdGhpczsgfSwNCiAgICAgICAgICAgICAgICBmb286IGZ1bmN0aW9uICgpIHsgcmV0dXJuICJZb3Ugd2luISEhISEiOyB9DQogICAgICAgICAgICB9Ow0KICAgICAgICB9DQogICAgICAgIGVsc2UNCiAgICAgICAgICAgIHJldHVybiBudWxsOw0KICAgIH0NCiAgICByZXR1cm4gRDsNCn0oQykpOw0KLy8jIHNvdXJjZU1hcHBpbmdVUkw9ZGVyaXZlZENsYXNzQ29uc3RydWN0b3JXaXRoRXhwbGljaXRSZXR1cm5zMDEuanMubWFw,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGVyaXZlZENsYXNzQ29uc3RydWN0b3JXaXRoRXhwbGljaXRSZXR1cm5zMDEuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJkZXJpdmVkQ2xhc3NDb25zdHJ1Y3RvcldpdGhFeHBsaWNpdFJldHVybnMwMS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7Ozs7Ozs7Ozs7O0FBQUE7SUFLSSxXQUFZLEtBQWE7UUFKekIsVUFBSyxHQUFHLEVBQUUsQ0FBQztRQUtQLE9BQU87WUFDSCxLQUFLLEVBQUUsS0FBSztZQUNaLEdBQUc7Z0JBQ0MsT0FBTyw4QkFBOEIsQ0FBQztZQUMxQyxDQUFDO1NBQ0osQ0FBQTtJQUNMLENBQUM7SUFURCxlQUFHLEdBQUgsY0FBUSxPQUFPLHVCQUF1QixDQUFDLENBQUMsQ0FBQztJQVU3QyxRQUFDO0FBQUQsQ0FBQyxBQWJELElBYUM7QUFFRDtJQUFnQixxQkFBQztJQUdiLFdBQVksQ0FBTztRQUFQLGtCQUFBLEVBQUEsT0FBTztRQUFuQixZQUNJLGtCQUFNLENBQUMsQ0FBQyxTQVlYO1FBZkQsV0FBSyxHQUFHLGNBQU0sT0FBQSxLQUFJLEVBQUosQ0FBSSxDQUFDO1FBS2YsSUFBSSxJQUFJLENBQUMsTUFBTSxFQUFFLEdBQUcsR0FBRyxFQUFFO1lBQ3JCLFVBQVUsQ0FBQTtZQUNWLE9BQU87Z0JBQ0gsS0FBSyxFQUFFLENBQUM7Z0JBQ1IsS0FBSyxFQUFFLGNBQU0sT0FBQSxLQUFJLEVBQUosQ0FBSTtnQkFDakIsR0FBRyxnQkFBSyxPQUFPLGNBQWMsQ0FBQSxDQUFDLENBQUM7YUFDbEMsQ0FBQztTQUNMOztZQUVHLE9BQU8sSUFBSSxDQUFDO0lBQ3BCLENBQUM7SUFDTCxRQUFDO0FBQUQsQ0FBQyxBQWpCRCxDQUFnQixDQUFDLEdBaUJoQiJ9,Y2xhc3MgQyB7CiAgICBjUHJvcCA9IDEwOwoKICAgIGZvbygpIHsgcmV0dXJuICJ0aGlzIG5ldmVyIGdldHMgdXNlZC4iOyB9CgogICAgY29uc3RydWN0b3IodmFsdWU6IG51bWJlcikgewogICAgICAgIHJldHVybiB7CiAgICAgICAgICAgIGNQcm9wOiB2YWx1ZSwKICAgICAgICAgICAgZm9vKCkgewogICAgICAgICAgICAgICAgcmV0dXJuICJ3ZWxsIHRoaXMgbG9va3Mga2luZGEgQy1pc2guIjsKICAgICAgICAgICAgfQogICAgICAgIH0KICAgIH0KfQoKY2xhc3MgRCBleHRlbmRzIEMgewogICAgZFByb3AgPSAoKSA9PiB0aGlzOwoKICAgIGNvbnN0cnVjdG9yKGEgPSAxMDApIHsKICAgICAgICBzdXBlcihhKTsKCiAgICAgICAgaWYgKE1hdGgucmFuZG9tKCkgPCAwLjUpIHsKICAgICAgICAgICAgIllvdSB3aW4hIgogICAgICAgICAgICByZXR1cm4gewogICAgICAgICAgICAgICAgY1Byb3A6IDEsCiAgICAgICAgICAgICAgICBkUHJvcDogKCkgPT4gdGhpcywKICAgICAgICAgICAgICAgIGZvbygpIHsgcmV0dXJuICJZb3Ugd2luISEhISEiIH0KICAgICAgICAgICAgfTsKICAgICAgICB9CiAgICAgICAgZWxzZQogICAgICAgICAgICByZXR1cm4gbnVsbDsKICAgIH0KfQ== +//// https://sokra.github.io/source-map-visualization#base64,dmFyIF9fZXh0ZW5kcyA9ICh0aGlzICYmIHRoaXMuX19leHRlbmRzKSB8fCAoZnVuY3Rpb24gKCkgew0KICAgIHZhciBleHRlbmRTdGF0aWNzID0gZnVuY3Rpb24gKGQsIGIpIHsNCiAgICAgICAgZXh0ZW5kU3RhdGljcyA9IE9iamVjdC5zZXRQcm90b3R5cGVPZiB8fA0KICAgICAgICAgICAgKHsgX19wcm90b19fOiBbXSB9IGluc3RhbmNlb2YgQXJyYXkgJiYgZnVuY3Rpb24gKGQsIGIpIHsgZC5fX3Byb3RvX18gPSBiOyB9KSB8fA0KICAgICAgICAgICAgZnVuY3Rpb24gKGQsIGIpIHsgZm9yICh2YXIgcCBpbiBiKSBpZiAoT2JqZWN0LnByb3RvdHlwZS5oYXNPd25Qcm9wZXJ0eS5jYWxsKGIsIHApKSBkW3BdID0gYltwXTsgfTsNCiAgICAgICAgcmV0dXJuIGV4dGVuZFN0YXRpY3MoZCwgYik7DQogICAgfTsNCiAgICByZXR1cm4gZnVuY3Rpb24gKGQsIGIpIHsNCiAgICAgICAgZXh0ZW5kU3RhdGljcyhkLCBiKTsNCiAgICAgICAgZnVuY3Rpb24gX18oKSB7IHRoaXMuY29uc3RydWN0b3IgPSBkOyB9DQogICAgICAgIGQucHJvdG90eXBlID0gYiA9PT0gbnVsbCA/IE9iamVjdC5jcmVhdGUoYikgOiAoX18ucHJvdG90eXBlID0gYi5wcm90b3R5cGUsIG5ldyBfXygpKTsNCiAgICB9Ow0KfSkoKTsNCnZhciBDID0gLyoqIEBjbGFzcyAqLyAoZnVuY3Rpb24gKCkgew0KICAgIGZ1bmN0aW9uIEModmFsdWUpIHsNCiAgICAgICAgdGhpcy5jUHJvcCA9IDEwOw0KICAgICAgICByZXR1cm4gew0KICAgICAgICAgICAgY1Byb3A6IHZhbHVlLA0KICAgICAgICAgICAgZm9vOiBmdW5jdGlvbiAoKSB7DQogICAgICAgICAgICAgICAgcmV0dXJuICJ3ZWxsIHRoaXMgbG9va3Mga2luZGEgQy1pc2guIjsNCiAgICAgICAgICAgIH0NCiAgICAgICAgfTsNCiAgICB9DQogICAgQy5wcm90b3R5cGUuZm9vID0gZnVuY3Rpb24gKCkgeyByZXR1cm4gInRoaXMgbmV2ZXIgZ2V0cyB1c2VkLiI7IH07DQogICAgcmV0dXJuIEM7DQp9KCkpOw0KdmFyIEQgPSAvKiogQGNsYXNzICovIChmdW5jdGlvbiAoX3N1cGVyKSB7DQogICAgX19leHRlbmRzKEQsIF9zdXBlcik7DQogICAgZnVuY3Rpb24gRChhKSB7DQogICAgICAgIGlmIChhID09PSB2b2lkIDApIHsgYSA9IDEwMDsgfQ0KICAgICAgICB2YXIgX3RoaXMgPSBfc3VwZXIuY2FsbCh0aGlzLCBhKSB8fCB0aGlzOw0KICAgICAgICBfdGhpcy5kUHJvcCA9IGZ1bmN0aW9uICgpIHsgcmV0dXJuIF90aGlzOyB9Ow0KICAgICAgICBpZiAoTWF0aC5yYW5kb20oKSA8IDAuNSkgew0KICAgICAgICAgICAgIllvdSB3aW4hIjsNCiAgICAgICAgICAgIHJldHVybiB7DQogICAgICAgICAgICAgICAgY1Byb3A6IDEsDQogICAgICAgICAgICAgICAgZFByb3A6IGZ1bmN0aW9uICgpIHsgcmV0dXJuIF90aGlzOyB9LA0KICAgICAgICAgICAgICAgIGZvbzogZnVuY3Rpb24gKCkgeyByZXR1cm4gIllvdSB3aW4hISEhISI7IH0NCiAgICAgICAgICAgIH07DQogICAgICAgIH0NCiAgICAgICAgZWxzZQ0KICAgICAgICAgICAgcmV0dXJuIG51bGw7DQogICAgfQ0KICAgIHJldHVybiBEOw0KfShDKSk7DQovLyMgc291cmNlTWFwcGluZ1VSTD1kZXJpdmVkQ2xhc3NDb25zdHJ1Y3RvcldpdGhFeHBsaWNpdFJldHVybnMwMS5qcy5tYXA=,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGVyaXZlZENsYXNzQ29uc3RydWN0b3JXaXRoRXhwbGljaXRSZXR1cm5zMDEuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJkZXJpdmVkQ2xhc3NDb25zdHJ1Y3RvcldpdGhFeHBsaWNpdFJldHVybnMwMS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7Ozs7Ozs7Ozs7O0FBQUE7SUFLSSxXQUFZLEtBQWE7UUFKekIsVUFBSyxHQUFHLEVBQUUsQ0FBQztRQUtQLE9BQU87WUFDSCxLQUFLLEVBQUUsS0FBSztZQUNaLEdBQUc7Z0JBQ0MsT0FBTyw4QkFBOEIsQ0FBQztZQUMxQyxDQUFDO1NBQ0osQ0FBQTtJQUNMLENBQUM7SUFURCxlQUFHLEdBQUgsY0FBUSxPQUFPLHVCQUF1QixDQUFDLENBQUMsQ0FBQztJQVU3QyxRQUFDO0FBQUQsQ0FBQyxBQWJELElBYUM7QUFFRDtJQUFnQixxQkFBQztJQUdiLFdBQVksQ0FBTztRQUFQLGtCQUFBLEVBQUEsT0FBTztRQUFuQixZQUNJLGtCQUFNLENBQUMsQ0FBQyxTQVlYO1FBZkQsV0FBSyxHQUFHLGNBQU0sT0FBQSxLQUFJLEVBQUosQ0FBSSxDQUFDO1FBS2YsSUFBSSxJQUFJLENBQUMsTUFBTSxFQUFFLEdBQUcsR0FBRyxFQUFFO1lBQ3JCLFVBQVUsQ0FBQTtZQUNWLE9BQU87Z0JBQ0gsS0FBSyxFQUFFLENBQUM7Z0JBQ1IsS0FBSyxFQUFFLGNBQU0sT0FBQSxLQUFJLEVBQUosQ0FBSTtnQkFDakIsR0FBRyxnQkFBSyxPQUFPLGNBQWMsQ0FBQSxDQUFDLENBQUM7YUFDbEMsQ0FBQztTQUNMOztZQUVHLE9BQU8sSUFBSSxDQUFDO0lBQ3BCLENBQUM7SUFDTCxRQUFDO0FBQUQsQ0FBQyxBQWpCRCxDQUFnQixDQUFDLEdBaUJoQiJ9,Y2xhc3MgQyB7CiAgICBjUHJvcCA9IDEwOwoKICAgIGZvbygpIHsgcmV0dXJuICJ0aGlzIG5ldmVyIGdldHMgdXNlZC4iOyB9CgogICAgY29uc3RydWN0b3IodmFsdWU6IG51bWJlcikgewogICAgICAgIHJldHVybiB7CiAgICAgICAgICAgIGNQcm9wOiB2YWx1ZSwKICAgICAgICAgICAgZm9vKCkgewogICAgICAgICAgICAgICAgcmV0dXJuICJ3ZWxsIHRoaXMgbG9va3Mga2luZGEgQy1pc2guIjsKICAgICAgICAgICAgfQogICAgICAgIH0KICAgIH0KfQoKY2xhc3MgRCBleHRlbmRzIEMgewogICAgZFByb3AgPSAoKSA9PiB0aGlzOwoKICAgIGNvbnN0cnVjdG9yKGEgPSAxMDApIHsKICAgICAgICBzdXBlcihhKTsKCiAgICAgICAgaWYgKE1hdGgucmFuZG9tKCkgPCAwLjUpIHsKICAgICAgICAgICAgIllvdSB3aW4hIgogICAgICAgICAgICByZXR1cm4gewogICAgICAgICAgICAgICAgY1Byb3A6IDEsCiAgICAgICAgICAgICAgICBkUHJvcDogKCkgPT4gdGhpcywKICAgICAgICAgICAgICAgIGZvbygpIHsgcmV0dXJuICJZb3Ugd2luISEhISEiIH0KICAgICAgICAgICAgfTsKICAgICAgICB9CiAgICAgICAgZWxzZQogICAgICAgICAgICByZXR1cm4gbnVsbDsKICAgIH0KfQ== diff --git a/tests/baselines/reference/derivedClassConstructorWithExplicitReturns01.sourcemap.txt b/tests/baselines/reference/derivedClassConstructorWithExplicitReturns01.sourcemap.txt index 56a565db980..55635afb425 100644 --- a/tests/baselines/reference/derivedClassConstructorWithExplicitReturns01.sourcemap.txt +++ b/tests/baselines/reference/derivedClassConstructorWithExplicitReturns01.sourcemap.txt @@ -12,7 +12,7 @@ sourceFile:derivedClassConstructorWithExplicitReturns01.ts >>> var extendStatics = function (d, b) { >>> extendStatics = Object.setPrototypeOf || >>> ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || ->>> function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; +>>> function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; >>> return extendStatics(d, b); >>> }; >>> return function (d, b) { diff --git a/tests/baselines/reference/derivedClassConstructorWithoutSuperCall.js b/tests/baselines/reference/derivedClassConstructorWithoutSuperCall.js index 32edf0885e9..11af2612027 100644 --- a/tests/baselines/reference/derivedClassConstructorWithoutSuperCall.js +++ b/tests/baselines/reference/derivedClassConstructorWithoutSuperCall.js @@ -38,7 +38,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassFunctionOverridesBaseClassAccessor.js b/tests/baselines/reference/derivedClassFunctionOverridesBaseClassAccessor.js index 6c7ef87451b..634aef4b2f6 100644 --- a/tests/baselines/reference/derivedClassFunctionOverridesBaseClassAccessor.js +++ b/tests/baselines/reference/derivedClassFunctionOverridesBaseClassAccessor.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassIncludesInheritedMembers.js b/tests/baselines/reference/derivedClassIncludesInheritedMembers.js index 2b7977f27ff..9a9b3d40a25 100644 --- a/tests/baselines/reference/derivedClassIncludesInheritedMembers.js +++ b/tests/baselines/reference/derivedClassIncludesInheritedMembers.js @@ -45,7 +45,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassOverridesIndexersWithAssignmentCompatibility.js b/tests/baselines/reference/derivedClassOverridesIndexersWithAssignmentCompatibility.js index f5019942482..f6e791e800b 100644 --- a/tests/baselines/reference/derivedClassOverridesIndexersWithAssignmentCompatibility.js +++ b/tests/baselines/reference/derivedClassOverridesIndexersWithAssignmentCompatibility.js @@ -22,7 +22,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassOverridesPrivateFunction1.js b/tests/baselines/reference/derivedClassOverridesPrivateFunction1.js index b84daa18b66..10623687a09 100644 --- a/tests/baselines/reference/derivedClassOverridesPrivateFunction1.js +++ b/tests/baselines/reference/derivedClassOverridesPrivateFunction1.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassOverridesPrivates.js b/tests/baselines/reference/derivedClassOverridesPrivates.js index d313a5b5647..5eda2798247 100644 --- a/tests/baselines/reference/derivedClassOverridesPrivates.js +++ b/tests/baselines/reference/derivedClassOverridesPrivates.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassOverridesProtectedMembers.js b/tests/baselines/reference/derivedClassOverridesProtectedMembers.js index 9c8a5ecd12c..1c02ac56bd2 100644 --- a/tests/baselines/reference/derivedClassOverridesProtectedMembers.js +++ b/tests/baselines/reference/derivedClassOverridesProtectedMembers.js @@ -40,7 +40,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassOverridesProtectedMembers2.js b/tests/baselines/reference/derivedClassOverridesProtectedMembers2.js index c956c36d1e5..d6bbac38485 100644 --- a/tests/baselines/reference/derivedClassOverridesProtectedMembers2.js +++ b/tests/baselines/reference/derivedClassOverridesProtectedMembers2.js @@ -68,7 +68,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassOverridesProtectedMembers3.js b/tests/baselines/reference/derivedClassOverridesProtectedMembers3.js index d709622f356..245d43cb3c4 100644 --- a/tests/baselines/reference/derivedClassOverridesProtectedMembers3.js +++ b/tests/baselines/reference/derivedClassOverridesProtectedMembers3.js @@ -75,7 +75,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassOverridesProtectedMembers4.js b/tests/baselines/reference/derivedClassOverridesProtectedMembers4.js index 099c450f692..23dce748e06 100644 --- a/tests/baselines/reference/derivedClassOverridesProtectedMembers4.js +++ b/tests/baselines/reference/derivedClassOverridesProtectedMembers4.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassOverridesPublicMembers.js b/tests/baselines/reference/derivedClassOverridesPublicMembers.js index f0c9651258b..8143a1843a2 100644 --- a/tests/baselines/reference/derivedClassOverridesPublicMembers.js +++ b/tests/baselines/reference/derivedClassOverridesPublicMembers.js @@ -67,7 +67,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassOverridesWithoutSubtype.js b/tests/baselines/reference/derivedClassOverridesWithoutSubtype.js index e526f7d8d9b..ae49f5853b2 100644 --- a/tests/baselines/reference/derivedClassOverridesWithoutSubtype.js +++ b/tests/baselines/reference/derivedClassOverridesWithoutSubtype.js @@ -28,7 +28,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassParameterProperties.js b/tests/baselines/reference/derivedClassParameterProperties.js index a3213b0ebbd..81a74f727ee 100644 --- a/tests/baselines/reference/derivedClassParameterProperties.js +++ b/tests/baselines/reference/derivedClassParameterProperties.js @@ -100,7 +100,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassSuperCallsInNonConstructorMembers.js b/tests/baselines/reference/derivedClassSuperCallsInNonConstructorMembers.js index b21d847aa57..49594dd68ec 100644 --- a/tests/baselines/reference/derivedClassSuperCallsInNonConstructorMembers.js +++ b/tests/baselines/reference/derivedClassSuperCallsInNonConstructorMembers.js @@ -37,7 +37,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassSuperCallsWithThisArg.js b/tests/baselines/reference/derivedClassSuperCallsWithThisArg.js index 93599cfbeea..60dbc1895dd 100644 --- a/tests/baselines/reference/derivedClassSuperCallsWithThisArg.js +++ b/tests/baselines/reference/derivedClassSuperCallsWithThisArg.js @@ -33,7 +33,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassTransitivity.js b/tests/baselines/reference/derivedClassTransitivity.js index 3a5641b5feb..e237985dd2c 100644 --- a/tests/baselines/reference/derivedClassTransitivity.js +++ b/tests/baselines/reference/derivedClassTransitivity.js @@ -26,7 +26,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassTransitivity2.js b/tests/baselines/reference/derivedClassTransitivity2.js index fcd9a6eb6dc..d71adae47e1 100644 --- a/tests/baselines/reference/derivedClassTransitivity2.js +++ b/tests/baselines/reference/derivedClassTransitivity2.js @@ -26,7 +26,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassTransitivity3.js b/tests/baselines/reference/derivedClassTransitivity3.js index b0b8481b224..6c8fce22d0e 100644 --- a/tests/baselines/reference/derivedClassTransitivity3.js +++ b/tests/baselines/reference/derivedClassTransitivity3.js @@ -26,7 +26,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassTransitivity4.js b/tests/baselines/reference/derivedClassTransitivity4.js index b5785a3cb4f..c5ab456b14f 100644 --- a/tests/baselines/reference/derivedClassTransitivity4.js +++ b/tests/baselines/reference/derivedClassTransitivity4.js @@ -26,7 +26,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassWithAny.js b/tests/baselines/reference/derivedClassWithAny.js index 57d540bed82..40a1aff33df 100644 --- a/tests/baselines/reference/derivedClassWithAny.js +++ b/tests/baselines/reference/derivedClassWithAny.js @@ -64,7 +64,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassWithPrivateInstanceShadowingProtectedInstance.js b/tests/baselines/reference/derivedClassWithPrivateInstanceShadowingProtectedInstance.js index 550927ab3ac..4f3b36091ff 100644 --- a/tests/baselines/reference/derivedClassWithPrivateInstanceShadowingProtectedInstance.js +++ b/tests/baselines/reference/derivedClassWithPrivateInstanceShadowingProtectedInstance.js @@ -26,7 +26,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassWithPrivateInstanceShadowingPublicInstance.js b/tests/baselines/reference/derivedClassWithPrivateInstanceShadowingPublicInstance.js index b2fc8c9ccb0..dc60996a983 100644 --- a/tests/baselines/reference/derivedClassWithPrivateInstanceShadowingPublicInstance.js +++ b/tests/baselines/reference/derivedClassWithPrivateInstanceShadowingPublicInstance.js @@ -37,7 +37,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassWithPrivateStaticShadowingProtectedStatic.js b/tests/baselines/reference/derivedClassWithPrivateStaticShadowingProtectedStatic.js index 35ef4038dd4..ab7c81dd200 100644 --- a/tests/baselines/reference/derivedClassWithPrivateStaticShadowingProtectedStatic.js +++ b/tests/baselines/reference/derivedClassWithPrivateStaticShadowingProtectedStatic.js @@ -25,7 +25,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassWithPrivateStaticShadowingPublicStatic.js b/tests/baselines/reference/derivedClassWithPrivateStaticShadowingPublicStatic.js index 35b9386cd94..38b581ea303 100644 --- a/tests/baselines/reference/derivedClassWithPrivateStaticShadowingPublicStatic.js +++ b/tests/baselines/reference/derivedClassWithPrivateStaticShadowingPublicStatic.js @@ -38,7 +38,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassWithoutExplicitConstructor.js b/tests/baselines/reference/derivedClassWithoutExplicitConstructor.js index 0a33ed849d0..ee8e936d1ce 100644 --- a/tests/baselines/reference/derivedClassWithoutExplicitConstructor.js +++ b/tests/baselines/reference/derivedClassWithoutExplicitConstructor.js @@ -30,7 +30,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassWithoutExplicitConstructor2.js b/tests/baselines/reference/derivedClassWithoutExplicitConstructor2.js index b74a76f85a2..5946f331aaf 100644 --- a/tests/baselines/reference/derivedClassWithoutExplicitConstructor2.js +++ b/tests/baselines/reference/derivedClassWithoutExplicitConstructor2.js @@ -38,7 +38,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClassWithoutExplicitConstructor3.js b/tests/baselines/reference/derivedClassWithoutExplicitConstructor3.js index efc9e5655ec..6618e723e1d 100644 --- a/tests/baselines/reference/derivedClassWithoutExplicitConstructor3.js +++ b/tests/baselines/reference/derivedClassWithoutExplicitConstructor3.js @@ -52,7 +52,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedClasses.js b/tests/baselines/reference/derivedClasses.js index 74de644d40c..01b6e820e1f 100644 --- a/tests/baselines/reference/derivedClasses.js +++ b/tests/baselines/reference/derivedClasses.js @@ -35,7 +35,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedGenericClassWithAny.js b/tests/baselines/reference/derivedGenericClassWithAny.js index ef245a7ee1e..0b356068bb1 100644 --- a/tests/baselines/reference/derivedGenericClassWithAny.js +++ b/tests/baselines/reference/derivedGenericClassWithAny.js @@ -47,7 +47,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedTypeAccessesHiddenBaseCallViaSuperPropertyAccess.js b/tests/baselines/reference/derivedTypeAccessesHiddenBaseCallViaSuperPropertyAccess.js index 3073a8182d0..53e6ecdff50 100644 --- a/tests/baselines/reference/derivedTypeAccessesHiddenBaseCallViaSuperPropertyAccess.js +++ b/tests/baselines/reference/derivedTypeAccessesHiddenBaseCallViaSuperPropertyAccess.js @@ -22,7 +22,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedTypeDoesNotRequireExtendsClause.js b/tests/baselines/reference/derivedTypeDoesNotRequireExtendsClause.js index 9fee874620f..299159711fa 100644 --- a/tests/baselines/reference/derivedTypeDoesNotRequireExtendsClause.js +++ b/tests/baselines/reference/derivedTypeDoesNotRequireExtendsClause.js @@ -25,7 +25,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/derivedUninitializedPropertyDeclaration.js b/tests/baselines/reference/derivedUninitializedPropertyDeclaration.js index a1536dafca4..c1ba6f6aa64 100644 --- a/tests/baselines/reference/derivedUninitializedPropertyDeclaration.js +++ b/tests/baselines/reference/derivedUninitializedPropertyDeclaration.js @@ -88,7 +88,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/destructuringParameterDeclaration5.js b/tests/baselines/reference/destructuringParameterDeclaration5.js index 6ceabf38507..a9c5597a3e5 100644 --- a/tests/baselines/reference/destructuringParameterDeclaration5.js +++ b/tests/baselines/reference/destructuringParameterDeclaration5.js @@ -56,7 +56,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/docker/office-ui-fabric.log b/tests/baselines/reference/docker/office-ui-fabric.log index 3a8ae0d4b9b..4d3d4e64ba7 100644 --- a/tests/baselines/reference/docker/office-ui-fabric.log +++ b/tests/baselines/reference/docker/office-ui-fabric.log @@ -13,59 +13,775 @@ Standard output: @fluentui/ability-attributes: > @fluentui/ability-attributes@X.X.X schema /office-ui-fabric-react/packages/fluentui/ability-attributes @fluentui/ability-attributes: > allyschema -c "process.env.NODE_ENV !== 'production'" schema.json > ./src/schema.ts @fluentui/ability-attributes: [XX:XX:XX] Requiring external module @uifabric/build/babel/register -@fluentui/ability-attributes: info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command. +@fluentui/ability-attributes: [XX:XX:XX] Using gulpfile /office-ui-fabric-react/packages/fluentui/ability-attributes/gulpfile.ts +@fluentui/ability-attributes: Done in ?s. +@fluentui/digest: yarn run vX.X.X +@fluentui/digest: $ just-scripts build +@fluentui/digest: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/fluentui/digest/tsconfig.json +@fluentui/digest: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --module esnext --outDir lib --project "/office-ui-fabric-react/packages/fluentui/digest/tsconfig.json" +@fluentui/digest: [XX:XX:XX XM] ■ Running Webpack +@fluentui/digest: [XX:XX:XX XM] ■ Webpack Config Path: null +@fluentui/digest: [XX:XX:XX XM] ■ webpack.config.js not found, skipping webpack +@fluentui/digest: Done in ?s. +@uifabric/build: yarn run vX.X.X +@uifabric/build: $ node ./just-scripts.js no-op +@uifabric/build: Done in ?s. +@uifabric/example-data: yarn run vX.X.X +@uifabric/example-data: $ just-scripts build +@uifabric/example-data: [XX:XX:XX XM] ■ Removing [lib, temp, dist, lib-amd, lib-commonjs, lib-es2015, coverage, src/**/*.scss.ts] +@uifabric/example-data: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/example-data/tsconfig.json +@uifabric/example-data: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib --module esnext --project "/office-ui-fabric-react/packages/example-data/tsconfig.json" +@uifabric/example-data: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/example-data/tsconfig.json +@uifabric/example-data: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib-commonjs --module commonjs --project "/office-ui-fabric-react/packages/example-data/tsconfig.json" +@uifabric/example-data: [XX:XX:XX XM] ■ Extracting Public API surface from '/office-ui-fabric-react/packages/example-data/lib/index.d.ts' +@uifabric/example-data: Done in ?s. +@fluentui/keyboard-key: yarn run vX.X.X +@fluentui/keyboard-key: $ just-scripts build +@fluentui/keyboard-key: [XX:XX:XX XM] ■ Removing [lib, temp, dist, lib-amd, lib-commonjs, lib-es2015, coverage, src/**/*.scss.ts] +@fluentui/keyboard-key: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/keyboard-key/tsconfig.json +@fluentui/keyboard-key: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib --module esnext --project "/office-ui-fabric-react/packages/keyboard-key/tsconfig.json" +@fluentui/keyboard-key: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/keyboard-key/tsconfig.json +@fluentui/keyboard-key: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib-commonjs --module commonjs --project "/office-ui-fabric-react/packages/keyboard-key/tsconfig.json" +@fluentui/keyboard-key: [XX:XX:XX XM] ■ Extracting Public API surface from '/office-ui-fabric-react/packages/keyboard-key/lib/index.d.ts' +@fluentui/keyboard-key: Done in ?s. +@uifabric/migration: yarn run vX.X.X +@uifabric/migration: $ just-scripts build +@uifabric/migration: [XX:XX:XX XM] ■ Removing [lib, temp, dist, lib-amd, lib-commonjs, lib-es2015, coverage, src/**/*.scss.ts] +@uifabric/migration: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/packages/migration/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/migration/tsconfig.json +@uifabric/migration: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/packages/migration/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib --module commonjs --project "/office-ui-fabric-react/packages/migration/tsconfig.json" +@uifabric/migration: Done in ?s. +@uifabric/monaco-editor: yarn run vX.X.X +@uifabric/monaco-editor: $ just-scripts build +@uifabric/monaco-editor: [XX:XX:XX XM] ■ Removing [esm, lib, lib-commonjs] +@uifabric/monaco-editor: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/monaco-editor/tsconfig.json +@uifabric/monaco-editor: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib --module esnext --project "/office-ui-fabric-react/packages/monaco-editor/tsconfig.json" +@uifabric/monaco-editor: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/monaco-editor/tsconfig.json +@uifabric/monaco-editor: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib-commonjs --module commonjs --project "/office-ui-fabric-react/packages/monaco-editor/tsconfig.json" +@uifabric/monaco-editor: Done in ?s. +@uifabric/set-version: yarn run vX.X.X +@uifabric/set-version: $ just-scripts build +@uifabric/set-version: [XX:XX:XX XM] ■ Removing [lib, temp, dist, lib-amd, lib-commonjs, lib-es2015, coverage, src/**/*.scss.ts] +@uifabric/set-version: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/set-version/tsconfig.json +@uifabric/set-version: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib --module esnext --project "/office-ui-fabric-react/packages/set-version/tsconfig.json" +@uifabric/set-version: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/set-version/tsconfig.json +@uifabric/set-version: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib-commonjs --module commonjs --project "/office-ui-fabric-react/packages/set-version/tsconfig.json" +@uifabric/set-version: Done in ?s. +@uifabric/webpack-utils: yarn run vX.X.X +@uifabric/webpack-utils: $ just-scripts build +@uifabric/webpack-utils: [XX:XX:XX XM] ■ Removing [lib, temp, dist, lib-amd, lib-commonjs, lib-es2015, coverage, src/**/*.scss.ts] +@uifabric/webpack-utils: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/webpack-utils/tsconfig.json +@uifabric/webpack-utils: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib --module commonjs --project "/office-ui-fabric-react/packages/webpack-utils/tsconfig.json" +@uifabric/webpack-utils: Done in ?s. +@fluentui/docs-components: yarn run vX.X.X +@fluentui/docs-components: $ gulp bundle:package:no-umd +@fluentui/docs-components: [XX:XX:XX] Requiring external module @uifabric/build/babel/register +@fluentui/docs-components: [XX:XX:XX] Using gulpfile /office-ui-fabric-react/packages/fluentui/docs-components/gulpfile.ts +@fluentui/docs-components: Done in ?s. +@fluentui/react-component-event-listener: yarn run vX.X.X +@fluentui/react-component-event-listener: $ gulp bundle:package:no-umd +@fluentui/react-component-event-listener: [XX:XX:XX] Requiring external module @uifabric/build/babel/register +@fluentui/react-component-event-listener: [XX:XX:XX] Using gulpfile /office-ui-fabric-react/packages/fluentui/react-component-event-listener/gulpfile.ts +@fluentui/react-component-event-listener: Done in ?s. +@fluentui/react-component-nesting-registry: yarn run vX.X.X +@fluentui/react-component-nesting-registry: $ gulp bundle:package:no-umd +@fluentui/react-component-nesting-registry: [XX:XX:XX] Requiring external module @uifabric/build/babel/register +@fluentui/react-component-nesting-registry: [XX:XX:XX] Using gulpfile /office-ui-fabric-react/packages/fluentui/react-component-nesting-registry/gulpfile.ts +@fluentui/react-component-nesting-registry: Done in ?s. +@fluentui/react-component-ref: yarn run vX.X.X +@fluentui/react-component-ref: $ gulp bundle:package:no-umd +@fluentui/react-component-ref: [XX:XX:XX] Requiring external module @uifabric/build/babel/register +@fluentui/react-component-ref: [XX:XX:XX] Using gulpfile /office-ui-fabric-react/packages/fluentui/react-component-ref/gulpfile.ts +@fluentui/react-component-ref: Done in ?s. +@fluentui/react-context-selector: yarn run vX.X.X +@fluentui/react-context-selector: $ gulp bundle:package:no-umd +@fluentui/react-context-selector: [XX:XX:XX] Requiring external module @uifabric/build/babel/register +@fluentui/react-context-selector: [XX:XX:XX] Using gulpfile /office-ui-fabric-react/packages/fluentui/react-context-selector/gulpfile.ts +@fluentui/react-context-selector: Done in ?s. +@fluentui/react-proptypes: yarn run vX.X.X +@fluentui/react-proptypes: $ gulp bundle:package:no-umd +@fluentui/react-proptypes: [XX:XX:XX] Requiring external module @uifabric/build/babel/register +@fluentui/react-proptypes: [XX:XX:XX] Using gulpfile /office-ui-fabric-react/packages/fluentui/react-proptypes/gulpfile.ts +@fluentui/react-proptypes: Done in ?s. +@fluentui/state: yarn run vX.X.X +@fluentui/state: $ gulp bundle:package:no-umd +@fluentui/state: [XX:XX:XX] Requiring external module @uifabric/build/babel/register +@fluentui/state: [XX:XX:XX] Using gulpfile /office-ui-fabric-react/packages/fluentui/state/gulpfile.ts +@fluentui/state: Done in ?s. +@fluentui/styles: yarn run vX.X.X +@fluentui/styles: $ gulp bundle:package:no-umd +@fluentui/styles: [XX:XX:XX] Requiring external module @uifabric/build/babel/register +@fluentui/styles: [XX:XX:XX] Using gulpfile /office-ui-fabric-react/packages/fluentui/styles/gulpfile.ts +@fluentui/styles: Done in ?s. +@fluentui/accessibility: yarn run vX.X.X +@fluentui/accessibility: $ gulp bundle:package:no-umd +@fluentui/accessibility: [XX:XX:XX] Requiring external module @uifabric/build/babel/register +@fluentui/accessibility: [XX:XX:XX] Using gulpfile /office-ui-fabric-react/packages/fluentui/accessibility/gulpfile.ts +@fluentui/accessibility: Done in ?s. +@fluentui/date-time-utilities: yarn run vX.X.X +@fluentui/date-time-utilities: $ just-scripts build +@fluentui/date-time-utilities: [XX:XX:XX XM] ■ Removing [lib, temp, dist, lib-amd, lib-commonjs, lib-es2015, coverage, src/**/*.scss.ts] +@fluentui/date-time-utilities: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/date-time-utilities/tsconfig.json +@fluentui/date-time-utilities: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib --module esnext --project "/office-ui-fabric-react/packages/date-time-utilities/tsconfig.json" +@fluentui/date-time-utilities: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/date-time-utilities/tsconfig.json +@fluentui/date-time-utilities: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib-commonjs --module commonjs --project "/office-ui-fabric-react/packages/date-time-utilities/tsconfig.json" +@fluentui/date-time-utilities: [XX:XX:XX XM] ■ Extracting Public API surface from '/office-ui-fabric-react/packages/date-time-utilities/lib/index.d.ts' +@fluentui/date-time-utilities: Done in ?s. +@uifabric/merge-styles: yarn run vX.X.X +@uifabric/merge-styles: $ just-scripts build +@uifabric/merge-styles: [XX:XX:XX XM] ■ Removing [lib, temp, dist, lib-amd, lib-commonjs, lib-es2015, coverage, src/**/*.scss.ts] +@uifabric/merge-styles: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/merge-styles/tsconfig.json +@uifabric/merge-styles: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib --module esnext --project "/office-ui-fabric-react/packages/merge-styles/tsconfig.json" +@uifabric/merge-styles: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/merge-styles/tsconfig.json +@uifabric/merge-styles: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib-commonjs --module commonjs --project "/office-ui-fabric-react/packages/merge-styles/tsconfig.json" +@uifabric/merge-styles: [XX:XX:XX XM] ■ Extracting Public API surface from '/office-ui-fabric-react/packages/merge-styles/lib/index.d.ts' +@uifabric/merge-styles: Done in ?s. +@fluentui/react-northstar-styles-renderer: yarn run vX.X.X +@fluentui/react-northstar-styles-renderer: $ gulp bundle:package:no-umd +@fluentui/react-northstar-styles-renderer: [XX:XX:XX] Requiring external module @uifabric/build/babel/register +@fluentui/react-northstar-styles-renderer: [XX:XX:XX] Using gulpfile /office-ui-fabric-react/packages/fluentui/react-northstar-styles-renderer/gulpfile.ts +@fluentui/react-northstar-styles-renderer: Done in ?s. +@uifabric/jest-serializer-merge-styles: yarn run vX.X.X +@uifabric/jest-serializer-merge-styles: $ just-scripts build +@uifabric/jest-serializer-merge-styles: [XX:XX:XX XM] ■ Removing [lib, temp, dist, lib-amd, lib-commonjs, lib-es2015, coverage, src/**/*.scss.ts] +@uifabric/jest-serializer-merge-styles: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/jest-serializer-merge-styles/tsconfig.json +@uifabric/jest-serializer-merge-styles: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib --module esnext --project "/office-ui-fabric-react/packages/jest-serializer-merge-styles/tsconfig.json" +@uifabric/jest-serializer-merge-styles: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/jest-serializer-merge-styles/tsconfig.json +@uifabric/jest-serializer-merge-styles: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib-commonjs --module commonjs --project "/office-ui-fabric-react/packages/jest-serializer-merge-styles/tsconfig.json" +@uifabric/jest-serializer-merge-styles: Done in ?s. +@fluentui/react-northstar-emotion-renderer: yarn run vX.X.X +@fluentui/react-northstar-emotion-renderer: $ gulp bundle:package:no-umd +@fluentui/react-northstar-emotion-renderer: [XX:XX:XX] Requiring external module @uifabric/build/babel/register +@fluentui/react-northstar-emotion-renderer: [XX:XX:XX] Using gulpfile /office-ui-fabric-react/packages/fluentui/react-northstar-emotion-renderer/gulpfile.ts +@fluentui/react-northstar-emotion-renderer: Done in ?s. +@fluentui/react-northstar-fela-renderer: yarn run vX.X.X +@fluentui/react-northstar-fela-renderer: $ gulp bundle:package:no-umd +@fluentui/react-northstar-fela-renderer: [XX:XX:XX] Requiring external module @uifabric/build/babel/register +@fluentui/react-northstar-fela-renderer: [XX:XX:XX] Using gulpfile /office-ui-fabric-react/packages/fluentui/react-northstar-fela-renderer/gulpfile.ts +@fluentui/react-northstar-fela-renderer: Done in ?s. +@fluentui/react-stylesheets: yarn run vX.X.X +@fluentui/react-stylesheets: $ just-scripts build +@fluentui/react-stylesheets: [XX:XX:XX XM] ■ Removing [lib, temp, dist, lib-amd, lib-commonjs, lib-es2015, coverage, src/**/*.scss.ts] +@fluentui/react-stylesheets: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/react-stylesheets/tsconfig.json +@fluentui/react-stylesheets: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib --module esnext --project "/office-ui-fabric-react/packages/react-stylesheets/tsconfig.json" +@fluentui/react-stylesheets: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/react-stylesheets/tsconfig.json +@fluentui/react-stylesheets: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib-commonjs --module commonjs --project "/office-ui-fabric-react/packages/react-stylesheets/tsconfig.json" +@fluentui/react-stylesheets: [XX:XX:XX XM] ■ Extracting Public API surface from '/office-ui-fabric-react/packages/react-stylesheets/lib/index.d.ts' +@fluentui/react-stylesheets: Done in ?s. +@uifabric/test-utilities: yarn run vX.X.X +@uifabric/test-utilities: $ just-scripts build +@uifabric/test-utilities: [XX:XX:XX XM] ■ Removing [lib, temp, dist, lib-amd, lib-commonjs, lib-es2015, coverage, src/**/*.scss.ts] +@uifabric/test-utilities: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/test-utilities/tsconfig.json +@uifabric/test-utilities: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib --module esnext --project "/office-ui-fabric-react/packages/test-utilities/tsconfig.json" +@uifabric/test-utilities: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/test-utilities/tsconfig.json +@uifabric/test-utilities: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib-commonjs --module commonjs --project "/office-ui-fabric-react/packages/test-utilities/tsconfig.json" +@uifabric/test-utilities: Done in ?s. +@uifabric/utilities: yarn run vX.X.X +@uifabric/utilities: $ just-scripts build +@uifabric/utilities: [XX:XX:XX XM] ■ Removing [lib, temp, dist, lib-amd, lib-commonjs, lib-es2015, coverage, src/**/*.scss.ts] +@uifabric/utilities: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/utilities/tsconfig.json +@uifabric/utilities: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib --module esnext --project "/office-ui-fabric-react/packages/utilities/tsconfig.json" +@uifabric/utilities: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/utilities/tsconfig.json +@uifabric/utilities: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib-commonjs --module commonjs --project "/office-ui-fabric-react/packages/utilities/tsconfig.json" +@uifabric/utilities: [XX:XX:XX XM] ■ Extracting Public API surface from '/office-ui-fabric-react/packages/utilities/lib/index.d.ts' +@uifabric/utilities: Done in ?s. +@fluentui/react-compose: yarn run vX.X.X +@fluentui/react-compose: $ just-scripts build +@fluentui/react-compose: [XX:XX:XX XM] ■ Removing [lib, temp, dist, lib-amd, lib-commonjs, lib-es2015, coverage, src/**/*.scss.ts] +@fluentui/react-compose: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/react-compose/tsconfig.json +@fluentui/react-compose: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib --module esnext --project "/office-ui-fabric-react/packages/react-compose/tsconfig.json" +@fluentui/react-compose: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/react-compose/tsconfig.json +@fluentui/react-compose: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib-commonjs --module commonjs --project "/office-ui-fabric-react/packages/react-compose/tsconfig.json" +@fluentui/react-compose: [XX:XX:XX XM] ■ Extracting Public API surface from '/office-ui-fabric-react/packages/react-compose/lib/index.d.ts' +@fluentui/react-compose: Done in ?s. +@uifabric/react-hooks: yarn run vX.X.X +@uifabric/react-hooks: $ just-scripts build +@uifabric/react-hooks: [XX:XX:XX XM] ■ Removing [lib, temp, dist, lib-amd, lib-commonjs, lib-es2015, coverage, src/**/*.scss.ts] +@uifabric/react-hooks: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/react-hooks/tsconfig.json +@uifabric/react-hooks: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib --module esnext --project "/office-ui-fabric-react/packages/react-hooks/tsconfig.json" +@uifabric/react-hooks: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/react-hooks/tsconfig.json +@uifabric/react-hooks: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib-commonjs --module commonjs --project "/office-ui-fabric-react/packages/react-hooks/tsconfig.json" +@uifabric/react-hooks: [XX:XX:XX XM] ■ Extracting Public API surface from '/office-ui-fabric-react/packages/react-hooks/lib/index.d.ts' +@uifabric/react-hooks: Done in ?s. +@fluentui/react-icons: yarn run vX.X.X +@fluentui/react-icons: $ just-scripts build +@fluentui/react-icons: [XX:XX:XX XM] ■ Removing [lib, temp, dist, lib-amd, lib-commonjs, lib-es2015, coverage, src/**/*.scss.ts] +@fluentui/react-icons: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/react-icons/tsconfig.json +@fluentui/react-icons: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib --module esnext --project "/office-ui-fabric-react/packages/react-icons/tsconfig.json" +@fluentui/react-icons: [XX:XX:XX XM] ■ Running /office-ui-fabric-react/node_modules/typescript/lib/tsc.js with /office-ui-fabric-react/packages/react-icons/tsconfig.json +@fluentui/react-icons: [XX:XX:XX XM] ■ Executing: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib-commonjs --module commonjs --project "/office-ui-fabric-react/packages/react-icons/tsconfig.json" +@fluentui/react-icons: info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command. Standard error: info cli using local version of lerna -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'cat' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'cat' of module exports inside circular dependency @uifabric/tslint-rules: (Use `node --trace-warnings ...` to show where the warning was created) -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'cd' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'chmod' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'cp' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'dirs' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'pushd' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'popd' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'echo' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'tempdir' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'pwd' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'exec' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'ls' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'find' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'grep' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'head' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'ln' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'mkdir' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'rm' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'mv' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'sed' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'set' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'sort' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'tail' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'test' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'to' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'toEnd' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'touch' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'uniq' of module exports inside circular dependency -@uifabric/tslint-rules: (node:28) Warning: Accessing non-existent property 'which' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'cd' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'chmod' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'cp' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'dirs' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'pushd' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'popd' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'echo' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'tempdir' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'pwd' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'exec' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'ls' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'find' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'grep' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'head' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'ln' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'mkdir' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'rm' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'mv' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'sed' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'set' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'sort' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'tail' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'test' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'to' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'toEnd' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'touch' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'uniq' of module exports inside circular dependency +@uifabric/tslint-rules: (node:29) Warning: Accessing non-existent property 'which' of module exports inside circular dependency @uifabric/tslint-rules: [XX:XX:XX XM] ▲ One of these [node-sass, postcss, autoprefixer] is not installed, so this task has no effect @fluentui/ability-attributes: npm WARN lifecycle The node binary used for scripts is but npm is using /usr/local/bin/node itself. Use the `--scripts-prepend-node-path` option to include the path for the node binary npm was executed with. -@fluentui/ability-attributes: internal/modules/cjs/loader.js:491 -@fluentui/ability-attributes: throw new ERR_PACKAGE_PATH_NOT_EXPORTED(basePath, mappingKey); -@fluentui/ability-attributes: ^ -@fluentui/ability-attributes: Error [ERR_PACKAGE_PATH_NOT_EXPORTED]: No "exports" main resolved in /office-ui-fabric-react/node_modules/@babel/helper-compilation-targets/package.json -@fluentui/ability-attributes: at applyExports (internal/modules/cjs/loader.js:491:9) -@fluentui/ability-attributes: at resolveExports (internal/modules/cjs/loader.js:507:23) -@fluentui/ability-attributes: at Function.Module._findPath (internal/modules/cjs/loader.js:635:31) -@fluentui/ability-attributes: at Function.Module._resolveFilename (internal/modules/cjs/loader.js:1007:27) -@fluentui/ability-attributes: at Function.Module._load (internal/modules/cjs/loader.js:890:27) -@fluentui/ability-attributes: at Module.require (internal/modules/cjs/loader.js:1080:19) -@fluentui/ability-attributes: at require (internal/modules/cjs/helpers.js:72:18) -@fluentui/ability-attributes: at Object. (/office-ui-fabric-react/node_modules/@babel/preset-env/lib/debug.js:8:33) -@fluentui/ability-attributes: at Module._compile (internal/modules/cjs/loader.js:1176:30) -@fluentui/ability-attributes: at Module._compile (/office-ui-fabric-react/node_modules/pirates/lib/index.js:99:24) { -@fluentui/ability-attributes: code: 'ERR_PACKAGE_PATH_NOT_EXPORTED' -@fluentui/ability-attributes: } -@fluentui/ability-attributes: error Command failed with exit code 1. -lerna ERR! yarn run build exited 1 in '@fluentui/ability-attributes' +@fluentui/ability-attributes: (node:87) [DEP0097] DeprecationWarning: Using a domain property in MakeCallback is deprecated. Use the async_context variant of MakeCallback or the AsyncResource class instead. +@fluentui/ability-attributes: (Use `node --trace-deprecation ...` to show where the warning was created) +@uifabric/build: warning package.json: "dependencies" has dependency "typescript" with range "3.7.2" that collides with a dependency in "devDependencies" of the same name with version "../typescript.tgz" +@uifabric/build: (node:146) Warning: Accessing non-existent property 'cat' of module exports inside circular dependency +@uifabric/build: (Use `node --trace-warnings ...` to show where the warning was created) +@uifabric/build: (node:146) Warning: Accessing non-existent property 'cd' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'chmod' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'cp' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'dirs' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'pushd' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'popd' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'echo' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'tempdir' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'pwd' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'exec' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'ls' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'find' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'grep' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'head' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'ln' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'mkdir' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'rm' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'mv' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'sed' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'set' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'sort' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'tail' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'test' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'to' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'toEnd' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'touch' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'uniq' of module exports inside circular dependency +@uifabric/build: (node:146) Warning: Accessing non-existent property 'which' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'cat' of module exports inside circular dependency +@uifabric/example-data: (Use `node --trace-warnings ...` to show where the warning was created) +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'cd' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'chmod' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'cp' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'dirs' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'pushd' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'popd' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'echo' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'tempdir' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'pwd' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'exec' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'ls' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'find' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'grep' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'head' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'ln' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'mkdir' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'rm' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'mv' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'sed' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'set' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'sort' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'tail' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'test' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'to' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'toEnd' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'touch' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'uniq' of module exports inside circular dependency +@uifabric/example-data: (node:165) Warning: Accessing non-existent property 'which' of module exports inside circular dependency +@uifabric/example-data: [XX:XX:XX XM] ▲ One of these [node-sass, postcss, autoprefixer] is not installed, so this task has no effect +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'cat' of module exports inside circular dependency +@fluentui/keyboard-key: (Use `node --trace-warnings ...` to show where the warning was created) +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'cd' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'chmod' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'cp' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'dirs' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'pushd' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'popd' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'echo' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'tempdir' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'pwd' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'exec' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'ls' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'find' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'grep' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'head' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'ln' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'mkdir' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'rm' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'mv' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'sed' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'set' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'sort' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'tail' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'test' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'to' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'toEnd' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'touch' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'uniq' of module exports inside circular dependency +@fluentui/keyboard-key: (node:204) Warning: Accessing non-existent property 'which' of module exports inside circular dependency +@fluentui/keyboard-key: [XX:XX:XX XM] ▲ One of these [node-sass, postcss, autoprefixer] is not installed, so this task has no effect +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'cat' of module exports inside circular dependency +@uifabric/migration: (Use `node --trace-warnings ...` to show where the warning was created) +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'cd' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'chmod' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'cp' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'dirs' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'pushd' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'popd' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'echo' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'tempdir' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'pwd' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'exec' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'ls' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'find' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'grep' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'head' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'ln' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'mkdir' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'rm' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'mv' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'sed' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'set' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'sort' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'tail' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'test' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'to' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'toEnd' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'touch' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'uniq' of module exports inside circular dependency +@uifabric/migration: (node:243) Warning: Accessing non-existent property 'which' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'cat' of module exports inside circular dependency +@uifabric/monaco-editor: (Use `node --trace-warnings ...` to show where the warning was created) +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'cd' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'chmod' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'cp' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'dirs' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'pushd' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'popd' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'echo' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'tempdir' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'pwd' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'exec' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'ls' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'find' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'grep' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'head' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'ln' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'mkdir' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'rm' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'mv' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'sed' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'set' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'sort' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'tail' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'test' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'to' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'toEnd' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'touch' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'uniq' of module exports inside circular dependency +@uifabric/monaco-editor: (node:274) Warning: Accessing non-existent property 'which' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'cat' of module exports inside circular dependency +@uifabric/set-version: (Use `node --trace-warnings ...` to show where the warning was created) +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'cd' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'chmod' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'cp' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'dirs' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'pushd' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'popd' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'echo' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'tempdir' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'pwd' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'exec' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'ls' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'find' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'grep' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'head' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'ln' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'mkdir' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'rm' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'mv' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'sed' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'set' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'sort' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'tail' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'test' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'to' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'toEnd' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'touch' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'uniq' of module exports inside circular dependency +@uifabric/set-version: (node:313) Warning: Accessing non-existent property 'which' of module exports inside circular dependency +@uifabric/set-version: [XX:XX:XX XM] ▲ One of these [node-sass, postcss, autoprefixer] is not installed, so this task has no effect +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'cat' of module exports inside circular dependency +@uifabric/webpack-utils: (Use `node --trace-warnings ...` to show where the warning was created) +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'cd' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'chmod' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'cp' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'dirs' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'pushd' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'popd' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'echo' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'tempdir' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'pwd' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'exec' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'ls' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'find' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'grep' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'head' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'ln' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'mkdir' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'rm' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'mv' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'sed' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'set' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'sort' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'tail' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'test' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'to' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'toEnd' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'touch' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'uniq' of module exports inside circular dependency +@uifabric/webpack-utils: (node:352) Warning: Accessing non-existent property 'which' of module exports inside circular dependency +@fluentui/docs-components: (node:383) [DEP0097] DeprecationWarning: Using a domain property in MakeCallback is deprecated. Use the async_context variant of MakeCallback or the AsyncResource class instead. +@fluentui/docs-components: (Use `node --trace-deprecation ...` to show where the warning was created) +@fluentui/react-component-event-listener: (node:414) [DEP0097] DeprecationWarning: Using a domain property in MakeCallback is deprecated. Use the async_context variant of MakeCallback or the AsyncResource class instead. +@fluentui/react-component-event-listener: (Use `node --trace-deprecation ...` to show where the warning was created) +@fluentui/react-component-nesting-registry: (node:445) [DEP0097] DeprecationWarning: Using a domain property in MakeCallback is deprecated. Use the async_context variant of MakeCallback or the AsyncResource class instead. +@fluentui/react-component-nesting-registry: (Use `node --trace-deprecation ...` to show where the warning was created) +@fluentui/react-component-ref: (node:476) [DEP0097] DeprecationWarning: Using a domain property in MakeCallback is deprecated. Use the async_context variant of MakeCallback or the AsyncResource class instead. +@fluentui/react-component-ref: (Use `node --trace-deprecation ...` to show where the warning was created) +@fluentui/react-context-selector: (node:507) [DEP0097] DeprecationWarning: Using a domain property in MakeCallback is deprecated. Use the async_context variant of MakeCallback or the AsyncResource class instead. +@fluentui/react-context-selector: (Use `node --trace-deprecation ...` to show where the warning was created) +@fluentui/react-proptypes: (node:538) [DEP0097] DeprecationWarning: Using a domain property in MakeCallback is deprecated. Use the async_context variant of MakeCallback or the AsyncResource class instead. +@fluentui/react-proptypes: (Use `node --trace-deprecation ...` to show where the warning was created) +@fluentui/state: (node:569) [DEP0097] DeprecationWarning: Using a domain property in MakeCallback is deprecated. Use the async_context variant of MakeCallback or the AsyncResource class instead. +@fluentui/state: (Use `node --trace-deprecation ...` to show where the warning was created) +@fluentui/styles: (node:600) [DEP0097] DeprecationWarning: Using a domain property in MakeCallback is deprecated. Use the async_context variant of MakeCallback or the AsyncResource class instead. +@fluentui/styles: (Use `node --trace-deprecation ...` to show where the warning was created) +@fluentui/accessibility: (node:631) [DEP0097] DeprecationWarning: Using a domain property in MakeCallback is deprecated. Use the async_context variant of MakeCallback or the AsyncResource class instead. +@fluentui/accessibility: (Use `node --trace-deprecation ...` to show where the warning was created) +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'cat' of module exports inside circular dependency +@fluentui/date-time-utilities: (Use `node --trace-warnings ...` to show where the warning was created) +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'cd' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'chmod' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'cp' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'dirs' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'pushd' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'popd' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'echo' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'tempdir' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'pwd' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'exec' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'ls' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'find' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'grep' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'head' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'ln' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'mkdir' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'rm' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'mv' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'sed' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'set' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'sort' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'tail' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'test' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'to' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'toEnd' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'touch' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'uniq' of module exports inside circular dependency +@fluentui/date-time-utilities: (node:662) Warning: Accessing non-existent property 'which' of module exports inside circular dependency +@fluentui/date-time-utilities: [XX:XX:XX XM] ▲ One of these [node-sass, postcss, autoprefixer] is not installed, so this task has no effect +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'cat' of module exports inside circular dependency +@uifabric/merge-styles: (Use `node --trace-warnings ...` to show where the warning was created) +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'cd' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'chmod' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'cp' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'dirs' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'pushd' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'popd' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'echo' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'tempdir' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'pwd' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'exec' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'ls' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'find' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'grep' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'head' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'ln' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'mkdir' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'rm' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'mv' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'sed' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'set' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'sort' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'tail' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'test' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'to' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'toEnd' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'touch' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'uniq' of module exports inside circular dependency +@uifabric/merge-styles: (node:701) Warning: Accessing non-existent property 'which' of module exports inside circular dependency +@uifabric/merge-styles: [XX:XX:XX XM] ▲ One of these [node-sass, postcss, autoprefixer] is not installed, so this task has no effect +@fluentui/react-northstar-styles-renderer: (node:740) [DEP0097] DeprecationWarning: Using a domain property in MakeCallback is deprecated. Use the async_context variant of MakeCallback or the AsyncResource class instead. +@fluentui/react-northstar-styles-renderer: (Use `node --trace-deprecation ...` to show where the warning was created) +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'cat' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (Use `node --trace-warnings ...` to show where the warning was created) +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'cd' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'chmod' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'cp' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'dirs' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'pushd' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'popd' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'echo' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'tempdir' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'pwd' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'exec' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'ls' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'find' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'grep' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'head' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'ln' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'mkdir' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'rm' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'mv' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'sed' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'set' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'sort' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'tail' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'test' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'to' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'toEnd' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'touch' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'uniq' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: (node:771) Warning: Accessing non-existent property 'which' of module exports inside circular dependency +@uifabric/jest-serializer-merge-styles: [XX:XX:XX XM] ▲ One of these [node-sass, postcss, autoprefixer] is not installed, so this task has no effect +@fluentui/react-northstar-emotion-renderer: (node:810) [DEP0097] DeprecationWarning: Using a domain property in MakeCallback is deprecated. Use the async_context variant of MakeCallback or the AsyncResource class instead. +@fluentui/react-northstar-emotion-renderer: (Use `node --trace-deprecation ...` to show where the warning was created) +@fluentui/react-northstar-fela-renderer: (node:841) [DEP0097] DeprecationWarning: Using a domain property in MakeCallback is deprecated. Use the async_context variant of MakeCallback or the AsyncResource class instead. +@fluentui/react-northstar-fela-renderer: (Use `node --trace-deprecation ...` to show where the warning was created) +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'cat' of module exports inside circular dependency +@fluentui/react-stylesheets: (Use `node --trace-warnings ...` to show where the warning was created) +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'cd' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'chmod' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'cp' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'dirs' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'pushd' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'popd' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'echo' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'tempdir' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'pwd' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'exec' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'ls' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'find' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'grep' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'head' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'ln' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'mkdir' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'rm' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'mv' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'sed' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'set' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'sort' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'tail' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'test' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'to' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'toEnd' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'touch' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'uniq' of module exports inside circular dependency +@fluentui/react-stylesheets: (node:872) Warning: Accessing non-existent property 'which' of module exports inside circular dependency +@fluentui/react-stylesheets: [XX:XX:XX XM] ▲ One of these [node-sass, postcss, autoprefixer] is not installed, so this task has no effect +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'cat' of module exports inside circular dependency +@uifabric/test-utilities: (Use `node --trace-warnings ...` to show where the warning was created) +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'cd' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'chmod' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'cp' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'dirs' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'pushd' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'popd' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'echo' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'tempdir' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'pwd' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'exec' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'ls' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'find' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'grep' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'head' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'ln' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'mkdir' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'rm' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'mv' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'sed' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'set' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'sort' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'tail' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'test' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'to' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'toEnd' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'touch' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'uniq' of module exports inside circular dependency +@uifabric/test-utilities: (node:911) Warning: Accessing non-existent property 'which' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'cat' of module exports inside circular dependency +@uifabric/utilities: (Use `node --trace-warnings ...` to show where the warning was created) +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'cd' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'chmod' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'cp' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'dirs' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'pushd' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'popd' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'echo' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'tempdir' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'pwd' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'exec' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'ls' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'find' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'grep' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'head' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'ln' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'mkdir' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'rm' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'mv' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'sed' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'set' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'sort' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'tail' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'test' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'to' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'toEnd' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'touch' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'uniq' of module exports inside circular dependency +@uifabric/utilities: (node:950) Warning: Accessing non-existent property 'which' of module exports inside circular dependency +@uifabric/utilities: [XX:XX:XX XM] ▲ One of these [node-sass, postcss, autoprefixer] is not installed, so this task has no effect +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'cat' of module exports inside circular dependency +@fluentui/react-compose: (Use `node --trace-warnings ...` to show where the warning was created) +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'cd' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'chmod' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'cp' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'dirs' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'pushd' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'popd' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'echo' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'tempdir' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'pwd' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'exec' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'ls' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'find' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'grep' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'head' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'ln' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'mkdir' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'rm' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'mv' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'sed' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'set' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'sort' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'tail' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'test' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'to' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'toEnd' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'touch' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'uniq' of module exports inside circular dependency +@fluentui/react-compose: (node:989) Warning: Accessing non-existent property 'which' of module exports inside circular dependency +@fluentui/react-compose: [XX:XX:XX XM] ▲ One of these [node-sass, postcss, autoprefixer] is not installed, so this task has no effect +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'cat' of module exports inside circular dependency +@uifabric/react-hooks: (Use `node --trace-warnings ...` to show where the warning was created) +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'cd' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'chmod' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'cp' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'dirs' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'pushd' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'popd' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'echo' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'tempdir' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'pwd' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'exec' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'ls' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'find' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'grep' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'head' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'ln' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'mkdir' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'rm' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'mv' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'sed' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'set' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'sort' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'tail' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'test' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'to' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'toEnd' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'touch' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'uniq' of module exports inside circular dependency +@uifabric/react-hooks: (node:1028) Warning: Accessing non-existent property 'which' of module exports inside circular dependency +@uifabric/react-hooks: [XX:XX:XX XM] ▲ One of these [node-sass, postcss, autoprefixer] is not installed, so this task has no effect +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'cat' of module exports inside circular dependency +@fluentui/react-icons: (Use `node --trace-warnings ...` to show where the warning was created) +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'cd' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'chmod' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'cp' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'dirs' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'pushd' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'popd' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'echo' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'tempdir' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'pwd' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'exec' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'ls' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'find' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'grep' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'head' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'ln' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'mkdir' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'rm' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'mv' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'sed' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'set' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'sort' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'tail' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'test' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'to' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'toEnd' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'touch' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'uniq' of module exports inside circular dependency +@fluentui/react-icons: (node:1067) Warning: Accessing non-existent property 'which' of module exports inside circular dependency +@fluentui/react-icons: [XX:XX:XX XM] ▲ One of these [node-sass, postcss, autoprefixer] is not installed, so this task has no effect +@fluentui/react-icons: [XX:XX:XX XM] x Error detected while running 'ts:esm' +@fluentui/react-icons: [XX:XX:XX XM] x ------------------------------------ +@fluentui/react-icons: [XX:XX:XX XM] x Error: Command failed: /usr/local/bin/node "/office-ui-fabric-react/node_modules/typescript/lib/tsc.js" --pretty --target es5 --outDir lib --module esnext --project "/office-ui-fabric-react/packages/react-icons/tsconfig.json" +@fluentui/react-icons: at ChildProcess.exithandler (child_process.js:308:12) +@fluentui/react-icons: at ChildProcess.emit (events.js:314:20) +@fluentui/react-icons: at ChildProcess.EventEmitter.emit (domain.js:548:15) +@fluentui/react-icons: at maybeClose (internal/child_process.js:1051:16) +@fluentui/react-icons: at Process.ChildProcess._handle.onexit (internal/child_process.js:287:5) +@fluentui/react-icons: at Process.topLevelDomainCallback (domain.js:138:15) +@fluentui/react-icons: at Process.callbackTrampoline (internal/async_hooks.js:121:14) +@fluentui/react-icons: [XX:XX:XX XM] x stdout: +@fluentui/react-icons: [XX:XX:XX XM] x src/utils/createSvgIcon.ts:3:26 - error TS2307: Cannot find module './SvgIcon.scss'. +@fluentui/react-icons: 3 import * as classes from './SvgIcon.scss'; +@fluentui/react-icons: ~~~~~~~~~~~~~~~~ +@fluentui/react-icons: Found 1 error. +@fluentui/react-icons: [XX:XX:XX XM] x ------------------------------------ +@fluentui/react-icons: [XX:XX:XX XM] x Error previously detected. See above for error messages. +@fluentui/react-icons: [XX:XX:XX XM] x Other tasks that did not complete: [ts:commonjs] +@fluentui/react-icons: error Command failed with exit code 1. +lerna ERR! yarn run build exited 1 in '@fluentui/react-icons' diff --git a/tests/baselines/reference/docker/vue-next.log b/tests/baselines/reference/docker/vue-next.log index 934f616dc11..0f24ac5461b 100644 --- a/tests/baselines/reference/docker/vue-next.log +++ b/tests/baselines/reference/docker/vue-next.log @@ -1,33 +1,43 @@ Exit Code: 0 Standard output: -> @X.X.X-beta.15 build /vue-next +> @X.X.X-beta.19 build /vue-next > node scripts/build.js "--types" Rolling up type definitions for compiler-core... +Analysis will use the bundled TypeScript version 3.9.6 +*** The target project appears to use TypeScript X.X.X-insiders.xxxxxxxx which is newer than the bundled compiler engine; consider upgrading API Extractor. Writing: /vue-next/temp/compiler-core.api.json The API report is up to date: temp/compiler-core.api.md Writing package typings: /vue-next/packages/compiler-core/dist/compiler-core.d.ts Writing package typings: /vue-next/dist/compiler-core.d.ts API Extractor completed successfully. Rolling up type definitions for compiler-dom... +Analysis will use the bundled TypeScript version 3.9.6 +*** The target project appears to use TypeScript X.X.X-insiders.xxxxxxxx which is newer than the bundled compiler engine; consider upgrading API Extractor. Writing: /vue-next/temp/compiler-dom.api.json The API report is up to date: temp/compiler-dom.api.md Writing package typings: /vue-next/packages/compiler-dom/dist/compiler-dom.d.ts Writing package typings: /vue-next/dist/compiler-dom.d.ts API Extractor completed successfully. Rolling up type definitions for compiler-sfc... +Analysis will use the bundled TypeScript version 3.9.6 +*** The target project appears to use TypeScript X.X.X-insiders.xxxxxxxx which is newer than the bundled compiler engine; consider upgrading API Extractor. Writing: /vue-next/temp/compiler-sfc.api.json The API report is up to date: temp/compiler-sfc.api.md Writing package typings: /vue-next/packages/compiler-sfc/dist/compiler-sfc.d.ts Writing package typings: /vue-next/dist/compiler-sfc.d.ts API Extractor completed successfully. Rolling up type definitions for compiler-ssr... +Analysis will use the bundled TypeScript version 3.9.6 +*** The target project appears to use TypeScript X.X.X-insiders.xxxxxxxx which is newer than the bundled compiler engine; consider upgrading API Extractor. Writing: /vue-next/temp/compiler-ssr.api.json The API report is up to date: temp/compiler-ssr.api.md Writing package typings: /vue-next/packages/compiler-ssr/dist/compiler-ssr.d.ts Writing package typings: /vue-next/dist/compiler-ssr.d.ts API Extractor completed successfully. Rolling up type definitions for reactivity... +Analysis will use the bundled TypeScript version 3.9.6 +*** The target project appears to use TypeScript X.X.X-insiders.xxxxxxxx which is newer than the bundled compiler engine; consider upgrading API Extractor. Writing: /vue-next/temp/reactivity.api.json The API report is up to date: temp/reactivity.api.md Writing package typings: /vue-next/packages/reactivity/dist/reactivity.d.ts @@ -54,10 +64,6 @@ Warning: dist/packages/compiler-core/src/options.d.ts:69:42 - (tsdoc-escape-righ Warning: dist/packages/compiler-core/src/options.d.ts:69:43 - (tsdoc-escape-right-brace) The "}" character should be escaped using a backslash to avoid confusion with a TSDoc inline tag Warning: dist/packages/compiler-core/src/options.d.ts:69:35 - (tsdoc-malformed-inline-tag) Expecting a TSDoc tag starting with "{@" Warning: dist/packages/compiler-core/src/options.d.ts:69:36 - (tsdoc-malformed-inline-tag) Expecting a TSDoc tag starting with "{@" -Warning: /vue-next/packages/runtime-dom/src/components/Transition.ts:71:5 - (TS7022) 'name' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer. -Warning: /vue-next/packages/runtime-dom/src/components/Transition.ts:75:5 - (TS7022) 'enterFromClass' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer. -Warning: /vue-next/packages/runtime-dom/src/components/Transition.ts:76:5 - (TS7022) 'enterActiveClass' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer. -Warning: /vue-next/packages/runtime-dom/src/components/Transition.ts:77:5 - (TS7022) 'enterToClass' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer. /vue-next/packages/compiler-dom/src/index.ts → packages/compiler-dom/dist/compiler-dom.esm-bundler.js... created packages/compiler-dom/dist/compiler-dom.esm-bundler.js in ?s /vue-next/packages/compiler-dom/src/index.ts → packages/compiler-dom/dist/compiler-dom.esm-browser.js... @@ -72,26 +78,14 @@ created packages/compiler-dom/dist/compiler-dom.esm-browser.prod.js in ?s created packages/compiler-dom/dist/compiler-dom.cjs.prod.js in ?s /vue-next/packages/compiler-dom/src/index.ts → packages/compiler-dom/dist/compiler-dom.global.prod.js... created packages/compiler-dom/dist/compiler-dom.global.prod.js in ?s -Warning: /vue-next/packages/runtime-dom/src/components/Transition.ts:71:5 - (TS7022) 'name' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer. -Warning: /vue-next/packages/runtime-dom/src/components/Transition.ts:75:5 - (TS7022) 'enterFromClass' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer. -Warning: /vue-next/packages/runtime-dom/src/components/Transition.ts:76:5 - (TS7022) 'enterActiveClass' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer. -Warning: /vue-next/packages/runtime-dom/src/components/Transition.ts:77:5 - (TS7022) 'enterToClass' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer. /vue-next/packages/compiler-sfc/src/index.ts → packages/compiler-sfc/dist/compiler-sfc.cjs.js... created packages/compiler-sfc/dist/compiler-sfc.cjs.js in ?s /vue-next/packages/compiler-sfc/src/index.ts → packages/compiler-sfc/dist/compiler-sfc.global.js... created packages/compiler-sfc/dist/compiler-sfc.global.js in ?s /vue-next/packages/compiler-sfc/src/index.ts → packages/compiler-sfc/dist/compiler-sfc.esm-browser.js... created packages/compiler-sfc/dist/compiler-sfc.esm-browser.js in ?s -Warning: /vue-next/packages/runtime-dom/src/components/Transition.ts:71:5 - (TS7022) 'name' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer. -Warning: /vue-next/packages/runtime-dom/src/components/Transition.ts:75:5 - (TS7022) 'enterFromClass' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer. -Warning: /vue-next/packages/runtime-dom/src/components/Transition.ts:76:5 - (TS7022) 'enterActiveClass' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer. -Warning: /vue-next/packages/runtime-dom/src/components/Transition.ts:77:5 - (TS7022) 'enterToClass' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer. /vue-next/packages/compiler-ssr/src/index.ts → packages/compiler-ssr/dist/compiler-ssr.cjs.js... created packages/compiler-ssr/dist/compiler-ssr.cjs.js in ?s -Warning: /vue-next/packages/runtime-dom/src/components/Transition.ts:71:5 - (TS7022) 'name' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer. -Warning: /vue-next/packages/runtime-dom/src/components/Transition.ts:75:5 - (TS7022) 'enterFromClass' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer. -Warning: /vue-next/packages/runtime-dom/src/components/Transition.ts:76:5 - (TS7022) 'enterActiveClass' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer. -Warning: /vue-next/packages/runtime-dom/src/components/Transition.ts:77:5 - (TS7022) 'enterToClass' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer. /vue-next/packages/reactivity/src/index.ts → packages/reactivity/dist/reactivity.esm-bundler.js... created packages/reactivity/dist/reactivity.esm-bundler.js in ?s /vue-next/packages/reactivity/src/index.ts → packages/reactivity/dist/reactivity.esm-browser.js... @@ -106,28 +100,24 @@ created packages/reactivity/dist/reactivity.esm-browser.prod.js in ?s created packages/reactivity/dist/reactivity.cjs.prod.js in ?s /vue-next/packages/reactivity/src/index.ts → packages/reactivity/dist/reactivity.global.prod.js... created packages/reactivity/dist/reactivity.global.prod.js in ?s -Warning: /vue-next/packages/runtime-dom/src/components/Transition.ts:71:5 - (TS7022) 'name' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer. -Warning: /vue-next/packages/runtime-dom/src/components/Transition.ts:75:5 - (TS7022) 'enterFromClass' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer. -Warning: /vue-next/packages/runtime-dom/src/components/Transition.ts:76:5 - (TS7022) 'enterActiveClass' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer. -Warning: /vue-next/packages/runtime-dom/src/components/Transition.ts:77:5 - (TS7022) 'enterToClass' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer. /vue-next/packages/runtime-core/src/index.ts → packages/runtime-core/dist/runtime-core.esm-bundler.js... [!] (plugin rpt2) Error: /vue-next/packages/runtime-core/src/apiInject.ts(40,9): semantic error TS2360: The left-hand side of an 'in' expression must be of type 'any', 'string', 'number', or 'symbol'. packages/runtime-core/src/apiInject.ts Error: /vue-next/packages/runtime-core/src/apiInject.ts(40,9): semantic error TS2360: The left-hand side of an 'in' expression must be of type 'any', 'string', 'number', or 'symbol'. - at error (/vue-next/node_modules/rollup/dist/shared/rollup.js:5154:30) - at throwPluginError (/vue-next/node_modules/rollup/dist/shared/rollup.js:17381:12) - at Object.error (/vue-next/node_modules/rollup/dist/shared/rollup.js:18002:24) - at Object.error (/vue-next/node_modules/rollup/dist/shared/rollup.js:17554:38) + at error (/vue-next/node_modules/rollup/dist/shared/rollup.js:5171:30) + at throwPluginError (/vue-next/node_modules/rollup/dist/shared/rollup.js:17415:12) + at Object.error (/vue-next/node_modules/rollup/dist/shared/rollup.js:18036:24) + at Object.error (/vue-next/node_modules/rollup/dist/shared/rollup.js:17588:38) at RollupContext.error (/vue-next/node_modules/rollup-plugin-typescript2/src/rollupcontext.ts:37:18) at /vue-next/node_modules/rollup-plugin-typescript2/src/print-diagnostics.ts:41:11 at arrayEach (/vue-next/node_modules/rollup-plugin-typescript2/node_modules/lodash/lodash.js:516:11) at forEach (/vue-next/node_modules/rollup-plugin-typescript2/node_modules/lodash/lodash.js:9342:14) at _.each (/vue-next/node_modules/rollup-plugin-typescript2/src/print-diagnostics.ts:9:2) at Object.transform (/vue-next/node_modules/rollup-plugin-typescript2/src/index.ts:242:5) -(node:17) UnhandledPromiseRejectionWarning: Error: Command failed with exit code 1: rollup -c --environment COMMIT:37a5952,NODE_ENV:production,TARGET:runtime-core,TYPES:true +(node:17) UnhandledPromiseRejectionWarning: Error: Command failed with exit code 1: rollup -c --environment COMMIT:9b04ea3,NODE_ENV:production,TARGET:runtime-core,TYPES:true at makeError (/vue-next/node_modules/execa/lib/error.js:59:11) at handlePromise (/vue-next/node_modules/execa/index.js:114:26) - at processTicksAndRejections (internal/process/task_queues.js:97:5) + at processTicksAndRejections (internal/process/task_queues.js:93:5) at async build (/vue-next/scripts/build.js:71:3) at async buildAll (/vue-next/scripts/build.js:50:5) at async run (/vue-next/scripts/build.js:40:5) diff --git a/tests/baselines/reference/doubleMixinConditionalTypeBaseClassWorks.js b/tests/baselines/reference/doubleMixinConditionalTypeBaseClassWorks.js index fa76dab7464..de28dcc9dd8 100644 --- a/tests/baselines/reference/doubleMixinConditionalTypeBaseClassWorks.js +++ b/tests/baselines/reference/doubleMixinConditionalTypeBaseClassWorks.js @@ -13,7 +13,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/doubleUnderscoreExportStarConflict.js b/tests/baselines/reference/doubleUnderscoreExportStarConflict.js index 3497051eb15..eee48374d1e 100644 --- a/tests/baselines/reference/doubleUnderscoreExportStarConflict.js +++ b/tests/baselines/reference/doubleUnderscoreExportStarConflict.js @@ -33,7 +33,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./b"), exports); diff --git a/tests/baselines/reference/emitBundleWithPrologueDirectives1.js b/tests/baselines/reference/emitBundleWithPrologueDirectives1.js index 1e11f3c45bb..e5da61c3aab 100644 --- a/tests/baselines/reference/emitBundleWithPrologueDirectives1.js +++ b/tests/baselines/reference/emitBundleWithPrologueDirectives1.js @@ -10,7 +10,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/emitBundleWithShebang1.js b/tests/baselines/reference/emitBundleWithShebang1.js index 0e19e997c6c..f9bcb19583b 100644 --- a/tests/baselines/reference/emitBundleWithShebang1.js +++ b/tests/baselines/reference/emitBundleWithShebang1.js @@ -9,7 +9,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/emitBundleWithShebang2.js b/tests/baselines/reference/emitBundleWithShebang2.js index ac0a54bd4d2..bab09ed8f36 100644 --- a/tests/baselines/reference/emitBundleWithShebang2.js +++ b/tests/baselines/reference/emitBundleWithShebang2.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/emitBundleWithShebangAndPrologueDirectives1.js b/tests/baselines/reference/emitBundleWithShebangAndPrologueDirectives1.js index 99590f80d01..771dee4607b 100644 --- a/tests/baselines/reference/emitBundleWithShebangAndPrologueDirectives1.js +++ b/tests/baselines/reference/emitBundleWithShebangAndPrologueDirectives1.js @@ -11,7 +11,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/emitBundleWithShebangAndPrologueDirectives2.js b/tests/baselines/reference/emitBundleWithShebangAndPrologueDirectives2.js index 9aac22c9c07..07f9743a996 100644 --- a/tests/baselines/reference/emitBundleWithShebangAndPrologueDirectives2.js +++ b/tests/baselines/reference/emitBundleWithShebangAndPrologueDirectives2.js @@ -21,7 +21,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/emitClassDeclarationWithPropertyAccessInHeritageClause1.js b/tests/baselines/reference/emitClassDeclarationWithPropertyAccessInHeritageClause1.js index 7d84518a75d..0ba98d427f2 100644 --- a/tests/baselines/reference/emitClassDeclarationWithPropertyAccessInHeritageClause1.js +++ b/tests/baselines/reference/emitClassDeclarationWithPropertyAccessInHeritageClause1.js @@ -10,7 +10,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/emitClassExpressionInDeclarationFile.js b/tests/baselines/reference/emitClassExpressionInDeclarationFile.js index efb14f6a077..0483803f04d 100644 --- a/tests/baselines/reference/emitClassExpressionInDeclarationFile.js +++ b/tests/baselines/reference/emitClassExpressionInDeclarationFile.js @@ -36,7 +36,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/emitClassExpressionInDeclarationFile2.js b/tests/baselines/reference/emitClassExpressionInDeclarationFile2.js index 7c74ad06888..6b749ac8596 100644 --- a/tests/baselines/reference/emitClassExpressionInDeclarationFile2.js +++ b/tests/baselines/reference/emitClassExpressionInDeclarationFile2.js @@ -35,7 +35,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/emitSuperCallBeforeEmitParameterPropertyDeclaration1.js b/tests/baselines/reference/emitSuperCallBeforeEmitParameterPropertyDeclaration1.js index 46979a25b15..6d6a6460436 100644 --- a/tests/baselines/reference/emitSuperCallBeforeEmitParameterPropertyDeclaration1.js +++ b/tests/baselines/reference/emitSuperCallBeforeEmitParameterPropertyDeclaration1.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/emitSuperCallBeforeEmitPropertyDeclaration1.js b/tests/baselines/reference/emitSuperCallBeforeEmitPropertyDeclaration1.js index 09985c47478..3632612fdb0 100644 --- a/tests/baselines/reference/emitSuperCallBeforeEmitPropertyDeclaration1.js +++ b/tests/baselines/reference/emitSuperCallBeforeEmitPropertyDeclaration1.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/emitSuperCallBeforeEmitPropertyDeclarationAndParameterPropertyDeclaration1.js b/tests/baselines/reference/emitSuperCallBeforeEmitPropertyDeclarationAndParameterPropertyDeclaration1.js index f94699c64a4..20eb259a72e 100644 --- a/tests/baselines/reference/emitSuperCallBeforeEmitPropertyDeclarationAndParameterPropertyDeclaration1.js +++ b/tests/baselines/reference/emitSuperCallBeforeEmitPropertyDeclarationAndParameterPropertyDeclaration1.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/emitThisInSuperMethodCall.js b/tests/baselines/reference/emitThisInSuperMethodCall.js index 399cd122285..39b034dd7ee 100644 --- a/tests/baselines/reference/emitThisInSuperMethodCall.js +++ b/tests/baselines/reference/emitThisInSuperMethodCall.js @@ -32,7 +32,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/emitter.asyncGenerators.classMethods.es5.js b/tests/baselines/reference/emitter.asyncGenerators.classMethods.es5.js index fa9c9f3a515..fa539ab546d 100644 --- a/tests/baselines/reference/emitter.asyncGenerators.classMethods.es5.js +++ b/tests/baselines/reference/emitter.asyncGenerators.classMethods.es5.js @@ -575,7 +575,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/emptyModuleName.js b/tests/baselines/reference/emptyModuleName.js index eaefba8304f..2c0a81c3709 100644 --- a/tests/baselines/reference/emptyModuleName.js +++ b/tests/baselines/reference/emptyModuleName.js @@ -9,7 +9,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/errorForwardReferenceForwadingConstructor.js b/tests/baselines/reference/errorForwardReferenceForwadingConstructor.js index 36abfb4d741..d30c2f53aaf 100644 --- a/tests/baselines/reference/errorForwardReferenceForwadingConstructor.js +++ b/tests/baselines/reference/errorForwardReferenceForwadingConstructor.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/errorSuperCalls.js b/tests/baselines/reference/errorSuperCalls.js index 5239c92a10f..699535b4963 100644 --- a/tests/baselines/reference/errorSuperCalls.js +++ b/tests/baselines/reference/errorSuperCalls.js @@ -79,7 +79,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/errorSuperPropertyAccess.js b/tests/baselines/reference/errorSuperPropertyAccess.js index e63854304d7..15a77f650ec 100644 --- a/tests/baselines/reference/errorSuperPropertyAccess.js +++ b/tests/baselines/reference/errorSuperPropertyAccess.js @@ -133,7 +133,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/errorsInGenericTypeReference.js b/tests/baselines/reference/errorsInGenericTypeReference.js index d64719af602..65b2827b3d2 100644 --- a/tests/baselines/reference/errorsInGenericTypeReference.js +++ b/tests/baselines/reference/errorsInGenericTypeReference.js @@ -76,7 +76,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/es6ClassSuperCodegenBug.js b/tests/baselines/reference/es6ClassSuperCodegenBug.js index 634223c8005..cf7cdafbeb3 100644 --- a/tests/baselines/reference/es6ClassSuperCodegenBug.js +++ b/tests/baselines/reference/es6ClassSuperCodegenBug.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/es6ClassTest.js b/tests/baselines/reference/es6ClassTest.js index c9384e6b48c..479e6bc28a2 100644 --- a/tests/baselines/reference/es6ClassTest.js +++ b/tests/baselines/reference/es6ClassTest.js @@ -89,7 +89,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/es6ClassTest2.js b/tests/baselines/reference/es6ClassTest2.js index 86edc5adcdb..148c33832cf 100644 --- a/tests/baselines/reference/es6ClassTest2.js +++ b/tests/baselines/reference/es6ClassTest2.js @@ -163,7 +163,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/es6ClassTest7.js b/tests/baselines/reference/es6ClassTest7.js index 0884a7ed382..99a724f9b9d 100644 --- a/tests/baselines/reference/es6ClassTest7.js +++ b/tests/baselines/reference/es6ClassTest7.js @@ -13,7 +13,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/es6ExportAllInEs5.js b/tests/baselines/reference/es6ExportAllInEs5.js index aaf14965eca..12bc63037a1 100644 --- a/tests/baselines/reference/es6ExportAllInEs5.js +++ b/tests/baselines/reference/es6ExportAllInEs5.js @@ -40,7 +40,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; Object.defineProperty(exports, "__esModule", { value: true }); __exportStar(require("./server"), exports); diff --git a/tests/baselines/reference/es6ExportEqualsInterop.js b/tests/baselines/reference/es6ExportEqualsInterop.js index 6655aba4263..7b0902786a1 100644 --- a/tests/baselines/reference/es6ExportEqualsInterop.js +++ b/tests/baselines/reference/es6ExportEqualsInterop.js @@ -217,7 +217,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; exports.a0 = exports.a9 = exports.a8 = exports.a7 = exports.a6 = exports.a5 = exports.a4 = exports.a3 = exports.a2 = exports.a1 = void 0; diff --git a/tests/baselines/reference/esModuleInterop.js b/tests/baselines/reference/esModuleInterop.js index 14085e89d79..dd4487c4339 100644 --- a/tests/baselines/reference/esModuleInterop.js +++ b/tests/baselines/reference/esModuleInterop.js @@ -35,7 +35,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; diff --git a/tests/baselines/reference/esModuleInteropImportCall.js b/tests/baselines/reference/esModuleInteropImportCall.js index d57eafba73b..c4e3b3b26ac 100644 --- a/tests/baselines/reference/esModuleInteropImportCall.js +++ b/tests/baselines/reference/esModuleInteropImportCall.js @@ -26,7 +26,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; diff --git a/tests/baselines/reference/esModuleInteropImportNamespace.js b/tests/baselines/reference/esModuleInteropImportNamespace.js index fee52b0157e..b392c4d7400 100644 --- a/tests/baselines/reference/esModuleInteropImportNamespace.js +++ b/tests/baselines/reference/esModuleInteropImportNamespace.js @@ -27,7 +27,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; diff --git a/tests/baselines/reference/esModuleInteropNamedDefaultImports.js b/tests/baselines/reference/esModuleInteropNamedDefaultImports.js index f87d7fe5f24..ab28bbfaae7 100644 --- a/tests/baselines/reference/esModuleInteropNamedDefaultImports.js +++ b/tests/baselines/reference/esModuleInteropNamedDefaultImports.js @@ -45,7 +45,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; diff --git a/tests/baselines/reference/esModuleInteropPrettyErrorRelatedInformation.js b/tests/baselines/reference/esModuleInteropPrettyErrorRelatedInformation.js index 6d05072a5bb..cba862db145 100644 --- a/tests/baselines/reference/esModuleInteropPrettyErrorRelatedInformation.js +++ b/tests/baselines/reference/esModuleInteropPrettyErrorRelatedInformation.js @@ -27,7 +27,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; diff --git a/tests/baselines/reference/esModuleInteropUsesExportStarWhenDefaultPlusNames.js b/tests/baselines/reference/esModuleInteropUsesExportStarWhenDefaultPlusNames.js index f463275511f..0586ebeeeca 100644 --- a/tests/baselines/reference/esModuleInteropUsesExportStarWhenDefaultPlusNames.js +++ b/tests/baselines/reference/esModuleInteropUsesExportStarWhenDefaultPlusNames.js @@ -20,7 +20,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; diff --git a/tests/baselines/reference/esModuleInteropWithExportStar(target=es3).js b/tests/baselines/reference/esModuleInteropWithExportStar(target=es3).js index 660a3f47df9..ef026250745 100644 --- a/tests/baselines/reference/esModuleInteropWithExportStar(target=es3).js +++ b/tests/baselines/reference/esModuleInteropWithExportStar(target=es3).js @@ -29,12 +29,12 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; exports.y = exports.x = void 0; diff --git a/tests/baselines/reference/esModuleInteropWithExportStar(target=es5).js b/tests/baselines/reference/esModuleInteropWithExportStar(target=es5).js index e76f08b133d..d306d05644c 100644 --- a/tests/baselines/reference/esModuleInteropWithExportStar(target=es5).js +++ b/tests/baselines/reference/esModuleInteropWithExportStar(target=es5).js @@ -29,12 +29,12 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; Object.defineProperty(exports, "__esModule", { value: true }); exports.y = exports.x = void 0; diff --git a/tests/baselines/reference/esModuleIntersectionCrash.js b/tests/baselines/reference/esModuleIntersectionCrash.js index b91f88929b7..ce60fc48e92 100644 --- a/tests/baselines/reference/esModuleIntersectionCrash.js +++ b/tests/baselines/reference/esModuleIntersectionCrash.js @@ -29,7 +29,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; diff --git a/tests/baselines/reference/expandoFunctionContextualTypesJs.symbols b/tests/baselines/reference/expandoFunctionContextualTypesJs.symbols index bf0b71f5664..bf0ef14f438 100644 --- a/tests/baselines/reference/expandoFunctionContextualTypesJs.symbols +++ b/tests/baselines/reference/expandoFunctionContextualTypesJs.symbols @@ -58,11 +58,14 @@ function foo() { * @type {MyComponentProps} */ this.props = { color: "red" }; +>this.props : Symbol(foo.props, Decl(input.js, 35, 16)) +>this : Symbol(foo, Decl(input.js, 33, 28)) >props : Symbol(foo.props, Decl(input.js, 35, 16)) >color : Symbol(color, Decl(input.js, 39, 18)) expectLiteral(this); >expectLiteral : Symbol(expectLiteral, Decl(input.js, 27, 27)) +>this : Symbol(foo, Decl(input.js, 33, 28)) } /** diff --git a/tests/baselines/reference/expandoFunctionContextualTypesJs.types b/tests/baselines/reference/expandoFunctionContextualTypesJs.types index 1a9a12b8595..5c314a28cba 100644 --- a/tests/baselines/reference/expandoFunctionContextualTypesJs.types +++ b/tests/baselines/reference/expandoFunctionContextualTypesJs.types @@ -70,9 +70,9 @@ function foo() { */ this.props = { color: "red" }; >this.props = { color: "red" } : { color: "red"; } ->this.props : any ->this : any ->props : any +>this.props : { color: "red" | "blue"; } +>this : this +>props : { color: "red" | "blue"; } >{ color: "red" } : { color: "red"; } >color : "red" >"red" : "red" @@ -80,7 +80,7 @@ function foo() { expectLiteral(this); >expectLiteral(this) : void >expectLiteral : (p: { props: { color: "red" | "blue"; }; }) => void ->this : any +>this : this } /** diff --git a/tests/baselines/reference/expandoOnAlias.errors.txt b/tests/baselines/reference/expandoOnAlias.errors.txt new file mode 100644 index 00000000000..d1b29d0aa31 --- /dev/null +++ b/tests/baselines/reference/expandoOnAlias.errors.txt @@ -0,0 +1,25 @@ +tests/cases/conformance/salsa/test.js(4,5): error TS2339: Property 'config' does not exist on type 'typeof Vue'. + + +==== tests/cases/conformance/salsa/vue.js (0 errors) ==== + export class Vue {} + export const config = { x: 0 }; + +==== tests/cases/conformance/salsa/test.js (1 errors) ==== + import { Vue, config } from "./vue"; + + // Expando declarations aren't allowed on aliases. + Vue.config = {}; + ~~~~~~ +!!! error TS2339: Property 'config' does not exist on type 'typeof Vue'. + new Vue(); + + // This is not an expando declaration; it's just a plain property assignment. + config.x = 1; + + // This is not an expando declaration; it works because non-strict JS allows + // loosey goosey assignment on objects. + config.y = {}; + config.x; + config.y; + \ No newline at end of file diff --git a/tests/baselines/reference/expandoOnAlias.js b/tests/baselines/reference/expandoOnAlias.js new file mode 100644 index 00000000000..39e20fb38d7 --- /dev/null +++ b/tests/baselines/reference/expandoOnAlias.js @@ -0,0 +1,33 @@ +//// [tests/cases/conformance/salsa/expandoOnAlias.ts] //// + +//// [vue.js] +export class Vue {} +export const config = { x: 0 }; + +//// [test.js] +import { Vue, config } from "./vue"; + +// Expando declarations aren't allowed on aliases. +Vue.config = {}; +new Vue(); + +// This is not an expando declaration; it's just a plain property assignment. +config.x = 1; + +// This is not an expando declaration; it works because non-strict JS allows +// loosey goosey assignment on objects. +config.y = {}; +config.x; +config.y; + + + + +//// [vue.d.ts] +export class Vue { +} +export namespace config { + const x: number; +} +//// [test.d.ts] +export {}; diff --git a/tests/baselines/reference/expandoOnAlias.symbols b/tests/baselines/reference/expandoOnAlias.symbols new file mode 100644 index 00000000000..e4aa1350dd4 --- /dev/null +++ b/tests/baselines/reference/expandoOnAlias.symbols @@ -0,0 +1,39 @@ +=== tests/cases/conformance/salsa/vue.js === +export class Vue {} +>Vue : Symbol(Vue, Decl(vue.js, 0, 0)) + +export const config = { x: 0 }; +>config : Symbol(config, Decl(vue.js, 1, 12)) +>x : Symbol(x, Decl(vue.js, 1, 23)) + +=== tests/cases/conformance/salsa/test.js === +import { Vue, config } from "./vue"; +>Vue : Symbol(Vue, Decl(test.js, 0, 8)) +>config : Symbol(config, Decl(test.js, 0, 13)) + +// Expando declarations aren't allowed on aliases. +Vue.config = {}; +>Vue : Symbol(Vue, Decl(test.js, 0, 8)) + +new Vue(); +>Vue : Symbol(Vue, Decl(test.js, 0, 8)) + +// This is not an expando declaration; it's just a plain property assignment. +config.x = 1; +>config.x : Symbol(x, Decl(vue.js, 1, 23)) +>config : Symbol(config, Decl(test.js, 0, 13)) +>x : Symbol(x, Decl(vue.js, 1, 23)) + +// This is not an expando declaration; it works because non-strict JS allows +// loosey goosey assignment on objects. +config.y = {}; +>config : Symbol(config, Decl(test.js, 0, 13)) + +config.x; +>config.x : Symbol(x, Decl(vue.js, 1, 23)) +>config : Symbol(config, Decl(test.js, 0, 13)) +>x : Symbol(x, Decl(vue.js, 1, 23)) + +config.y; +>config : Symbol(config, Decl(test.js, 0, 13)) + diff --git a/tests/baselines/reference/expandoOnAlias.types b/tests/baselines/reference/expandoOnAlias.types new file mode 100644 index 00000000000..a0dd0872dea --- /dev/null +++ b/tests/baselines/reference/expandoOnAlias.types @@ -0,0 +1,54 @@ +=== tests/cases/conformance/salsa/vue.js === +export class Vue {} +>Vue : Vue + +export const config = { x: 0 }; +>config : { x: number; } +>{ x: 0 } : { x: number; } +>x : number +>0 : 0 + +=== tests/cases/conformance/salsa/test.js === +import { Vue, config } from "./vue"; +>Vue : typeof Vue +>config : { x: number; } + +// Expando declarations aren't allowed on aliases. +Vue.config = {}; +>Vue.config = {} : {} +>Vue.config : any +>Vue : typeof Vue +>config : any +>{} : {} + +new Vue(); +>new Vue() : Vue +>Vue : typeof Vue + +// This is not an expando declaration; it's just a plain property assignment. +config.x = 1; +>config.x = 1 : 1 +>config.x : number +>config : { x: number; } +>x : number +>1 : 1 + +// This is not an expando declaration; it works because non-strict JS allows +// loosey goosey assignment on objects. +config.y = {}; +>config.y = {} : {} +>config.y : any +>config : { x: number; } +>y : any +>{} : {} + +config.x; +>config.x : number +>config : { x: number; } +>x : number + +config.y; +>config.y : any +>config : { x: number; } +>y : any + diff --git a/tests/baselines/reference/exportAsNamespace2(module=amd).js b/tests/baselines/reference/exportAsNamespace2(module=amd).js index 247e56049ba..a211d159abf 100644 --- a/tests/baselines/reference/exportAsNamespace2(module=amd).js +++ b/tests/baselines/reference/exportAsNamespace2(module=amd).js @@ -39,7 +39,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; @@ -67,7 +67,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; diff --git a/tests/baselines/reference/exportAsNamespace2(module=commonjs).js b/tests/baselines/reference/exportAsNamespace2(module=commonjs).js index 501cacf8957..9b0ba0dd3e1 100644 --- a/tests/baselines/reference/exportAsNamespace2(module=commonjs).js +++ b/tests/baselines/reference/exportAsNamespace2(module=commonjs).js @@ -38,7 +38,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; @@ -64,7 +64,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; diff --git a/tests/baselines/reference/exportAsNamespace2(module=umd).js b/tests/baselines/reference/exportAsNamespace2(module=umd).js index b0ff51a1161..f8e27459393 100644 --- a/tests/baselines/reference/exportAsNamespace2(module=umd).js +++ b/tests/baselines/reference/exportAsNamespace2(module=umd).js @@ -47,7 +47,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; @@ -83,7 +83,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; diff --git a/tests/baselines/reference/exportAsNamespace3(module=amd).js b/tests/baselines/reference/exportAsNamespace3(module=amd).js index 3e291ae18b5..0d0f63426fa 100644 --- a/tests/baselines/reference/exportAsNamespace3(module=amd).js +++ b/tests/baselines/reference/exportAsNamespace3(module=amd).js @@ -42,7 +42,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; @@ -73,7 +73,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; diff --git a/tests/baselines/reference/exportAsNamespace3(module=commonjs).js b/tests/baselines/reference/exportAsNamespace3(module=commonjs).js index 2312f9c6524..5d2226039fb 100644 --- a/tests/baselines/reference/exportAsNamespace3(module=commonjs).js +++ b/tests/baselines/reference/exportAsNamespace3(module=commonjs).js @@ -41,7 +41,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; @@ -70,7 +70,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; diff --git a/tests/baselines/reference/exportAsNamespace3(module=umd).js b/tests/baselines/reference/exportAsNamespace3(module=umd).js index 33068de8d56..da902de4e41 100644 --- a/tests/baselines/reference/exportAsNamespace3(module=umd).js +++ b/tests/baselines/reference/exportAsNamespace3(module=umd).js @@ -50,7 +50,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; @@ -89,7 +89,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; diff --git a/tests/baselines/reference/exportAsNamespace_exportAssignment.js b/tests/baselines/reference/exportAsNamespace_exportAssignment.js index 71f1dcf31b5..dd7ac8623c8 100644 --- a/tests/baselines/reference/exportAsNamespace_exportAssignment.js +++ b/tests/baselines/reference/exportAsNamespace_exportAssignment.js @@ -27,7 +27,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; diff --git a/tests/baselines/reference/exportAssignmentOfGenericType1.js b/tests/baselines/reference/exportAssignmentOfGenericType1.js index c9b807c8dfd..3c392e5d05f 100644 --- a/tests/baselines/reference/exportAssignmentOfGenericType1.js +++ b/tests/baselines/reference/exportAssignmentOfGenericType1.js @@ -28,7 +28,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/exportClassExtendingIntersection.js b/tests/baselines/reference/exportClassExtendingIntersection.js index c363e0a7a02..28f19d44442 100644 --- a/tests/baselines/reference/exportClassExtendingIntersection.js +++ b/tests/baselines/reference/exportClassExtendingIntersection.js @@ -51,7 +51,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { @@ -78,7 +78,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/exportDeclarationInInternalModule.js b/tests/baselines/reference/exportDeclarationInInternalModule.js index a0bb5687fd8..ec87d8a94ba 100644 --- a/tests/baselines/reference/exportDeclarationInInternalModule.js +++ b/tests/baselines/reference/exportDeclarationInInternalModule.js @@ -22,7 +22,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/exportDefault.js b/tests/baselines/reference/exportDefault.js index c02053175da..ff7173e1c0e 100644 --- a/tests/baselines/reference/exportDefault.js +++ b/tests/baselines/reference/exportDefault.js @@ -59,7 +59,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; @@ -92,7 +92,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; diff --git a/tests/baselines/reference/exportDefaultAbstractClass.js b/tests/baselines/reference/exportDefaultAbstractClass.js index cf11705bdb5..30bf12124fb 100644 --- a/tests/baselines/reference/exportDefaultAbstractClass.js +++ b/tests/baselines/reference/exportDefaultAbstractClass.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { @@ -48,7 +48,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/exportDefaultMarksIdentifierAsUsed.symbols b/tests/baselines/reference/exportDefaultMarksIdentifierAsUsed.symbols index ffb9643c6bb..9dbdf4e44db 100644 --- a/tests/baselines/reference/exportDefaultMarksIdentifierAsUsed.symbols +++ b/tests/baselines/reference/exportDefaultMarksIdentifierAsUsed.symbols @@ -7,10 +7,8 @@ export default Obj; === tests/cases/compiler/b.js === import Obj from './a'; ->Obj : Symbol(Obj, Decl(b.js, 0, 6), Decl(b.js, 0, 22)) +>Obj : Symbol(Obj, Decl(b.js, 0, 6)) Obj.fn = function() {}; ->Obj.fn : Symbol(Obj.fn, Decl(b.js, 0, 22)) ->Obj : Symbol(Obj, Decl(b.js, 0, 6), Decl(b.js, 0, 22)) ->fn : Symbol(Obj.fn, Decl(b.js, 0, 22)) +>Obj : Symbol(Obj, Decl(b.js, 0, 6)) diff --git a/tests/baselines/reference/exportDefaultMarksIdentifierAsUsed.types b/tests/baselines/reference/exportDefaultMarksIdentifierAsUsed.types index f2c20778de0..68ec7924aa1 100644 --- a/tests/baselines/reference/exportDefaultMarksIdentifierAsUsed.types +++ b/tests/baselines/reference/exportDefaultMarksIdentifierAsUsed.types @@ -8,12 +8,12 @@ export default Obj; === tests/cases/compiler/b.js === import Obj from './a'; ->Obj : typeof Obj +>Obj : {} Obj.fn = function() {}; >Obj.fn = function() {} : () => void ->Obj.fn : () => void ->Obj : typeof Obj ->fn : () => void +>Obj.fn : error +>Obj : {} +>fn : any >function() {} : () => void diff --git a/tests/baselines/reference/exportNamespace1.js b/tests/baselines/reference/exportNamespace1.js index 5631e6d8194..0ff7ef64173 100644 --- a/tests/baselines/reference/exportNamespace1.js +++ b/tests/baselines/reference/exportNamespace1.js @@ -37,7 +37,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./b"), exports); diff --git a/tests/baselines/reference/exportNestedNamespaces.symbols b/tests/baselines/reference/exportNestedNamespaces.symbols index 10f1600a2df..9afe4840f34 100644 --- a/tests/baselines/reference/exportNestedNamespaces.symbols +++ b/tests/baselines/reference/exportNestedNamespaces.symbols @@ -12,7 +12,8 @@ exports.n.K = function () { >K : Symbol(n.K, Decl(mod.js, 0, 15)) this.x = 10; ->this : Symbol(n, Decl(mod.js, 0, 0), Decl(mod.js, 1, 8)) +>this.x : Symbol(K.x, Decl(mod.js, 1, 27)) +>this : Symbol(K, Decl(mod.js, 1, 13)) >x : Symbol(K.x, Decl(mod.js, 1, 27)) } exports.Classic = class { diff --git a/tests/baselines/reference/exportNestedNamespaces.types b/tests/baselines/reference/exportNestedNamespaces.types index aae9e30a535..28cb0a5fad3 100644 --- a/tests/baselines/reference/exportNestedNamespaces.types +++ b/tests/baselines/reference/exportNestedNamespaces.types @@ -18,7 +18,7 @@ exports.n.K = function () { this.x = 10; >this.x = 10 : 10 >this.x : any ->this : typeof n +>this : this >x : any >10 : 10 } diff --git a/tests/baselines/reference/exportStar-amd.js b/tests/baselines/reference/exportStar-amd.js index 3292a18294d..f209cc99744 100644 --- a/tests/baselines/reference/exportStar-amd.js +++ b/tests/baselines/reference/exportStar-amd.js @@ -66,7 +66,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; define(["require", "exports", "./t1", "./t2", "./t3"], function (require, exports, t1_1, t2_1, t3_1) { "use strict"; diff --git a/tests/baselines/reference/exportStar.js b/tests/baselines/reference/exportStar.js index 7d2cb9e1fe8..7b0feb3675e 100644 --- a/tests/baselines/reference/exportStar.js +++ b/tests/baselines/reference/exportStar.js @@ -61,7 +61,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; Object.defineProperty(exports, "__esModule", { value: true }); __exportStar(require("./t1"), exports); diff --git a/tests/baselines/reference/exportStarForValues.js b/tests/baselines/reference/exportStarForValues.js index fad8c19a1c7..d361304a7db 100644 --- a/tests/baselines/reference/exportStarForValues.js +++ b/tests/baselines/reference/exportStarForValues.js @@ -21,7 +21,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; define(["require", "exports", "file1"], function (require, exports, file1_1) { "use strict"; diff --git a/tests/baselines/reference/exportStarForValues2.js b/tests/baselines/reference/exportStarForValues2.js index 19c55f2ff84..afa4f5a4481 100644 --- a/tests/baselines/reference/exportStarForValues2.js +++ b/tests/baselines/reference/exportStarForValues2.js @@ -25,7 +25,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; define(["require", "exports", "file1"], function (require, exports, file1_1) { "use strict"; @@ -42,7 +42,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; define(["require", "exports", "file2"], function (require, exports, file2_1) { "use strict"; diff --git a/tests/baselines/reference/exportStarForValues3.js b/tests/baselines/reference/exportStarForValues3.js index a0ea7d524ee..35e5b40ac16 100644 --- a/tests/baselines/reference/exportStarForValues3.js +++ b/tests/baselines/reference/exportStarForValues3.js @@ -37,7 +37,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; define(["require", "exports", "file1"], function (require, exports, file1_1) { "use strict"; @@ -54,7 +54,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; define(["require", "exports", "file1"], function (require, exports, file1_1) { "use strict"; @@ -71,7 +71,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; define(["require", "exports", "file2", "file3"], function (require, exports, file2_1, file3_1) { "use strict"; @@ -89,7 +89,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; define(["require", "exports", "file4"], function (require, exports, file4_1) { "use strict"; diff --git a/tests/baselines/reference/exportStarForValues4.js b/tests/baselines/reference/exportStarForValues4.js index 13a6dfae6cc..0b7f5aa3b96 100644 --- a/tests/baselines/reference/exportStarForValues4.js +++ b/tests/baselines/reference/exportStarForValues4.js @@ -29,7 +29,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; define(["require", "exports", "file2"], function (require, exports, file2_1) { "use strict"; @@ -46,7 +46,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; define(["require", "exports", "file1", "file3"], function (require, exports, file1_1, file3_1) { "use strict"; diff --git a/tests/baselines/reference/exportStarForValues5.js b/tests/baselines/reference/exportStarForValues5.js index d3ecb850f86..200bb38188e 100644 --- a/tests/baselines/reference/exportStarForValues5.js +++ b/tests/baselines/reference/exportStarForValues5.js @@ -21,7 +21,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; define(["require", "exports", "file1"], function (require, exports, file1_1) { "use strict"; diff --git a/tests/baselines/reference/exportStarForValues7.js b/tests/baselines/reference/exportStarForValues7.js index 5d9e534333e..db443acd80e 100644 --- a/tests/baselines/reference/exportStarForValues7.js +++ b/tests/baselines/reference/exportStarForValues7.js @@ -25,7 +25,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; define(["require", "exports", "file1"], function (require, exports, file1_1) { "use strict"; @@ -43,7 +43,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; define(["require", "exports", "file2"], function (require, exports, file2_1) { "use strict"; diff --git a/tests/baselines/reference/exportStarForValues8.js b/tests/baselines/reference/exportStarForValues8.js index 66111015e70..ad8e183a19e 100644 --- a/tests/baselines/reference/exportStarForValues8.js +++ b/tests/baselines/reference/exportStarForValues8.js @@ -37,7 +37,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; define(["require", "exports", "file1"], function (require, exports, file1_1) { "use strict"; @@ -55,7 +55,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; define(["require", "exports", "file1"], function (require, exports, file1_1) { "use strict"; @@ -73,7 +73,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; define(["require", "exports", "file2", "file3"], function (require, exports, file2_1, file3_1) { "use strict"; @@ -92,7 +92,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; define(["require", "exports", "file4"], function (require, exports, file4_1) { "use strict"; diff --git a/tests/baselines/reference/exportStarForValues9.js b/tests/baselines/reference/exportStarForValues9.js index c328f25910b..8eb91c032fa 100644 --- a/tests/baselines/reference/exportStarForValues9.js +++ b/tests/baselines/reference/exportStarForValues9.js @@ -29,7 +29,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; define(["require", "exports", "file2"], function (require, exports, file2_1) { "use strict"; @@ -47,7 +47,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; define(["require", "exports", "file1", "file3"], function (require, exports, file1_1, file3_1) { "use strict"; diff --git a/tests/baselines/reference/exportStarFromEmptyModule.js b/tests/baselines/reference/exportStarFromEmptyModule.js index 9864a341f7e..1b5484fa76d 100644 --- a/tests/baselines/reference/exportStarFromEmptyModule.js +++ b/tests/baselines/reference/exportStarFromEmptyModule.js @@ -44,7 +44,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; Object.defineProperty(exports, "__esModule", { value: true }); exports.A = void 0; diff --git a/tests/baselines/reference/exportStarNotElided.js b/tests/baselines/reference/exportStarNotElided.js index 0b36837f6ea..1db6c1f0169 100644 --- a/tests/baselines/reference/exportStarNotElided.js +++ b/tests/baselines/reference/exportStarNotElided.js @@ -32,7 +32,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; exports.aliased = void 0; diff --git a/tests/baselines/reference/extBaseClass1.js b/tests/baselines/reference/extBaseClass1.js index 1891a78c422..889f00da506 100644 --- a/tests/baselines/reference/extBaseClass1.js +++ b/tests/baselines/reference/extBaseClass1.js @@ -24,7 +24,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/extBaseClass2.js b/tests/baselines/reference/extBaseClass2.js index 703f8070a44..09112dace61 100644 --- a/tests/baselines/reference/extBaseClass2.js +++ b/tests/baselines/reference/extBaseClass2.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/extendAndImplementTheSameBaseType.js b/tests/baselines/reference/extendAndImplementTheSameBaseType.js index 24a9d09e190..16727d9e087 100644 --- a/tests/baselines/reference/extendAndImplementTheSameBaseType.js +++ b/tests/baselines/reference/extendAndImplementTheSameBaseType.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/extendAndImplementTheSameBaseType2.js b/tests/baselines/reference/extendAndImplementTheSameBaseType2.js index b18e331a902..de26c820505 100644 --- a/tests/baselines/reference/extendAndImplementTheSameBaseType2.js +++ b/tests/baselines/reference/extendAndImplementTheSameBaseType2.js @@ -21,7 +21,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/extendBaseClassBeforeItsDeclared.js b/tests/baselines/reference/extendBaseClassBeforeItsDeclared.js index 149b33c1ff2..f620e629d51 100644 --- a/tests/baselines/reference/extendBaseClassBeforeItsDeclared.js +++ b/tests/baselines/reference/extendBaseClassBeforeItsDeclared.js @@ -8,7 +8,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/extendClassExpressionFromModule.js b/tests/baselines/reference/extendClassExpressionFromModule.js index 8878af7efb6..96aefde09be 100644 --- a/tests/baselines/reference/extendClassExpressionFromModule.js +++ b/tests/baselines/reference/extendClassExpressionFromModule.js @@ -25,7 +25,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/extendConstructSignatureInInterface.js b/tests/baselines/reference/extendConstructSignatureInInterface.js index f94010bef97..1dd003021c7 100644 --- a/tests/baselines/reference/extendConstructSignatureInInterface.js +++ b/tests/baselines/reference/extendConstructSignatureInInterface.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/extendFromAny.js b/tests/baselines/reference/extendFromAny.js index d7d4a4b8ba2..01de898e502 100644 --- a/tests/baselines/reference/extendFromAny.js +++ b/tests/baselines/reference/extendFromAny.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/extendNonClassSymbol1.js b/tests/baselines/reference/extendNonClassSymbol1.js index cb5cf45baa2..8bd7ed7e84f 100644 --- a/tests/baselines/reference/extendNonClassSymbol1.js +++ b/tests/baselines/reference/extendNonClassSymbol1.js @@ -8,7 +8,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/extendNonClassSymbol2.js b/tests/baselines/reference/extendNonClassSymbol2.js index 6f6cebbdf28..74cb7a35c79 100644 --- a/tests/baselines/reference/extendNonClassSymbol2.js +++ b/tests/baselines/reference/extendNonClassSymbol2.js @@ -10,7 +10,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/extendPrivateConstructorClass.js b/tests/baselines/reference/extendPrivateConstructorClass.js index 96c06ca6e68..61eaf32e372 100644 --- a/tests/baselines/reference/extendPrivateConstructorClass.js +++ b/tests/baselines/reference/extendPrivateConstructorClass.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/extendingClassFromAliasAndUsageInIndexer.js b/tests/baselines/reference/extendingClassFromAliasAndUsageInIndexer.js index fd154a744bb..083cf486456 100644 --- a/tests/baselines/reference/extendingClassFromAliasAndUsageInIndexer.js +++ b/tests/baselines/reference/extendingClassFromAliasAndUsageInIndexer.js @@ -48,7 +48,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { @@ -74,7 +74,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/extendsClause.js b/tests/baselines/reference/extendsClause.js index c75d2dc8c6e..9efe389b8ae 100644 --- a/tests/baselines/reference/extendsClause.js +++ b/tests/baselines/reference/extendsClause.js @@ -40,7 +40,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/extendsClauseAlreadySeen.js b/tests/baselines/reference/extendsClauseAlreadySeen.js index d1ffec90d29..034d78f5d1d 100644 --- a/tests/baselines/reference/extendsClauseAlreadySeen.js +++ b/tests/baselines/reference/extendsClauseAlreadySeen.js @@ -11,7 +11,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/extendsClauseAlreadySeen2.js b/tests/baselines/reference/extendsClauseAlreadySeen2.js index 2a3bac4008d..67ae052d946 100644 --- a/tests/baselines/reference/extendsClauseAlreadySeen2.js +++ b/tests/baselines/reference/extendsClauseAlreadySeen2.js @@ -11,7 +11,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/extendsUntypedModule.js b/tests/baselines/reference/extendsUntypedModule.js index c239ca4af0f..3d5b09c9ff8 100644 --- a/tests/baselines/reference/extendsUntypedModule.js +++ b/tests/baselines/reference/extendsUntypedModule.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/fluentClasses.js b/tests/baselines/reference/fluentClasses.js index 9f68730010d..05ae3e8ddea 100644 --- a/tests/baselines/reference/fluentClasses.js +++ b/tests/baselines/reference/fluentClasses.js @@ -23,7 +23,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/for-inStatements.js b/tests/baselines/reference/for-inStatements.js index 37349f4d6e6..9ebbf19e9b3 100644 --- a/tests/baselines/reference/for-inStatements.js +++ b/tests/baselines/reference/for-inStatements.js @@ -85,7 +85,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/for-inStatementsInvalid.js b/tests/baselines/reference/for-inStatementsInvalid.js index 195f166317c..de8199c40d6 100644 --- a/tests/baselines/reference/for-inStatementsInvalid.js +++ b/tests/baselines/reference/for-inStatementsInvalid.js @@ -68,7 +68,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/forStatementsMultipleInvalidDecl.js b/tests/baselines/reference/forStatementsMultipleInvalidDecl.js index 0dcda5b1bbb..abfb3aea001 100644 --- a/tests/baselines/reference/forStatementsMultipleInvalidDecl.js +++ b/tests/baselines/reference/forStatementsMultipleInvalidDecl.js @@ -58,7 +58,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/functionExpressionNames.symbols b/tests/baselines/reference/functionExpressionNames.symbols index ba97fd82f52..1675f159134 100644 --- a/tests/baselines/reference/functionExpressionNames.symbols +++ b/tests/baselines/reference/functionExpressionNames.symbols @@ -5,6 +5,8 @@ exports.E = function() { >E : Symbol(E, Decl(b.js, 0, 0)) this.e = 'exported' +>this.e : Symbol(E.e, Decl(b.js, 0, 24)) +>this : Symbol(E, Decl(b.js, 0, 11)) >e : Symbol(E.e, Decl(b.js, 0, 24)) } var e = new exports.E(); @@ -20,7 +22,8 @@ var o = { >C : Symbol(C, Decl(b.js, 5, 9)) this.c = 'nested object' ->this : Symbol(o, Decl(b.js, 5, 7)) +>this.c : Symbol(C.c, Decl(b.js, 6, 20)) +>this : Symbol(C, Decl(b.js, 6, 6)) >c : Symbol(C.c, Decl(b.js, 6, 20)) } } @@ -34,6 +37,8 @@ var V = function () { >V : Symbol(V, Decl(b.js, 12, 3)) this.v = 'simple' +>this.v : Symbol(V.v, Decl(b.js, 12, 21)) +>this : Symbol(V, Decl(b.js, 12, 7)) >v : Symbol(V.v, Decl(b.js, 12, 21)) } var v = new V(); @@ -47,6 +52,8 @@ A = function () { >A : Symbol(A, Decl(b.js, 17, 3)) this.a = 'assignment' +>this.a : Symbol(A.a, Decl(b.js, 18, 17)) +>this : Symbol(A, Decl(b.js, 18, 3)) >a : Symbol(A.a, Decl(b.js, 18, 17)) } var a = new A(); @@ -58,6 +65,8 @@ const { >B : Symbol(B, Decl(b.js, 23, 7)) this.b = 'binding pattern' +>this.b : Symbol(B.b, Decl(b.js, 24, 20)) +>this : Symbol(B, Decl(b.js, 24, 7)) >b : Symbol(B.b, Decl(b.js, 24, 20)) } } = { B: undefined }; diff --git a/tests/baselines/reference/functionExpressionNames.types b/tests/baselines/reference/functionExpressionNames.types index c3e09b4ba46..50c45ed46d3 100644 --- a/tests/baselines/reference/functionExpressionNames.types +++ b/tests/baselines/reference/functionExpressionNames.types @@ -9,7 +9,7 @@ exports.E = function() { this.e = 'exported' >this.e = 'exported' : "exported" >this.e : any ->this : any +>this : this >e : any >'exported' : "exported" } @@ -31,7 +31,7 @@ var o = { this.c = 'nested object' >this.c = 'nested object' : "nested object" >this.c : any ->this : { C: typeof C; } +>this : this >c : any >'nested object' : "nested object" } @@ -50,7 +50,7 @@ var V = function () { this.v = 'simple' >this.v = 'simple' : "simple" >this.v : any ->this : any +>this : this >v : any >'simple' : "simple" } @@ -70,7 +70,7 @@ A = function () { this.a = 'assignment' >this.a = 'assignment' : "assignment" >this.a : any ->this : any +>this : this >a : any >'assignment' : "assignment" } @@ -87,7 +87,7 @@ const { this.b = 'binding pattern' >this.b = 'binding pattern' : "binding pattern" >this.b : any ->this : any +>this : this >b : any >'binding pattern' : "binding pattern" } diff --git a/tests/baselines/reference/functionImplementationErrors.js b/tests/baselines/reference/functionImplementationErrors.js index 10595e3152c..b1124574e5a 100644 --- a/tests/baselines/reference/functionImplementationErrors.js +++ b/tests/baselines/reference/functionImplementationErrors.js @@ -78,7 +78,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/functionImplementations.js b/tests/baselines/reference/functionImplementations.js index d78f694377d..e2d8586dfef 100644 --- a/tests/baselines/reference/functionImplementations.js +++ b/tests/baselines/reference/functionImplementations.js @@ -161,7 +161,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/functionSubtypingOfVarArgs.js b/tests/baselines/reference/functionSubtypingOfVarArgs.js index 6a039fa4821..f63daa56f3b 100644 --- a/tests/baselines/reference/functionSubtypingOfVarArgs.js +++ b/tests/baselines/reference/functionSubtypingOfVarArgs.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/functionSubtypingOfVarArgs2.js b/tests/baselines/reference/functionSubtypingOfVarArgs2.js index 16b2b9537e7..155c288d5d7 100644 --- a/tests/baselines/reference/functionSubtypingOfVarArgs2.js +++ b/tests/baselines/reference/functionSubtypingOfVarArgs2.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/generatedContextualTyping.js b/tests/baselines/reference/generatedContextualTyping.js index 961510504f9..c391c285599 100644 --- a/tests/baselines/reference/generatedContextualTyping.js +++ b/tests/baselines/reference/generatedContextualTyping.js @@ -359,7 +359,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericBaseClassLiteralProperty.js b/tests/baselines/reference/genericBaseClassLiteralProperty.js index 5756b5aedff..04aadf5a91b 100644 --- a/tests/baselines/reference/genericBaseClassLiteralProperty.js +++ b/tests/baselines/reference/genericBaseClassLiteralProperty.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericBaseClassLiteralProperty2.js b/tests/baselines/reference/genericBaseClassLiteralProperty2.js index 48dc4da7aa3..492414a278d 100644 --- a/tests/baselines/reference/genericBaseClassLiteralProperty2.js +++ b/tests/baselines/reference/genericBaseClassLiteralProperty2.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericCallWithConstraintsTypeArgumentInference.js b/tests/baselines/reference/genericCallWithConstraintsTypeArgumentInference.js index daa564b9915..d8deb60bbbe 100644 --- a/tests/baselines/reference/genericCallWithConstraintsTypeArgumentInference.js +++ b/tests/baselines/reference/genericCallWithConstraintsTypeArgumentInference.js @@ -113,7 +113,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericCallWithObjectTypeArgs2.js b/tests/baselines/reference/genericCallWithObjectTypeArgs2.js index 06b0267b269..9cca66978ee 100644 --- a/tests/baselines/reference/genericCallWithObjectTypeArgs2.js +++ b/tests/baselines/reference/genericCallWithObjectTypeArgs2.js @@ -37,7 +37,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints2.js b/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints2.js index cf8c30e6430..187c45cf697 100644 --- a/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints2.js +++ b/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints2.js @@ -45,7 +45,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints3.js b/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints3.js index c9d4de80643..be8ee9e0e52 100644 --- a/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints3.js +++ b/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints3.js @@ -43,7 +43,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericCallbacksAndClassHierarchy.js b/tests/baselines/reference/genericCallbacksAndClassHierarchy.js index 4056291f961..3a06f0f4a8d 100644 --- a/tests/baselines/reference/genericCallbacksAndClassHierarchy.js +++ b/tests/baselines/reference/genericCallbacksAndClassHierarchy.js @@ -28,7 +28,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericClassExpressionInFunction.js b/tests/baselines/reference/genericClassExpressionInFunction.js index bf93d5d336b..1990f71015a 100644 --- a/tests/baselines/reference/genericClassExpressionInFunction.js +++ b/tests/baselines/reference/genericClassExpressionInFunction.js @@ -36,7 +36,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericClassInheritsConstructorFromNonGenericClass.js b/tests/baselines/reference/genericClassInheritsConstructorFromNonGenericClass.js index 2f36fc1290c..e5109beb8ae 100644 --- a/tests/baselines/reference/genericClassInheritsConstructorFromNonGenericClass.js +++ b/tests/baselines/reference/genericClassInheritsConstructorFromNonGenericClass.js @@ -10,7 +10,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericClassPropertyInheritanceSpecialization.js b/tests/baselines/reference/genericClassPropertyInheritanceSpecialization.js index d99e89f06c0..dcebdd3369c 100644 --- a/tests/baselines/reference/genericClassPropertyInheritanceSpecialization.js +++ b/tests/baselines/reference/genericClassPropertyInheritanceSpecialization.js @@ -80,7 +80,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericClassStaticMethod.js b/tests/baselines/reference/genericClassStaticMethod.js index 216d915d6e5..5f2156a9ea6 100644 --- a/tests/baselines/reference/genericClassStaticMethod.js +++ b/tests/baselines/reference/genericClassStaticMethod.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericClasses3.js b/tests/baselines/reference/genericClasses3.js index ff4e5e1a095..0bda39dcc19 100644 --- a/tests/baselines/reference/genericClasses3.js +++ b/tests/baselines/reference/genericClasses3.js @@ -22,7 +22,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericConstraintOnExtendedBuiltinTypes.js b/tests/baselines/reference/genericConstraintOnExtendedBuiltinTypes.js index b5d7064c993..87ee3e75b2a 100644 --- a/tests/baselines/reference/genericConstraintOnExtendedBuiltinTypes.js +++ b/tests/baselines/reference/genericConstraintOnExtendedBuiltinTypes.js @@ -31,7 +31,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericConstraintOnExtendedBuiltinTypes2.js b/tests/baselines/reference/genericConstraintOnExtendedBuiltinTypes2.js index dae891378a2..e243fc57f81 100644 --- a/tests/baselines/reference/genericConstraintOnExtendedBuiltinTypes2.js +++ b/tests/baselines/reference/genericConstraintOnExtendedBuiltinTypes2.js @@ -30,7 +30,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericDerivedTypeWithSpecializedBase.js b/tests/baselines/reference/genericDerivedTypeWithSpecializedBase.js index 7803c463eb8..d3b01267423 100644 --- a/tests/baselines/reference/genericDerivedTypeWithSpecializedBase.js +++ b/tests/baselines/reference/genericDerivedTypeWithSpecializedBase.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericDerivedTypeWithSpecializedBase2.js b/tests/baselines/reference/genericDerivedTypeWithSpecializedBase2.js index 08674c5a251..61806008b34 100644 --- a/tests/baselines/reference/genericDerivedTypeWithSpecializedBase2.js +++ b/tests/baselines/reference/genericDerivedTypeWithSpecializedBase2.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericInheritedDefaultConstructors.js b/tests/baselines/reference/genericInheritedDefaultConstructors.js index 9ebf6c517ea..c543c448762 100644 --- a/tests/baselines/reference/genericInheritedDefaultConstructors.js +++ b/tests/baselines/reference/genericInheritedDefaultConstructors.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericPrototypeProperty2.js b/tests/baselines/reference/genericPrototypeProperty2.js index 4d9c9fced86..62d8f8af0e2 100644 --- a/tests/baselines/reference/genericPrototypeProperty2.js +++ b/tests/baselines/reference/genericPrototypeProperty2.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericPrototypeProperty3.js b/tests/baselines/reference/genericPrototypeProperty3.js index 433b57906c3..99178918374 100644 --- a/tests/baselines/reference/genericPrototypeProperty3.js +++ b/tests/baselines/reference/genericPrototypeProperty3.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericRecursiveImplicitConstructorErrors2.js b/tests/baselines/reference/genericRecursiveImplicitConstructorErrors2.js index e2567e52764..ac1729a4871 100644 --- a/tests/baselines/reference/genericRecursiveImplicitConstructorErrors2.js +++ b/tests/baselines/reference/genericRecursiveImplicitConstructorErrors2.js @@ -31,7 +31,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericRecursiveImplicitConstructorErrors3.js b/tests/baselines/reference/genericRecursiveImplicitConstructorErrors3.js index 3f95abc3c35..bb80d2045ae 100644 --- a/tests/baselines/reference/genericRecursiveImplicitConstructorErrors3.js +++ b/tests/baselines/reference/genericRecursiveImplicitConstructorErrors3.js @@ -35,7 +35,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericTypeAssertions2.js b/tests/baselines/reference/genericTypeAssertions2.js index 786ce3440d2..1cb08b21ce5 100644 --- a/tests/baselines/reference/genericTypeAssertions2.js +++ b/tests/baselines/reference/genericTypeAssertions2.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericTypeAssertions4.js b/tests/baselines/reference/genericTypeAssertions4.js index bcf6c1e7b8e..4939e7de9e1 100644 --- a/tests/baselines/reference/genericTypeAssertions4.js +++ b/tests/baselines/reference/genericTypeAssertions4.js @@ -30,7 +30,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericTypeAssertions6.js b/tests/baselines/reference/genericTypeAssertions6.js index 70136b61e2a..133d65fff80 100644 --- a/tests/baselines/reference/genericTypeAssertions6.js +++ b/tests/baselines/reference/genericTypeAssertions6.js @@ -29,7 +29,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericTypeConstraints.js b/tests/baselines/reference/genericTypeConstraints.js index 8cf0092ce71..6d49d5313a1 100644 --- a/tests/baselines/reference/genericTypeConstraints.js +++ b/tests/baselines/reference/genericTypeConstraints.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericTypeReferenceWithoutTypeArgument.js b/tests/baselines/reference/genericTypeReferenceWithoutTypeArgument.js index ad5c6d483e3..4abd3431cbb 100644 --- a/tests/baselines/reference/genericTypeReferenceWithoutTypeArgument.js +++ b/tests/baselines/reference/genericTypeReferenceWithoutTypeArgument.js @@ -44,7 +44,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericTypeReferenceWithoutTypeArgument2.js b/tests/baselines/reference/genericTypeReferenceWithoutTypeArgument2.js index c0eb72cf288..d1a05327c3e 100644 --- a/tests/baselines/reference/genericTypeReferenceWithoutTypeArgument2.js +++ b/tests/baselines/reference/genericTypeReferenceWithoutTypeArgument2.js @@ -44,7 +44,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/genericWithIndexerOfTypeParameterType2.js b/tests/baselines/reference/genericWithIndexerOfTypeParameterType2.js index 9b6ea15c12b..1831a569462 100644 --- a/tests/baselines/reference/genericWithIndexerOfTypeParameterType2.js +++ b/tests/baselines/reference/genericWithIndexerOfTypeParameterType2.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/heterogeneousArrayLiterals.js b/tests/baselines/reference/heterogeneousArrayLiterals.js index b3d710a63b9..94d1c53f671 100644 --- a/tests/baselines/reference/heterogeneousArrayLiterals.js +++ b/tests/baselines/reference/heterogeneousArrayLiterals.js @@ -137,7 +137,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/ifDoWhileStatements.js b/tests/baselines/reference/ifDoWhileStatements.js index d81331b5a99..a36975a40bf 100644 --- a/tests/baselines/reference/ifDoWhileStatements.js +++ b/tests/baselines/reference/ifDoWhileStatements.js @@ -167,7 +167,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/illegalSuperCallsInConstructor.js b/tests/baselines/reference/illegalSuperCallsInConstructor.js index 2c914494b80..7137216402d 100644 --- a/tests/baselines/reference/illegalSuperCallsInConstructor.js +++ b/tests/baselines/reference/illegalSuperCallsInConstructor.js @@ -25,7 +25,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/implementClausePrecedingExtends.js b/tests/baselines/reference/implementClausePrecedingExtends.js index f915ba4514a..9ffac83b6fc 100644 --- a/tests/baselines/reference/implementClausePrecedingExtends.js +++ b/tests/baselines/reference/implementClausePrecedingExtends.js @@ -7,7 +7,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/implementingAnInterfaceExtendingClassWithPrivates2.js b/tests/baselines/reference/implementingAnInterfaceExtendingClassWithPrivates2.js index 65cd2a5c28d..a645b9d4a66 100644 --- a/tests/baselines/reference/implementingAnInterfaceExtendingClassWithPrivates2.js +++ b/tests/baselines/reference/implementingAnInterfaceExtendingClassWithPrivates2.js @@ -90,7 +90,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/implementingAnInterfaceExtendingClassWithProtecteds.js b/tests/baselines/reference/implementingAnInterfaceExtendingClassWithProtecteds.js index 315a26b124a..2c5d9f46dfd 100644 --- a/tests/baselines/reference/implementingAnInterfaceExtendingClassWithProtecteds.js +++ b/tests/baselines/reference/implementingAnInterfaceExtendingClassWithProtecteds.js @@ -46,7 +46,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/importAsBaseClass.js b/tests/baselines/reference/importAsBaseClass.js index 78f468f54f8..94bd340a37e 100644 --- a/tests/baselines/reference/importAsBaseClass.js +++ b/tests/baselines/reference/importAsBaseClass.js @@ -27,7 +27,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/importEquals1.js b/tests/baselines/reference/importEquals1.js index 099c6c4221b..ba224823ac9 100644 --- a/tests/baselines/reference/importEquals1.js +++ b/tests/baselines/reference/importEquals1.js @@ -58,7 +58,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; diff --git a/tests/baselines/reference/importEquals2.js b/tests/baselines/reference/importEquals2.js index 43f05ceea40..8eb56dd89af 100644 --- a/tests/baselines/reference/importEquals2.js +++ b/tests/baselines/reference/importEquals2.js @@ -38,7 +38,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; diff --git a/tests/baselines/reference/importHelpers.js b/tests/baselines/reference/importHelpers.js index a32077ae476..ab354a43de8 100644 --- a/tests/baselines/reference/importHelpers.js +++ b/tests/baselines/reference/importHelpers.js @@ -91,7 +91,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/importHelpersNoHelpers.js b/tests/baselines/reference/importHelpersNoHelpers.js index 2fdea1ff579..f99e1549fb5 100644 --- a/tests/baselines/reference/importHelpersNoHelpers.js +++ b/tests/baselines/reference/importHelpersNoHelpers.js @@ -85,7 +85,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/importHelpersNoModule.js b/tests/baselines/reference/importHelpersNoModule.js index 80a25f8758b..4cce2b15a26 100644 --- a/tests/baselines/reference/importHelpersNoModule.js +++ b/tests/baselines/reference/importHelpersNoModule.js @@ -65,7 +65,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/importNotElidedWhenNotFound.js b/tests/baselines/reference/importNotElidedWhenNotFound.js index 9af5664d338..6333fcff7f0 100644 --- a/tests/baselines/reference/importNotElidedWhenNotFound.js +++ b/tests/baselines/reference/importNotElidedWhenNotFound.js @@ -23,7 +23,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/importShadowsGlobalName.js b/tests/baselines/reference/importShadowsGlobalName.js index c1ae9b816fc..ce2ecafce17 100644 --- a/tests/baselines/reference/importShadowsGlobalName.js +++ b/tests/baselines/reference/importShadowsGlobalName.js @@ -24,7 +24,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/importUsedInExtendsList1.js b/tests/baselines/reference/importUsedInExtendsList1.js index 215e2e1df70..cf292ef1568 100644 --- a/tests/baselines/reference/importUsedInExtendsList1.js +++ b/tests/baselines/reference/importUsedInExtendsList1.js @@ -27,7 +27,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/indexedAccessKeyofNestedSimplifiedSubstituteUnwrapped.js b/tests/baselines/reference/indexedAccessKeyofNestedSimplifiedSubstituteUnwrapped.js index 2ff1261fd79..fd004783596 100644 --- a/tests/baselines/reference/indexedAccessKeyofNestedSimplifiedSubstituteUnwrapped.js +++ b/tests/baselines/reference/indexedAccessKeyofNestedSimplifiedSubstituteUnwrapped.js @@ -27,7 +27,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/indexedAccessRelation.js b/tests/baselines/reference/indexedAccessRelation.js index 643200eaf6e..7bab276dac5 100644 --- a/tests/baselines/reference/indexedAccessRelation.js +++ b/tests/baselines/reference/indexedAccessRelation.js @@ -26,7 +26,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/indexedAccessTypeConstraints.js b/tests/baselines/reference/indexedAccessTypeConstraints.js index 47007268c2b..2fc326a1d34 100644 --- a/tests/baselines/reference/indexedAccessTypeConstraints.js +++ b/tests/baselines/reference/indexedAccessTypeConstraints.js @@ -42,7 +42,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/indexerConstraints2.js b/tests/baselines/reference/indexerConstraints2.js index 634be50d22b..adce25026fd 100644 --- a/tests/baselines/reference/indexerConstraints2.js +++ b/tests/baselines/reference/indexerConstraints2.js @@ -86,7 +86,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/indirectSelfReference.js b/tests/baselines/reference/indirectSelfReference.js index 9cf86981793..0f45ac1008a 100644 --- a/tests/baselines/reference/indirectSelfReference.js +++ b/tests/baselines/reference/indirectSelfReference.js @@ -7,7 +7,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/indirectSelfReferenceGeneric.js b/tests/baselines/reference/indirectSelfReferenceGeneric.js index a70fdaddac5..ab38504ec2a 100644 --- a/tests/baselines/reference/indirectSelfReferenceGeneric.js +++ b/tests/baselines/reference/indirectSelfReferenceGeneric.js @@ -7,7 +7,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inferringClassMembersFromAssignments2.symbols b/tests/baselines/reference/inferringClassMembersFromAssignments2.symbols index 457dc9bea02..89be524d4cd 100644 --- a/tests/baselines/reference/inferringClassMembersFromAssignments2.symbols +++ b/tests/baselines/reference/inferringClassMembersFromAssignments2.symbols @@ -14,6 +14,8 @@ function OOOrder() { >OOOrder : Symbol(OOOrder, Decl(a.js, 2, 1)) this.x = 1 +>this.x : Symbol(OOOrder.x, Decl(a.js, 3, 20)) +>this : Symbol(OOOrder, Decl(a.js, 2, 1)) >x : Symbol(OOOrder.x, Decl(a.js, 3, 20)) } diff --git a/tests/baselines/reference/inferringClassMembersFromAssignments2.types b/tests/baselines/reference/inferringClassMembersFromAssignments2.types index 39c00bc9181..c3c9067a5d3 100644 --- a/tests/baselines/reference/inferringClassMembersFromAssignments2.types +++ b/tests/baselines/reference/inferringClassMembersFromAssignments2.types @@ -21,7 +21,7 @@ function OOOrder() { this.x = 1 >this.x = 1 : 1 >this.x : any ->this : any +>this : this >x : any >1 : 1 } diff --git a/tests/baselines/reference/infinitelyExpandingTypesNonGenericBase.js b/tests/baselines/reference/infinitelyExpandingTypesNonGenericBase.js index 406ae7e5fc4..8789ed14610 100644 --- a/tests/baselines/reference/infinitelyExpandingTypesNonGenericBase.js +++ b/tests/baselines/reference/infinitelyExpandingTypesNonGenericBase.js @@ -29,7 +29,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritFromGenericTypeParameter.js b/tests/baselines/reference/inheritFromGenericTypeParameter.js index 9821870ab35..d65cbe4edf2 100644 --- a/tests/baselines/reference/inheritFromGenericTypeParameter.js +++ b/tests/baselines/reference/inheritFromGenericTypeParameter.js @@ -7,7 +7,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritSameNamePrivatePropertiesFromSameOrigin.js b/tests/baselines/reference/inheritSameNamePrivatePropertiesFromSameOrigin.js index f0db5d77f18..706d36854c7 100644 --- a/tests/baselines/reference/inheritSameNamePrivatePropertiesFromSameOrigin.js +++ b/tests/baselines/reference/inheritSameNamePrivatePropertiesFromSameOrigin.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritance.js b/tests/baselines/reference/inheritance.js index 6ef3652ce02..aa87de523c3 100644 --- a/tests/baselines/reference/inheritance.js +++ b/tests/baselines/reference/inheritance.js @@ -39,7 +39,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritance1.js b/tests/baselines/reference/inheritance1.js index c6c01b716dd..10477378882 100644 --- a/tests/baselines/reference/inheritance1.js +++ b/tests/baselines/reference/inheritance1.js @@ -66,7 +66,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceGrandParentPrivateMemberCollision.js b/tests/baselines/reference/inheritanceGrandParentPrivateMemberCollision.js index 394c139e9aa..5da7c5f319e 100644 --- a/tests/baselines/reference/inheritanceGrandParentPrivateMemberCollision.js +++ b/tests/baselines/reference/inheritanceGrandParentPrivateMemberCollision.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceGrandParentPrivateMemberCollisionWithPublicMember.js b/tests/baselines/reference/inheritanceGrandParentPrivateMemberCollisionWithPublicMember.js index 63b2bfe7baf..27e64cde414 100644 --- a/tests/baselines/reference/inheritanceGrandParentPrivateMemberCollisionWithPublicMember.js +++ b/tests/baselines/reference/inheritanceGrandParentPrivateMemberCollisionWithPublicMember.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceGrandParentPublicMemberCollisionWithPrivateMember.js b/tests/baselines/reference/inheritanceGrandParentPublicMemberCollisionWithPrivateMember.js index e6d9647a29d..1807924b73d 100644 --- a/tests/baselines/reference/inheritanceGrandParentPublicMemberCollisionWithPrivateMember.js +++ b/tests/baselines/reference/inheritanceGrandParentPublicMemberCollisionWithPrivateMember.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceMemberAccessorOverridingAccessor.js b/tests/baselines/reference/inheritanceMemberAccessorOverridingAccessor.js index b8255468e15..be415e78f08 100644 --- a/tests/baselines/reference/inheritanceMemberAccessorOverridingAccessor.js +++ b/tests/baselines/reference/inheritanceMemberAccessorOverridingAccessor.js @@ -22,7 +22,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceMemberAccessorOverridingMethod.js b/tests/baselines/reference/inheritanceMemberAccessorOverridingMethod.js index 537be89bb5e..26bdf6f8402 100644 --- a/tests/baselines/reference/inheritanceMemberAccessorOverridingMethod.js +++ b/tests/baselines/reference/inheritanceMemberAccessorOverridingMethod.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceMemberAccessorOverridingProperty.js b/tests/baselines/reference/inheritanceMemberAccessorOverridingProperty.js index 246cd5548fe..79327b77cbe 100644 --- a/tests/baselines/reference/inheritanceMemberAccessorOverridingProperty.js +++ b/tests/baselines/reference/inheritanceMemberAccessorOverridingProperty.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceMemberFuncOverridingAccessor.js b/tests/baselines/reference/inheritanceMemberFuncOverridingAccessor.js index 2a05146e053..2672c8a399e 100644 --- a/tests/baselines/reference/inheritanceMemberFuncOverridingAccessor.js +++ b/tests/baselines/reference/inheritanceMemberFuncOverridingAccessor.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceMemberFuncOverridingMethod.js b/tests/baselines/reference/inheritanceMemberFuncOverridingMethod.js index 8236df5357f..fe433891573 100644 --- a/tests/baselines/reference/inheritanceMemberFuncOverridingMethod.js +++ b/tests/baselines/reference/inheritanceMemberFuncOverridingMethod.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceMemberFuncOverridingProperty.js b/tests/baselines/reference/inheritanceMemberFuncOverridingProperty.js index f6d1413cb36..fd74b8cb01d 100644 --- a/tests/baselines/reference/inheritanceMemberFuncOverridingProperty.js +++ b/tests/baselines/reference/inheritanceMemberFuncOverridingProperty.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceMemberPropertyOverridingAccessor.js b/tests/baselines/reference/inheritanceMemberPropertyOverridingAccessor.js index 99c69af4853..598492448cd 100644 --- a/tests/baselines/reference/inheritanceMemberPropertyOverridingAccessor.js +++ b/tests/baselines/reference/inheritanceMemberPropertyOverridingAccessor.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceMemberPropertyOverridingMethod.js b/tests/baselines/reference/inheritanceMemberPropertyOverridingMethod.js index 3b29c457ef3..01e939821b4 100644 --- a/tests/baselines/reference/inheritanceMemberPropertyOverridingMethod.js +++ b/tests/baselines/reference/inheritanceMemberPropertyOverridingMethod.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceMemberPropertyOverridingProperty.js b/tests/baselines/reference/inheritanceMemberPropertyOverridingProperty.js index b9bb7dc695f..a115c62512e 100644 --- a/tests/baselines/reference/inheritanceMemberPropertyOverridingProperty.js +++ b/tests/baselines/reference/inheritanceMemberPropertyOverridingProperty.js @@ -12,7 +12,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceOfGenericConstructorMethod1.js b/tests/baselines/reference/inheritanceOfGenericConstructorMethod1.js index 2b346e8a0fa..436ee095bcc 100644 --- a/tests/baselines/reference/inheritanceOfGenericConstructorMethod1.js +++ b/tests/baselines/reference/inheritanceOfGenericConstructorMethod1.js @@ -12,7 +12,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceOfGenericConstructorMethod2.js b/tests/baselines/reference/inheritanceOfGenericConstructorMethod2.js index 8635b909d65..49c3c64566e 100644 --- a/tests/baselines/reference/inheritanceOfGenericConstructorMethod2.js +++ b/tests/baselines/reference/inheritanceOfGenericConstructorMethod2.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceStaticAccessorOverridingAccessor.js b/tests/baselines/reference/inheritanceStaticAccessorOverridingAccessor.js index 909680e76e1..2993921e66f 100644 --- a/tests/baselines/reference/inheritanceStaticAccessorOverridingAccessor.js +++ b/tests/baselines/reference/inheritanceStaticAccessorOverridingAccessor.js @@ -22,7 +22,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceStaticAccessorOverridingMethod.js b/tests/baselines/reference/inheritanceStaticAccessorOverridingMethod.js index 82813d3724e..2d17a3675be 100644 --- a/tests/baselines/reference/inheritanceStaticAccessorOverridingMethod.js +++ b/tests/baselines/reference/inheritanceStaticAccessorOverridingMethod.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceStaticAccessorOverridingProperty.js b/tests/baselines/reference/inheritanceStaticAccessorOverridingProperty.js index 6ce9dd493b2..442d7efa521 100644 --- a/tests/baselines/reference/inheritanceStaticAccessorOverridingProperty.js +++ b/tests/baselines/reference/inheritanceStaticAccessorOverridingProperty.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceStaticFuncOverridingAccessor.js b/tests/baselines/reference/inheritanceStaticFuncOverridingAccessor.js index 95c48fac138..0c9329a30a3 100644 --- a/tests/baselines/reference/inheritanceStaticFuncOverridingAccessor.js +++ b/tests/baselines/reference/inheritanceStaticFuncOverridingAccessor.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceStaticFuncOverridingAccessorOfFuncType.js b/tests/baselines/reference/inheritanceStaticFuncOverridingAccessorOfFuncType.js index 07523c67356..0df4a32e3cc 100644 --- a/tests/baselines/reference/inheritanceStaticFuncOverridingAccessorOfFuncType.js +++ b/tests/baselines/reference/inheritanceStaticFuncOverridingAccessorOfFuncType.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceStaticFuncOverridingMethod.js b/tests/baselines/reference/inheritanceStaticFuncOverridingMethod.js index cb83e666784..9a2c3af1501 100644 --- a/tests/baselines/reference/inheritanceStaticFuncOverridingMethod.js +++ b/tests/baselines/reference/inheritanceStaticFuncOverridingMethod.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceStaticFuncOverridingProperty.js b/tests/baselines/reference/inheritanceStaticFuncOverridingProperty.js index bf32cc8ecb7..85b011173a2 100644 --- a/tests/baselines/reference/inheritanceStaticFuncOverridingProperty.js +++ b/tests/baselines/reference/inheritanceStaticFuncOverridingProperty.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceStaticFuncOverridingPropertyOfFuncType.js b/tests/baselines/reference/inheritanceStaticFuncOverridingPropertyOfFuncType.js index aed7d3109cd..01fcf1fa936 100644 --- a/tests/baselines/reference/inheritanceStaticFuncOverridingPropertyOfFuncType.js +++ b/tests/baselines/reference/inheritanceStaticFuncOverridingPropertyOfFuncType.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceStaticFunctionOverridingInstanceProperty.js b/tests/baselines/reference/inheritanceStaticFunctionOverridingInstanceProperty.js index 7af6c7abc69..9beb3ae700c 100644 --- a/tests/baselines/reference/inheritanceStaticFunctionOverridingInstanceProperty.js +++ b/tests/baselines/reference/inheritanceStaticFunctionOverridingInstanceProperty.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceStaticMembersCompatible.js b/tests/baselines/reference/inheritanceStaticMembersCompatible.js index 18a5fba9fbc..da02be29198 100644 --- a/tests/baselines/reference/inheritanceStaticMembersCompatible.js +++ b/tests/baselines/reference/inheritanceStaticMembersCompatible.js @@ -12,7 +12,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceStaticMembersIncompatible.js b/tests/baselines/reference/inheritanceStaticMembersIncompatible.js index 3b1d0da9111..51efe0f4b08 100644 --- a/tests/baselines/reference/inheritanceStaticMembersIncompatible.js +++ b/tests/baselines/reference/inheritanceStaticMembersIncompatible.js @@ -12,7 +12,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceStaticPropertyOverridingAccessor.js b/tests/baselines/reference/inheritanceStaticPropertyOverridingAccessor.js index bb39efe42b4..8f67286e644 100644 --- a/tests/baselines/reference/inheritanceStaticPropertyOverridingAccessor.js +++ b/tests/baselines/reference/inheritanceStaticPropertyOverridingAccessor.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceStaticPropertyOverridingMethod.js b/tests/baselines/reference/inheritanceStaticPropertyOverridingMethod.js index 7a7368dcaeb..ce6e4e5292b 100644 --- a/tests/baselines/reference/inheritanceStaticPropertyOverridingMethod.js +++ b/tests/baselines/reference/inheritanceStaticPropertyOverridingMethod.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritanceStaticPropertyOverridingProperty.js b/tests/baselines/reference/inheritanceStaticPropertyOverridingProperty.js index 347e1c3ddb1..64136e1d18b 100644 --- a/tests/baselines/reference/inheritanceStaticPropertyOverridingProperty.js +++ b/tests/baselines/reference/inheritanceStaticPropertyOverridingProperty.js @@ -12,7 +12,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritedConstructorWithRestParams.js b/tests/baselines/reference/inheritedConstructorWithRestParams.js index 85d1f41d926..d691457514b 100644 --- a/tests/baselines/reference/inheritedConstructorWithRestParams.js +++ b/tests/baselines/reference/inheritedConstructorWithRestParams.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritedConstructorWithRestParams2.js b/tests/baselines/reference/inheritedConstructorWithRestParams2.js index 92eacb7d32b..57aca4de7cc 100644 --- a/tests/baselines/reference/inheritedConstructorWithRestParams2.js +++ b/tests/baselines/reference/inheritedConstructorWithRestParams2.js @@ -39,7 +39,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inheritedModuleMembersForClodule.js b/tests/baselines/reference/inheritedModuleMembersForClodule.js index 7e352b29e7b..95bece91d1f 100644 --- a/tests/baselines/reference/inheritedModuleMembersForClodule.js +++ b/tests/baselines/reference/inheritedModuleMembersForClodule.js @@ -26,7 +26,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/initializerWithThisPropertyAccess.js b/tests/baselines/reference/initializerWithThisPropertyAccess.js index dee3469b39f..6e86158e1c4 100644 --- a/tests/baselines/reference/initializerWithThisPropertyAccess.js +++ b/tests/baselines/reference/initializerWithThisPropertyAccess.js @@ -39,7 +39,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/inlineJsxFactoryDeclarations.js b/tests/baselines/reference/inlineJsxFactoryDeclarations.js index e799b950b6a..9ed3d43d115 100644 --- a/tests/baselines/reference/inlineJsxFactoryDeclarations.js +++ b/tests/baselines/reference/inlineJsxFactoryDeclarations.js @@ -73,7 +73,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; /** @jsx dom */ diff --git a/tests/baselines/reference/instanceOfAssignability.js b/tests/baselines/reference/instanceOfAssignability.js index 9a93ea71e66..be3bdd78a7f 100644 --- a/tests/baselines/reference/instanceOfAssignability.js +++ b/tests/baselines/reference/instanceOfAssignability.js @@ -94,7 +94,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/instancePropertiesInheritedIntoClassType.js b/tests/baselines/reference/instancePropertiesInheritedIntoClassType.js index a63976a830e..93098172f99 100644 --- a/tests/baselines/reference/instancePropertiesInheritedIntoClassType.js +++ b/tests/baselines/reference/instancePropertiesInheritedIntoClassType.js @@ -47,7 +47,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/instanceSubtypeCheck2.js b/tests/baselines/reference/instanceSubtypeCheck2.js index 2924ae3be05..bc3c32bfac0 100644 --- a/tests/baselines/reference/instanceSubtypeCheck2.js +++ b/tests/baselines/reference/instanceSubtypeCheck2.js @@ -12,7 +12,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/instanceofWithStructurallyIdenticalTypes.js b/tests/baselines/reference/instanceofWithStructurallyIdenticalTypes.js index 125e5d8a310..e332ce97253 100644 --- a/tests/baselines/reference/instanceofWithStructurallyIdenticalTypes.js +++ b/tests/baselines/reference/instanceofWithStructurallyIdenticalTypes.js @@ -76,7 +76,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/instantiatedReturnTypeContravariance.js b/tests/baselines/reference/instantiatedReturnTypeContravariance.js index c6cbd93e8bc..d53d8af6de9 100644 --- a/tests/baselines/reference/instantiatedReturnTypeContravariance.js +++ b/tests/baselines/reference/instantiatedReturnTypeContravariance.js @@ -35,7 +35,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/interfaceClassMerging.js b/tests/baselines/reference/interfaceClassMerging.js index 67e99f40a37..7e2720ad1de 100644 --- a/tests/baselines/reference/interfaceClassMerging.js +++ b/tests/baselines/reference/interfaceClassMerging.js @@ -45,7 +45,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/interfaceClassMerging2.js b/tests/baselines/reference/interfaceClassMerging2.js index 6a636cfebb8..cf75cbac90d 100644 --- a/tests/baselines/reference/interfaceClassMerging2.js +++ b/tests/baselines/reference/interfaceClassMerging2.js @@ -41,7 +41,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/interfaceExtendsClass1.js b/tests/baselines/reference/interfaceExtendsClass1.js index e63dce8f199..be17558f77e 100644 --- a/tests/baselines/reference/interfaceExtendsClass1.js +++ b/tests/baselines/reference/interfaceExtendsClass1.js @@ -23,7 +23,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/interfaceExtendsClassWithPrivate1.js b/tests/baselines/reference/interfaceExtendsClassWithPrivate1.js index 6da140d08c3..ed24a458204 100644 --- a/tests/baselines/reference/interfaceExtendsClassWithPrivate1.js +++ b/tests/baselines/reference/interfaceExtendsClassWithPrivate1.js @@ -32,7 +32,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/interfaceExtendsClassWithPrivate2.js b/tests/baselines/reference/interfaceExtendsClassWithPrivate2.js index c135119dd04..fb4d2651d4a 100644 --- a/tests/baselines/reference/interfaceExtendsClassWithPrivate2.js +++ b/tests/baselines/reference/interfaceExtendsClassWithPrivate2.js @@ -28,7 +28,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/interfaceExtendsObjectIntersection.js b/tests/baselines/reference/interfaceExtendsObjectIntersection.js index 6138af53977..9af8f619504 100644 --- a/tests/baselines/reference/interfaceExtendsObjectIntersection.js +++ b/tests/baselines/reference/interfaceExtendsObjectIntersection.js @@ -59,7 +59,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/interfaceExtendsObjectIntersectionErrors.js b/tests/baselines/reference/interfaceExtendsObjectIntersectionErrors.js index ece951d7d97..daa8d4c552d 100644 --- a/tests/baselines/reference/interfaceExtendsObjectIntersectionErrors.js +++ b/tests/baselines/reference/interfaceExtendsObjectIntersectionErrors.js @@ -53,7 +53,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/interfaceImplementation8.js b/tests/baselines/reference/interfaceImplementation8.js index f4fba428a1e..a432b82fecb 100644 --- a/tests/baselines/reference/interfaceImplementation8.js +++ b/tests/baselines/reference/interfaceImplementation8.js @@ -45,7 +45,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/invalidModuleWithStatementsOfEveryKind.js b/tests/baselines/reference/invalidModuleWithStatementsOfEveryKind.js index 29eb714d366..8f0c5ad86f9 100644 --- a/tests/baselines/reference/invalidModuleWithStatementsOfEveryKind.js +++ b/tests/baselines/reference/invalidModuleWithStatementsOfEveryKind.js @@ -84,7 +84,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/invalidMultipleVariableDeclarations.js b/tests/baselines/reference/invalidMultipleVariableDeclarations.js index e9cbbf2a2d2..175c4f7d4e8 100644 --- a/tests/baselines/reference/invalidMultipleVariableDeclarations.js +++ b/tests/baselines/reference/invalidMultipleVariableDeclarations.js @@ -58,7 +58,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/invalidReturnStatements.js b/tests/baselines/reference/invalidReturnStatements.js index 99e75dff032..e7a1223a4c7 100644 --- a/tests/baselines/reference/invalidReturnStatements.js +++ b/tests/baselines/reference/invalidReturnStatements.js @@ -25,7 +25,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/isolatedModulesImportExportElision.js b/tests/baselines/reference/isolatedModulesImportExportElision.js index 04f74adbe4f..028593b6ea6 100644 --- a/tests/baselines/reference/isolatedModulesImportExportElision.js +++ b/tests/baselines/reference/isolatedModulesImportExportElision.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/jsDeclarationsClassExtendsVisibility.js b/tests/baselines/reference/jsDeclarationsClassExtendsVisibility.js index 9eb48e8d603..653fed447c4 100644 --- a/tests/baselines/reference/jsDeclarationsClassExtendsVisibility.js +++ b/tests/baselines/reference/jsDeclarationsClassExtendsVisibility.js @@ -25,7 +25,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/jsDeclarationsClassStaticMethodAugmentation.js b/tests/baselines/reference/jsDeclarationsClassStaticMethodAugmentation.js new file mode 100644 index 00000000000..2640672f164 --- /dev/null +++ b/tests/baselines/reference/jsDeclarationsClassStaticMethodAugmentation.js @@ -0,0 +1,30 @@ +//// [source.js] +export class Clazz { + static method() { } +} + +Clazz.method.prop = 5; + +//// [source.js] +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +exports.Clazz = void 0; +var Clazz = /** @class */ (function () { + function Clazz() { + } + Clazz.method = function () { }; + return Clazz; +}()); +exports.Clazz = Clazz; +Clazz.method.prop = 5; + + +//// [source.d.ts] +export class Clazz { +} +export namespace Clazz { + function method(): void; + namespace method { + const prop: number; + } +} diff --git a/tests/baselines/reference/jsDeclarationsClassStaticMethodAugmentation.symbols b/tests/baselines/reference/jsDeclarationsClassStaticMethodAugmentation.symbols new file mode 100644 index 00000000000..2e9295a8a99 --- /dev/null +++ b/tests/baselines/reference/jsDeclarationsClassStaticMethodAugmentation.symbols @@ -0,0 +1,15 @@ +=== tests/cases/conformance/jsdoc/declarations/source.js === +export class Clazz { +>Clazz : Symbol(Clazz, Decl(source.js, 0, 0), Decl(source.js, 2, 1)) + + static method() { } +>method : Symbol(Clazz.method, Decl(source.js, 0, 20), Decl(source.js, 4, 6)) +} + +Clazz.method.prop = 5; +>Clazz.method.prop : Symbol(Clazz.method.prop, Decl(source.js, 2, 1)) +>Clazz.method : Symbol(Clazz.method, Decl(source.js, 0, 20), Decl(source.js, 4, 6)) +>Clazz : Symbol(Clazz, Decl(source.js, 0, 0), Decl(source.js, 2, 1)) +>method : Symbol(Clazz.method, Decl(source.js, 0, 20), Decl(source.js, 4, 6)) +>prop : Symbol(Clazz.method.prop, Decl(source.js, 2, 1)) + diff --git a/tests/baselines/reference/jsDeclarationsClassStaticMethodAugmentation.types b/tests/baselines/reference/jsDeclarationsClassStaticMethodAugmentation.types new file mode 100644 index 00000000000..ddb6dc85da6 --- /dev/null +++ b/tests/baselines/reference/jsDeclarationsClassStaticMethodAugmentation.types @@ -0,0 +1,17 @@ +=== tests/cases/conformance/jsdoc/declarations/source.js === +export class Clazz { +>Clazz : Clazz + + static method() { } +>method : typeof Clazz.method +} + +Clazz.method.prop = 5; +>Clazz.method.prop = 5 : 5 +>Clazz.method.prop : number +>Clazz.method : typeof Clazz.method +>Clazz : typeof Clazz +>method : typeof Clazz.method +>prop : number +>5 : 5 + diff --git a/tests/baselines/reference/jsDeclarationsClasses.js b/tests/baselines/reference/jsDeclarationsClasses.js index d639c862cb9..e9ffd6c24f0 100644 --- a/tests/baselines/reference/jsDeclarationsClasses.js +++ b/tests/baselines/reference/jsDeclarationsClasses.js @@ -200,7 +200,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/jsDeclarationsClassesErr.js b/tests/baselines/reference/jsDeclarationsClassesErr.js index 4345c92adbd..a3746e70346 100644 --- a/tests/baselines/reference/jsDeclarationsClassesErr.js +++ b/tests/baselines/reference/jsDeclarationsClassesErr.js @@ -78,7 +78,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/jsDeclarationsConstsAsNamespacesWithReferences.js b/tests/baselines/reference/jsDeclarationsConstsAsNamespacesWithReferences.js new file mode 100644 index 00000000000..3ac594f0a88 --- /dev/null +++ b/tests/baselines/reference/jsDeclarationsConstsAsNamespacesWithReferences.js @@ -0,0 +1,26 @@ +//// [index.js] +export const colors = { + royalBlue: "#6400e4", +}; + +export const brandColors = { + purple: colors.royalBlue, +}; + +//// [index.js] +export const colors = { + royalBlue: "#6400e4", +}; +export const brandColors = { + purple: colors.royalBlue, +}; + + +//// [index.d.ts] +export namespace colors { + const royalBlue: string; +} +export namespace brandColors { + import purple = colors.royalBlue; + export { purple }; +} diff --git a/tests/baselines/reference/jsDeclarationsConstsAsNamespacesWithReferences.symbols b/tests/baselines/reference/jsDeclarationsConstsAsNamespacesWithReferences.symbols new file mode 100644 index 00000000000..d3b482be557 --- /dev/null +++ b/tests/baselines/reference/jsDeclarationsConstsAsNamespacesWithReferences.symbols @@ -0,0 +1,19 @@ +=== tests/cases/conformance/jsdoc/declarations/index.js === +export const colors = { +>colors : Symbol(colors, Decl(index.js, 0, 12)) + + royalBlue: "#6400e4", +>royalBlue : Symbol(royalBlue, Decl(index.js, 0, 23)) + +}; + +export const brandColors = { +>brandColors : Symbol(brandColors, Decl(index.js, 4, 12)) + + purple: colors.royalBlue, +>purple : Symbol(purple, Decl(index.js, 4, 28)) +>colors.royalBlue : Symbol(royalBlue, Decl(index.js, 0, 23)) +>colors : Symbol(colors, Decl(index.js, 0, 12)) +>royalBlue : Symbol(royalBlue, Decl(index.js, 0, 23)) + +}; diff --git a/tests/baselines/reference/jsDeclarationsConstsAsNamespacesWithReferences.types b/tests/baselines/reference/jsDeclarationsConstsAsNamespacesWithReferences.types new file mode 100644 index 00000000000..d9749bcc706 --- /dev/null +++ b/tests/baselines/reference/jsDeclarationsConstsAsNamespacesWithReferences.types @@ -0,0 +1,22 @@ +=== tests/cases/conformance/jsdoc/declarations/index.js === +export const colors = { +>colors : { royalBlue: string; } +>{ royalBlue: "#6400e4",} : { royalBlue: string; } + + royalBlue: "#6400e4", +>royalBlue : string +>"#6400e4" : "#6400e4" + +}; + +export const brandColors = { +>brandColors : { purple: string; } +>{ purple: colors.royalBlue,} : { purple: string; } + + purple: colors.royalBlue, +>purple : string +>colors.royalBlue : string +>colors : { royalBlue: string; } +>royalBlue : string + +}; diff --git a/tests/baselines/reference/jsDeclarationsDefault.js b/tests/baselines/reference/jsDeclarationsDefault.js index 2c7df6d14b9..81c50d1ccdb 100644 --- a/tests/baselines/reference/jsDeclarationsDefault.js +++ b/tests/baselines/reference/jsDeclarationsDefault.js @@ -73,7 +73,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/jsDeclarationsExportAssignedConstructorFunctionWithSub.errors.txt b/tests/baselines/reference/jsDeclarationsExportAssignedConstructorFunctionWithSub.errors.txt index b0aca99dcab..44efa54d013 100644 --- a/tests/baselines/reference/jsDeclarationsExportAssignedConstructorFunctionWithSub.errors.txt +++ b/tests/baselines/reference/jsDeclarationsExportAssignedConstructorFunctionWithSub.errors.txt @@ -1,9 +1,7 @@ tests/cases/conformance/jsdoc/declarations/jsDeclarationsExportAssignedConstructorFunctionWithSub.js(4,1): error TS9005: Declaration emit for this file requires using private name 'exports'. An explicit type annotation may unblock declaration emit. -tests/cases/conformance/jsdoc/declarations/jsDeclarationsExportAssignedConstructorFunctionWithSub.js(5,10): error TS2339: Property 't' does not exist on type '{ "\"tests/cases/conformance/jsdoc/declarations/jsDeclarationsExportAssignedConstructorFunctionWithSub\"": typeof exports; }'. -tests/cases/conformance/jsdoc/declarations/jsDeclarationsExportAssignedConstructorFunctionWithSub.js(8,10): error TS2339: Property 'instance' does not exist on type 'typeof exports'. -==== tests/cases/conformance/jsdoc/declarations/jsDeclarationsExportAssignedConstructorFunctionWithSub.js (3 errors) ==== +==== tests/cases/conformance/jsdoc/declarations/jsDeclarationsExportAssignedConstructorFunctionWithSub.js (1 errors) ==== /** * @param {number} p */ @@ -11,13 +9,9 @@ tests/cases/conformance/jsdoc/declarations/jsDeclarationsExportAssignedConstruct ~~~~~~ !!! error TS9005: Declaration emit for this file requires using private name 'exports'. An explicit type annotation may unblock declaration emit. this.t = 12 + p; - ~ -!!! error TS2339: Property 't' does not exist on type '{ "\"tests/cases/conformance/jsdoc/declarations/jsDeclarationsExportAssignedConstructorFunctionWithSub\"": typeof exports; }'. } module.exports.Sub = function() { this.instance = new module.exports(10); - ~~~~~~~~ -!!! error TS2339: Property 'instance' does not exist on type 'typeof exports'. } module.exports.Sub.prototype = { } \ No newline at end of file diff --git a/tests/baselines/reference/jsDeclarationsExportAssignedConstructorFunctionWithSub.symbols b/tests/baselines/reference/jsDeclarationsExportAssignedConstructorFunctionWithSub.symbols index 9f570d90194..44f53888094 100644 --- a/tests/baselines/reference/jsDeclarationsExportAssignedConstructorFunctionWithSub.symbols +++ b/tests/baselines/reference/jsDeclarationsExportAssignedConstructorFunctionWithSub.symbols @@ -9,7 +9,8 @@ module.exports = function (p) { >p : Symbol(p, Decl(jsDeclarationsExportAssignedConstructorFunctionWithSub.js, 3, 27)) this.t = 12 + p; ->this : Symbol(module, Decl(jsDeclarationsExportAssignedConstructorFunctionWithSub.js, 0, 0), Decl(jsDeclarationsExportAssignedConstructorFunctionWithSub.js, 7, 23)) +>this.t : Symbol(exports.t, Decl(jsDeclarationsExportAssignedConstructorFunctionWithSub.js, 3, 31)) +>this : Symbol(exports, Decl(jsDeclarationsExportAssignedConstructorFunctionWithSub.js, 3, 16)) >t : Symbol(exports.t, Decl(jsDeclarationsExportAssignedConstructorFunctionWithSub.js, 3, 31)) >p : Symbol(p, Decl(jsDeclarationsExportAssignedConstructorFunctionWithSub.js, 3, 27)) } @@ -21,7 +22,8 @@ module.exports.Sub = function() { >Sub : Symbol(Sub, Decl(jsDeclarationsExportAssignedConstructorFunctionWithSub.js, 5, 1), Decl(jsDeclarationsExportAssignedConstructorFunctionWithSub.js, 9, 15)) this.instance = new module.exports(10); ->this : Symbol(exports, Decl(jsDeclarationsExportAssignedConstructorFunctionWithSub.js, 3, 16)) +>this.instance : Symbol(Sub.instance, Decl(jsDeclarationsExportAssignedConstructorFunctionWithSub.js, 6, 33)) +>this : Symbol(Sub, Decl(jsDeclarationsExportAssignedConstructorFunctionWithSub.js, 6, 20)) >instance : Symbol(Sub.instance, Decl(jsDeclarationsExportAssignedConstructorFunctionWithSub.js, 6, 33)) >module.exports : Symbol("tests/cases/conformance/jsdoc/declarations/jsDeclarationsExportAssignedConstructorFunctionWithSub", Decl(jsDeclarationsExportAssignedConstructorFunctionWithSub.js, 0, 0)) >module : Symbol(module, Decl(jsDeclarationsExportAssignedConstructorFunctionWithSub.js, 0, 0), Decl(jsDeclarationsExportAssignedConstructorFunctionWithSub.js, 7, 23)) diff --git a/tests/baselines/reference/jsDeclarationsExportAssignedConstructorFunctionWithSub.types b/tests/baselines/reference/jsDeclarationsExportAssignedConstructorFunctionWithSub.types index d40012a7ccb..7a738df3bb0 100644 --- a/tests/baselines/reference/jsDeclarationsExportAssignedConstructorFunctionWithSub.types +++ b/tests/baselines/reference/jsDeclarationsExportAssignedConstructorFunctionWithSub.types @@ -13,7 +13,7 @@ module.exports = function (p) { this.t = 12 + p; >this.t = 12 + p : number >this.t : any ->this : { "\"tests/cases/conformance/jsdoc/declarations/jsDeclarationsExportAssignedConstructorFunctionWithSub\"": typeof exports; } +>this : this >t : any >12 + p : number >12 : 12 @@ -31,7 +31,7 @@ module.exports.Sub = function() { this.instance = new module.exports(10); >this.instance = new module.exports(10) : exports >this.instance : any ->this : typeof exports +>this : this >instance : any >new module.exports(10) : exports >module.exports : typeof exports diff --git a/tests/baselines/reference/jsDeclarationsExportForms.js b/tests/baselines/reference/jsDeclarationsExportForms.js index 8134e557a11..d39e44d875c 100644 --- a/tests/baselines/reference/jsDeclarationsExportForms.js +++ b/tests/baselines/reference/jsDeclarationsExportForms.js @@ -84,7 +84,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; Object.defineProperty(exports, "__esModule", { value: true }); __exportStar(require("./cls"), exports); @@ -98,7 +98,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; Object.defineProperty(exports, "__esModule", { value: true }); __exportStar(require("./func"), exports); diff --git a/tests/baselines/reference/jsDeclarationsExportFormsErr.js b/tests/baselines/reference/jsDeclarationsExportFormsErr.js index 6f777832804..14c94dd65dc 100644 --- a/tests/baselines/reference/jsDeclarationsExportFormsErr.js +++ b/tests/baselines/reference/jsDeclarationsExportFormsErr.js @@ -50,7 +50,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; Object.defineProperty(exports, "__esModule", { value: true }); __exportStar(require("./cls"), exports); diff --git a/tests/baselines/reference/jsDeclarationsFunctionClassesCjsExportAssignment.symbols b/tests/baselines/reference/jsDeclarationsFunctionClassesCjsExportAssignment.symbols index a8e34ede3cf..d667f9d0cc2 100644 --- a/tests/baselines/reference/jsDeclarationsFunctionClassesCjsExportAssignment.symbols +++ b/tests/baselines/reference/jsDeclarationsFunctionClassesCjsExportAssignment.symbols @@ -7,6 +7,8 @@ function Timer(timeout) { >timeout : Symbol(timeout, Decl(timer.js, 3, 15)) this.timeout = timeout; +>this.timeout : Symbol(Timer.timeout, Decl(timer.js, 3, 25)) +>this : Symbol(Timer, Decl(timer.js, 0, 0)) >timeout : Symbol(Timer.timeout, Decl(timer.js, 3, 25)) >timeout : Symbol(timeout, Decl(timer.js, 3, 15)) } @@ -28,6 +30,8 @@ function Hook(handle) { >handle : Symbol(handle, Decl(hook.js, 6, 14)) this.handle = handle; +>this.handle : Symbol(Hook.handle, Decl(hook.js, 6, 23)) +>this : Symbol(Hook, Decl(hook.js, 0, 0)) >handle : Symbol(Hook.handle, Decl(hook.js, 6, 23)) >handle : Symbol(handle, Decl(hook.js, 6, 14)) } diff --git a/tests/baselines/reference/jsDeclarationsFunctionClassesCjsExportAssignment.types b/tests/baselines/reference/jsDeclarationsFunctionClassesCjsExportAssignment.types index 8b533ee2919..b374a461752 100644 --- a/tests/baselines/reference/jsDeclarationsFunctionClassesCjsExportAssignment.types +++ b/tests/baselines/reference/jsDeclarationsFunctionClassesCjsExportAssignment.types @@ -9,7 +9,7 @@ function Timer(timeout) { this.timeout = timeout; >this.timeout = timeout : number >this.timeout : any ->this : any +>this : this >timeout : any >timeout : number } @@ -34,7 +34,7 @@ function Hook(handle) { this.handle = handle; >this.handle = handle : (arg: import("tests/cases/conformance/jsdoc/declarations/context")) => void >this.handle : any ->this : any +>this : this >handle : any >handle : (arg: import("tests/cases/conformance/jsdoc/declarations/context")) => void } diff --git a/tests/baselines/reference/jsDeclarationsFunctionLikeClasses.symbols b/tests/baselines/reference/jsDeclarationsFunctionLikeClasses.symbols index 61e0872f479..178ee0761cc 100644 --- a/tests/baselines/reference/jsDeclarationsFunctionLikeClasses.symbols +++ b/tests/baselines/reference/jsDeclarationsFunctionLikeClasses.symbols @@ -9,6 +9,7 @@ export function Point(x, y) { >y : Symbol(y, Decl(source.js, 4, 24)) if (!(this instanceof Point)) { +>this : Symbol(Point, Decl(source.js, 0, 0)) >Point : Symbol(Point, Decl(source.js, 0, 0)) return new Point(x, y); @@ -17,10 +18,14 @@ export function Point(x, y) { >y : Symbol(y, Decl(source.js, 4, 24)) } this.x = x; +>this.x : Symbol(Point.x, Decl(source.js, 7, 5)) +>this : Symbol(Point, Decl(source.js, 0, 0)) >x : Symbol(Point.x, Decl(source.js, 7, 5)) >x : Symbol(x, Decl(source.js, 4, 22)) this.y = y; +>this.y : Symbol(Point.y, Decl(source.js, 8, 15)) +>this : Symbol(Point, Decl(source.js, 0, 0)) >y : Symbol(Point.y, Decl(source.js, 8, 15)) >y : Symbol(y, Decl(source.js, 4, 24)) } diff --git a/tests/baselines/reference/jsDeclarationsFunctionLikeClasses.types b/tests/baselines/reference/jsDeclarationsFunctionLikeClasses.types index 02ad20be62c..663c0ddc2db 100644 --- a/tests/baselines/reference/jsDeclarationsFunctionLikeClasses.types +++ b/tests/baselines/reference/jsDeclarationsFunctionLikeClasses.types @@ -12,7 +12,7 @@ export function Point(x, y) { >!(this instanceof Point) : boolean >(this instanceof Point) : boolean >this instanceof Point : boolean ->this : any +>this : this >Point : typeof Point return new Point(x, y); @@ -24,14 +24,14 @@ export function Point(x, y) { this.x = x; >this.x = x : number >this.x : any ->this : any +>this : this >x : any >x : number this.y = y; >this.y = y : number >this.y : any ->this : any +>this : this >y : any >y : number } diff --git a/tests/baselines/reference/jsDeclarationsFunctionLikeClasses2.symbols b/tests/baselines/reference/jsDeclarationsFunctionLikeClasses2.symbols index 8e9894b37f9..8ab6611dfa4 100644 --- a/tests/baselines/reference/jsDeclarationsFunctionLikeClasses2.symbols +++ b/tests/baselines/reference/jsDeclarationsFunctionLikeClasses2.symbols @@ -10,6 +10,8 @@ export function Vec(len) { * @type {number[]} */ this.storage = new Array(len); +>this.storage : Symbol(Vec.storage, Decl(source.js, 3, 26)) +>this : Symbol(Vec, Decl(source.js, 0, 0), Decl(source.js, 8, 1)) >storage : Symbol(Vec.storage, Decl(source.js, 3, 26)) >Array : Symbol(Array, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --)) >len : Symbol(len, Decl(source.js, 3, 20)) @@ -111,6 +113,7 @@ export function Point2D(x, y) { >y : Symbol(y, Decl(source.js, 37, 26)) if (!(this instanceof Point2D)) { +>this : Symbol(Point2D, Decl(source.js, 31, 1), Decl(source.js, 44, 1)) >Point2D : Symbol(Point2D, Decl(source.js, 31, 1), Decl(source.js, 44, 1)) return new Point2D(x, y); @@ -122,12 +125,17 @@ export function Point2D(x, y) { >Vec.call : Symbol(Function.call, Decl(lib.es5.d.ts, --, --)) >Vec : Symbol(Vec, Decl(source.js, 0, 0), Decl(source.js, 8, 1)) >call : Symbol(Function.call, Decl(lib.es5.d.ts, --, --)) +>this : Symbol(Point2D, Decl(source.js, 31, 1), Decl(source.js, 44, 1)) this.x = x; +>this.x : Symbol(Point2D.x, Decl(source.js, 41, 22), Decl(source.js, 47, 19), Decl(source.js, 50, 6)) +>this : Symbol(Point2D, Decl(source.js, 31, 1), Decl(source.js, 44, 1)) >x : Symbol(Point2D.x, Decl(source.js, 41, 22), Decl(source.js, 47, 19), Decl(source.js, 50, 6)) >x : Symbol(x, Decl(source.js, 37, 24)) this.y = y; +>this.y : Symbol(Point2D.y, Decl(source.js, 42, 15), Decl(source.js, 56, 6), Decl(source.js, 59, 6)) +>this : Symbol(Point2D, Decl(source.js, 31, 1), Decl(source.js, 44, 1)) >y : Symbol(Point2D.y, Decl(source.js, 42, 15), Decl(source.js, 56, 6), Decl(source.js, 59, 6)) >y : Symbol(y, Decl(source.js, 37, 26)) } diff --git a/tests/baselines/reference/jsDeclarationsFunctionLikeClasses2.types b/tests/baselines/reference/jsDeclarationsFunctionLikeClasses2.types index 3e94d055ee2..bca10bf7a88 100644 --- a/tests/baselines/reference/jsDeclarationsFunctionLikeClasses2.types +++ b/tests/baselines/reference/jsDeclarationsFunctionLikeClasses2.types @@ -11,9 +11,9 @@ export function Vec(len) { */ this.storage = new Array(len); >this.storage = new Array(len) : any[] ->this.storage : any ->this : any ->storage : any +>this.storage : number[] +>this : this +>storage : number[] >new Array(len) : any[] >Array : ArrayConstructor >len : number @@ -142,7 +142,7 @@ export function Point2D(x, y) { >!(this instanceof Point2D) : boolean >(this instanceof Point2D) : boolean >this instanceof Point2D : boolean ->this : any +>this : this >Point2D : typeof Point2D return new Point2D(x, y); @@ -156,21 +156,21 @@ export function Point2D(x, y) { >Vec.call : (this: Function, thisArg: any, ...argArray: any[]) => any >Vec : typeof Vec >call : (this: Function, thisArg: any, ...argArray: any[]) => any ->this : any +>this : this >2 : 2 this.x = x; >this.x = x : number ->this.x : any ->this : any ->x : any +>this.x : number +>this : this +>x : number >x : number this.y = y; >this.y = y : number ->this.y : any ->this : any ->y : any +>this.y : number +>this : this +>y : number >y : number } diff --git a/tests/baselines/reference/jsDeclarationsThisTypes.js b/tests/baselines/reference/jsDeclarationsThisTypes.js index 65858ab41dc..6abff7fdf4f 100644 --- a/tests/baselines/reference/jsDeclarationsThisTypes.js +++ b/tests/baselines/reference/jsDeclarationsThisTypes.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/jsFunctionWithPrototypeNoErrorTruncationNoCrash.symbols b/tests/baselines/reference/jsFunctionWithPrototypeNoErrorTruncationNoCrash.symbols index d2bb8c9079c..1c4c212e2ad 100644 --- a/tests/baselines/reference/jsFunctionWithPrototypeNoErrorTruncationNoCrash.symbols +++ b/tests/baselines/reference/jsFunctionWithPrototypeNoErrorTruncationNoCrash.symbols @@ -4,6 +4,8 @@ function Color(obj) { >obj : Symbol(obj, Decl(index.js, 0, 15)) this.example = true +>this.example : Symbol(Color.example, Decl(index.js, 0, 21)) +>this : Symbol(Color, Decl(index.js, 0, 0), Decl(index.js, 2, 2)) >example : Symbol(Color.example, Decl(index.js, 0, 21)) }; diff --git a/tests/baselines/reference/jsFunctionWithPrototypeNoErrorTruncationNoCrash.types b/tests/baselines/reference/jsFunctionWithPrototypeNoErrorTruncationNoCrash.types index 5d547a666e8..04f8a89c8b3 100644 --- a/tests/baselines/reference/jsFunctionWithPrototypeNoErrorTruncationNoCrash.types +++ b/tests/baselines/reference/jsFunctionWithPrototypeNoErrorTruncationNoCrash.types @@ -6,7 +6,7 @@ function Color(obj) { this.example = true >this.example = true : true >this.example : any ->this : any +>this : this >example : any >true : true diff --git a/tests/baselines/reference/jsNoImplicitAnyNoCascadingReferenceErrors.js b/tests/baselines/reference/jsNoImplicitAnyNoCascadingReferenceErrors.js index 52933132cb4..d245b3de659 100644 --- a/tests/baselines/reference/jsNoImplicitAnyNoCascadingReferenceErrors.js +++ b/tests/baselines/reference/jsNoImplicitAnyNoCascadingReferenceErrors.js @@ -21,7 +21,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/jsdocConstructorFunctionTypeReference.symbols b/tests/baselines/reference/jsdocConstructorFunctionTypeReference.symbols index f4e58505c2e..ef9292d4f86 100644 --- a/tests/baselines/reference/jsdocConstructorFunctionTypeReference.symbols +++ b/tests/baselines/reference/jsdocConstructorFunctionTypeReference.symbols @@ -4,6 +4,8 @@ var Validator = function VFunc() { >VFunc : Symbol(VFunc, Decl(jsdocConstructorFunctionTypeReference.js, 0, 15)) this.flags = "gim" +>this.flags : Symbol(VFunc.flags, Decl(jsdocConstructorFunctionTypeReference.js, 0, 34)) +>this : Symbol(VFunc, Decl(jsdocConstructorFunctionTypeReference.js, 0, 15)) >flags : Symbol(VFunc.flags, Decl(jsdocConstructorFunctionTypeReference.js, 0, 34)) }; diff --git a/tests/baselines/reference/jsdocConstructorFunctionTypeReference.types b/tests/baselines/reference/jsdocConstructorFunctionTypeReference.types index e7550faa72e..4cceb9c4ed3 100644 --- a/tests/baselines/reference/jsdocConstructorFunctionTypeReference.types +++ b/tests/baselines/reference/jsdocConstructorFunctionTypeReference.types @@ -7,7 +7,7 @@ var Validator = function VFunc() { this.flags = "gim" >this.flags = "gim" : "gim" >this.flags : any ->this : any +>this : this >flags : any >"gim" : "gim" diff --git a/tests/baselines/reference/jsdocFunctionType.errors.txt b/tests/baselines/reference/jsdocFunctionType.errors.txt index 30bd6d7f7f9..c6a105929bf 100644 --- a/tests/baselines/reference/jsdocFunctionType.errors.txt +++ b/tests/baselines/reference/jsdocFunctionType.errors.txt @@ -72,4 +72,16 @@ tests/cases/conformance/jsdoc/functions.js(65,14): error TS2345: Argument of typ !!! error TS2345: Argument of type 'typeof E' is not assignable to parameter of type 'new (arg1: number) => { length: number; }'. !!! error TS2345: Property 'length' is missing in type 'E' but required in type '{ length: number; }'. !!! related TS2728 tests/cases/conformance/jsdoc/functions.js:12:28: 'length' is declared here. + + // Repro from #39229 + + /** + * @type {(...args: [string, string] | [number, string, string]) => void} + */ + function foo(...args) { + args; + } + + foo('abc', 'def'); + foo(42, 'abc', 'def'); \ No newline at end of file diff --git a/tests/baselines/reference/jsdocFunctionType.symbols b/tests/baselines/reference/jsdocFunctionType.symbols index 70917e7657c..194fb63d58f 100644 --- a/tests/baselines/reference/jsdocFunctionType.symbols +++ b/tests/baselines/reference/jsdocFunctionType.symbols @@ -141,3 +141,22 @@ var y3 = id2(E); >id2 : Symbol(id2, Decl(functions.js, 8, 53)) >E : Symbol(E, Decl(functions.js, 59, 3)) +// Repro from #39229 + +/** + * @type {(...args: [string, string] | [number, string, string]) => void} + */ +function foo(...args) { +>foo : Symbol(foo, Decl(functions.js, 64, 16)) +>args : Symbol(args, Decl(functions.js, 71, 13)) + + args; +>args : Symbol(args, Decl(functions.js, 71, 13)) +} + +foo('abc', 'def'); +>foo : Symbol(foo, Decl(functions.js, 64, 16)) + +foo(42, 'abc', 'def'); +>foo : Symbol(foo, Decl(functions.js, 64, 16)) + diff --git a/tests/baselines/reference/jsdocFunctionType.types b/tests/baselines/reference/jsdocFunctionType.types index f43ce2e84e2..d58213ab1ca 100644 --- a/tests/baselines/reference/jsdocFunctionType.types +++ b/tests/baselines/reference/jsdocFunctionType.types @@ -165,3 +165,29 @@ var y3 = id2(E); >id2 : (c: new (arg1: number) => { length: number; }) => new (arg1: number) => { length: number; } >E : typeof E +// Repro from #39229 + +/** + * @type {(...args: [string, string] | [number, string, string]) => void} + */ +function foo(...args) { +>foo : (...args: [string, string] | [number, string, string]) => void +>args : [string, string] | [number, string, string] + + args; +>args : [string, string] | [number, string, string] +} + +foo('abc', 'def'); +>foo('abc', 'def') : void +>foo : (...args: [string, string] | [number, string, string]) => void +>'abc' : "abc" +>'def' : "def" + +foo(42, 'abc', 'def'); +>foo(42, 'abc', 'def') : void +>foo : (...args: [string, string] | [number, string, string]) => void +>42 : 42 +>'abc' : "abc" +>'def' : "def" + diff --git a/tests/baselines/reference/jsdocParamTagTypeLiteral.types b/tests/baselines/reference/jsdocParamTagTypeLiteral.types index 6a51e49ee6c..ef926eec222 100644 --- a/tests/baselines/reference/jsdocParamTagTypeLiteral.types +++ b/tests/baselines/reference/jsdocParamTagTypeLiteral.types @@ -23,18 +23,18 @@ normal(12); * @param {string} [opts1.w="hi"] doc5 */ function foo1(opts1) { ->foo1 : (opts1: { x: string; y?: string | undefined; z: string; w: string;}) => void ->opts1 : { x: string; y?: string | undefined; z?: string; w?: string; } +>foo1 : (opts1: { x: string; y?: string | undefined; z: string | undefined; w: string | undefined;}) => void +>opts1 : { x: string; y?: string | undefined; z?: string | undefined; w?: string | undefined; } opts1.x; >opts1.x : string ->opts1 : { x: string; y?: string | undefined; z?: string; w?: string; } +>opts1 : { x: string; y?: string | undefined; z?: string | undefined; w?: string | undefined; } >x : string } foo1({x: 'abc'}); >foo1({x: 'abc'}) : void ->foo1 : (opts1: { x: string; y?: string | undefined; z?: string; w?: string; }) => void +>foo1 : (opts1: { x: string; y?: string | undefined; z?: string | undefined; w?: string | undefined; }) => void >{x: 'abc'} : { x: string; } >x : string >'abc' : "abc" @@ -93,19 +93,19 @@ foo3({x: 'abc'}); */ function foo4(opts4) { >foo4 : (opts4: { x: string; y?: string | undefined; z: string; w: string;}) => void ->opts4 : { x: string; y?: string | undefined; z?: string; w?: string; }[] +>opts4 : { x: string; y?: string | undefined; z?: string | undefined; w?: string | undefined; }[] opts4[0].x; >opts4[0].x : string ->opts4[0] : { x: string; y?: string | undefined; z?: string; w?: string; } ->opts4 : { x: string; y?: string | undefined; z?: string; w?: string; }[] +>opts4[0] : { x: string; y?: string | undefined; z?: string | undefined; w?: string | undefined; } +>opts4 : { x: string; y?: string | undefined; z?: string | undefined; w?: string | undefined; }[] >0 : 0 >x : string } foo4([{ x: 'hi' }]); >foo4([{ x: 'hi' }]) : void ->foo4 : (opts4: { x: string; y?: string | undefined; z?: string; w?: string; }[]) => void +>foo4 : (opts4: { x: string; y?: string | undefined; z?: string | undefined; w?: string | undefined; }[]) => void >[{ x: 'hi' }] : { x: string; }[] >{ x: 'hi' } : { x: string; } >x : string diff --git a/tests/baselines/reference/jsdocPrototypePropertyAccessWithType.errors.txt b/tests/baselines/reference/jsdocPrototypePropertyAccessWithType.errors.txt new file mode 100644 index 00000000000..02d48d1bb77 --- /dev/null +++ b/tests/baselines/reference/jsdocPrototypePropertyAccessWithType.errors.txt @@ -0,0 +1,11 @@ +/a.js(1,16): error TS2322: Type 'boolean' is not assignable to type 'number'. + + +==== /a.js (1 errors) ==== + function C() { this.x = false; }; + ~~~~~~ +!!! error TS2322: Type 'boolean' is not assignable to type 'number'. + /** @type {number} */ + C.prototype.x; + new C().x; + \ No newline at end of file diff --git a/tests/baselines/reference/jsdocPrototypePropertyAccessWithType.symbols b/tests/baselines/reference/jsdocPrototypePropertyAccessWithType.symbols index 00e906ea4ad..009004b201b 100644 --- a/tests/baselines/reference/jsdocPrototypePropertyAccessWithType.symbols +++ b/tests/baselines/reference/jsdocPrototypePropertyAccessWithType.symbols @@ -1,6 +1,8 @@ === /a.js === function C() { this.x = false; }; >C : Symbol(C, Decl(a.js, 0, 0)) +>this.x : Symbol(C.x, Decl(a.js, 0, 14), Decl(a.js, 0, 33)) +>this : Symbol(C, Decl(a.js, 0, 0)) >x : Symbol(C.x, Decl(a.js, 0, 14), Decl(a.js, 0, 33)) /** @type {number} */ diff --git a/tests/baselines/reference/jsdocPrototypePropertyAccessWithType.types b/tests/baselines/reference/jsdocPrototypePropertyAccessWithType.types index 6756c07f231..e2c5d088baa 100644 --- a/tests/baselines/reference/jsdocPrototypePropertyAccessWithType.types +++ b/tests/baselines/reference/jsdocPrototypePropertyAccessWithType.types @@ -2,9 +2,9 @@ function C() { this.x = false; }; >C : typeof C >this.x = false : false ->this.x : any ->this : any ->x : any +>this.x : number +>this : this +>x : number >false : false /** @type {number} */ diff --git a/tests/baselines/reference/jsdocReadonlyDeclarations.symbols b/tests/baselines/reference/jsdocReadonlyDeclarations.symbols index 97c9d3d3ef3..2c100ca3303 100644 --- a/tests/baselines/reference/jsdocReadonlyDeclarations.symbols +++ b/tests/baselines/reference/jsdocReadonlyDeclarations.symbols @@ -37,6 +37,8 @@ function F() { /** @readonly */ this.z = 1 +>this.z : Symbol(F.z, Decl(jsdocReadonlyDeclarations.js, 15, 14)) +>this : Symbol(F, Decl(jsdocReadonlyDeclarations.js, 13, 9)) >z : Symbol(F.z, Decl(jsdocReadonlyDeclarations.js, 15, 14)) } diff --git a/tests/baselines/reference/jsdocReadonlyDeclarations.types b/tests/baselines/reference/jsdocReadonlyDeclarations.types index 10e0a99c05e..33e157ae5ad 100644 --- a/tests/baselines/reference/jsdocReadonlyDeclarations.types +++ b/tests/baselines/reference/jsdocReadonlyDeclarations.types @@ -43,7 +43,7 @@ function F() { this.z = 1 >this.z = 1 : 1 >this.z : any ->this : any +>this : this >z : any >1 : 1 } diff --git a/tests/baselines/reference/jsdocTemplateConstructorFunction.symbols b/tests/baselines/reference/jsdocTemplateConstructorFunction.symbols index f9b5d1c6b6e..6ab42970bf9 100644 --- a/tests/baselines/reference/jsdocTemplateConstructorFunction.symbols +++ b/tests/baselines/reference/jsdocTemplateConstructorFunction.symbols @@ -13,7 +13,13 @@ function Zet(t) { /** @type {T} */ this.u +>this.u : Symbol(Zet.u, Decl(templateTagOnConstructorFunctions.js, 8, 17), Decl(templateTagOnConstructorFunctions.js, 17, 37)) +>this : Symbol(Zet, Decl(templateTagOnConstructorFunctions.js, 0, 0)) +>u : Symbol(Zet.u, Decl(templateTagOnConstructorFunctions.js, 8, 17), Decl(templateTagOnConstructorFunctions.js, 17, 37)) + this.t = t +>this.t : Symbol(Zet.t, Decl(templateTagOnConstructorFunctions.js, 10, 10)) +>this : Symbol(Zet, Decl(templateTagOnConstructorFunctions.js, 0, 0)) >t : Symbol(Zet.t, Decl(templateTagOnConstructorFunctions.js, 10, 10)) >t : Symbol(t, Decl(templateTagOnConstructorFunctions.js, 8, 13)) } diff --git a/tests/baselines/reference/jsdocTemplateConstructorFunction.types b/tests/baselines/reference/jsdocTemplateConstructorFunction.types index 6caba31540c..018054de5bc 100644 --- a/tests/baselines/reference/jsdocTemplateConstructorFunction.types +++ b/tests/baselines/reference/jsdocTemplateConstructorFunction.types @@ -13,14 +13,14 @@ function Zet(t) { /** @type {T} */ this.u ->this.u : any ->this : any ->u : any +>this.u : T +>this : this +>u : T this.t = t >this.t = t : T >this.t : any ->this : any +>this : this >t : any >t : T } diff --git a/tests/baselines/reference/jsdocTemplateConstructorFunction2.symbols b/tests/baselines/reference/jsdocTemplateConstructorFunction2.symbols index 41211488656..beb90c1b762 100644 --- a/tests/baselines/reference/jsdocTemplateConstructorFunction2.symbols +++ b/tests/baselines/reference/jsdocTemplateConstructorFunction2.symbols @@ -9,7 +9,13 @@ function Zet(t) { /** @type {T} */ this.u +>this.u : Symbol(Zet.u, Decl(templateTagWithNestedTypeLiteral.js, 4, 17), Decl(templateTagWithNestedTypeLiteral.js, 14, 36)) +>this : Symbol(Zet, Decl(templateTagWithNestedTypeLiteral.js, 0, 0)) +>u : Symbol(Zet.u, Decl(templateTagWithNestedTypeLiteral.js, 4, 17), Decl(templateTagWithNestedTypeLiteral.js, 14, 36)) + this.t = t +>this.t : Symbol(Zet.t, Decl(templateTagWithNestedTypeLiteral.js, 6, 10)) +>this : Symbol(Zet, Decl(templateTagWithNestedTypeLiteral.js, 0, 0)) >t : Symbol(Zet.t, Decl(templateTagWithNestedTypeLiteral.js, 6, 10)) >t : Symbol(t, Decl(templateTagWithNestedTypeLiteral.js, 4, 13)) } diff --git a/tests/baselines/reference/jsdocTemplateConstructorFunction2.types b/tests/baselines/reference/jsdocTemplateConstructorFunction2.types index dc70e5282c3..316981e10af 100644 --- a/tests/baselines/reference/jsdocTemplateConstructorFunction2.types +++ b/tests/baselines/reference/jsdocTemplateConstructorFunction2.types @@ -9,14 +9,14 @@ function Zet(t) { /** @type {T} */ this.u ->this.u : any ->this : any ->u : any +>this.u : T +>this : this +>u : T this.t = t >this.t = t : T >this.t : any ->this : any +>this : this >t : any >t : T } diff --git a/tests/baselines/reference/jsdocTypeFromChainedAssignment.symbols b/tests/baselines/reference/jsdocTypeFromChainedAssignment.symbols index 5b1be631fd9..0107dfaad73 100644 --- a/tests/baselines/reference/jsdocTypeFromChainedAssignment.symbols +++ b/tests/baselines/reference/jsdocTypeFromChainedAssignment.symbols @@ -3,11 +3,17 @@ function A () { >A : Symbol(A, Decl(a.js, 0, 0), Decl(a.js, 8, 1), Decl(a.js, 10, 5)) this.x = 1 +>this.x : Symbol(A.x, Decl(a.js, 0, 15)) +>this : Symbol(A, Decl(a.js, 0, 0), Decl(a.js, 8, 1), Decl(a.js, 10, 5)) >x : Symbol(A.x, Decl(a.js, 0, 15)) /** @type {1} */ this.first = this.second = 1 +>this.first : Symbol(A.first, Decl(a.js, 1, 14)) +>this : Symbol(A, Decl(a.js, 0, 0), Decl(a.js, 8, 1), Decl(a.js, 10, 5)) >first : Symbol(A.first, Decl(a.js, 1, 14)) +>this.second : Symbol(A.second, Decl(a.js, 3, 16)) +>this : Symbol(A, Decl(a.js, 0, 0), Decl(a.js, 8, 1), Decl(a.js, 10, 5)) >second : Symbol(A.second, Decl(a.js, 3, 16)) } /** @param {number} n */ diff --git a/tests/baselines/reference/jsdocTypeFromChainedAssignment.types b/tests/baselines/reference/jsdocTypeFromChainedAssignment.types index 974ba2b1cdd..6cc9c457e57 100644 --- a/tests/baselines/reference/jsdocTypeFromChainedAssignment.types +++ b/tests/baselines/reference/jsdocTypeFromChainedAssignment.types @@ -5,20 +5,20 @@ function A () { this.x = 1 >this.x = 1 : 1 >this.x : any ->this : any +>this : this >x : any >1 : 1 /** @type {1} */ this.first = this.second = 1 >this.first = this.second = 1 : 1 ->this.first : any ->this : any ->first : any +>this.first : 1 +>this : this +>first : 1 >this.second = 1 : 1 ->this.second : any ->this : any ->second : any +>this.second : 1 +>this : this +>second : 1 >1 : 1 } /** @param {number} n */ diff --git a/tests/baselines/reference/jsdocTypeTagCast.js b/tests/baselines/reference/jsdocTypeTagCast.js index 53bf465b41a..e54a5550ecb 100644 --- a/tests/baselines/reference/jsdocTypeTagCast.js +++ b/tests/baselines/reference/jsdocTypeTagCast.js @@ -83,7 +83,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/jsdocTypeTagCast.symbols b/tests/baselines/reference/jsdocTypeTagCast.symbols index 679470b4c9c..5c4fbefb2c7 100644 --- a/tests/baselines/reference/jsdocTypeTagCast.symbols +++ b/tests/baselines/reference/jsdocTypeTagCast.symbols @@ -64,6 +64,8 @@ function SomeFakeClass() { /** @type {string|number} */ this.p = "bar"; +>this.p : Symbol(SomeFakeClass.p, Decl(b.js, 31, 26)) +>this : Symbol(SomeFakeClass, Decl(b.js, 29, 1)) >p : Symbol(SomeFakeClass.p, Decl(b.js, 31, 26)) } diff --git a/tests/baselines/reference/jsdocTypeTagCast.types b/tests/baselines/reference/jsdocTypeTagCast.types index f7e9136ca34..5a330825aea 100644 --- a/tests/baselines/reference/jsdocTypeTagCast.types +++ b/tests/baselines/reference/jsdocTypeTagCast.types @@ -85,9 +85,9 @@ function SomeFakeClass() { /** @type {string|number} */ this.p = "bar"; >this.p = "bar" : "bar" ->this.p : any ->this : any ->p : any +>this.p : string | number +>this : this +>p : string | number >"bar" : "bar" } diff --git a/tests/baselines/reference/jsxCallbackWithDestructuring.js b/tests/baselines/reference/jsxCallbackWithDestructuring.js index 2569315133a..d2c079d5a40 100644 --- a/tests/baselines/reference/jsxCallbackWithDestructuring.js +++ b/tests/baselines/reference/jsxCallbackWithDestructuring.js @@ -32,7 +32,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/jsxChildrenSingleChildConfusableWithMultipleChildrenNoError.js b/tests/baselines/reference/jsxChildrenSingleChildConfusableWithMultipleChildrenNoError.js index e212514d699..a04925139c3 100644 --- a/tests/baselines/reference/jsxChildrenSingleChildConfusableWithMultipleChildrenNoError.js +++ b/tests/baselines/reference/jsxChildrenSingleChildConfusableWithMultipleChildrenNoError.js @@ -31,7 +31,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/jsxHasLiteralType.js b/tests/baselines/reference/jsxHasLiteralType.js index a32d8ec409b..0564341c764 100644 --- a/tests/baselines/reference/jsxHasLiteralType.js +++ b/tests/baselines/reference/jsxHasLiteralType.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/jsxInExtendsClause.js b/tests/baselines/reference/jsxInExtendsClause.js index 4ccb1b2d33f..8f9c056d7eb 100644 --- a/tests/baselines/reference/jsxInExtendsClause.js +++ b/tests/baselines/reference/jsxInExtendsClause.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/jsxViaImport.2.js b/tests/baselines/reference/jsxViaImport.2.js index 8f68e25cf93..d2ac31a9c4d 100644 --- a/tests/baselines/reference/jsxViaImport.2.js +++ b/tests/baselines/reference/jsxViaImport.2.js @@ -28,7 +28,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/jsxViaImport.js b/tests/baselines/reference/jsxViaImport.js index 28ef5ac96da..1b0baaf16b3 100644 --- a/tests/baselines/reference/jsxViaImport.js +++ b/tests/baselines/reference/jsxViaImport.js @@ -28,7 +28,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/keyofAndIndexedAccess.js b/tests/baselines/reference/keyofAndIndexedAccess.js index e56ad3d5434..38283e24b5f 100644 --- a/tests/baselines/reference/keyofAndIndexedAccess.js +++ b/tests/baselines/reference/keyofAndIndexedAccess.js @@ -663,7 +663,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/lambdaArgCrash.js b/tests/baselines/reference/lambdaArgCrash.js index 50f166548c1..527d14a636c 100644 --- a/tests/baselines/reference/lambdaArgCrash.js +++ b/tests/baselines/reference/lambdaArgCrash.js @@ -39,7 +39,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/lift.js b/tests/baselines/reference/lift.js index d2e9d4351d3..33a434f1f92 100644 --- a/tests/baselines/reference/lift.js +++ b/tests/baselines/reference/lift.js @@ -22,7 +22,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/localTypes1.js b/tests/baselines/reference/localTypes1.js index 8f59847f258..f9924dac59c 100644 --- a/tests/baselines/reference/localTypes1.js +++ b/tests/baselines/reference/localTypes1.js @@ -145,7 +145,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/m7Bugs.js b/tests/baselines/reference/m7Bugs.js index 442d320e5a7..e04a0ba5aaa 100644 --- a/tests/baselines/reference/m7Bugs.js +++ b/tests/baselines/reference/m7Bugs.js @@ -31,7 +31,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/mappedTypePartialConstraints.js b/tests/baselines/reference/mappedTypePartialConstraints.js index ba39eb341e9..c3a5ac9b70c 100644 --- a/tests/baselines/reference/mappedTypePartialConstraints.js +++ b/tests/baselines/reference/mappedTypePartialConstraints.js @@ -22,7 +22,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/mergedDeclarations5.js b/tests/baselines/reference/mergedDeclarations5.js index c54082e7490..353f16db6f0 100644 --- a/tests/baselines/reference/mergedDeclarations5.js +++ b/tests/baselines/reference/mergedDeclarations5.js @@ -23,7 +23,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/mergedDeclarations6.js b/tests/baselines/reference/mergedDeclarations6.js index 6dfc6015a96..9c369a9dea5 100644 --- a/tests/baselines/reference/mergedDeclarations6.js +++ b/tests/baselines/reference/mergedDeclarations6.js @@ -42,7 +42,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/mergedInheritedClassInterface.js b/tests/baselines/reference/mergedInheritedClassInterface.js index 374ba758996..32186fba27e 100644 --- a/tests/baselines/reference/mergedInheritedClassInterface.js +++ b/tests/baselines/reference/mergedInheritedClassInterface.js @@ -51,7 +51,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/mergedInheritedMembersSatisfyAbstractBase.js b/tests/baselines/reference/mergedInheritedMembersSatisfyAbstractBase.js index 4f6814b7524..097faa3bd7c 100644 --- a/tests/baselines/reference/mergedInheritedMembersSatisfyAbstractBase.js +++ b/tests/baselines/reference/mergedInheritedMembersSatisfyAbstractBase.js @@ -25,7 +25,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/mergedInterfacesWithInheritedPrivates2.js b/tests/baselines/reference/mergedInterfacesWithInheritedPrivates2.js index 8a4084f8ddc..824ecd7f9b8 100644 --- a/tests/baselines/reference/mergedInterfacesWithInheritedPrivates2.js +++ b/tests/baselines/reference/mergedInterfacesWithInheritedPrivates2.js @@ -36,7 +36,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/mergedInterfacesWithInheritedPrivates3.js b/tests/baselines/reference/mergedInterfacesWithInheritedPrivates3.js index 0e16f4a5c3d..4cba16610de 100644 --- a/tests/baselines/reference/mergedInterfacesWithInheritedPrivates3.js +++ b/tests/baselines/reference/mergedInterfacesWithInheritedPrivates3.js @@ -43,7 +43,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/missingPropertiesOfClassExpression.js b/tests/baselines/reference/missingPropertiesOfClassExpression.js index 09bd027beac..ee280c88444 100644 --- a/tests/baselines/reference/missingPropertiesOfClassExpression.js +++ b/tests/baselines/reference/missingPropertiesOfClassExpression.js @@ -11,7 +11,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/mixinAccessModifiers.js b/tests/baselines/reference/mixinAccessModifiers.js index 2d158f6841e..a90ebefbd08 100644 --- a/tests/baselines/reference/mixinAccessModifiers.js +++ b/tests/baselines/reference/mixinAccessModifiers.js @@ -137,7 +137,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/mixinClassesAnnotated.js b/tests/baselines/reference/mixinClassesAnnotated.js index 4c5269508f4..f8ee303d1aa 100644 --- a/tests/baselines/reference/mixinClassesAnnotated.js +++ b/tests/baselines/reference/mixinClassesAnnotated.js @@ -71,7 +71,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/mixinClassesAnonymous.js b/tests/baselines/reference/mixinClassesAnonymous.js index f2328d4c6d1..f06e47db7e0 100644 --- a/tests/baselines/reference/mixinClassesAnonymous.js +++ b/tests/baselines/reference/mixinClassesAnonymous.js @@ -70,7 +70,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/mixinClassesMembers.js b/tests/baselines/reference/mixinClassesMembers.js index 173ee687a35..2195186d622 100644 --- a/tests/baselines/reference/mixinClassesMembers.js +++ b/tests/baselines/reference/mixinClassesMembers.js @@ -103,7 +103,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/mixinIntersectionIsValidbaseType.js b/tests/baselines/reference/mixinIntersectionIsValidbaseType.js index 3c489812625..f4ad4a84f3d 100644 --- a/tests/baselines/reference/mixinIntersectionIsValidbaseType.js +++ b/tests/baselines/reference/mixinIntersectionIsValidbaseType.js @@ -33,7 +33,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/mixinPrivateAndProtected.js b/tests/baselines/reference/mixinPrivateAndProtected.js index 601cce00e37..c94ee6c9443 100644 --- a/tests/baselines/reference/mixinPrivateAndProtected.js +++ b/tests/baselines/reference/mixinPrivateAndProtected.js @@ -95,7 +95,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/mixingApparentTypeOverrides.js b/tests/baselines/reference/mixingApparentTypeOverrides.js index 74f9afc8389..d790b39ab4a 100644 --- a/tests/baselines/reference/mixingApparentTypeOverrides.js +++ b/tests/baselines/reference/mixingApparentTypeOverrides.js @@ -33,7 +33,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/moduleAsBaseType.js b/tests/baselines/reference/moduleAsBaseType.js index 260735687ca..862b305409b 100644 --- a/tests/baselines/reference/moduleAsBaseType.js +++ b/tests/baselines/reference/moduleAsBaseType.js @@ -9,7 +9,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/moduleAugmentationDoesInterfaceMergeOfReexport.js b/tests/baselines/reference/moduleAugmentationDoesInterfaceMergeOfReexport.js index 2d3b3b7a1b4..45b1fe736c9 100644 --- a/tests/baselines/reference/moduleAugmentationDoesInterfaceMergeOfReexport.js +++ b/tests/baselines/reference/moduleAugmentationDoesInterfaceMergeOfReexport.js @@ -35,7 +35,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./file"), exports); diff --git a/tests/baselines/reference/moduleAugmentationDoesNamespaceEnumMergeOfReexport.js b/tests/baselines/reference/moduleAugmentationDoesNamespaceEnumMergeOfReexport.js index 38bfb39d776..33f63201f65 100644 --- a/tests/baselines/reference/moduleAugmentationDoesNamespaceEnumMergeOfReexport.js +++ b/tests/baselines/reference/moduleAugmentationDoesNamespaceEnumMergeOfReexport.js @@ -40,7 +40,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./file"), exports); diff --git a/tests/baselines/reference/moduleAugmentationDoesNamespaceMergeOfReexport.js b/tests/baselines/reference/moduleAugmentationDoesNamespaceMergeOfReexport.js index 8a606153bd1..16a902446fa 100644 --- a/tests/baselines/reference/moduleAugmentationDoesNamespaceMergeOfReexport.js +++ b/tests/baselines/reference/moduleAugmentationDoesNamespaceMergeOfReexport.js @@ -39,7 +39,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./file"), exports); diff --git a/tests/baselines/reference/moduleAugmentationEnumClassMergeOfReexportIsError.js b/tests/baselines/reference/moduleAugmentationEnumClassMergeOfReexportIsError.js index 0cb50179bfd..e86b27b4538 100644 --- a/tests/baselines/reference/moduleAugmentationEnumClassMergeOfReexportIsError.js +++ b/tests/baselines/reference/moduleAugmentationEnumClassMergeOfReexportIsError.js @@ -38,7 +38,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./file"), exports); diff --git a/tests/baselines/reference/moduleDeclarationExportStarShadowingGlobalIsNameable.js b/tests/baselines/reference/moduleDeclarationExportStarShadowingGlobalIsNameable.js index f243093f5be..64b264fc8ee 100644 --- a/tests/baselines/reference/moduleDeclarationExportStarShadowingGlobalIsNameable.js +++ b/tests/baselines/reference/moduleDeclarationExportStarShadowingGlobalIsNameable.js @@ -38,7 +38,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./account"), exports); diff --git a/tests/baselines/reference/moduleExportAlias2.symbols b/tests/baselines/reference/moduleExportAlias2.symbols index 6dc88d4d8c9..3571a6760e1 100644 --- a/tests/baselines/reference/moduleExportAlias2.symbols +++ b/tests/baselines/reference/moduleExportAlias2.symbols @@ -47,5 +47,7 @@ function C() { >C : Symbol(C, Decl(semver.js, 2, 22)) this.p = 1 +>this.p : Symbol(C.p, Decl(semver.js, 3, 14)) +>this : Symbol(C, Decl(semver.js, 2, 22)) >p : Symbol(C.p, Decl(semver.js, 3, 14)) } diff --git a/tests/baselines/reference/moduleExportAlias2.types b/tests/baselines/reference/moduleExportAlias2.types index 44b04455aa4..6552d860754 100644 --- a/tests/baselines/reference/moduleExportAlias2.types +++ b/tests/baselines/reference/moduleExportAlias2.types @@ -59,7 +59,7 @@ function C() { this.p = 1 >this.p = 1 : 1 >this.p : any ->this : any +>this : this >p : any >1 : 1 } diff --git a/tests/baselines/reference/moduleExportNestedNamespaces.symbols b/tests/baselines/reference/moduleExportNestedNamespaces.symbols index 0472ea186b0..2ed7db8d287 100644 --- a/tests/baselines/reference/moduleExportNestedNamespaces.symbols +++ b/tests/baselines/reference/moduleExportNestedNamespaces.symbols @@ -17,7 +17,8 @@ module.exports.n.K = function C() { >C : Symbol(C, Decl(mod.js, 1, 20)) this.x = 10; ->this : Symbol(n, Decl(mod.js, 0, 0), Decl(mod.js, 1, 15)) +>this.x : Symbol(C.x, Decl(mod.js, 1, 35)) +>this : Symbol(C, Decl(mod.js, 1, 20)) >x : Symbol(C.x, Decl(mod.js, 1, 35)) } module.exports.Classic = class { diff --git a/tests/baselines/reference/moduleExportNestedNamespaces.types b/tests/baselines/reference/moduleExportNestedNamespaces.types index 5a266b23277..7da94f8a29d 100644 --- a/tests/baselines/reference/moduleExportNestedNamespaces.types +++ b/tests/baselines/reference/moduleExportNestedNamespaces.types @@ -23,7 +23,7 @@ module.exports.n.K = function C() { this.x = 10; >this.x = 10 : 10 >this.x : any ->this : typeof n +>this : this >x : any >10 : 10 } diff --git a/tests/baselines/reference/moduleExportWithExportPropertyAssignment4.symbols b/tests/baselines/reference/moduleExportWithExportPropertyAssignment4.symbols index 76fecbc0b2c..82277b0540a 100644 --- a/tests/baselines/reference/moduleExportWithExportPropertyAssignment4.symbols +++ b/tests/baselines/reference/moduleExportWithExportPropertyAssignment4.symbols @@ -72,6 +72,8 @@ function A() { >A : Symbol(A, Decl(mod1.js, 5, 18), Decl(mod1.js, 1, 36), Decl(mod1.js, 2, 16), Decl(mod1.js, 3, 16)) this.p = 1 +>this.p : Symbol(A.p, Decl(mod1.js, 6, 14)) +>this : Symbol(A, Decl(mod1.js, 5, 18), Decl(mod1.js, 1, 36), Decl(mod1.js, 2, 16), Decl(mod1.js, 3, 16)) >p : Symbol(A.p, Decl(mod1.js, 6, 14)) } module.exports.bothAfter = 'string' diff --git a/tests/baselines/reference/moduleExportWithExportPropertyAssignment4.types b/tests/baselines/reference/moduleExportWithExportPropertyAssignment4.types index 41b03e786d0..0ddaff1d58a 100644 --- a/tests/baselines/reference/moduleExportWithExportPropertyAssignment4.types +++ b/tests/baselines/reference/moduleExportWithExportPropertyAssignment4.types @@ -91,7 +91,7 @@ function A() { this.p = 1 >this.p = 1 : 1 >this.p : any ->this : any +>this : this >p : any >1 : 1 } diff --git a/tests/baselines/reference/moduleImportedForTypeArgumentPosition.js b/tests/baselines/reference/moduleImportedForTypeArgumentPosition.js index b0ad743cffa..9765ef7d72d 100644 --- a/tests/baselines/reference/moduleImportedForTypeArgumentPosition.js +++ b/tests/baselines/reference/moduleImportedForTypeArgumentPosition.js @@ -21,7 +21,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/moduleNoneOutFile.js b/tests/baselines/reference/moduleNoneOutFile.js index 723e266e6d3..c772cc4e351 100644 --- a/tests/baselines/reference/moduleNoneOutFile.js +++ b/tests/baselines/reference/moduleNoneOutFile.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/moduleSameValueDuplicateExportedBindings1.js b/tests/baselines/reference/moduleSameValueDuplicateExportedBindings1.js index 4051b88b059..f0d186d22d4 100644 --- a/tests/baselines/reference/moduleSameValueDuplicateExportedBindings1.js +++ b/tests/baselines/reference/moduleSameValueDuplicateExportedBindings1.js @@ -25,7 +25,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./c"), exports); @@ -39,7 +39,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./b"), exports); diff --git a/tests/baselines/reference/moduleSameValueDuplicateExportedBindings2.js b/tests/baselines/reference/moduleSameValueDuplicateExportedBindings2.js index 93b5a363948..5fef7d152df 100644 --- a/tests/baselines/reference/moduleSameValueDuplicateExportedBindings2.js +++ b/tests/baselines/reference/moduleSameValueDuplicateExportedBindings2.js @@ -46,7 +46,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./b"), exports); diff --git a/tests/baselines/reference/moduleWithStatementsOfEveryKind.js b/tests/baselines/reference/moduleWithStatementsOfEveryKind.js index af336676867..fce46332a59 100644 --- a/tests/baselines/reference/moduleWithStatementsOfEveryKind.js +++ b/tests/baselines/reference/moduleWithStatementsOfEveryKind.js @@ -63,7 +63,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/multipleDeclarations.symbols b/tests/baselines/reference/multipleDeclarations.symbols index b33ebc0222f..2c2b60fb6ab 100644 --- a/tests/baselines/reference/multipleDeclarations.symbols +++ b/tests/baselines/reference/multipleDeclarations.symbols @@ -3,6 +3,8 @@ function C() { >C : Symbol(C, Decl(input.js, 0, 0)) this.m = null; +>this.m : Symbol(C.m, Decl(input.js, 0, 14)) +>this : Symbol(C, Decl(input.js, 0, 0)) >m : Symbol(C.m, Decl(input.js, 0, 14)) } C.prototype.m = function() { diff --git a/tests/baselines/reference/multipleDeclarations.types b/tests/baselines/reference/multipleDeclarations.types index 445d737019e..12aa74ecaf0 100644 --- a/tests/baselines/reference/multipleDeclarations.types +++ b/tests/baselines/reference/multipleDeclarations.types @@ -5,7 +5,7 @@ function C() { this.m = null; >this.m = null : null >this.m : any ->this : any +>this : this >m : any >null : null } diff --git a/tests/baselines/reference/multipleInheritance.js b/tests/baselines/reference/multipleInheritance.js index b80794c1e71..ae5e7da4414 100644 --- a/tests/baselines/reference/multipleInheritance.js +++ b/tests/baselines/reference/multipleInheritance.js @@ -43,7 +43,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/mutuallyRecursiveGenericBaseTypes2.js b/tests/baselines/reference/mutuallyRecursiveGenericBaseTypes2.js index 54fea7b4d53..3e1d91ca354 100644 --- a/tests/baselines/reference/mutuallyRecursiveGenericBaseTypes2.js +++ b/tests/baselines/reference/mutuallyRecursiveGenericBaseTypes2.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/mutuallyRecursiveInference.js b/tests/baselines/reference/mutuallyRecursiveInference.js index f43ea313001..a3d79a6623e 100644 --- a/tests/baselines/reference/mutuallyRecursiveInference.js +++ b/tests/baselines/reference/mutuallyRecursiveInference.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/narrowingOfDottedNames.js b/tests/baselines/reference/narrowingOfDottedNames.js index 4b4d9ada399..4cb1da7cddd 100644 --- a/tests/baselines/reference/narrowingOfDottedNames.js +++ b/tests/baselines/reference/narrowingOfDottedNames.js @@ -98,7 +98,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/neverReturningFunctions1.js b/tests/baselines/reference/neverReturningFunctions1.js index 512c8205ce4..35be732c3ec 100644 --- a/tests/baselines/reference/neverReturningFunctions1.js +++ b/tests/baselines/reference/neverReturningFunctions1.js @@ -255,7 +255,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/newTarget.es5.js b/tests/baselines/reference/newTarget.es5.js index 92be98d08fb..60a4f9b0ac6 100644 --- a/tests/baselines/reference/newTarget.es5.js +++ b/tests/baselines/reference/newTarget.es5.js @@ -37,7 +37,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/noCrashOnMixin.js b/tests/baselines/reference/noCrashOnMixin.js index 2a72e5ba185..600d163fef4 100644 --- a/tests/baselines/reference/noCrashOnMixin.js +++ b/tests/baselines/reference/noCrashOnMixin.js @@ -28,7 +28,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/noImplicitAnyMissingGetAccessor.js b/tests/baselines/reference/noImplicitAnyMissingGetAccessor.js index d5c7bdb0915..2e8d3aa7f6b 100644 --- a/tests/baselines/reference/noImplicitAnyMissingGetAccessor.js +++ b/tests/baselines/reference/noImplicitAnyMissingGetAccessor.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/noImplicitAnyMissingSetAccessor.js b/tests/baselines/reference/noImplicitAnyMissingSetAccessor.js index c4db0caa2ce..35de497eeeb 100644 --- a/tests/baselines/reference/noImplicitAnyMissingSetAccessor.js +++ b/tests/baselines/reference/noImplicitAnyMissingSetAccessor.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.errors.txt b/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.errors.txt index 729c8236abd..9e547245d94 100644 --- a/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.errors.txt +++ b/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.errors.txt @@ -35,9 +35,10 @@ tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts(76,1): error TS7053: tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts(81,1): error TS7053: Element implicitly has an 'any' type because expression of type 'StrEnum' can't be used to index type '{ a: number; }'. Property '[StrEnum.b]' does not exist on type '{ a: number; }'. tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts(93,5): error TS2538: Type 'Dog' cannot be used as an index type. +tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts(99,1): error TS7052: Element implicitly has an 'any' type because type 'MyMap' has no index signature. Did you mean to call 'm.prop.get'? -==== tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts (30 errors) ==== +==== tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts (31 errors) ==== var a = {}["hello"]; ~~~~~~~~~~~ !!! error TS7053: Element implicitly has an 'any' type because expression of type '"hello"' can't be used to index type '{}'. @@ -198,4 +199,12 @@ tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts(93,5): error TS2538: map[rover] = "Rover"; ~~~~~ !!! error TS2538: Type 'Dog' cannot be used as an index type. + + interface I { + prop: MyMap + } + declare const m: I; + m.prop['a']; + ~~~~~~~~~~~ +!!! error TS7052: Element implicitly has an 'any' type because type 'MyMap' has no index signature. Did you mean to call 'm.prop.get'? \ No newline at end of file diff --git a/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.js b/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.js index aade38856d0..2d3b613a023 100644 --- a/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.js +++ b/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.js @@ -92,6 +92,12 @@ let rover: Dog = { bark() {} }; declare let map: MyMap; map[rover] = "Rover"; + +interface I { + prop: MyMap +} +declare const m: I; +m.prop['a']; //// [noImplicitAnyStringIndexerOnObject.js] @@ -168,3 +174,4 @@ var strEnumKey; o[strEnumKey]; var rover = { bark: function () { } }; map[rover] = "Rover"; +m.prop['a']; diff --git a/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.symbols b/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.symbols index 17361623965..0eda5fa9c36 100644 --- a/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.symbols +++ b/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.symbols @@ -277,3 +277,19 @@ map[rover] = "Rover"; >map : Symbol(map, Decl(noImplicitAnyStringIndexerOnObject.ts, 91, 11)) >rover : Symbol(rover, Decl(noImplicitAnyStringIndexerOnObject.ts, 89, 3)) +interface I { +>I : Symbol(I, Decl(noImplicitAnyStringIndexerOnObject.ts, 92, 21)) + + prop: MyMap +>prop : Symbol(I.prop, Decl(noImplicitAnyStringIndexerOnObject.ts, 94, 13)) +>MyMap : Symbol(MyMap, Decl(noImplicitAnyStringIndexerOnObject.ts, 80, 14)) +} +declare const m: I; +>m : Symbol(m, Decl(noImplicitAnyStringIndexerOnObject.ts, 97, 13)) +>I : Symbol(I, Decl(noImplicitAnyStringIndexerOnObject.ts, 92, 21)) + +m.prop['a']; +>m.prop : Symbol(I.prop, Decl(noImplicitAnyStringIndexerOnObject.ts, 94, 13)) +>m : Symbol(m, Decl(noImplicitAnyStringIndexerOnObject.ts, 97, 13)) +>prop : Symbol(I.prop, Decl(noImplicitAnyStringIndexerOnObject.ts, 94, 13)) + diff --git a/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.types b/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.types index 4a12805418b..20aa05cb40e 100644 --- a/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.types +++ b/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.types @@ -418,3 +418,17 @@ map[rover] = "Rover"; >rover : Dog >"Rover" : "Rover" +interface I { + prop: MyMap +>prop : MyMap +} +declare const m: I; +>m : I + +m.prop['a']; +>m.prop['a'] : any +>m.prop : MyMap +>m : I +>prop : MyMap +>'a' : "a" + diff --git a/tests/baselines/reference/nonGenericClassExtendingGenericClassWithAny.js b/tests/baselines/reference/nonGenericClassExtendingGenericClassWithAny.js index 93a8b21daae..6f29b44a41c 100644 --- a/tests/baselines/reference/nonGenericClassExtendingGenericClassWithAny.js +++ b/tests/baselines/reference/nonGenericClassExtendingGenericClassWithAny.js @@ -10,7 +10,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/numericIndexerConstrainsPropertyDeclarations2.js b/tests/baselines/reference/numericIndexerConstrainsPropertyDeclarations2.js index 37b827cc8c4..8f60fa2a073 100644 --- a/tests/baselines/reference/numericIndexerConstrainsPropertyDeclarations2.js +++ b/tests/baselines/reference/numericIndexerConstrainsPropertyDeclarations2.js @@ -51,7 +51,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/numericIndexerConstraint3.js b/tests/baselines/reference/numericIndexerConstraint3.js index f6e1a201de6..6eef60ae775 100644 --- a/tests/baselines/reference/numericIndexerConstraint3.js +++ b/tests/baselines/reference/numericIndexerConstraint3.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/numericIndexerConstraint4.js b/tests/baselines/reference/numericIndexerConstraint4.js index e2cb7c58dff..74034978f4b 100644 --- a/tests/baselines/reference/numericIndexerConstraint4.js +++ b/tests/baselines/reference/numericIndexerConstraint4.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/numericIndexerTyping2.js b/tests/baselines/reference/numericIndexerTyping2.js index 28af1636aec..ee3299b4170 100644 --- a/tests/baselines/reference/numericIndexerTyping2.js +++ b/tests/baselines/reference/numericIndexerTyping2.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/objectCreationOfElementAccessExpression.js b/tests/baselines/reference/objectCreationOfElementAccessExpression.js index ed67113d387..8737125f6a9 100644 --- a/tests/baselines/reference/objectCreationOfElementAccessExpression.js +++ b/tests/baselines/reference/objectCreationOfElementAccessExpression.js @@ -60,7 +60,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/objectTypeHidingMembersOfExtendedObject.js b/tests/baselines/reference/objectTypeHidingMembersOfExtendedObject.js index 9cdb3cf42fd..1a3ac3d04fd 100644 --- a/tests/baselines/reference/objectTypeHidingMembersOfExtendedObject.js +++ b/tests/baselines/reference/objectTypeHidingMembersOfExtendedObject.js @@ -59,7 +59,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/objectTypesIdentityWithNumericIndexers1.js b/tests/baselines/reference/objectTypesIdentityWithNumericIndexers1.js index f6d5a970664..0dbf74a4009 100644 --- a/tests/baselines/reference/objectTypesIdentityWithNumericIndexers1.js +++ b/tests/baselines/reference/objectTypesIdentityWithNumericIndexers1.js @@ -128,7 +128,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/objectTypesIdentityWithNumericIndexers2.js b/tests/baselines/reference/objectTypesIdentityWithNumericIndexers2.js index bbc9351a922..e64466bc8ed 100644 --- a/tests/baselines/reference/objectTypesIdentityWithNumericIndexers2.js +++ b/tests/baselines/reference/objectTypesIdentityWithNumericIndexers2.js @@ -131,7 +131,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/objectTypesIdentityWithNumericIndexers3.js b/tests/baselines/reference/objectTypesIdentityWithNumericIndexers3.js index ffe0bcc558f..7456b54646f 100644 --- a/tests/baselines/reference/objectTypesIdentityWithNumericIndexers3.js +++ b/tests/baselines/reference/objectTypesIdentityWithNumericIndexers3.js @@ -128,7 +128,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/objectTypesIdentityWithPrivates.js b/tests/baselines/reference/objectTypesIdentityWithPrivates.js index 3774b171204..462f1310bca 100644 --- a/tests/baselines/reference/objectTypesIdentityWithPrivates.js +++ b/tests/baselines/reference/objectTypesIdentityWithPrivates.js @@ -126,7 +126,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/objectTypesIdentityWithPrivates2.js b/tests/baselines/reference/objectTypesIdentityWithPrivates2.js index e18a0096cb4..d11c6759c00 100644 --- a/tests/baselines/reference/objectTypesIdentityWithPrivates2.js +++ b/tests/baselines/reference/objectTypesIdentityWithPrivates2.js @@ -44,7 +44,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/objectTypesIdentityWithPrivates3.js b/tests/baselines/reference/objectTypesIdentityWithPrivates3.js index 2fe25fdfaec..eec67a3d852 100644 --- a/tests/baselines/reference/objectTypesIdentityWithPrivates3.js +++ b/tests/baselines/reference/objectTypesIdentityWithPrivates3.js @@ -30,7 +30,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/objectTypesIdentityWithStringIndexers.js b/tests/baselines/reference/objectTypesIdentityWithStringIndexers.js index 070686b15cc..4ebbb280ca7 100644 --- a/tests/baselines/reference/objectTypesIdentityWithStringIndexers.js +++ b/tests/baselines/reference/objectTypesIdentityWithStringIndexers.js @@ -128,7 +128,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/objectTypesIdentityWithStringIndexers2.js b/tests/baselines/reference/objectTypesIdentityWithStringIndexers2.js index bc882c7ecd8..8e48bf2eb92 100644 --- a/tests/baselines/reference/objectTypesIdentityWithStringIndexers2.js +++ b/tests/baselines/reference/objectTypesIdentityWithStringIndexers2.js @@ -131,7 +131,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/optionalConstructorArgInSuper.js b/tests/baselines/reference/optionalConstructorArgInSuper.js index 29535a3b317..8b4e559438c 100644 --- a/tests/baselines/reference/optionalConstructorArgInSuper.js +++ b/tests/baselines/reference/optionalConstructorArgInSuper.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/optionalMethods.js b/tests/baselines/reference/optionalMethods.js index 0a409e935eb..d8d19d1d042 100644 --- a/tests/baselines/reference/optionalMethods.js +++ b/tests/baselines/reference/optionalMethods.js @@ -61,7 +61,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/optionalParamArgsTest.js b/tests/baselines/reference/optionalParamArgsTest.js index a89d3d39273..1bd62b44fd5 100644 --- a/tests/baselines/reference/optionalParamArgsTest.js +++ b/tests/baselines/reference/optionalParamArgsTest.js @@ -129,7 +129,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/optionalParamInOverride.js b/tests/baselines/reference/optionalParamInOverride.js index e4d417bbc65..eb008f11401 100644 --- a/tests/baselines/reference/optionalParamInOverride.js +++ b/tests/baselines/reference/optionalParamInOverride.js @@ -12,7 +12,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/optionalParameterProperty.js b/tests/baselines/reference/optionalParameterProperty.js index 80c3ce96f66..e41b5e52e68 100644 --- a/tests/baselines/reference/optionalParameterProperty.js +++ b/tests/baselines/reference/optionalParameterProperty.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/organizeImports/TypeOnly.ts b/tests/baselines/reference/organizeImports/TypeOnly.ts index dcd18e7ef86..96281b4ada5 100644 --- a/tests/baselines/reference/organizeImports/TypeOnly.ts +++ b/tests/baselines/reference/organizeImports/TypeOnly.ts @@ -8,8 +8,8 @@ import type { A, B } from "lib"; export { A, B, X, Y, Z }; // ==ORGANIZED== -import { X, Z } from "lib"; import type Y from "lib"; import type { A, B } from "lib"; +import { X, Z } from "lib"; export { A, B, X, Y, Z }; diff --git a/tests/baselines/reference/outModuleConcatAmd.js b/tests/baselines/reference/outModuleConcatAmd.js index f3e7fa6a5a2..d91c056ad45 100644 --- a/tests/baselines/reference/outModuleConcatAmd.js +++ b/tests/baselines/reference/outModuleConcatAmd.js @@ -12,7 +12,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/outModuleConcatAmd.js.map b/tests/baselines/reference/outModuleConcatAmd.js.map index 0d033f2b660..29e19b23016 100644 --- a/tests/baselines/reference/outModuleConcatAmd.js.map +++ b/tests/baselines/reference/outModuleConcatAmd.js.map @@ -1,3 +1,3 @@ //// [all.js.map] {"version":3,"file":"all.js","sourceRoot":"","sources":["tests/cases/compiler/ref/a.ts","tests/cases/compiler/b.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;IAAA;QAAA;QAAiB,CAAC;QAAD,QAAC;IAAD,CAAC,AAAlB,IAAkB;IAAL,cAAC;;;;;;ICCd;QAAuB,qBAAC;QAAxB;;QAA2B,CAAC;QAAD,QAAC;IAAD,CAAC,AAA5B,CAAuB,KAAC,GAAI;IAAf,cAAC"} -//// https://sokra.github.io/source-map-visualization#base64,dmFyIF9fZXh0ZW5kcyA9ICh0aGlzICYmIHRoaXMuX19leHRlbmRzKSB8fCAoZnVuY3Rpb24gKCkgew0KICAgIHZhciBleHRlbmRTdGF0aWNzID0gZnVuY3Rpb24gKGQsIGIpIHsNCiAgICAgICAgZXh0ZW5kU3RhdGljcyA9IE9iamVjdC5zZXRQcm90b3R5cGVPZiB8fA0KICAgICAgICAgICAgKHsgX19wcm90b19fOiBbXSB9IGluc3RhbmNlb2YgQXJyYXkgJiYgZnVuY3Rpb24gKGQsIGIpIHsgZC5fX3Byb3RvX18gPSBiOyB9KSB8fA0KICAgICAgICAgICAgZnVuY3Rpb24gKGQsIGIpIHsgZm9yICh2YXIgcCBpbiBiKSBpZiAoYi5oYXNPd25Qcm9wZXJ0eShwKSkgZFtwXSA9IGJbcF07IH07DQogICAgICAgIHJldHVybiBleHRlbmRTdGF0aWNzKGQsIGIpOw0KICAgIH07DQogICAgcmV0dXJuIGZ1bmN0aW9uIChkLCBiKSB7DQogICAgICAgIGV4dGVuZFN0YXRpY3MoZCwgYik7DQogICAgICAgIGZ1bmN0aW9uIF9fKCkgeyB0aGlzLmNvbnN0cnVjdG9yID0gZDsgfQ0KICAgICAgICBkLnByb3RvdHlwZSA9IGIgPT09IG51bGwgPyBPYmplY3QuY3JlYXRlKGIpIDogKF9fLnByb3RvdHlwZSA9IGIucHJvdG90eXBlLCBuZXcgX18oKSk7DQogICAgfTsNCn0pKCk7DQpkZWZpbmUoInJlZi9hIiwgWyJyZXF1aXJlIiwgImV4cG9ydHMiXSwgZnVuY3Rpb24gKHJlcXVpcmUsIGV4cG9ydHMpIHsNCiAgICAidXNlIHN0cmljdCI7DQogICAgT2JqZWN0LmRlZmluZVByb3BlcnR5KGV4cG9ydHMsICJfX2VzTW9kdWxlIiwgeyB2YWx1ZTogdHJ1ZSB9KTsNCiAgICBleHBvcnRzLkEgPSB2b2lkIDA7DQogICAgdmFyIEEgPSAvKiogQGNsYXNzICovIChmdW5jdGlvbiAoKSB7DQogICAgICAgIGZ1bmN0aW9uIEEoKSB7DQogICAgICAgIH0NCiAgICAgICAgcmV0dXJuIEE7DQogICAgfSgpKTsNCiAgICBleHBvcnRzLkEgPSBBOw0KfSk7DQpkZWZpbmUoImIiLCBbInJlcXVpcmUiLCAiZXhwb3J0cyIsICJyZWYvYSJdLCBmdW5jdGlvbiAocmVxdWlyZSwgZXhwb3J0cywgYV8xKSB7DQogICAgInVzZSBzdHJpY3QiOw0KICAgIE9iamVjdC5kZWZpbmVQcm9wZXJ0eShleHBvcnRzLCAiX19lc01vZHVsZSIsIHsgdmFsdWU6IHRydWUgfSk7DQogICAgZXhwb3J0cy5CID0gdm9pZCAwOw0KICAgIHZhciBCID0gLyoqIEBjbGFzcyAqLyAoZnVuY3Rpb24gKF9zdXBlcikgew0KICAgICAgICBfX2V4dGVuZHMoQiwgX3N1cGVyKTsNCiAgICAgICAgZnVuY3Rpb24gQigpIHsNCiAgICAgICAgICAgIHJldHVybiBfc3VwZXIgIT09IG51bGwgJiYgX3N1cGVyLmFwcGx5KHRoaXMsIGFyZ3VtZW50cykgfHwgdGhpczsNCiAgICAgICAgfQ0KICAgICAgICByZXR1cm4gQjsNCiAgICB9KGFfMS5BKSk7DQogICAgZXhwb3J0cy5CID0gQjsNCn0pOw0KLy8jIHNvdXJjZU1hcHBpbmdVUkw9YWxsLmpzLm1hcA==,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYWxsLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsidGVzdHMvY2FzZXMvY29tcGlsZXIvcmVmL2EudHMiLCJ0ZXN0cy9jYXNlcy9jb21waWxlci9iLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7Ozs7Ozs7Ozs7Ozs7O0lBQUE7UUFBQTtRQUFpQixDQUFDO1FBQUQsUUFBQztJQUFELENBQUMsQUFBbEIsSUFBa0I7SUFBTCxjQUFDOzs7Ozs7SUNDZDtRQUF1QixxQkFBQztRQUF4Qjs7UUFBMkIsQ0FBQztRQUFELFFBQUM7SUFBRCxDQUFDLEFBQTVCLENBQXVCLEtBQUMsR0FBSTtJQUFmLGNBQUMifQ==,ZXhwb3J0IGNsYXNzIEEgeyB9Cg==,aW1wb3J0IHtBfSBmcm9tICIuL3JlZi9hIjsKZXhwb3J0IGNsYXNzIEIgZXh0ZW5kcyBBIHsgfQ== +//// https://sokra.github.io/source-map-visualization#base64,dmFyIF9fZXh0ZW5kcyA9ICh0aGlzICYmIHRoaXMuX19leHRlbmRzKSB8fCAoZnVuY3Rpb24gKCkgew0KICAgIHZhciBleHRlbmRTdGF0aWNzID0gZnVuY3Rpb24gKGQsIGIpIHsNCiAgICAgICAgZXh0ZW5kU3RhdGljcyA9IE9iamVjdC5zZXRQcm90b3R5cGVPZiB8fA0KICAgICAgICAgICAgKHsgX19wcm90b19fOiBbXSB9IGluc3RhbmNlb2YgQXJyYXkgJiYgZnVuY3Rpb24gKGQsIGIpIHsgZC5fX3Byb3RvX18gPSBiOyB9KSB8fA0KICAgICAgICAgICAgZnVuY3Rpb24gKGQsIGIpIHsgZm9yICh2YXIgcCBpbiBiKSBpZiAoT2JqZWN0LnByb3RvdHlwZS5oYXNPd25Qcm9wZXJ0eS5jYWxsKGIsIHApKSBkW3BdID0gYltwXTsgfTsNCiAgICAgICAgcmV0dXJuIGV4dGVuZFN0YXRpY3MoZCwgYik7DQogICAgfTsNCiAgICByZXR1cm4gZnVuY3Rpb24gKGQsIGIpIHsNCiAgICAgICAgZXh0ZW5kU3RhdGljcyhkLCBiKTsNCiAgICAgICAgZnVuY3Rpb24gX18oKSB7IHRoaXMuY29uc3RydWN0b3IgPSBkOyB9DQogICAgICAgIGQucHJvdG90eXBlID0gYiA9PT0gbnVsbCA/IE9iamVjdC5jcmVhdGUoYikgOiAoX18ucHJvdG90eXBlID0gYi5wcm90b3R5cGUsIG5ldyBfXygpKTsNCiAgICB9Ow0KfSkoKTsNCmRlZmluZSgicmVmL2EiLCBbInJlcXVpcmUiLCAiZXhwb3J0cyJdLCBmdW5jdGlvbiAocmVxdWlyZSwgZXhwb3J0cykgew0KICAgICJ1c2Ugc3RyaWN0IjsNCiAgICBPYmplY3QuZGVmaW5lUHJvcGVydHkoZXhwb3J0cywgIl9fZXNNb2R1bGUiLCB7IHZhbHVlOiB0cnVlIH0pOw0KICAgIGV4cG9ydHMuQSA9IHZvaWQgMDsNCiAgICB2YXIgQSA9IC8qKiBAY2xhc3MgKi8gKGZ1bmN0aW9uICgpIHsNCiAgICAgICAgZnVuY3Rpb24gQSgpIHsNCiAgICAgICAgfQ0KICAgICAgICByZXR1cm4gQTsNCiAgICB9KCkpOw0KICAgIGV4cG9ydHMuQSA9IEE7DQp9KTsNCmRlZmluZSgiYiIsIFsicmVxdWlyZSIsICJleHBvcnRzIiwgInJlZi9hIl0sIGZ1bmN0aW9uIChyZXF1aXJlLCBleHBvcnRzLCBhXzEpIHsNCiAgICAidXNlIHN0cmljdCI7DQogICAgT2JqZWN0LmRlZmluZVByb3BlcnR5KGV4cG9ydHMsICJfX2VzTW9kdWxlIiwgeyB2YWx1ZTogdHJ1ZSB9KTsNCiAgICBleHBvcnRzLkIgPSB2b2lkIDA7DQogICAgdmFyIEIgPSAvKiogQGNsYXNzICovIChmdW5jdGlvbiAoX3N1cGVyKSB7DQogICAgICAgIF9fZXh0ZW5kcyhCLCBfc3VwZXIpOw0KICAgICAgICBmdW5jdGlvbiBCKCkgew0KICAgICAgICAgICAgcmV0dXJuIF9zdXBlciAhPT0gbnVsbCAmJiBfc3VwZXIuYXBwbHkodGhpcywgYXJndW1lbnRzKSB8fCB0aGlzOw0KICAgICAgICB9DQogICAgICAgIHJldHVybiBCOw0KICAgIH0oYV8xLkEpKTsNCiAgICBleHBvcnRzLkIgPSBCOw0KfSk7DQovLyMgc291cmNlTWFwcGluZ1VSTD1hbGwuanMubWFw,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYWxsLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsidGVzdHMvY2FzZXMvY29tcGlsZXIvcmVmL2EudHMiLCJ0ZXN0cy9jYXNlcy9jb21waWxlci9iLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7Ozs7Ozs7Ozs7Ozs7O0lBQUE7UUFBQTtRQUFpQixDQUFDO1FBQUQsUUFBQztJQUFELENBQUMsQUFBbEIsSUFBa0I7SUFBTCxjQUFDOzs7Ozs7SUNDZDtRQUF1QixxQkFBQztRQUF4Qjs7UUFBMkIsQ0FBQztRQUFELFFBQUM7SUFBRCxDQUFDLEFBQTVCLENBQXVCLEtBQUMsR0FBSTtJQUFmLGNBQUMifQ==,ZXhwb3J0IGNsYXNzIEEgeyB9Cg==,aW1wb3J0IHtBfSBmcm9tICIuL3JlZi9hIjsKZXhwb3J0IGNsYXNzIEIgZXh0ZW5kcyBBIHsgfQ== diff --git a/tests/baselines/reference/outModuleConcatAmd.sourcemap.txt b/tests/baselines/reference/outModuleConcatAmd.sourcemap.txt index 98fe55766af..70614855a0b 100644 --- a/tests/baselines/reference/outModuleConcatAmd.sourcemap.txt +++ b/tests/baselines/reference/outModuleConcatAmd.sourcemap.txt @@ -12,7 +12,7 @@ sourceFile:tests/cases/compiler/ref/a.ts >>> var extendStatics = function (d, b) { >>> extendStatics = Object.setPrototypeOf || >>> ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || ->>> function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; +>>> function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; >>> return extendStatics(d, b); >>> }; >>> return function (d, b) { diff --git a/tests/baselines/reference/outModuleConcatSystem.js b/tests/baselines/reference/outModuleConcatSystem.js index b566b887736..34cbdb19603 100644 --- a/tests/baselines/reference/outModuleConcatSystem.js +++ b/tests/baselines/reference/outModuleConcatSystem.js @@ -12,7 +12,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/outModuleConcatSystem.js.map b/tests/baselines/reference/outModuleConcatSystem.js.map index 9f2bee320f1..4d775bea4f0 100644 --- a/tests/baselines/reference/outModuleConcatSystem.js.map +++ b/tests/baselines/reference/outModuleConcatSystem.js.map @@ -1,3 +1,3 @@ //// [all.js.map] {"version":3,"file":"all.js","sourceRoot":"","sources":["tests/cases/compiler/ref/a.ts","tests/cases/compiler/b.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;YAAA;gBAAA;gBAAiB,CAAC;gBAAD,QAAC;YAAD,CAAC,AAAlB,IAAkB;;QAClB,CAAC;;;;;;;;;;;;;;YCAD;gBAAuB,qBAAC;gBAAxB;;gBAA2B,CAAC;gBAAD,QAAC;YAAD,CAAC,AAA5B,CAAuB,KAAC,GAAI;;QAAA,CAAC"} -//// https://sokra.github.io/source-map-visualization#base64,dmFyIF9fZXh0ZW5kcyA9ICh0aGlzICYmIHRoaXMuX19leHRlbmRzKSB8fCAoZnVuY3Rpb24gKCkgew0KICAgIHZhciBleHRlbmRTdGF0aWNzID0gZnVuY3Rpb24gKGQsIGIpIHsNCiAgICAgICAgZXh0ZW5kU3RhdGljcyA9IE9iamVjdC5zZXRQcm90b3R5cGVPZiB8fA0KICAgICAgICAgICAgKHsgX19wcm90b19fOiBbXSB9IGluc3RhbmNlb2YgQXJyYXkgJiYgZnVuY3Rpb24gKGQsIGIpIHsgZC5fX3Byb3RvX18gPSBiOyB9KSB8fA0KICAgICAgICAgICAgZnVuY3Rpb24gKGQsIGIpIHsgZm9yICh2YXIgcCBpbiBiKSBpZiAoYi5oYXNPd25Qcm9wZXJ0eShwKSkgZFtwXSA9IGJbcF07IH07DQogICAgICAgIHJldHVybiBleHRlbmRTdGF0aWNzKGQsIGIpOw0KICAgIH07DQogICAgcmV0dXJuIGZ1bmN0aW9uIChkLCBiKSB7DQogICAgICAgIGV4dGVuZFN0YXRpY3MoZCwgYik7DQogICAgICAgIGZ1bmN0aW9uIF9fKCkgeyB0aGlzLmNvbnN0cnVjdG9yID0gZDsgfQ0KICAgICAgICBkLnByb3RvdHlwZSA9IGIgPT09IG51bGwgPyBPYmplY3QuY3JlYXRlKGIpIDogKF9fLnByb3RvdHlwZSA9IGIucHJvdG90eXBlLCBuZXcgX18oKSk7DQogICAgfTsNCn0pKCk7DQpTeXN0ZW0ucmVnaXN0ZXIoInJlZi9hIiwgW10sIGZ1bmN0aW9uIChleHBvcnRzXzEsIGNvbnRleHRfMSkgew0KICAgICJ1c2Ugc3RyaWN0IjsNCiAgICB2YXIgQTsNCiAgICB2YXIgX19tb2R1bGVOYW1lID0gY29udGV4dF8xICYmIGNvbnRleHRfMS5pZDsNCiAgICByZXR1cm4gew0KICAgICAgICBzZXR0ZXJzOiBbXSwNCiAgICAgICAgZXhlY3V0ZTogZnVuY3Rpb24gKCkgew0KICAgICAgICAgICAgQSA9IC8qKiBAY2xhc3MgKi8gKGZ1bmN0aW9uICgpIHsNCiAgICAgICAgICAgICAgICBmdW5jdGlvbiBBKCkgew0KICAgICAgICAgICAgICAgIH0NCiAgICAgICAgICAgICAgICByZXR1cm4gQTsNCiAgICAgICAgICAgIH0oKSk7DQogICAgICAgICAgICBleHBvcnRzXzEoIkEiLCBBKTsNCiAgICAgICAgfQ0KICAgIH07DQp9KTsNClN5c3RlbS5yZWdpc3RlcigiYiIsIFsicmVmL2EiXSwgZnVuY3Rpb24gKGV4cG9ydHNfMiwgY29udGV4dF8yKSB7DQogICAgInVzZSBzdHJpY3QiOw0KICAgIHZhciBhXzEsIEI7DQogICAgdmFyIF9fbW9kdWxlTmFtZSA9IGNvbnRleHRfMiAmJiBjb250ZXh0XzIuaWQ7DQogICAgcmV0dXJuIHsNCiAgICAgICAgc2V0dGVyczogWw0KICAgICAgICAgICAgZnVuY3Rpb24gKGFfMV8xKSB7DQogICAgICAgICAgICAgICAgYV8xID0gYV8xXzE7DQogICAgICAgICAgICB9DQogICAgICAgIF0sDQogICAgICAgIGV4ZWN1dGU6IGZ1bmN0aW9uICgpIHsNCiAgICAgICAgICAgIEIgPSAvKiogQGNsYXNzICovIChmdW5jdGlvbiAoX3N1cGVyKSB7DQogICAgICAgICAgICAgICAgX19leHRlbmRzKEIsIF9zdXBlcik7DQogICAgICAgICAgICAgICAgZnVuY3Rpb24gQigpIHsNCiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIF9zdXBlciAhPT0gbnVsbCAmJiBfc3VwZXIuYXBwbHkodGhpcywgYXJndW1lbnRzKSB8fCB0aGlzOw0KICAgICAgICAgICAgICAgIH0NCiAgICAgICAgICAgICAgICByZXR1cm4gQjsNCiAgICAgICAgICAgIH0oYV8xLkEpKTsNCiAgICAgICAgICAgIGV4cG9ydHNfMigiQiIsIEIpOw0KICAgICAgICB9DQogICAgfTsNCn0pOw0KLy8jIHNvdXJjZU1hcHBpbmdVUkw9YWxsLmpzLm1hcA==,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYWxsLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsidGVzdHMvY2FzZXMvY29tcGlsZXIvcmVmL2EudHMiLCJ0ZXN0cy9jYXNlcy9jb21waWxlci9iLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7O1lBQUE7Z0JBQUE7Z0JBQWlCLENBQUM7Z0JBQUQsUUFBQztZQUFELENBQUMsQUFBbEIsSUFBa0I7O1FBQ2xCLENBQUM7Ozs7Ozs7Ozs7Ozs7O1lDQUQ7Z0JBQXVCLHFCQUFDO2dCQUF4Qjs7Z0JBQTJCLENBQUM7Z0JBQUQsUUFBQztZQUFELENBQUMsQUFBNUIsQ0FBdUIsS0FBQyxHQUFJOztRQUFBLENBQUMifQ==,ZXhwb3J0IGNsYXNzIEEgeyB9Cg==,aW1wb3J0IHtBfSBmcm9tICIuL3JlZi9hIjsKZXhwb3J0IGNsYXNzIEIgZXh0ZW5kcyBBIHsgfQ== +//// https://sokra.github.io/source-map-visualization#base64,dmFyIF9fZXh0ZW5kcyA9ICh0aGlzICYmIHRoaXMuX19leHRlbmRzKSB8fCAoZnVuY3Rpb24gKCkgew0KICAgIHZhciBleHRlbmRTdGF0aWNzID0gZnVuY3Rpb24gKGQsIGIpIHsNCiAgICAgICAgZXh0ZW5kU3RhdGljcyA9IE9iamVjdC5zZXRQcm90b3R5cGVPZiB8fA0KICAgICAgICAgICAgKHsgX19wcm90b19fOiBbXSB9IGluc3RhbmNlb2YgQXJyYXkgJiYgZnVuY3Rpb24gKGQsIGIpIHsgZC5fX3Byb3RvX18gPSBiOyB9KSB8fA0KICAgICAgICAgICAgZnVuY3Rpb24gKGQsIGIpIHsgZm9yICh2YXIgcCBpbiBiKSBpZiAoT2JqZWN0LnByb3RvdHlwZS5oYXNPd25Qcm9wZXJ0eS5jYWxsKGIsIHApKSBkW3BdID0gYltwXTsgfTsNCiAgICAgICAgcmV0dXJuIGV4dGVuZFN0YXRpY3MoZCwgYik7DQogICAgfTsNCiAgICByZXR1cm4gZnVuY3Rpb24gKGQsIGIpIHsNCiAgICAgICAgZXh0ZW5kU3RhdGljcyhkLCBiKTsNCiAgICAgICAgZnVuY3Rpb24gX18oKSB7IHRoaXMuY29uc3RydWN0b3IgPSBkOyB9DQogICAgICAgIGQucHJvdG90eXBlID0gYiA9PT0gbnVsbCA/IE9iamVjdC5jcmVhdGUoYikgOiAoX18ucHJvdG90eXBlID0gYi5wcm90b3R5cGUsIG5ldyBfXygpKTsNCiAgICB9Ow0KfSkoKTsNClN5c3RlbS5yZWdpc3RlcigicmVmL2EiLCBbXSwgZnVuY3Rpb24gKGV4cG9ydHNfMSwgY29udGV4dF8xKSB7DQogICAgInVzZSBzdHJpY3QiOw0KICAgIHZhciBBOw0KICAgIHZhciBfX21vZHVsZU5hbWUgPSBjb250ZXh0XzEgJiYgY29udGV4dF8xLmlkOw0KICAgIHJldHVybiB7DQogICAgICAgIHNldHRlcnM6IFtdLA0KICAgICAgICBleGVjdXRlOiBmdW5jdGlvbiAoKSB7DQogICAgICAgICAgICBBID0gLyoqIEBjbGFzcyAqLyAoZnVuY3Rpb24gKCkgew0KICAgICAgICAgICAgICAgIGZ1bmN0aW9uIEEoKSB7DQogICAgICAgICAgICAgICAgfQ0KICAgICAgICAgICAgICAgIHJldHVybiBBOw0KICAgICAgICAgICAgfSgpKTsNCiAgICAgICAgICAgIGV4cG9ydHNfMSgiQSIsIEEpOw0KICAgICAgICB9DQogICAgfTsNCn0pOw0KU3lzdGVtLnJlZ2lzdGVyKCJiIiwgWyJyZWYvYSJdLCBmdW5jdGlvbiAoZXhwb3J0c18yLCBjb250ZXh0XzIpIHsNCiAgICAidXNlIHN0cmljdCI7DQogICAgdmFyIGFfMSwgQjsNCiAgICB2YXIgX19tb2R1bGVOYW1lID0gY29udGV4dF8yICYmIGNvbnRleHRfMi5pZDsNCiAgICByZXR1cm4gew0KICAgICAgICBzZXR0ZXJzOiBbDQogICAgICAgICAgICBmdW5jdGlvbiAoYV8xXzEpIHsNCiAgICAgICAgICAgICAgICBhXzEgPSBhXzFfMTsNCiAgICAgICAgICAgIH0NCiAgICAgICAgXSwNCiAgICAgICAgZXhlY3V0ZTogZnVuY3Rpb24gKCkgew0KICAgICAgICAgICAgQiA9IC8qKiBAY2xhc3MgKi8gKGZ1bmN0aW9uIChfc3VwZXIpIHsNCiAgICAgICAgICAgICAgICBfX2V4dGVuZHMoQiwgX3N1cGVyKTsNCiAgICAgICAgICAgICAgICBmdW5jdGlvbiBCKCkgew0KICAgICAgICAgICAgICAgICAgICByZXR1cm4gX3N1cGVyICE9PSBudWxsICYmIF9zdXBlci5hcHBseSh0aGlzLCBhcmd1bWVudHMpIHx8IHRoaXM7DQogICAgICAgICAgICAgICAgfQ0KICAgICAgICAgICAgICAgIHJldHVybiBCOw0KICAgICAgICAgICAgfShhXzEuQSkpOw0KICAgICAgICAgICAgZXhwb3J0c18yKCJCIiwgQik7DQogICAgICAgIH0NCiAgICB9Ow0KfSk7DQovLyMgc291cmNlTWFwcGluZ1VSTD1hbGwuanMubWFw,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYWxsLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsidGVzdHMvY2FzZXMvY29tcGlsZXIvcmVmL2EudHMiLCJ0ZXN0cy9jYXNlcy9jb21waWxlci9iLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7O1lBQUE7Z0JBQUE7Z0JBQWlCLENBQUM7Z0JBQUQsUUFBQztZQUFELENBQUMsQUFBbEIsSUFBa0I7O1FBQ2xCLENBQUM7Ozs7Ozs7Ozs7Ozs7O1lDQUQ7Z0JBQXVCLHFCQUFDO2dCQUF4Qjs7Z0JBQTJCLENBQUM7Z0JBQUQsUUFBQztZQUFELENBQUMsQUFBNUIsQ0FBdUIsS0FBQyxHQUFJOztRQUFBLENBQUMifQ==,ZXhwb3J0IGNsYXNzIEEgeyB9Cg==,aW1wb3J0IHtBfSBmcm9tICIuL3JlZi9hIjsKZXhwb3J0IGNsYXNzIEIgZXh0ZW5kcyBBIHsgfQ== diff --git a/tests/baselines/reference/outModuleConcatSystem.sourcemap.txt b/tests/baselines/reference/outModuleConcatSystem.sourcemap.txt index 08aa323aa83..1aa4c5df345 100644 --- a/tests/baselines/reference/outModuleConcatSystem.sourcemap.txt +++ b/tests/baselines/reference/outModuleConcatSystem.sourcemap.txt @@ -12,7 +12,7 @@ sourceFile:tests/cases/compiler/ref/a.ts >>> var extendStatics = function (d, b) { >>> extendStatics = Object.setPrototypeOf || >>> ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || ->>> function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; +>>> function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; >>> return extendStatics(d, b); >>> }; >>> return function (d, b) { diff --git a/tests/baselines/reference/outModuleTripleSlashRefs.js b/tests/baselines/reference/outModuleTripleSlashRefs.js index 9e9beae947a..e6a88420320 100644 --- a/tests/baselines/reference/outModuleTripleSlashRefs.js +++ b/tests/baselines/reference/outModuleTripleSlashRefs.js @@ -34,7 +34,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/outModuleTripleSlashRefs.js.map b/tests/baselines/reference/outModuleTripleSlashRefs.js.map index 7153346631a..5420dc3dd71 100644 --- a/tests/baselines/reference/outModuleTripleSlashRefs.js.map +++ b/tests/baselines/reference/outModuleTripleSlashRefs.js.map @@ -1,3 +1,3 @@ //// [all.js.map] {"version":3,"file":"all.js","sourceRoot":"","sources":["tests/cases/compiler/ref/b.ts","tests/cases/compiler/ref/a.ts","tests/cases/compiler/b.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,iCAAiC;AACjC;IAAA;IAEA,CAAC;IAAD,UAAC;AAAD,CAAC,AAFD,IAEC;;;;;ICHD,+BAA+B;IAC/B;QAAA;QAEA,CAAC;QAAD,QAAC;IAAD,CAAC,AAFD,IAEC;IAFY,cAAC;;;;;;ICAd;QAAuB,qBAAC;QAAxB;;QAA2B,CAAC;QAAD,QAAC;IAAD,CAAC,AAA5B,CAAuB,KAAC,GAAI;IAAf,cAAC"} -//// https://sokra.github.io/source-map-visualization#base64,dmFyIF9fZXh0ZW5kcyA9ICh0aGlzICYmIHRoaXMuX19leHRlbmRzKSB8fCAoZnVuY3Rpb24gKCkgew0KICAgIHZhciBleHRlbmRTdGF0aWNzID0gZnVuY3Rpb24gKGQsIGIpIHsNCiAgICAgICAgZXh0ZW5kU3RhdGljcyA9IE9iamVjdC5zZXRQcm90b3R5cGVPZiB8fA0KICAgICAgICAgICAgKHsgX19wcm90b19fOiBbXSB9IGluc3RhbmNlb2YgQXJyYXkgJiYgZnVuY3Rpb24gKGQsIGIpIHsgZC5fX3Byb3RvX18gPSBiOyB9KSB8fA0KICAgICAgICAgICAgZnVuY3Rpb24gKGQsIGIpIHsgZm9yICh2YXIgcCBpbiBiKSBpZiAoYi5oYXNPd25Qcm9wZXJ0eShwKSkgZFtwXSA9IGJbcF07IH07DQogICAgICAgIHJldHVybiBleHRlbmRTdGF0aWNzKGQsIGIpOw0KICAgIH07DQogICAgcmV0dXJuIGZ1bmN0aW9uIChkLCBiKSB7DQogICAgICAgIGV4dGVuZFN0YXRpY3MoZCwgYik7DQogICAgICAgIGZ1bmN0aW9uIF9fKCkgeyB0aGlzLmNvbnN0cnVjdG9yID0gZDsgfQ0KICAgICAgICBkLnByb3RvdHlwZSA9IGIgPT09IG51bGwgPyBPYmplY3QuY3JlYXRlKGIpIDogKF9fLnByb3RvdHlwZSA9IGIucHJvdG90eXBlLCBuZXcgX18oKSk7DQogICAgfTsNCn0pKCk7DQovLy8gPHJlZmVyZW5jZSBwYXRoPSIuL2MuZC50cyIgLz4NCnZhciBGb28gPSAvKiogQGNsYXNzICovIChmdW5jdGlvbiAoKSB7DQogICAgZnVuY3Rpb24gRm9vKCkgew0KICAgIH0NCiAgICByZXR1cm4gRm9vOw0KfSgpKTsNCmRlZmluZSgicmVmL2EiLCBbInJlcXVpcmUiLCAiZXhwb3J0cyJdLCBmdW5jdGlvbiAocmVxdWlyZSwgZXhwb3J0cykgew0KICAgICJ1c2Ugc3RyaWN0IjsNCiAgICBPYmplY3QuZGVmaW5lUHJvcGVydHkoZXhwb3J0cywgIl9fZXNNb2R1bGUiLCB7IHZhbHVlOiB0cnVlIH0pOw0KICAgIGV4cG9ydHMuQSA9IHZvaWQgMDsNCiAgICAvLy8gPHJlZmVyZW5jZSBwYXRoPSIuL2IudHMiIC8+DQogICAgdmFyIEEgPSAvKiogQGNsYXNzICovIChmdW5jdGlvbiAoKSB7DQogICAgICAgIGZ1bmN0aW9uIEEoKSB7DQogICAgICAgIH0NCiAgICAgICAgcmV0dXJuIEE7DQogICAgfSgpKTsNCiAgICBleHBvcnRzLkEgPSBBOw0KfSk7DQpkZWZpbmUoImIiLCBbInJlcXVpcmUiLCAiZXhwb3J0cyIsICJyZWYvYSJdLCBmdW5jdGlvbiAocmVxdWlyZSwgZXhwb3J0cywgYV8xKSB7DQogICAgInVzZSBzdHJpY3QiOw0KICAgIE9iamVjdC5kZWZpbmVQcm9wZXJ0eShleHBvcnRzLCAiX19lc01vZHVsZSIsIHsgdmFsdWU6IHRydWUgfSk7DQogICAgZXhwb3J0cy5CID0gdm9pZCAwOw0KICAgIHZhciBCID0gLyoqIEBjbGFzcyAqLyAoZnVuY3Rpb24gKF9zdXBlcikgew0KICAgICAgICBfX2V4dGVuZHMoQiwgX3N1cGVyKTsNCiAgICAgICAgZnVuY3Rpb24gQigpIHsNCiAgICAgICAgICAgIHJldHVybiBfc3VwZXIgIT09IG51bGwgJiYgX3N1cGVyLmFwcGx5KHRoaXMsIGFyZ3VtZW50cykgfHwgdGhpczsNCiAgICAgICAgfQ0KICAgICAgICByZXR1cm4gQjsNCiAgICB9KGFfMS5BKSk7DQogICAgZXhwb3J0cy5CID0gQjsNCn0pOw0KLy8jIHNvdXJjZU1hcHBpbmdVUkw9YWxsLmpzLm1hcA==,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYWxsLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsidGVzdHMvY2FzZXMvY29tcGlsZXIvcmVmL2IudHMiLCJ0ZXN0cy9jYXNlcy9jb21waWxlci9yZWYvYS50cyIsInRlc3RzL2Nhc2VzL2NvbXBpbGVyL2IudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7Ozs7Ozs7Ozs7OztBQUFBLGlDQUFpQztBQUNqQztJQUFBO0lBRUEsQ0FBQztJQUFELFVBQUM7QUFBRCxDQUFDLEFBRkQsSUFFQzs7Ozs7SUNIRCwrQkFBK0I7SUFDL0I7UUFBQTtRQUVBLENBQUM7UUFBRCxRQUFDO0lBQUQsQ0FBQyxBQUZELElBRUM7SUFGWSxjQUFDOzs7Ozs7SUNBZDtRQUF1QixxQkFBQztRQUF4Qjs7UUFBMkIsQ0FBQztRQUFELFFBQUM7SUFBRCxDQUFDLEFBQTVCLENBQXVCLEtBQUMsR0FBSTtJQUFmLGNBQUMifQ==,Ly8vIDxyZWZlcmVuY2UgcGF0aD0iLi9jLmQudHMiIC8+CmNsYXNzIEZvbyB7CgltZW1iZXI6IEJhcjsKfQpkZWNsYXJlIHZhciBHbG9iYWxGb286IEZvbzsK,Ly8vIDxyZWZlcmVuY2UgcGF0aD0iLi9iLnRzIiAvPgpleHBvcnQgY2xhc3MgQSB7CgltZW1iZXI6IHR5cGVvZiBHbG9iYWxGb287Cn0K,aW1wb3J0IHtBfSBmcm9tICIuL3JlZi9hIjsKZXhwb3J0IGNsYXNzIEIgZXh0ZW5kcyBBIHsgfQo= +//// https://sokra.github.io/source-map-visualization#base64,dmFyIF9fZXh0ZW5kcyA9ICh0aGlzICYmIHRoaXMuX19leHRlbmRzKSB8fCAoZnVuY3Rpb24gKCkgew0KICAgIHZhciBleHRlbmRTdGF0aWNzID0gZnVuY3Rpb24gKGQsIGIpIHsNCiAgICAgICAgZXh0ZW5kU3RhdGljcyA9IE9iamVjdC5zZXRQcm90b3R5cGVPZiB8fA0KICAgICAgICAgICAgKHsgX19wcm90b19fOiBbXSB9IGluc3RhbmNlb2YgQXJyYXkgJiYgZnVuY3Rpb24gKGQsIGIpIHsgZC5fX3Byb3RvX18gPSBiOyB9KSB8fA0KICAgICAgICAgICAgZnVuY3Rpb24gKGQsIGIpIHsgZm9yICh2YXIgcCBpbiBiKSBpZiAoT2JqZWN0LnByb3RvdHlwZS5oYXNPd25Qcm9wZXJ0eS5jYWxsKGIsIHApKSBkW3BdID0gYltwXTsgfTsNCiAgICAgICAgcmV0dXJuIGV4dGVuZFN0YXRpY3MoZCwgYik7DQogICAgfTsNCiAgICByZXR1cm4gZnVuY3Rpb24gKGQsIGIpIHsNCiAgICAgICAgZXh0ZW5kU3RhdGljcyhkLCBiKTsNCiAgICAgICAgZnVuY3Rpb24gX18oKSB7IHRoaXMuY29uc3RydWN0b3IgPSBkOyB9DQogICAgICAgIGQucHJvdG90eXBlID0gYiA9PT0gbnVsbCA/IE9iamVjdC5jcmVhdGUoYikgOiAoX18ucHJvdG90eXBlID0gYi5wcm90b3R5cGUsIG5ldyBfXygpKTsNCiAgICB9Ow0KfSkoKTsNCi8vLyA8cmVmZXJlbmNlIHBhdGg9Ii4vYy5kLnRzIiAvPg0KdmFyIEZvbyA9IC8qKiBAY2xhc3MgKi8gKGZ1bmN0aW9uICgpIHsNCiAgICBmdW5jdGlvbiBGb28oKSB7DQogICAgfQ0KICAgIHJldHVybiBGb287DQp9KCkpOw0KZGVmaW5lKCJyZWYvYSIsIFsicmVxdWlyZSIsICJleHBvcnRzIl0sIGZ1bmN0aW9uIChyZXF1aXJlLCBleHBvcnRzKSB7DQogICAgInVzZSBzdHJpY3QiOw0KICAgIE9iamVjdC5kZWZpbmVQcm9wZXJ0eShleHBvcnRzLCAiX19lc01vZHVsZSIsIHsgdmFsdWU6IHRydWUgfSk7DQogICAgZXhwb3J0cy5BID0gdm9pZCAwOw0KICAgIC8vLyA8cmVmZXJlbmNlIHBhdGg9Ii4vYi50cyIgLz4NCiAgICB2YXIgQSA9IC8qKiBAY2xhc3MgKi8gKGZ1bmN0aW9uICgpIHsNCiAgICAgICAgZnVuY3Rpb24gQSgpIHsNCiAgICAgICAgfQ0KICAgICAgICByZXR1cm4gQTsNCiAgICB9KCkpOw0KICAgIGV4cG9ydHMuQSA9IEE7DQp9KTsNCmRlZmluZSgiYiIsIFsicmVxdWlyZSIsICJleHBvcnRzIiwgInJlZi9hIl0sIGZ1bmN0aW9uIChyZXF1aXJlLCBleHBvcnRzLCBhXzEpIHsNCiAgICAidXNlIHN0cmljdCI7DQogICAgT2JqZWN0LmRlZmluZVByb3BlcnR5KGV4cG9ydHMsICJfX2VzTW9kdWxlIiwgeyB2YWx1ZTogdHJ1ZSB9KTsNCiAgICBleHBvcnRzLkIgPSB2b2lkIDA7DQogICAgdmFyIEIgPSAvKiogQGNsYXNzICovIChmdW5jdGlvbiAoX3N1cGVyKSB7DQogICAgICAgIF9fZXh0ZW5kcyhCLCBfc3VwZXIpOw0KICAgICAgICBmdW5jdGlvbiBCKCkgew0KICAgICAgICAgICAgcmV0dXJuIF9zdXBlciAhPT0gbnVsbCAmJiBfc3VwZXIuYXBwbHkodGhpcywgYXJndW1lbnRzKSB8fCB0aGlzOw0KICAgICAgICB9DQogICAgICAgIHJldHVybiBCOw0KICAgIH0oYV8xLkEpKTsNCiAgICBleHBvcnRzLkIgPSBCOw0KfSk7DQovLyMgc291cmNlTWFwcGluZ1VSTD1hbGwuanMubWFw,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYWxsLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsidGVzdHMvY2FzZXMvY29tcGlsZXIvcmVmL2IudHMiLCJ0ZXN0cy9jYXNlcy9jb21waWxlci9yZWYvYS50cyIsInRlc3RzL2Nhc2VzL2NvbXBpbGVyL2IudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7Ozs7Ozs7Ozs7OztBQUFBLGlDQUFpQztBQUNqQztJQUFBO0lBRUEsQ0FBQztJQUFELFVBQUM7QUFBRCxDQUFDLEFBRkQsSUFFQzs7Ozs7SUNIRCwrQkFBK0I7SUFDL0I7UUFBQTtRQUVBLENBQUM7UUFBRCxRQUFDO0lBQUQsQ0FBQyxBQUZELElBRUM7SUFGWSxjQUFDOzs7Ozs7SUNBZDtRQUF1QixxQkFBQztRQUF4Qjs7UUFBMkIsQ0FBQztRQUFELFFBQUM7SUFBRCxDQUFDLEFBQTVCLENBQXVCLEtBQUMsR0FBSTtJQUFmLGNBQUMifQ==,Ly8vIDxyZWZlcmVuY2UgcGF0aD0iLi9jLmQudHMiIC8+CmNsYXNzIEZvbyB7CgltZW1iZXI6IEJhcjsKfQpkZWNsYXJlIHZhciBHbG9iYWxGb286IEZvbzsK,Ly8vIDxyZWZlcmVuY2UgcGF0aD0iLi9iLnRzIiAvPgpleHBvcnQgY2xhc3MgQSB7CgltZW1iZXI6IHR5cGVvZiBHbG9iYWxGb287Cn0K,aW1wb3J0IHtBfSBmcm9tICIuL3JlZi9hIjsKZXhwb3J0IGNsYXNzIEIgZXh0ZW5kcyBBIHsgfQo= diff --git a/tests/baselines/reference/outModuleTripleSlashRefs.sourcemap.txt b/tests/baselines/reference/outModuleTripleSlashRefs.sourcemap.txt index e148cb692a4..a32b83c2ec7 100644 --- a/tests/baselines/reference/outModuleTripleSlashRefs.sourcemap.txt +++ b/tests/baselines/reference/outModuleTripleSlashRefs.sourcemap.txt @@ -12,7 +12,7 @@ sourceFile:tests/cases/compiler/ref/b.ts >>> var extendStatics = function (d, b) { >>> extendStatics = Object.setPrototypeOf || >>> ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || ->>> function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; +>>> function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; >>> return extendStatics(d, b); >>> }; >>> return function (d, b) { diff --git a/tests/baselines/reference/overload1.js b/tests/baselines/reference/overload1.js index 9a14efd2ae6..70e88d8849d 100644 --- a/tests/baselines/reference/overload1.js +++ b/tests/baselines/reference/overload1.js @@ -44,7 +44,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/overloadOnConstConstraintChecks1.js b/tests/baselines/reference/overloadOnConstConstraintChecks1.js index 94bb534a26d..d5c306c082d 100644 --- a/tests/baselines/reference/overloadOnConstConstraintChecks1.js +++ b/tests/baselines/reference/overloadOnConstConstraintChecks1.js @@ -27,7 +27,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/overloadOnConstConstraintChecks2.js b/tests/baselines/reference/overloadOnConstConstraintChecks2.js index d38132dae57..3311562f7b4 100644 --- a/tests/baselines/reference/overloadOnConstConstraintChecks2.js +++ b/tests/baselines/reference/overloadOnConstConstraintChecks2.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/overloadOnConstConstraintChecks3.js b/tests/baselines/reference/overloadOnConstConstraintChecks3.js index 73bcfbb2397..c7db249a26a 100644 --- a/tests/baselines/reference/overloadOnConstConstraintChecks3.js +++ b/tests/baselines/reference/overloadOnConstConstraintChecks3.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/overloadOnConstConstraintChecks4.js b/tests/baselines/reference/overloadOnConstConstraintChecks4.js index b0b8e76eacd..18618c1749f 100644 --- a/tests/baselines/reference/overloadOnConstConstraintChecks4.js +++ b/tests/baselines/reference/overloadOnConstConstraintChecks4.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/overloadOnConstantsInvalidOverload1.js b/tests/baselines/reference/overloadOnConstantsInvalidOverload1.js index 00768a84e42..647e9d1dc1c 100644 --- a/tests/baselines/reference/overloadOnConstantsInvalidOverload1.js +++ b/tests/baselines/reference/overloadOnConstantsInvalidOverload1.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/overloadResolution.js b/tests/baselines/reference/overloadResolution.js index 509483c61be..f009cfa69d0 100644 --- a/tests/baselines/reference/overloadResolution.js +++ b/tests/baselines/reference/overloadResolution.js @@ -99,7 +99,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/overloadResolutionClassConstructors.js b/tests/baselines/reference/overloadResolutionClassConstructors.js index 7c852c21914..ffc75a9ab80 100644 --- a/tests/baselines/reference/overloadResolutionClassConstructors.js +++ b/tests/baselines/reference/overloadResolutionClassConstructors.js @@ -106,7 +106,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/overloadResolutionConstructors.js b/tests/baselines/reference/overloadResolutionConstructors.js index 31a0309ae23..1d3b660f028 100644 --- a/tests/baselines/reference/overloadResolutionConstructors.js +++ b/tests/baselines/reference/overloadResolutionConstructors.js @@ -107,7 +107,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/overloadingOnConstants1.js b/tests/baselines/reference/overloadingOnConstants1.js index 8c742c8fda2..a92a0af138e 100644 --- a/tests/baselines/reference/overloadingOnConstants1.js +++ b/tests/baselines/reference/overloadingOnConstants1.js @@ -30,7 +30,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/overloadingOnConstants2.js b/tests/baselines/reference/overloadingOnConstants2.js index 978f9524a1c..3ad315bfc56 100644 --- a/tests/baselines/reference/overloadingOnConstants2.js +++ b/tests/baselines/reference/overloadingOnConstants2.js @@ -32,7 +32,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/overrideBaseIntersectionMethod.js b/tests/baselines/reference/overrideBaseIntersectionMethod.js index b58c1f78674..57e76190298 100644 --- a/tests/baselines/reference/overrideBaseIntersectionMethod.js +++ b/tests/baselines/reference/overrideBaseIntersectionMethod.js @@ -37,7 +37,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/overridingPrivateStaticMembers.js b/tests/baselines/reference/overridingPrivateStaticMembers.js index 9ced500351f..dfb5033af10 100644 --- a/tests/baselines/reference/overridingPrivateStaticMembers.js +++ b/tests/baselines/reference/overridingPrivateStaticMembers.js @@ -12,7 +12,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/paramTagTypeResolution2.symbols b/tests/baselines/reference/paramTagTypeResolution2.symbols new file mode 100644 index 00000000000..dd1632606cf --- /dev/null +++ b/tests/baselines/reference/paramTagTypeResolution2.symbols @@ -0,0 +1,21 @@ +=== tests/cases/conformance/jsdoc/38572.js === +/** + * @template T + * @param {T} a + * @param {{[K in keyof T]: (value: T[K]) => void }} b + */ +function f(a, b) { +>f : Symbol(f, Decl(38572.js, 0, 0)) +>a : Symbol(a, Decl(38572.js, 5, 11)) +>b : Symbol(b, Decl(38572.js, 5, 13)) +} + +f({ x: 42 }, { x(param) { param.toFixed() } }); +>f : Symbol(f, Decl(38572.js, 0, 0)) +>x : Symbol(x, Decl(38572.js, 8, 3)) +>x : Symbol(x, Decl(38572.js, 8, 14)) +>param : Symbol(param, Decl(38572.js, 8, 17)) +>param.toFixed : Symbol(Number.toFixed, Decl(lib.es5.d.ts, --, --)) +>param : Symbol(param, Decl(38572.js, 8, 17)) +>toFixed : Symbol(Number.toFixed, Decl(lib.es5.d.ts, --, --)) + diff --git a/tests/baselines/reference/paramTagTypeResolution2.types b/tests/baselines/reference/paramTagTypeResolution2.types new file mode 100644 index 00000000000..e3cb0358ed6 --- /dev/null +++ b/tests/baselines/reference/paramTagTypeResolution2.types @@ -0,0 +1,26 @@ +=== tests/cases/conformance/jsdoc/38572.js === +/** + * @template T + * @param {T} a + * @param {{[K in keyof T]: (value: T[K]) => void }} b + */ +function f(a, b) { +>f : (a: T, b: { [K in keyof T]: (value: T[K]) => void; }) => void +>a : T +>b : { [K in keyof T]: (value: T[K]) => void; } +} + +f({ x: 42 }, { x(param) { param.toFixed() } }); +>f({ x: 42 }, { x(param) { param.toFixed() } }) : void +>f : (a: T, b: { [K in keyof T]: (value: T[K]) => void; }) => void +>{ x: 42 } : { x: number; } +>x : number +>42 : 42 +>{ x(param) { param.toFixed() } } : { x(param: number): void; } +>x : (param: number) => void +>param : number +>param.toFixed() : string +>param.toFixed : (fractionDigits?: number) => string +>param : number +>toFixed : (fractionDigits?: number) => string + diff --git a/tests/baselines/reference/parseErrorInHeritageClause1.js b/tests/baselines/reference/parseErrorInHeritageClause1.js index d0d1331e44a..332334d3dd8 100644 --- a/tests/baselines/reference/parseErrorInHeritageClause1.js +++ b/tests/baselines/reference/parseErrorInHeritageClause1.js @@ -7,7 +7,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/parser509630.js b/tests/baselines/reference/parser509630.js index c0d6d667543..a24a6449da5 100644 --- a/tests/baselines/reference/parser509630.js +++ b/tests/baselines/reference/parser509630.js @@ -11,7 +11,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/parserAstSpans1.js b/tests/baselines/reference/parserAstSpans1.js index 0cf04e89a30..459c6a69d3f 100644 --- a/tests/baselines/reference/parserAstSpans1.js +++ b/tests/baselines/reference/parserAstSpans1.js @@ -224,7 +224,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/parserClassDeclaration1.js b/tests/baselines/reference/parserClassDeclaration1.js index 65c9d46babb..2c54a06a175 100644 --- a/tests/baselines/reference/parserClassDeclaration1.js +++ b/tests/baselines/reference/parserClassDeclaration1.js @@ -7,7 +7,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/parserClassDeclaration3.js b/tests/baselines/reference/parserClassDeclaration3.js index 07e15c82f26..d822c79580b 100644 --- a/tests/baselines/reference/parserClassDeclaration3.js +++ b/tests/baselines/reference/parserClassDeclaration3.js @@ -7,7 +7,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/parserClassDeclaration4.js b/tests/baselines/reference/parserClassDeclaration4.js index ce636f307a9..745d6a765f4 100644 --- a/tests/baselines/reference/parserClassDeclaration4.js +++ b/tests/baselines/reference/parserClassDeclaration4.js @@ -7,7 +7,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/parserClassDeclaration5.js b/tests/baselines/reference/parserClassDeclaration5.js index 0d276534cf6..e87607445f0 100644 --- a/tests/baselines/reference/parserClassDeclaration5.js +++ b/tests/baselines/reference/parserClassDeclaration5.js @@ -7,7 +7,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/parserClassDeclaration6.js b/tests/baselines/reference/parserClassDeclaration6.js index 89f5518c86d..a5570bc76fb 100644 --- a/tests/baselines/reference/parserClassDeclaration6.js +++ b/tests/baselines/reference/parserClassDeclaration6.js @@ -7,7 +7,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/parserErrorRecovery_ExtendsOrImplementsClause2.js b/tests/baselines/reference/parserErrorRecovery_ExtendsOrImplementsClause2.js index cb35279660c..97bb668a513 100644 --- a/tests/baselines/reference/parserErrorRecovery_ExtendsOrImplementsClause2.js +++ b/tests/baselines/reference/parserErrorRecovery_ExtendsOrImplementsClause2.js @@ -7,7 +7,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/parserErrorRecovery_ExtendsOrImplementsClause4.js b/tests/baselines/reference/parserErrorRecovery_ExtendsOrImplementsClause4.js index 227af5ebf4d..b5a8c4455f7 100644 --- a/tests/baselines/reference/parserErrorRecovery_ExtendsOrImplementsClause4.js +++ b/tests/baselines/reference/parserErrorRecovery_ExtendsOrImplementsClause4.js @@ -7,7 +7,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/parserErrorRecovery_ExtendsOrImplementsClause5.js b/tests/baselines/reference/parserErrorRecovery_ExtendsOrImplementsClause5.js index 77ba94cd3eb..ca9cc79ac6e 100644 --- a/tests/baselines/reference/parserErrorRecovery_ExtendsOrImplementsClause5.js +++ b/tests/baselines/reference/parserErrorRecovery_ExtendsOrImplementsClause5.js @@ -7,7 +7,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/parserGenericsInTypeContexts1.js b/tests/baselines/reference/parserGenericsInTypeContexts1.js index f221d429b3f..3ca8ac10ded 100644 --- a/tests/baselines/reference/parserGenericsInTypeContexts1.js +++ b/tests/baselines/reference/parserGenericsInTypeContexts1.js @@ -22,7 +22,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/parserGenericsInTypeContexts2.js b/tests/baselines/reference/parserGenericsInTypeContexts2.js index 39b2d2c5e70..4631e0d03bb 100644 --- a/tests/baselines/reference/parserGenericsInTypeContexts2.js +++ b/tests/baselines/reference/parserGenericsInTypeContexts2.js @@ -22,7 +22,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/parserRealSource10.js b/tests/baselines/reference/parserRealSource10.js index 968cecc30ed..bf073e5780d 100644 --- a/tests/baselines/reference/parserRealSource10.js +++ b/tests/baselines/reference/parserRealSource10.js @@ -462,7 +462,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/parserRealSource11.js b/tests/baselines/reference/parserRealSource11.js index cd48bcc4fd6..11f109d234b 100644 --- a/tests/baselines/reference/parserRealSource11.js +++ b/tests/baselines/reference/parserRealSource11.js @@ -2371,7 +2371,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/parserharness.js b/tests/baselines/reference/parserharness.js index 53ae2f28510..2e73e321d13 100644 --- a/tests/baselines/reference/parserharness.js +++ b/tests/baselines/reference/parserharness.js @@ -2100,7 +2100,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/partiallyAnnotatedFunctionInferenceError.js b/tests/baselines/reference/partiallyAnnotatedFunctionInferenceError.js index 8412890ee19..f1e0ff9e5b7 100644 --- a/tests/baselines/reference/partiallyAnnotatedFunctionInferenceError.js +++ b/tests/baselines/reference/partiallyAnnotatedFunctionInferenceError.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/partiallyAnnotatedFunctionInferenceWithTypeParameter.js b/tests/baselines/reference/partiallyAnnotatedFunctionInferenceWithTypeParameter.js index 89f698cff0e..203f4a8e64a 100644 --- a/tests/baselines/reference/partiallyAnnotatedFunctionInferenceWithTypeParameter.js +++ b/tests/baselines/reference/partiallyAnnotatedFunctionInferenceWithTypeParameter.js @@ -39,7 +39,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/primitiveMembers.js b/tests/baselines/reference/primitiveMembers.js index 37a92e41617..5fdcca2178a 100644 --- a/tests/baselines/reference/primitiveMembers.js +++ b/tests/baselines/reference/primitiveMembers.js @@ -36,7 +36,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/privacyClass.js b/tests/baselines/reference/privacyClass.js index c09f3890ca3..7c0f3c0ae5c 100644 --- a/tests/baselines/reference/privacyClass.js +++ b/tests/baselines/reference/privacyClass.js @@ -133,7 +133,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/privacyClassExtendsClauseDeclFile.js b/tests/baselines/reference/privacyClassExtendsClauseDeclFile.js index 0090e03260a..5e08c6927a5 100644 --- a/tests/baselines/reference/privacyClassExtendsClauseDeclFile.js +++ b/tests/baselines/reference/privacyClassExtendsClauseDeclFile.js @@ -102,7 +102,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { @@ -298,7 +298,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/privacyGloClass.js b/tests/baselines/reference/privacyGloClass.js index 3665d45e9f3..1c293eb57e6 100644 --- a/tests/baselines/reference/privacyGloClass.js +++ b/tests/baselines/reference/privacyGloClass.js @@ -65,7 +65,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/privateAccessInSubclass1.js b/tests/baselines/reference/privateAccessInSubclass1.js index 6d6edb5c6a6..c81c13f60b6 100644 --- a/tests/baselines/reference/privateAccessInSubclass1.js +++ b/tests/baselines/reference/privateAccessInSubclass1.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/privateConstructorFunction.symbols b/tests/baselines/reference/privateConstructorFunction.symbols index 32e8406918d..9ed75eead7b 100644 --- a/tests/baselines/reference/privateConstructorFunction.symbols +++ b/tests/baselines/reference/privateConstructorFunction.symbols @@ -8,6 +8,8 @@ >C : Symbol(C, Decl(privateConstructorFunction.js, 0, 1)) this.x = 1 +>this.x : Symbol(C.x, Decl(privateConstructorFunction.js, 5, 18)) +>this : Symbol(C, Decl(privateConstructorFunction.js, 0, 1)) >x : Symbol(C.x, Decl(privateConstructorFunction.js, 5, 18)) } new C() diff --git a/tests/baselines/reference/privateConstructorFunction.types b/tests/baselines/reference/privateConstructorFunction.types index 19fae01d8eb..5f4919e57de 100644 --- a/tests/baselines/reference/privateConstructorFunction.types +++ b/tests/baselines/reference/privateConstructorFunction.types @@ -10,7 +10,7 @@ this.x = 1 >this.x = 1 : 1 >this.x : any ->this : any +>this : this >x : any >1 : 1 } diff --git a/tests/baselines/reference/privateInstanceMemberAccessibility.js b/tests/baselines/reference/privateInstanceMemberAccessibility.js index ffcefc92836..95559cc6ff3 100644 --- a/tests/baselines/reference/privateInstanceMemberAccessibility.js +++ b/tests/baselines/reference/privateInstanceMemberAccessibility.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/privateProtectedMembersAreNotAccessibleDestructuring.js b/tests/baselines/reference/privateProtectedMembersAreNotAccessibleDestructuring.js index eb45924bda7..b4f479975e7 100644 --- a/tests/baselines/reference/privateProtectedMembersAreNotAccessibleDestructuring.js +++ b/tests/baselines/reference/privateProtectedMembersAreNotAccessibleDestructuring.js @@ -29,7 +29,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/privateStaticMemberAccessibility.js b/tests/baselines/reference/privateStaticMemberAccessibility.js index 389f614e72c..1bb3f28208c 100644 --- a/tests/baselines/reference/privateStaticMemberAccessibility.js +++ b/tests/baselines/reference/privateStaticMemberAccessibility.js @@ -13,7 +13,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/privateStaticNotAccessibleInClodule2.js b/tests/baselines/reference/privateStaticNotAccessibleInClodule2.js index 2d9007b9501..a788d8aea65 100644 --- a/tests/baselines/reference/privateStaticNotAccessibleInClodule2.js +++ b/tests/baselines/reference/privateStaticNotAccessibleInClodule2.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/project/privacyCheckOnImportedModuleDeclarationsInsideModule/amd/testGlo.js b/tests/baselines/reference/project/privacyCheckOnImportedModuleDeclarationsInsideModule/amd/testGlo.js index 345b99e5672..3c9467ae5ae 100644 --- a/tests/baselines/reference/project/privacyCheckOnImportedModuleDeclarationsInsideModule/amd/testGlo.js +++ b/tests/baselines/reference/project/privacyCheckOnImportedModuleDeclarationsInsideModule/amd/testGlo.js @@ -2,7 +2,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/project/privacyCheckOnImportedModuleDeclarationsInsideModule/node/testGlo.js b/tests/baselines/reference/project/privacyCheckOnImportedModuleDeclarationsInsideModule/node/testGlo.js index 345b99e5672..3c9467ae5ae 100644 --- a/tests/baselines/reference/project/privacyCheckOnImportedModuleDeclarationsInsideModule/node/testGlo.js +++ b/tests/baselines/reference/project/privacyCheckOnImportedModuleDeclarationsInsideModule/node/testGlo.js @@ -2,7 +2,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/project/prologueEmit/amd/out.js b/tests/baselines/reference/project/prologueEmit/amd/out.js index f758fc4a85f..1c47628758d 100644 --- a/tests/baselines/reference/project/prologueEmit/amd/out.js +++ b/tests/baselines/reference/project/prologueEmit/amd/out.js @@ -2,7 +2,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/project/prologueEmit/node/out.js b/tests/baselines/reference/project/prologueEmit/node/out.js index f758fc4a85f..1c47628758d 100644 --- a/tests/baselines/reference/project/prologueEmit/node/out.js +++ b/tests/baselines/reference/project/prologueEmit/node/out.js @@ -2,7 +2,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/project/quotesInFileAndDirectoryNames/amd/m'ain.js b/tests/baselines/reference/project/quotesInFileAndDirectoryNames/amd/m'ain.js index 351bc0f0af6..21a02daa9eb 100644 --- a/tests/baselines/reference/project/quotesInFileAndDirectoryNames/amd/m'ain.js +++ b/tests/baselines/reference/project/quotesInFileAndDirectoryNames/amd/m'ain.js @@ -3,7 +3,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/project/quotesInFileAndDirectoryNames/node/m'ain.js b/tests/baselines/reference/project/quotesInFileAndDirectoryNames/node/m'ain.js index 351bc0f0af6..21a02daa9eb 100644 --- a/tests/baselines/reference/project/quotesInFileAndDirectoryNames/node/m'ain.js +++ b/tests/baselines/reference/project/quotesInFileAndDirectoryNames/node/m'ain.js @@ -3,7 +3,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/propertiesAndIndexers.js b/tests/baselines/reference/propertiesAndIndexers.js index ba5ec00d539..a4ed7e688cc 100644 --- a/tests/baselines/reference/propertiesAndIndexers.js +++ b/tests/baselines/reference/propertiesAndIndexers.js @@ -56,7 +56,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/propertiesOfGenericConstructorFunctions.symbols b/tests/baselines/reference/propertiesOfGenericConstructorFunctions.symbols index 48606c4b15c..62d7c98235f 100644 --- a/tests/baselines/reference/propertiesOfGenericConstructorFunctions.symbols +++ b/tests/baselines/reference/propertiesOfGenericConstructorFunctions.symbols @@ -12,10 +12,14 @@ function Multimap(ik, iv) { /** @type {{ [s: string]: V }} */ this._map = {}; +>this._map : Symbol(Multimap._map, Decl(propertiesOfGenericConstructorFunctions.js, 6, 27)) +>this : Symbol(Multimap, Decl(propertiesOfGenericConstructorFunctions.js, 0, 0)) >_map : Symbol(Multimap._map, Decl(propertiesOfGenericConstructorFunctions.js, 6, 27)) // without type annotation this._map2 = { [ik]: iv }; +>this._map2 : Symbol(Multimap._map2, Decl(propertiesOfGenericConstructorFunctions.js, 8, 19)) +>this : Symbol(Multimap, Decl(propertiesOfGenericConstructorFunctions.js, 0, 0)) >_map2 : Symbol(Multimap._map2, Decl(propertiesOfGenericConstructorFunctions.js, 8, 19)) >[ik] : Symbol([ik], Decl(propertiesOfGenericConstructorFunctions.js, 10, 18)) >ik : Symbol(ik, Decl(propertiesOfGenericConstructorFunctions.js, 6, 18)) diff --git a/tests/baselines/reference/propertiesOfGenericConstructorFunctions.types b/tests/baselines/reference/propertiesOfGenericConstructorFunctions.types index 42bf2ea2e94..8ac0f3f98be 100644 --- a/tests/baselines/reference/propertiesOfGenericConstructorFunctions.types +++ b/tests/baselines/reference/propertiesOfGenericConstructorFunctions.types @@ -13,16 +13,16 @@ function Multimap(ik, iv) { /** @type {{ [s: string]: V }} */ this._map = {}; >this._map = {} : {} ->this._map : any ->this : any ->_map : any +>this._map : { [s: string]: V; } +>this : this +>_map : { [s: string]: V; } >{} : {} // without type annotation this._map2 = { [ik]: iv }; >this._map2 = { [ik]: iv } : { [x: string]: V; } >this._map2 : any ->this : any +>this : this >_map2 : any >{ [ik]: iv } : { [x: string]: V; } >[ik] : V diff --git a/tests/baselines/reference/propertyAccess.js b/tests/baselines/reference/propertyAccess.js index 8681c3fb404..ad0b38e07da 100644 --- a/tests/baselines/reference/propertyAccess.js +++ b/tests/baselines/reference/propertyAccess.js @@ -155,7 +155,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints2.js b/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints2.js index cf5315528db..43eda51678c 100644 --- a/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints2.js +++ b/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints2.js @@ -87,7 +87,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints3.js b/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints3.js index bde85a52f38..308c55b1e9f 100644 --- a/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints3.js +++ b/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints3.js @@ -62,7 +62,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints5.js b/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints5.js index ea74da04fd7..2c0e09ef233 100644 --- a/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints5.js +++ b/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints5.js @@ -49,7 +49,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/propertyAssignmentOnImportedSymbol.symbols b/tests/baselines/reference/propertyAssignmentOnImportedSymbol.symbols index 453816e38cf..f8d01ae6981 100644 --- a/tests/baselines/reference/propertyAssignmentOnImportedSymbol.symbols +++ b/tests/baselines/reference/propertyAssignmentOnImportedSymbol.symbols @@ -4,10 +4,8 @@ export var hurk = {} === tests/cases/conformance/salsa/bug24658.js === import { hurk } from './mod1' ->hurk : Symbol(hurk, Decl(bug24658.js, 0, 8), Decl(bug24658.js, 0, 29)) +>hurk : Symbol(hurk, Decl(bug24658.js, 0, 8)) hurk.expando = 4 ->hurk.expando : Symbol(hurk.expando, Decl(bug24658.js, 0, 29)) ->hurk : Symbol(hurk, Decl(bug24658.js, 0, 8), Decl(bug24658.js, 0, 29)) ->expando : Symbol(hurk.expando, Decl(bug24658.js, 0, 29)) +>hurk : Symbol(hurk, Decl(bug24658.js, 0, 8)) diff --git a/tests/baselines/reference/propertyAssignmentOnImportedSymbol.types b/tests/baselines/reference/propertyAssignmentOnImportedSymbol.types index 53930f09a65..8df4f984574 100644 --- a/tests/baselines/reference/propertyAssignmentOnImportedSymbol.types +++ b/tests/baselines/reference/propertyAssignmentOnImportedSymbol.types @@ -5,12 +5,12 @@ export var hurk = {} === tests/cases/conformance/salsa/bug24658.js === import { hurk } from './mod1' ->hurk : typeof hurk +>hurk : {} hurk.expando = 4 >hurk.expando = 4 : 4 ->hurk.expando : number ->hurk : typeof hurk ->expando : number +>hurk.expando : any +>hurk : {} +>expando : any >4 : 4 diff --git a/tests/baselines/reference/propertyOverridesAccessors4.js b/tests/baselines/reference/propertyOverridesAccessors4.js index 1c284e6aa49..0c990aeea01 100644 --- a/tests/baselines/reference/propertyOverridesAccessors4.js +++ b/tests/baselines/reference/propertyOverridesAccessors4.js @@ -13,7 +13,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/propertyOverridingPrototype.js b/tests/baselines/reference/propertyOverridingPrototype.js index 67d70fb3c35..674e8114527 100644 --- a/tests/baselines/reference/propertyOverridingPrototype.js +++ b/tests/baselines/reference/propertyOverridingPrototype.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/protectedClassPropertyAccessibleWithinNestedSubclass.js b/tests/baselines/reference/protectedClassPropertyAccessibleWithinNestedSubclass.js index 9cc42fa96f1..82e7dd32965 100644 --- a/tests/baselines/reference/protectedClassPropertyAccessibleWithinNestedSubclass.js +++ b/tests/baselines/reference/protectedClassPropertyAccessibleWithinNestedSubclass.js @@ -42,7 +42,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/protectedClassPropertyAccessibleWithinNestedSubclass1.js b/tests/baselines/reference/protectedClassPropertyAccessibleWithinNestedSubclass1.js index cd4a43d05e5..355ae08a85e 100644 --- a/tests/baselines/reference/protectedClassPropertyAccessibleWithinNestedSubclass1.js +++ b/tests/baselines/reference/protectedClassPropertyAccessibleWithinNestedSubclass1.js @@ -119,7 +119,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/protectedClassPropertyAccessibleWithinSubclass.js b/tests/baselines/reference/protectedClassPropertyAccessibleWithinSubclass.js index 18e6100afe1..cb770540736 100644 --- a/tests/baselines/reference/protectedClassPropertyAccessibleWithinSubclass.js +++ b/tests/baselines/reference/protectedClassPropertyAccessibleWithinSubclass.js @@ -25,7 +25,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/protectedClassPropertyAccessibleWithinSubclass2.js b/tests/baselines/reference/protectedClassPropertyAccessibleWithinSubclass2.js index 0d3d47efff3..0e605eebdbc 100644 --- a/tests/baselines/reference/protectedClassPropertyAccessibleWithinSubclass2.js +++ b/tests/baselines/reference/protectedClassPropertyAccessibleWithinSubclass2.js @@ -99,7 +99,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/protectedClassPropertyAccessibleWithinSubclass3.js b/tests/baselines/reference/protectedClassPropertyAccessibleWithinSubclass3.js index e8b32190035..c987b7c6baf 100644 --- a/tests/baselines/reference/protectedClassPropertyAccessibleWithinSubclass3.js +++ b/tests/baselines/reference/protectedClassPropertyAccessibleWithinSubclass3.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/protectedInstanceMemberAccessibility.js b/tests/baselines/reference/protectedInstanceMemberAccessibility.js index a7372dfc15c..6ef90e96d64 100644 --- a/tests/baselines/reference/protectedInstanceMemberAccessibility.js +++ b/tests/baselines/reference/protectedInstanceMemberAccessibility.js @@ -49,7 +49,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/protectedMembers.js b/tests/baselines/reference/protectedMembers.js index b90e487fd21..1cd339c3c6b 100644 --- a/tests/baselines/reference/protectedMembers.js +++ b/tests/baselines/reference/protectedMembers.js @@ -120,7 +120,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/protectedStaticClassPropertyAccessibleWithinSubclass.js b/tests/baselines/reference/protectedStaticClassPropertyAccessibleWithinSubclass.js index 2a7bb5ecaa1..6d99965e1d8 100644 --- a/tests/baselines/reference/protectedStaticClassPropertyAccessibleWithinSubclass.js +++ b/tests/baselines/reference/protectedStaticClassPropertyAccessibleWithinSubclass.js @@ -48,7 +48,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/protectedStaticClassPropertyAccessibleWithinSubclass2.js b/tests/baselines/reference/protectedStaticClassPropertyAccessibleWithinSubclass2.js index 86d5df89867..9d7cccb71b4 100644 --- a/tests/baselines/reference/protectedStaticClassPropertyAccessibleWithinSubclass2.js +++ b/tests/baselines/reference/protectedStaticClassPropertyAccessibleWithinSubclass2.js @@ -26,7 +26,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/prototypePropertyAssignmentMergeAcrossFiles.symbols b/tests/baselines/reference/prototypePropertyAssignmentMergeAcrossFiles.symbols index 087d83cb6b3..8d3f4d9231c 100644 --- a/tests/baselines/reference/prototypePropertyAssignmentMergeAcrossFiles.symbols +++ b/tests/baselines/reference/prototypePropertyAssignmentMergeAcrossFiles.symbols @@ -3,6 +3,8 @@ function C() { >C : Symbol(C, Decl(prototypePropertyAssignmentMergeAcrossFiles.js, 0, 0)) this.a = 1 +>this.a : Symbol(C.a, Decl(prototypePropertyAssignmentMergeAcrossFiles.js, 0, 14)) +>this : Symbol(C, Decl(prototypePropertyAssignmentMergeAcrossFiles.js, 0, 0)) >a : Symbol(C.a, Decl(prototypePropertyAssignmentMergeAcrossFiles.js, 0, 14)) } diff --git a/tests/baselines/reference/prototypePropertyAssignmentMergeAcrossFiles.types b/tests/baselines/reference/prototypePropertyAssignmentMergeAcrossFiles.types index 8e399f618b9..c31cc2c5cc5 100644 --- a/tests/baselines/reference/prototypePropertyAssignmentMergeAcrossFiles.types +++ b/tests/baselines/reference/prototypePropertyAssignmentMergeAcrossFiles.types @@ -5,7 +5,7 @@ function C() { this.a = 1 >this.a = 1 : 1 >this.a : any ->this : any +>this : this >a : any >1 : 1 } diff --git a/tests/baselines/reference/qualifiedName_entity-name-resolution-does-not-affect-class-heritage.js b/tests/baselines/reference/qualifiedName_entity-name-resolution-does-not-affect-class-heritage.js index 8d91be85bbd..28a0f20ff38 100644 --- a/tests/baselines/reference/qualifiedName_entity-name-resolution-does-not-affect-class-heritage.js +++ b/tests/baselines/reference/qualifiedName_entity-name-resolution-does-not-affect-class-heritage.js @@ -11,7 +11,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/reactDefaultPropsInferenceSuccess.js b/tests/baselines/reference/reactDefaultPropsInferenceSuccess.js index a87e225a148..6628f0232b6 100644 --- a/tests/baselines/reference/reactDefaultPropsInferenceSuccess.js +++ b/tests/baselines/reference/reactDefaultPropsInferenceSuccess.js @@ -75,7 +75,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/reactHOCSpreadprops.js b/tests/baselines/reference/reactHOCSpreadprops.js index 45ecbe35f68..d3a33aed92d 100644 --- a/tests/baselines/reference/reactHOCSpreadprops.js +++ b/tests/baselines/reference/reactHOCSpreadprops.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/reactReadonlyHOCAssignabilityReal.js b/tests/baselines/reference/reactReadonlyHOCAssignabilityReal.js index 57f6680e098..ce4b2b5a8ec 100644 --- a/tests/baselines/reference/reactReadonlyHOCAssignabilityReal.js +++ b/tests/baselines/reference/reactReadonlyHOCAssignabilityReal.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/reactReduxLikeDeferredInferenceAllowsAssignment.js b/tests/baselines/reference/reactReduxLikeDeferredInferenceAllowsAssignment.js index 3c2cb0e7626..1073733bd8d 100644 --- a/tests/baselines/reference/reactReduxLikeDeferredInferenceAllowsAssignment.js +++ b/tests/baselines/reference/reactReduxLikeDeferredInferenceAllowsAssignment.js @@ -153,7 +153,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/readonlyAssignmentInSubclassOfClassExpression.js b/tests/baselines/reference/readonlyAssignmentInSubclassOfClassExpression.js index 9807f417017..427c85b247e 100644 --- a/tests/baselines/reference/readonlyAssignmentInSubclassOfClassExpression.js +++ b/tests/baselines/reference/readonlyAssignmentInSubclassOfClassExpression.js @@ -12,7 +12,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/readonlyConstructorAssignment.js b/tests/baselines/reference/readonlyConstructorAssignment.js index 0b42900e5b2..ad0115b7c08 100644 --- a/tests/baselines/reference/readonlyConstructorAssignment.js +++ b/tests/baselines/reference/readonlyConstructorAssignment.js @@ -45,7 +45,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/recursiveBaseCheck3.js b/tests/baselines/reference/recursiveBaseCheck3.js index ee8cd3f8914..c1d6657fecb 100644 --- a/tests/baselines/reference/recursiveBaseCheck3.js +++ b/tests/baselines/reference/recursiveBaseCheck3.js @@ -9,7 +9,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/recursiveBaseCheck4.js b/tests/baselines/reference/recursiveBaseCheck4.js index aace4c73cb9..cac4428e20b 100644 --- a/tests/baselines/reference/recursiveBaseCheck4.js +++ b/tests/baselines/reference/recursiveBaseCheck4.js @@ -7,7 +7,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/recursiveBaseCheck6.js b/tests/baselines/reference/recursiveBaseCheck6.js index b372d21c57e..2d650955399 100644 --- a/tests/baselines/reference/recursiveBaseCheck6.js +++ b/tests/baselines/reference/recursiveBaseCheck6.js @@ -7,7 +7,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/recursiveBaseConstructorCreation1.js b/tests/baselines/reference/recursiveBaseConstructorCreation1.js index fb5d8b95226..33560e5f50b 100644 --- a/tests/baselines/reference/recursiveBaseConstructorCreation1.js +++ b/tests/baselines/reference/recursiveBaseConstructorCreation1.js @@ -11,7 +11,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/recursiveClassInstantiationsWithDefaultConstructors.js b/tests/baselines/reference/recursiveClassInstantiationsWithDefaultConstructors.js index 31a63524f92..a5457694118 100644 --- a/tests/baselines/reference/recursiveClassInstantiationsWithDefaultConstructors.js +++ b/tests/baselines/reference/recursiveClassInstantiationsWithDefaultConstructors.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/recursiveClassReferenceTest.js b/tests/baselines/reference/recursiveClassReferenceTest.js index 078959861b9..9a05a00906e 100644 --- a/tests/baselines/reference/recursiveClassReferenceTest.js +++ b/tests/baselines/reference/recursiveClassReferenceTest.js @@ -109,7 +109,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/recursiveClassReferenceTest.js.map b/tests/baselines/reference/recursiveClassReferenceTest.js.map index a78d8e7cb5d..05290f25aa1 100644 --- a/tests/baselines/reference/recursiveClassReferenceTest.js.map +++ b/tests/baselines/reference/recursiveClassReferenceTest.js.map @@ -1,3 +1,3 @@ //// [recursiveClassReferenceTest.js.map] {"version":3,"file":"recursiveClassReferenceTest.js","sourceRoot":"","sources":["recursiveClassReferenceTest.ts"],"names":[],"mappings":"AAAA,iEAAiE;AACjE,0EAA0E;;;;;;;;;;;;;;AA8B1E,IAAO,MAAM,CAUZ;AAVD,WAAO,MAAM;IAAC,IAAA,OAAO,CAUpB;IAVa,WAAA,OAAO;QAAC,IAAA,KAAK,CAU1B;QAVqB,WAAA,OAAK;YAAC,IAAA,IAAI,CAU/B;YAV2B,WAAA,IAAI;gBAC/B;oBAAA;oBAQA,CAAC;oBANO,+BAAK,GAAZ,cAAiB,OAAO,IAAI,CAAC,CAAC,CAAC;oBAExB,6BAAG,GAAV,UAAW,KAA6B;wBAEvC,OAAO,IAAI,CAAC;oBACb,CAAC;oBACF,sBAAC;gBAAD,CAAC,AARD,IAQC;gBARY,oBAAe,kBAQ3B,CAAA;YACF,CAAC,EAV2B,IAAI,GAAJ,YAAI,KAAJ,YAAI,QAU/B;QAAD,CAAC,EAVqB,KAAK,GAAL,aAAK,KAAL,aAAK,QAU1B;IAAD,CAAC,EAVa,OAAO,GAAP,cAAO,KAAP,cAAO,QAUpB;AAAD,CAAC,EAVM,MAAM,KAAN,MAAM,QAUZ;AAED,WAAO,MAAM;IAAC,IAAA,KAAK,CAoBlB;IApBa,WAAA,KAAK;QAAC,IAAA,OAAO,CAoB1B;QApBmB,WAAA,OAAO;YAC1B;gBAKC,oBAAoB,SAAkC;oBAAlC,cAAS,GAAT,SAAS,CAAyB;oBAD9C,YAAO,GAAO,IAAI,CAAC;oBAEvB,aAAa;oBACb,SAAS,CAAC,SAAS,CAAC,WAAW,EAAE,IAAI,CAAC,CAAC;gBAC3C,CAAC;gBANM,wBAAG,GAAV,UAAW,MAAyC,IAAI,IAAI,IAAI,EAAE;oBAAC,OAAO,MAAM,CAAC,IAAI,CAAC,CAAC;iBAAC,CAAA,CAAC;gBAQlF,+BAAU,GAAjB;oBACC,OAAO,OAAO,CAAC;gBAChB,CAAC;gBAEM,4BAAO,GAAd;gBAEA,CAAC;gBAEF,iBAAC;YAAD,CAAC,AAlBD,IAkBC;YAlBY,kBAAU,aAkBtB,CAAA;QACF,CAAC,EApBmB,OAAO,GAAP,aAAO,KAAP,aAAO,QAoB1B;IAAD,CAAC,EApBa,KAAK,GAAL,YAAK,KAAL,YAAK,QAoBlB;AAAD,CAAC,EApBM,MAAM,KAAN,MAAM,QAoBZ;AAGD;IAAA;IAAuF,CAAC;IAA3C,sCAAe,GAAtB,cAAmC,OAAO,IAAI,CAAC,CAAA,CAAC;IAAC,mBAAC;AAAD,CAAC,AAAxF,IAAwF;AASxF,WAAO,MAAM;IAAC,IAAA,KAAK,CAwBlB;IAxBa,WAAA,KAAK;QAAC,IAAA,SAAS,CAwB5B;QAxBmB,WAAA,SAAS;YAAC,IAAA,SAAS,CAwBtC;YAxB6B,WAAA,SAAS;gBAEtC;oBACO,eAAoB,IAAW;wBAAX,SAAI,GAAJ,IAAI,CAAO;oBAAI,CAAC;oBACnC,qBAAK,GAAZ;wBACC,OAAO,IAAI,CAAC;oBACb,CAAC;oBAEM,sBAAM,GAAb,UAAc,KAAY;wBACzB,OAAO,IAAI,KAAK,KAAK,CAAC;oBACvB,CAAC;oBAEM,uBAAO,GAAd,cAA0B,OAAO,IAAI,CAAC,CAAC,CAAC;oBACzC,YAAC;gBAAD,CAAC,AAXD,IAWC;gBAXY,eAAK,QAWjB,CAAA;gBAED;oBAA0B,wBAAY;oBAAtC;;oBAQA,CAAC;oBANA,aAAa;oBACN,8BAAe,GAAtB;wBACC,OAAO,IAAI,KAAK,CAAC,IAAI,CAAC,CAAC;oBACxB,CAAC;oBAGF,WAAC;gBAAD,CAAC,AARD,CAA0B,YAAY,GAQrC;gBARY,cAAI,OAQhB,CAAA;YACF,CAAC,EAxB6B,SAAS,GAAT,mBAAS,KAAT,mBAAS,QAwBtC;QAAD,CAAC,EAxBmB,SAAS,GAAT,eAAS,KAAT,eAAS,QAwB5B;IAAD,CAAC,EAxBa,KAAK,GAAL,YAAK,KAAL,YAAK,QAwBlB;AAAD,CAAC,EAxBM,MAAM,KAAN,MAAM,QAwBZ"} -//// https://sokra.github.io/source-map-visualization#base64,Ly8gU2NlbmFyaW8gMTogVGVzdCByZXF1cnNpdmUgZnVuY3Rpb24gY2FsbCB3aXRoICJ0aGlzIiBwYXJhbWV0ZXINCi8vIFNjZW5hcmlvIDI6IFRlc3QgcmVjdXJzaXZlIGZ1bmN0aW9uIGNhbGwgd2l0aCBjYXN0IGFuZCAidGhpcyIgcGFyYW1ldGVyDQp2YXIgX19leHRlbmRzID0gKHRoaXMgJiYgdGhpcy5fX2V4dGVuZHMpIHx8IChmdW5jdGlvbiAoKSB7DQogICAgdmFyIGV4dGVuZFN0YXRpY3MgPSBmdW5jdGlvbiAoZCwgYikgew0KICAgICAgICBleHRlbmRTdGF0aWNzID0gT2JqZWN0LnNldFByb3RvdHlwZU9mIHx8DQogICAgICAgICAgICAoeyBfX3Byb3RvX186IFtdIH0gaW5zdGFuY2VvZiBBcnJheSAmJiBmdW5jdGlvbiAoZCwgYikgeyBkLl9fcHJvdG9fXyA9IGI7IH0pIHx8DQogICAgICAgICAgICBmdW5jdGlvbiAoZCwgYikgeyBmb3IgKHZhciBwIGluIGIpIGlmIChiLmhhc093blByb3BlcnR5KHApKSBkW3BdID0gYltwXTsgfTsNCiAgICAgICAgcmV0dXJuIGV4dGVuZFN0YXRpY3MoZCwgYik7DQogICAgfTsNCiAgICByZXR1cm4gZnVuY3Rpb24gKGQsIGIpIHsNCiAgICAgICAgZXh0ZW5kU3RhdGljcyhkLCBiKTsNCiAgICAgICAgZnVuY3Rpb24gX18oKSB7IHRoaXMuY29uc3RydWN0b3IgPSBkOyB9DQogICAgICAgIGQucHJvdG90eXBlID0gYiA9PT0gbnVsbCA/IE9iamVjdC5jcmVhdGUoYikgOiAoX18ucHJvdG90eXBlID0gYi5wcm90b3R5cGUsIG5ldyBfXygpKTsNCiAgICB9Ow0KfSkoKTsNCnZhciBTYW1wbGU7DQooZnVuY3Rpb24gKFNhbXBsZSkgew0KICAgIHZhciBBY3Rpb25zOw0KICAgIChmdW5jdGlvbiAoQWN0aW9ucykgew0KICAgICAgICB2YXIgVGhpbmc7DQogICAgICAgIChmdW5jdGlvbiAoVGhpbmdfMSkgew0KICAgICAgICAgICAgdmFyIEZpbmQ7DQogICAgICAgICAgICAoZnVuY3Rpb24gKEZpbmQpIHsNCiAgICAgICAgICAgICAgICB2YXIgU3RhcnRGaW5kQWN0aW9uID0gLyoqIEBjbGFzcyAqLyAoZnVuY3Rpb24gKCkgew0KICAgICAgICAgICAgICAgICAgICBmdW5jdGlvbiBTdGFydEZpbmRBY3Rpb24oKSB7DQogICAgICAgICAgICAgICAgICAgIH0NCiAgICAgICAgICAgICAgICAgICAgU3RhcnRGaW5kQWN0aW9uLnByb3RvdHlwZS5nZXRJZCA9IGZ1bmN0aW9uICgpIHsgcmV0dXJuICJ5byI7IH07DQogICAgICAgICAgICAgICAgICAgIFN0YXJ0RmluZEFjdGlvbi5wcm90b3R5cGUucnVuID0gZnVuY3Rpb24gKFRoaW5nKSB7DQogICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gdHJ1ZTsNCiAgICAgICAgICAgICAgICAgICAgfTsNCiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIFN0YXJ0RmluZEFjdGlvbjsNCiAgICAgICAgICAgICAgICB9KCkpOw0KICAgICAgICAgICAgICAgIEZpbmQuU3RhcnRGaW5kQWN0aW9uID0gU3RhcnRGaW5kQWN0aW9uOw0KICAgICAgICAgICAgfSkoRmluZCA9IFRoaW5nXzEuRmluZCB8fCAoVGhpbmdfMS5GaW5kID0ge30pKTsNCiAgICAgICAgfSkoVGhpbmcgPSBBY3Rpb25zLlRoaW5nIHx8IChBY3Rpb25zLlRoaW5nID0ge30pKTsNCiAgICB9KShBY3Rpb25zID0gU2FtcGxlLkFjdGlvbnMgfHwgKFNhbXBsZS5BY3Rpb25zID0ge30pKTsNCn0pKFNhbXBsZSB8fCAoU2FtcGxlID0ge30pKTsNCihmdW5jdGlvbiAoU2FtcGxlKSB7DQogICAgdmFyIFRoaW5nOw0KICAgIChmdW5jdGlvbiAoVGhpbmcpIHsNCiAgICAgICAgdmFyIFdpZGdldHM7DQogICAgICAgIChmdW5jdGlvbiAoV2lkZ2V0cykgew0KICAgICAgICAgICAgdmFyIEZpbmRXaWRnZXQgPSAvKiogQGNsYXNzICovIChmdW5jdGlvbiAoKSB7DQogICAgICAgICAgICAgICAgZnVuY3Rpb24gRmluZFdpZGdldChjb2RlVGhpbmcpIHsNCiAgICAgICAgICAgICAgICAgICAgdGhpcy5jb2RlVGhpbmcgPSBjb2RlVGhpbmc7DQogICAgICAgICAgICAgICAgICAgIHRoaXMuZG9tTm9kZSA9IG51bGw7DQogICAgICAgICAgICAgICAgICAgIC8vIHNjZW5hcmlvIDENCiAgICAgICAgICAgICAgICAgICAgY29kZVRoaW5nLmFkZFdpZGdldCgiYWRkV2lkZ2V0IiwgdGhpcyk7DQogICAgICAgICAgICAgICAgfQ0KICAgICAgICAgICAgICAgIEZpbmRXaWRnZXQucHJvdG90eXBlLmdhciA9IGZ1bmN0aW9uIChydW5uZXIpIHsgaWYgKHRydWUpIHsNCiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHJ1bm5lcih0aGlzKTsNCiAgICAgICAgICAgICAgICB9IH07DQogICAgICAgICAgICAgICAgRmluZFdpZGdldC5wcm90b3R5cGUuZ2V0RG9tTm9kZSA9IGZ1bmN0aW9uICgpIHsNCiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIGRvbU5vZGU7DQogICAgICAgICAgICAgICAgfTsNCiAgICAgICAgICAgICAgICBGaW5kV2lkZ2V0LnByb3RvdHlwZS5kZXN0cm95ID0gZnVuY3Rpb24gKCkgew0KICAgICAgICAgICAgICAgIH07DQogICAgICAgICAgICAgICAgcmV0dXJuIEZpbmRXaWRnZXQ7DQogICAgICAgICAgICB9KCkpOw0KICAgICAgICAgICAgV2lkZ2V0cy5GaW5kV2lkZ2V0ID0gRmluZFdpZGdldDsNCiAgICAgICAgfSkoV2lkZ2V0cyA9IFRoaW5nLldpZGdldHMgfHwgKFRoaW5nLldpZGdldHMgPSB7fSkpOw0KICAgIH0pKFRoaW5nID0gU2FtcGxlLlRoaW5nIHx8IChTYW1wbGUuVGhpbmcgPSB7fSkpOw0KfSkoU2FtcGxlIHx8IChTYW1wbGUgPSB7fSkpOw0KdmFyIEFic3RyYWN0TW9kZSA9IC8qKiBAY2xhc3MgKi8gKGZ1bmN0aW9uICgpIHsNCiAgICBmdW5jdGlvbiBBYnN0cmFjdE1vZGUoKSB7DQogICAgfQ0KICAgIEFic3RyYWN0TW9kZS5wcm90b3R5cGUuZ2V0SW5pdGlhbFN0YXRlID0gZnVuY3Rpb24gKCkgeyByZXR1cm4gbnVsbDsgfTsNCiAgICByZXR1cm4gQWJzdHJhY3RNb2RlOw0KfSgpKTsNCihmdW5jdGlvbiAoU2FtcGxlKSB7DQogICAgdmFyIFRoaW5nOw0KICAgIChmdW5jdGlvbiAoVGhpbmcpIHsNCiAgICAgICAgdmFyIExhbmd1YWdlczsNCiAgICAgICAgKGZ1bmN0aW9uIChMYW5ndWFnZXMpIHsNCiAgICAgICAgICAgIHZhciBQbGFpblRleHQ7DQogICAgICAgICAgICAoZnVuY3Rpb24gKFBsYWluVGV4dCkgew0KICAgICAgICAgICAgICAgIHZhciBTdGF0ZSA9IC8qKiBAY2xhc3MgKi8gKGZ1bmN0aW9uICgpIHsNCiAgICAgICAgICAgICAgICAgICAgZnVuY3Rpb24gU3RhdGUobW9kZSkgew0KICAgICAgICAgICAgICAgICAgICAgICAgdGhpcy5tb2RlID0gbW9kZTsNCiAgICAgICAgICAgICAgICAgICAgfQ0KICAgICAgICAgICAgICAgICAgICBTdGF0ZS5wcm90b3R5cGUuY2xvbmUgPSBmdW5jdGlvbiAoKSB7DQogICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gdGhpczsNCiAgICAgICAgICAgICAgICAgICAgfTsNCiAgICAgICAgICAgICAgICAgICAgU3RhdGUucHJvdG90eXBlLmVxdWFscyA9IGZ1bmN0aW9uIChvdGhlcikgew0KICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHRoaXMgPT09IG90aGVyOw0KICAgICAgICAgICAgICAgICAgICB9Ow0KICAgICAgICAgICAgICAgICAgICBTdGF0ZS5wcm90b3R5cGUuZ2V0TW9kZSA9IGZ1bmN0aW9uICgpIHsgcmV0dXJuIG1vZGU7IH07DQogICAgICAgICAgICAgICAgICAgIHJldHVybiBTdGF0ZTsNCiAgICAgICAgICAgICAgICB9KCkpOw0KICAgICAgICAgICAgICAgIFBsYWluVGV4dC5TdGF0ZSA9IFN0YXRlOw0KICAgICAgICAgICAgICAgIHZhciBNb2RlID0gLyoqIEBjbGFzcyAqLyAoZnVuY3Rpb24gKF9zdXBlcikgew0KICAgICAgICAgICAgICAgICAgICBfX2V4dGVuZHMoTW9kZSwgX3N1cGVyKTsNCiAgICAgICAgICAgICAgICAgICAgZnVuY3Rpb24gTW9kZSgpIHsNCiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBfc3VwZXIgIT09IG51bGwgJiYgX3N1cGVyLmFwcGx5KHRoaXMsIGFyZ3VtZW50cykgfHwgdGhpczsNCiAgICAgICAgICAgICAgICAgICAgfQ0KICAgICAgICAgICAgICAgICAgICAvLyBzY2VuYXJpbyAyDQogICAgICAgICAgICAgICAgICAgIE1vZGUucHJvdG90eXBlLmdldEluaXRpYWxTdGF0ZSA9IGZ1bmN0aW9uICgpIHsNCiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBuZXcgU3RhdGUoc2VsZik7DQogICAgICAgICAgICAgICAgICAgIH07DQogICAgICAgICAgICAgICAgICAgIHJldHVybiBNb2RlOw0KICAgICAgICAgICAgICAgIH0oQWJzdHJhY3RNb2RlKSk7DQogICAgICAgICAgICAgICAgUGxhaW5UZXh0Lk1vZGUgPSBNb2RlOw0KICAgICAgICAgICAgfSkoUGxhaW5UZXh0ID0gTGFuZ3VhZ2VzLlBsYWluVGV4dCB8fCAoTGFuZ3VhZ2VzLlBsYWluVGV4dCA9IHt9KSk7DQogICAgICAgIH0pKExhbmd1YWdlcyA9IFRoaW5nLkxhbmd1YWdlcyB8fCAoVGhpbmcuTGFuZ3VhZ2VzID0ge30pKTsNCiAgICB9KShUaGluZyA9IFNhbXBsZS5UaGluZyB8fCAoU2FtcGxlLlRoaW5nID0ge30pKTsNCn0pKFNhbXBsZSB8fCAoU2FtcGxlID0ge30pKTsNCi8vIyBzb3VyY2VNYXBwaW5nVVJMPXJlY3Vyc2l2ZUNsYXNzUmVmZXJlbmNlVGVzdC5qcy5tYXA=,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmVjdXJzaXZlQ2xhc3NSZWZlcmVuY2VUZXN0LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsicmVjdXJzaXZlQ2xhc3NSZWZlcmVuY2VUZXN0LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLGlFQUFpRTtBQUNqRSwwRUFBMEU7Ozs7Ozs7Ozs7Ozs7O0FBOEIxRSxJQUFPLE1BQU0sQ0FVWjtBQVZELFdBQU8sTUFBTTtJQUFDLElBQUEsT0FBTyxDQVVwQjtJQVZhLFdBQUEsT0FBTztRQUFDLElBQUEsS0FBSyxDQVUxQjtRQVZxQixXQUFBLE9BQUs7WUFBQyxJQUFBLElBQUksQ0FVL0I7WUFWMkIsV0FBQSxJQUFJO2dCQUMvQjtvQkFBQTtvQkFRQSxDQUFDO29CQU5PLCtCQUFLLEdBQVosY0FBaUIsT0FBTyxJQUFJLENBQUMsQ0FBQyxDQUFDO29CQUV4Qiw2QkFBRyxHQUFWLFVBQVcsS0FBNkI7d0JBRXZDLE9BQU8sSUFBSSxDQUFDO29CQUNiLENBQUM7b0JBQ0Ysc0JBQUM7Z0JBQUQsQ0FBQyxBQVJELElBUUM7Z0JBUlksb0JBQWUsa0JBUTNCLENBQUE7WUFDRixDQUFDLEVBVjJCLElBQUksR0FBSixZQUFJLEtBQUosWUFBSSxRQVUvQjtRQUFELENBQUMsRUFWcUIsS0FBSyxHQUFMLGFBQUssS0FBTCxhQUFLLFFBVTFCO0lBQUQsQ0FBQyxFQVZhLE9BQU8sR0FBUCxjQUFPLEtBQVAsY0FBTyxRQVVwQjtBQUFELENBQUMsRUFWTSxNQUFNLEtBQU4sTUFBTSxRQVVaO0FBRUQsV0FBTyxNQUFNO0lBQUMsSUFBQSxLQUFLLENBb0JsQjtJQXBCYSxXQUFBLEtBQUs7UUFBQyxJQUFBLE9BQU8sQ0FvQjFCO1FBcEJtQixXQUFBLE9BQU87WUFDMUI7Z0JBS0Msb0JBQW9CLFNBQWtDO29CQUFsQyxjQUFTLEdBQVQsU0FBUyxDQUF5QjtvQkFEOUMsWUFBTyxHQUFPLElBQUksQ0FBQztvQkFFdkIsYUFBYTtvQkFDYixTQUFTLENBQUMsU0FBUyxDQUFDLFdBQVcsRUFBRSxJQUFJLENBQUMsQ0FBQztnQkFDM0MsQ0FBQztnQkFOTSx3QkFBRyxHQUFWLFVBQVcsTUFBeUMsSUFBSSxJQUFJLElBQUksRUFBRTtvQkFBQyxPQUFPLE1BQU0sQ0FBQyxJQUFJLENBQUMsQ0FBQztpQkFBQyxDQUFBLENBQUM7Z0JBUWxGLCtCQUFVLEdBQWpCO29CQUNDLE9BQU8sT0FBTyxDQUFDO2dCQUNoQixDQUFDO2dCQUVNLDRCQUFPLEdBQWQ7Z0JBRUEsQ0FBQztnQkFFRixpQkFBQztZQUFELENBQUMsQUFsQkQsSUFrQkM7WUFsQlksa0JBQVUsYUFrQnRCLENBQUE7UUFDRixDQUFDLEVBcEJtQixPQUFPLEdBQVAsYUFBTyxLQUFQLGFBQU8sUUFvQjFCO0lBQUQsQ0FBQyxFQXBCYSxLQUFLLEdBQUwsWUFBSyxLQUFMLFlBQUssUUFvQmxCO0FBQUQsQ0FBQyxFQXBCTSxNQUFNLEtBQU4sTUFBTSxRQW9CWjtBQUdEO0lBQUE7SUFBdUYsQ0FBQztJQUEzQyxzQ0FBZSxHQUF0QixjQUFtQyxPQUFPLElBQUksQ0FBQyxDQUFBLENBQUM7SUFBQyxtQkFBQztBQUFELENBQUMsQUFBeEYsSUFBd0Y7QUFTeEYsV0FBTyxNQUFNO0lBQUMsSUFBQSxLQUFLLENBd0JsQjtJQXhCYSxXQUFBLEtBQUs7UUFBQyxJQUFBLFNBQVMsQ0F3QjVCO1FBeEJtQixXQUFBLFNBQVM7WUFBQyxJQUFBLFNBQVMsQ0F3QnRDO1lBeEI2QixXQUFBLFNBQVM7Z0JBRXRDO29CQUNPLGVBQW9CLElBQVc7d0JBQVgsU0FBSSxHQUFKLElBQUksQ0FBTztvQkFBSSxDQUFDO29CQUNuQyxxQkFBSyxHQUFaO3dCQUNDLE9BQU8sSUFBSSxDQUFDO29CQUNiLENBQUM7b0JBRU0sc0JBQU0sR0FBYixVQUFjLEtBQVk7d0JBQ3pCLE9BQU8sSUFBSSxLQUFLLEtBQUssQ0FBQztvQkFDdkIsQ0FBQztvQkFFTSx1QkFBTyxHQUFkLGNBQTBCLE9BQU8sSUFBSSxDQUFDLENBQUMsQ0FBQztvQkFDekMsWUFBQztnQkFBRCxDQUFDLEFBWEQsSUFXQztnQkFYWSxlQUFLLFFBV2pCLENBQUE7Z0JBRUQ7b0JBQTBCLHdCQUFZO29CQUF0Qzs7b0JBUUEsQ0FBQztvQkFOQSxhQUFhO29CQUNOLDhCQUFlLEdBQXRCO3dCQUNDLE9BQU8sSUFBSSxLQUFLLENBQUMsSUFBSSxDQUFDLENBQUM7b0JBQ3hCLENBQUM7b0JBR0YsV0FBQztnQkFBRCxDQUFDLEFBUkQsQ0FBMEIsWUFBWSxHQVFyQztnQkFSWSxjQUFJLE9BUWhCLENBQUE7WUFDRixDQUFDLEVBeEI2QixTQUFTLEdBQVQsbUJBQVMsS0FBVCxtQkFBUyxRQXdCdEM7UUFBRCxDQUFDLEVBeEJtQixTQUFTLEdBQVQsZUFBUyxLQUFULGVBQVMsUUF3QjVCO0lBQUQsQ0FBQyxFQXhCYSxLQUFLLEdBQUwsWUFBSyxLQUFMLFlBQUssUUF3QmxCO0FBQUQsQ0FBQyxFQXhCTSxNQUFNLEtBQU4sTUFBTSxRQXdCWiJ9,Ly8gU2NlbmFyaW8gMTogVGVzdCByZXF1cnNpdmUgZnVuY3Rpb24gY2FsbCB3aXRoICJ0aGlzIiBwYXJhbWV0ZXIKLy8gU2NlbmFyaW8gMjogVGVzdCByZWN1cnNpdmUgZnVuY3Rpb24gY2FsbCB3aXRoIGNhc3QgYW5kICJ0aGlzIiBwYXJhbWV0ZXIKCgoKZGVjbGFyZSBtb2R1bGUgU2FtcGxlLlRoaW5nIHsKCglleHBvcnQgaW50ZXJmYWNlIElXaWRnZXQgewoJCWdldERvbU5vZGUoKTogYW55OwoJCWRlc3Ryb3koKTsKCQlnYXIocnVubmVyOih3aWRnZXQ6U2FtcGxlLlRoaW5nLklXaWRnZXQpPT5hbnkpOmFueTsKCX0KCglleHBvcnQgaW50ZXJmYWNlIElDb2RlVGhpbmcgewogIAogIAkJZ2V0RG9tTm9kZSgpOiBFbGVtZW50OwoJCQoJCWFkZFdpZGdldCh3aWRnZXRJZDpzdHJpbmcsIHdpZGdldDpJV2lkZ2V0KTsKCgkJCgkJZm9jdXMoKTsgCgkJCgkJLy9hZGRXaWRnZXQod2lkZ2V0OiBTYW1wbGUuVGhpbmcuV2lkZ2V0cy5JV2lkZ2V0KTsKCX0KCglleHBvcnQgaW50ZXJmYWNlIElBY3Rpb24gewoJCXJ1bihUaGluZzpJQ29kZVRoaW5nKTpib29sZWFuOwoJCWdldElkKCk6c3RyaW5nOwoJfQkKfQoKbW9kdWxlIFNhbXBsZS5BY3Rpb25zLlRoaW5nLkZpbmQgewoJZXhwb3J0IGNsYXNzIFN0YXJ0RmluZEFjdGlvbiBpbXBsZW1lbnRzIFNhbXBsZS5UaGluZy5JQWN0aW9uIHsKCQkKCQlwdWJsaWMgZ2V0SWQoKSB7IHJldHVybiAieW8iOyB9CgkJCgkJcHVibGljIHJ1bihUaGluZzpTYW1wbGUuVGhpbmcuSUNvZGVUaGluZyk6Ym9vbGVhbiB7CgoJCQlyZXR1cm4gdHJ1ZTsKCQl9Cgl9Cn0KCm1vZHVsZSBTYW1wbGUuVGhpbmcuV2lkZ2V0cyB7CglleHBvcnQgY2xhc3MgRmluZFdpZGdldCBpbXBsZW1lbnRzIFNhbXBsZS5UaGluZy5JV2lkZ2V0IHsKCgkJcHVibGljIGdhcihydW5uZXI6KHdpZGdldDpTYW1wbGUuVGhpbmcuSVdpZGdldCk9PmFueSkgeyBpZiAodHJ1ZSkge3JldHVybiBydW5uZXIodGhpcyk7fX0KCQkJCgkJcHJpdmF0ZSBkb21Ob2RlOmFueSA9IG51bGw7CgkJY29uc3RydWN0b3IocHJpdmF0ZSBjb2RlVGhpbmc6IFNhbXBsZS5UaGluZy5JQ29kZVRoaW5nKSB7CgkJICAgIC8vIHNjZW5hcmlvIDEKCQkgICAgY29kZVRoaW5nLmFkZFdpZGdldCgiYWRkV2lkZ2V0IiwgdGhpcyk7CgkJfQoJCQoJCXB1YmxpYyBnZXREb21Ob2RlKCkgewoJCQlyZXR1cm4gZG9tTm9kZTsKCQl9CgkJCgkJcHVibGljIGRlc3Ryb3koKSB7CgoJCX0KCgl9Cn0KCmludGVyZmFjZSBJTW9kZSB7IGdldEluaXRpYWxTdGF0ZSgpOiBJU3RhdGU7fSAKY2xhc3MgQWJzdHJhY3RNb2RlIGltcGxlbWVudHMgSU1vZGUgeyBwdWJsaWMgZ2V0SW5pdGlhbFN0YXRlKCk6IElTdGF0ZSB7IHJldHVybiBudWxsO30gfQoKaW50ZXJmYWNlIElTdGF0ZSB7fQoKaW50ZXJmYWNlIFdpbmRvdyB7CiAgICBvcGVuZXI6IFdpbmRvdzsKfQpkZWNsYXJlIHZhciBzZWxmOiBXaW5kb3c7Cgptb2R1bGUgU2FtcGxlLlRoaW5nLkxhbmd1YWdlcy5QbGFpblRleHQgewoJCglleHBvcnQgY2xhc3MgU3RhdGUgaW1wbGVtZW50cyBJU3RhdGUgewkJCiAgICAgICAgY29uc3RydWN0b3IocHJpdmF0ZSBtb2RlOiBJTW9kZSkgeyB9CgkJcHVibGljIGNsb25lKCk6SVN0YXRlIHsKCQkJcmV0dXJuIHRoaXM7CgkJfQoKCQlwdWJsaWMgZXF1YWxzKG90aGVyOklTdGF0ZSk6Ym9vbGVhbiB7CgkJCXJldHVybiB0aGlzID09PSBvdGhlcjsKCQl9CgkJCgkJcHVibGljIGdldE1vZGUoKTogSU1vZGUgeyByZXR1cm4gbW9kZTsgfQoJfQoJCglleHBvcnQgY2xhc3MgTW9kZSBleHRlbmRzIEFic3RyYWN0TW9kZSB7CgoJCS8vIHNjZW5hcmlvIDIKCQlwdWJsaWMgZ2V0SW5pdGlhbFN0YXRlKCk6IElTdGF0ZSB7CgkJCXJldHVybiBuZXcgU3RhdGUoc2VsZik7CgkJfQoKCgl9Cn0KCg== +//// https://sokra.github.io/source-map-visualization#base64,Ly8gU2NlbmFyaW8gMTogVGVzdCByZXF1cnNpdmUgZnVuY3Rpb24gY2FsbCB3aXRoICJ0aGlzIiBwYXJhbWV0ZXINCi8vIFNjZW5hcmlvIDI6IFRlc3QgcmVjdXJzaXZlIGZ1bmN0aW9uIGNhbGwgd2l0aCBjYXN0IGFuZCAidGhpcyIgcGFyYW1ldGVyDQp2YXIgX19leHRlbmRzID0gKHRoaXMgJiYgdGhpcy5fX2V4dGVuZHMpIHx8IChmdW5jdGlvbiAoKSB7DQogICAgdmFyIGV4dGVuZFN0YXRpY3MgPSBmdW5jdGlvbiAoZCwgYikgew0KICAgICAgICBleHRlbmRTdGF0aWNzID0gT2JqZWN0LnNldFByb3RvdHlwZU9mIHx8DQogICAgICAgICAgICAoeyBfX3Byb3RvX186IFtdIH0gaW5zdGFuY2VvZiBBcnJheSAmJiBmdW5jdGlvbiAoZCwgYikgeyBkLl9fcHJvdG9fXyA9IGI7IH0pIHx8DQogICAgICAgICAgICBmdW5jdGlvbiAoZCwgYikgeyBmb3IgKHZhciBwIGluIGIpIGlmIChPYmplY3QucHJvdG90eXBlLmhhc093blByb3BlcnR5LmNhbGwoYiwgcCkpIGRbcF0gPSBiW3BdOyB9Ow0KICAgICAgICByZXR1cm4gZXh0ZW5kU3RhdGljcyhkLCBiKTsNCiAgICB9Ow0KICAgIHJldHVybiBmdW5jdGlvbiAoZCwgYikgew0KICAgICAgICBleHRlbmRTdGF0aWNzKGQsIGIpOw0KICAgICAgICBmdW5jdGlvbiBfXygpIHsgdGhpcy5jb25zdHJ1Y3RvciA9IGQ7IH0NCiAgICAgICAgZC5wcm90b3R5cGUgPSBiID09PSBudWxsID8gT2JqZWN0LmNyZWF0ZShiKSA6IChfXy5wcm90b3R5cGUgPSBiLnByb3RvdHlwZSwgbmV3IF9fKCkpOw0KICAgIH07DQp9KSgpOw0KdmFyIFNhbXBsZTsNCihmdW5jdGlvbiAoU2FtcGxlKSB7DQogICAgdmFyIEFjdGlvbnM7DQogICAgKGZ1bmN0aW9uIChBY3Rpb25zKSB7DQogICAgICAgIHZhciBUaGluZzsNCiAgICAgICAgKGZ1bmN0aW9uIChUaGluZ18xKSB7DQogICAgICAgICAgICB2YXIgRmluZDsNCiAgICAgICAgICAgIChmdW5jdGlvbiAoRmluZCkgew0KICAgICAgICAgICAgICAgIHZhciBTdGFydEZpbmRBY3Rpb24gPSAvKiogQGNsYXNzICovIChmdW5jdGlvbiAoKSB7DQogICAgICAgICAgICAgICAgICAgIGZ1bmN0aW9uIFN0YXJ0RmluZEFjdGlvbigpIHsNCiAgICAgICAgICAgICAgICAgICAgfQ0KICAgICAgICAgICAgICAgICAgICBTdGFydEZpbmRBY3Rpb24ucHJvdG90eXBlLmdldElkID0gZnVuY3Rpb24gKCkgeyByZXR1cm4gInlvIjsgfTsNCiAgICAgICAgICAgICAgICAgICAgU3RhcnRGaW5kQWN0aW9uLnByb3RvdHlwZS5ydW4gPSBmdW5jdGlvbiAoVGhpbmcpIHsNCiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiB0cnVlOw0KICAgICAgICAgICAgICAgICAgICB9Ow0KICAgICAgICAgICAgICAgICAgICByZXR1cm4gU3RhcnRGaW5kQWN0aW9uOw0KICAgICAgICAgICAgICAgIH0oKSk7DQogICAgICAgICAgICAgICAgRmluZC5TdGFydEZpbmRBY3Rpb24gPSBTdGFydEZpbmRBY3Rpb247DQogICAgICAgICAgICB9KShGaW5kID0gVGhpbmdfMS5GaW5kIHx8IChUaGluZ18xLkZpbmQgPSB7fSkpOw0KICAgICAgICB9KShUaGluZyA9IEFjdGlvbnMuVGhpbmcgfHwgKEFjdGlvbnMuVGhpbmcgPSB7fSkpOw0KICAgIH0pKEFjdGlvbnMgPSBTYW1wbGUuQWN0aW9ucyB8fCAoU2FtcGxlLkFjdGlvbnMgPSB7fSkpOw0KfSkoU2FtcGxlIHx8IChTYW1wbGUgPSB7fSkpOw0KKGZ1bmN0aW9uIChTYW1wbGUpIHsNCiAgICB2YXIgVGhpbmc7DQogICAgKGZ1bmN0aW9uIChUaGluZykgew0KICAgICAgICB2YXIgV2lkZ2V0czsNCiAgICAgICAgKGZ1bmN0aW9uIChXaWRnZXRzKSB7DQogICAgICAgICAgICB2YXIgRmluZFdpZGdldCA9IC8qKiBAY2xhc3MgKi8gKGZ1bmN0aW9uICgpIHsNCiAgICAgICAgICAgICAgICBmdW5jdGlvbiBGaW5kV2lkZ2V0KGNvZGVUaGluZykgew0KICAgICAgICAgICAgICAgICAgICB0aGlzLmNvZGVUaGluZyA9IGNvZGVUaGluZzsNCiAgICAgICAgICAgICAgICAgICAgdGhpcy5kb21Ob2RlID0gbnVsbDsNCiAgICAgICAgICAgICAgICAgICAgLy8gc2NlbmFyaW8gMQ0KICAgICAgICAgICAgICAgICAgICBjb2RlVGhpbmcuYWRkV2lkZ2V0KCJhZGRXaWRnZXQiLCB0aGlzKTsNCiAgICAgICAgICAgICAgICB9DQogICAgICAgICAgICAgICAgRmluZFdpZGdldC5wcm90b3R5cGUuZ2FyID0gZnVuY3Rpb24gKHJ1bm5lcikgeyBpZiAodHJ1ZSkgew0KICAgICAgICAgICAgICAgICAgICByZXR1cm4gcnVubmVyKHRoaXMpOw0KICAgICAgICAgICAgICAgIH0gfTsNCiAgICAgICAgICAgICAgICBGaW5kV2lkZ2V0LnByb3RvdHlwZS5nZXREb21Ob2RlID0gZnVuY3Rpb24gKCkgew0KICAgICAgICAgICAgICAgICAgICByZXR1cm4gZG9tTm9kZTsNCiAgICAgICAgICAgICAgICB9Ow0KICAgICAgICAgICAgICAgIEZpbmRXaWRnZXQucHJvdG90eXBlLmRlc3Ryb3kgPSBmdW5jdGlvbiAoKSB7DQogICAgICAgICAgICAgICAgfTsNCiAgICAgICAgICAgICAgICByZXR1cm4gRmluZFdpZGdldDsNCiAgICAgICAgICAgIH0oKSk7DQogICAgICAgICAgICBXaWRnZXRzLkZpbmRXaWRnZXQgPSBGaW5kV2lkZ2V0Ow0KICAgICAgICB9KShXaWRnZXRzID0gVGhpbmcuV2lkZ2V0cyB8fCAoVGhpbmcuV2lkZ2V0cyA9IHt9KSk7DQogICAgfSkoVGhpbmcgPSBTYW1wbGUuVGhpbmcgfHwgKFNhbXBsZS5UaGluZyA9IHt9KSk7DQp9KShTYW1wbGUgfHwgKFNhbXBsZSA9IHt9KSk7DQp2YXIgQWJzdHJhY3RNb2RlID0gLyoqIEBjbGFzcyAqLyAoZnVuY3Rpb24gKCkgew0KICAgIGZ1bmN0aW9uIEFic3RyYWN0TW9kZSgpIHsNCiAgICB9DQogICAgQWJzdHJhY3RNb2RlLnByb3RvdHlwZS5nZXRJbml0aWFsU3RhdGUgPSBmdW5jdGlvbiAoKSB7IHJldHVybiBudWxsOyB9Ow0KICAgIHJldHVybiBBYnN0cmFjdE1vZGU7DQp9KCkpOw0KKGZ1bmN0aW9uIChTYW1wbGUpIHsNCiAgICB2YXIgVGhpbmc7DQogICAgKGZ1bmN0aW9uIChUaGluZykgew0KICAgICAgICB2YXIgTGFuZ3VhZ2VzOw0KICAgICAgICAoZnVuY3Rpb24gKExhbmd1YWdlcykgew0KICAgICAgICAgICAgdmFyIFBsYWluVGV4dDsNCiAgICAgICAgICAgIChmdW5jdGlvbiAoUGxhaW5UZXh0KSB7DQogICAgICAgICAgICAgICAgdmFyIFN0YXRlID0gLyoqIEBjbGFzcyAqLyAoZnVuY3Rpb24gKCkgew0KICAgICAgICAgICAgICAgICAgICBmdW5jdGlvbiBTdGF0ZShtb2RlKSB7DQogICAgICAgICAgICAgICAgICAgICAgICB0aGlzLm1vZGUgPSBtb2RlOw0KICAgICAgICAgICAgICAgICAgICB9DQogICAgICAgICAgICAgICAgICAgIFN0YXRlLnByb3RvdHlwZS5jbG9uZSA9IGZ1bmN0aW9uICgpIHsNCiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiB0aGlzOw0KICAgICAgICAgICAgICAgICAgICB9Ow0KICAgICAgICAgICAgICAgICAgICBTdGF0ZS5wcm90b3R5cGUuZXF1YWxzID0gZnVuY3Rpb24gKG90aGVyKSB7DQogICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gdGhpcyA9PT0gb3RoZXI7DQogICAgICAgICAgICAgICAgICAgIH07DQogICAgICAgICAgICAgICAgICAgIFN0YXRlLnByb3RvdHlwZS5nZXRNb2RlID0gZnVuY3Rpb24gKCkgeyByZXR1cm4gbW9kZTsgfTsNCiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIFN0YXRlOw0KICAgICAgICAgICAgICAgIH0oKSk7DQogICAgICAgICAgICAgICAgUGxhaW5UZXh0LlN0YXRlID0gU3RhdGU7DQogICAgICAgICAgICAgICAgdmFyIE1vZGUgPSAvKiogQGNsYXNzICovIChmdW5jdGlvbiAoX3N1cGVyKSB7DQogICAgICAgICAgICAgICAgICAgIF9fZXh0ZW5kcyhNb2RlLCBfc3VwZXIpOw0KICAgICAgICAgICAgICAgICAgICBmdW5jdGlvbiBNb2RlKCkgew0KICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIF9zdXBlciAhPT0gbnVsbCAmJiBfc3VwZXIuYXBwbHkodGhpcywgYXJndW1lbnRzKSB8fCB0aGlzOw0KICAgICAgICAgICAgICAgICAgICB9DQogICAgICAgICAgICAgICAgICAgIC8vIHNjZW5hcmlvIDINCiAgICAgICAgICAgICAgICAgICAgTW9kZS5wcm90b3R5cGUuZ2V0SW5pdGlhbFN0YXRlID0gZnVuY3Rpb24gKCkgew0KICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIG5ldyBTdGF0ZShzZWxmKTsNCiAgICAgICAgICAgICAgICAgICAgfTsNCiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIE1vZGU7DQogICAgICAgICAgICAgICAgfShBYnN0cmFjdE1vZGUpKTsNCiAgICAgICAgICAgICAgICBQbGFpblRleHQuTW9kZSA9IE1vZGU7DQogICAgICAgICAgICB9KShQbGFpblRleHQgPSBMYW5ndWFnZXMuUGxhaW5UZXh0IHx8IChMYW5ndWFnZXMuUGxhaW5UZXh0ID0ge30pKTsNCiAgICAgICAgfSkoTGFuZ3VhZ2VzID0gVGhpbmcuTGFuZ3VhZ2VzIHx8IChUaGluZy5MYW5ndWFnZXMgPSB7fSkpOw0KICAgIH0pKFRoaW5nID0gU2FtcGxlLlRoaW5nIHx8IChTYW1wbGUuVGhpbmcgPSB7fSkpOw0KfSkoU2FtcGxlIHx8IChTYW1wbGUgPSB7fSkpOw0KLy8jIHNvdXJjZU1hcHBpbmdVUkw9cmVjdXJzaXZlQ2xhc3NSZWZlcmVuY2VUZXN0LmpzLm1hcA==,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmVjdXJzaXZlQ2xhc3NSZWZlcmVuY2VUZXN0LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsicmVjdXJzaXZlQ2xhc3NSZWZlcmVuY2VUZXN0LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLGlFQUFpRTtBQUNqRSwwRUFBMEU7Ozs7Ozs7Ozs7Ozs7O0FBOEIxRSxJQUFPLE1BQU0sQ0FVWjtBQVZELFdBQU8sTUFBTTtJQUFDLElBQUEsT0FBTyxDQVVwQjtJQVZhLFdBQUEsT0FBTztRQUFDLElBQUEsS0FBSyxDQVUxQjtRQVZxQixXQUFBLE9BQUs7WUFBQyxJQUFBLElBQUksQ0FVL0I7WUFWMkIsV0FBQSxJQUFJO2dCQUMvQjtvQkFBQTtvQkFRQSxDQUFDO29CQU5PLCtCQUFLLEdBQVosY0FBaUIsT0FBTyxJQUFJLENBQUMsQ0FBQyxDQUFDO29CQUV4Qiw2QkFBRyxHQUFWLFVBQVcsS0FBNkI7d0JBRXZDLE9BQU8sSUFBSSxDQUFDO29CQUNiLENBQUM7b0JBQ0Ysc0JBQUM7Z0JBQUQsQ0FBQyxBQVJELElBUUM7Z0JBUlksb0JBQWUsa0JBUTNCLENBQUE7WUFDRixDQUFDLEVBVjJCLElBQUksR0FBSixZQUFJLEtBQUosWUFBSSxRQVUvQjtRQUFELENBQUMsRUFWcUIsS0FBSyxHQUFMLGFBQUssS0FBTCxhQUFLLFFBVTFCO0lBQUQsQ0FBQyxFQVZhLE9BQU8sR0FBUCxjQUFPLEtBQVAsY0FBTyxRQVVwQjtBQUFELENBQUMsRUFWTSxNQUFNLEtBQU4sTUFBTSxRQVVaO0FBRUQsV0FBTyxNQUFNO0lBQUMsSUFBQSxLQUFLLENBb0JsQjtJQXBCYSxXQUFBLEtBQUs7UUFBQyxJQUFBLE9BQU8sQ0FvQjFCO1FBcEJtQixXQUFBLE9BQU87WUFDMUI7Z0JBS0Msb0JBQW9CLFNBQWtDO29CQUFsQyxjQUFTLEdBQVQsU0FBUyxDQUF5QjtvQkFEOUMsWUFBTyxHQUFPLElBQUksQ0FBQztvQkFFdkIsYUFBYTtvQkFDYixTQUFTLENBQUMsU0FBUyxDQUFDLFdBQVcsRUFBRSxJQUFJLENBQUMsQ0FBQztnQkFDM0MsQ0FBQztnQkFOTSx3QkFBRyxHQUFWLFVBQVcsTUFBeUMsSUFBSSxJQUFJLElBQUksRUFBRTtvQkFBQyxPQUFPLE1BQU0sQ0FBQyxJQUFJLENBQUMsQ0FBQztpQkFBQyxDQUFBLENBQUM7Z0JBUWxGLCtCQUFVLEdBQWpCO29CQUNDLE9BQU8sT0FBTyxDQUFDO2dCQUNoQixDQUFDO2dCQUVNLDRCQUFPLEdBQWQ7Z0JBRUEsQ0FBQztnQkFFRixpQkFBQztZQUFELENBQUMsQUFsQkQsSUFrQkM7WUFsQlksa0JBQVUsYUFrQnRCLENBQUE7UUFDRixDQUFDLEVBcEJtQixPQUFPLEdBQVAsYUFBTyxLQUFQLGFBQU8sUUFvQjFCO0lBQUQsQ0FBQyxFQXBCYSxLQUFLLEdBQUwsWUFBSyxLQUFMLFlBQUssUUFvQmxCO0FBQUQsQ0FBQyxFQXBCTSxNQUFNLEtBQU4sTUFBTSxRQW9CWjtBQUdEO0lBQUE7SUFBdUYsQ0FBQztJQUEzQyxzQ0FBZSxHQUF0QixjQUFtQyxPQUFPLElBQUksQ0FBQyxDQUFBLENBQUM7SUFBQyxtQkFBQztBQUFELENBQUMsQUFBeEYsSUFBd0Y7QUFTeEYsV0FBTyxNQUFNO0lBQUMsSUFBQSxLQUFLLENBd0JsQjtJQXhCYSxXQUFBLEtBQUs7UUFBQyxJQUFBLFNBQVMsQ0F3QjVCO1FBeEJtQixXQUFBLFNBQVM7WUFBQyxJQUFBLFNBQVMsQ0F3QnRDO1lBeEI2QixXQUFBLFNBQVM7Z0JBRXRDO29CQUNPLGVBQW9CLElBQVc7d0JBQVgsU0FBSSxHQUFKLElBQUksQ0FBTztvQkFBSSxDQUFDO29CQUNuQyxxQkFBSyxHQUFaO3dCQUNDLE9BQU8sSUFBSSxDQUFDO29CQUNiLENBQUM7b0JBRU0sc0JBQU0sR0FBYixVQUFjLEtBQVk7d0JBQ3pCLE9BQU8sSUFBSSxLQUFLLEtBQUssQ0FBQztvQkFDdkIsQ0FBQztvQkFFTSx1QkFBTyxHQUFkLGNBQTBCLE9BQU8sSUFBSSxDQUFDLENBQUMsQ0FBQztvQkFDekMsWUFBQztnQkFBRCxDQUFDLEFBWEQsSUFXQztnQkFYWSxlQUFLLFFBV2pCLENBQUE7Z0JBRUQ7b0JBQTBCLHdCQUFZO29CQUF0Qzs7b0JBUUEsQ0FBQztvQkFOQSxhQUFhO29CQUNOLDhCQUFlLEdBQXRCO3dCQUNDLE9BQU8sSUFBSSxLQUFLLENBQUMsSUFBSSxDQUFDLENBQUM7b0JBQ3hCLENBQUM7b0JBR0YsV0FBQztnQkFBRCxDQUFDLEFBUkQsQ0FBMEIsWUFBWSxHQVFyQztnQkFSWSxjQUFJLE9BUWhCLENBQUE7WUFDRixDQUFDLEVBeEI2QixTQUFTLEdBQVQsbUJBQVMsS0FBVCxtQkFBUyxRQXdCdEM7UUFBRCxDQUFDLEVBeEJtQixTQUFTLEdBQVQsZUFBUyxLQUFULGVBQVMsUUF3QjVCO0lBQUQsQ0FBQyxFQXhCYSxLQUFLLEdBQUwsWUFBSyxLQUFMLFlBQUssUUF3QmxCO0FBQUQsQ0FBQyxFQXhCTSxNQUFNLEtBQU4sTUFBTSxRQXdCWiJ9,Ly8gU2NlbmFyaW8gMTogVGVzdCByZXF1cnNpdmUgZnVuY3Rpb24gY2FsbCB3aXRoICJ0aGlzIiBwYXJhbWV0ZXIKLy8gU2NlbmFyaW8gMjogVGVzdCByZWN1cnNpdmUgZnVuY3Rpb24gY2FsbCB3aXRoIGNhc3QgYW5kICJ0aGlzIiBwYXJhbWV0ZXIKCgoKZGVjbGFyZSBtb2R1bGUgU2FtcGxlLlRoaW5nIHsKCglleHBvcnQgaW50ZXJmYWNlIElXaWRnZXQgewoJCWdldERvbU5vZGUoKTogYW55OwoJCWRlc3Ryb3koKTsKCQlnYXIocnVubmVyOih3aWRnZXQ6U2FtcGxlLlRoaW5nLklXaWRnZXQpPT5hbnkpOmFueTsKCX0KCglleHBvcnQgaW50ZXJmYWNlIElDb2RlVGhpbmcgewogIAogIAkJZ2V0RG9tTm9kZSgpOiBFbGVtZW50OwoJCQoJCWFkZFdpZGdldCh3aWRnZXRJZDpzdHJpbmcsIHdpZGdldDpJV2lkZ2V0KTsKCgkJCgkJZm9jdXMoKTsgCgkJCgkJLy9hZGRXaWRnZXQod2lkZ2V0OiBTYW1wbGUuVGhpbmcuV2lkZ2V0cy5JV2lkZ2V0KTsKCX0KCglleHBvcnQgaW50ZXJmYWNlIElBY3Rpb24gewoJCXJ1bihUaGluZzpJQ29kZVRoaW5nKTpib29sZWFuOwoJCWdldElkKCk6c3RyaW5nOwoJfQkKfQoKbW9kdWxlIFNhbXBsZS5BY3Rpb25zLlRoaW5nLkZpbmQgewoJZXhwb3J0IGNsYXNzIFN0YXJ0RmluZEFjdGlvbiBpbXBsZW1lbnRzIFNhbXBsZS5UaGluZy5JQWN0aW9uIHsKCQkKCQlwdWJsaWMgZ2V0SWQoKSB7IHJldHVybiAieW8iOyB9CgkJCgkJcHVibGljIHJ1bihUaGluZzpTYW1wbGUuVGhpbmcuSUNvZGVUaGluZyk6Ym9vbGVhbiB7CgoJCQlyZXR1cm4gdHJ1ZTsKCQl9Cgl9Cn0KCm1vZHVsZSBTYW1wbGUuVGhpbmcuV2lkZ2V0cyB7CglleHBvcnQgY2xhc3MgRmluZFdpZGdldCBpbXBsZW1lbnRzIFNhbXBsZS5UaGluZy5JV2lkZ2V0IHsKCgkJcHVibGljIGdhcihydW5uZXI6KHdpZGdldDpTYW1wbGUuVGhpbmcuSVdpZGdldCk9PmFueSkgeyBpZiAodHJ1ZSkge3JldHVybiBydW5uZXIodGhpcyk7fX0KCQkJCgkJcHJpdmF0ZSBkb21Ob2RlOmFueSA9IG51bGw7CgkJY29uc3RydWN0b3IocHJpdmF0ZSBjb2RlVGhpbmc6IFNhbXBsZS5UaGluZy5JQ29kZVRoaW5nKSB7CgkJICAgIC8vIHNjZW5hcmlvIDEKCQkgICAgY29kZVRoaW5nLmFkZFdpZGdldCgiYWRkV2lkZ2V0IiwgdGhpcyk7CgkJfQoJCQoJCXB1YmxpYyBnZXREb21Ob2RlKCkgewoJCQlyZXR1cm4gZG9tTm9kZTsKCQl9CgkJCgkJcHVibGljIGRlc3Ryb3koKSB7CgoJCX0KCgl9Cn0KCmludGVyZmFjZSBJTW9kZSB7IGdldEluaXRpYWxTdGF0ZSgpOiBJU3RhdGU7fSAKY2xhc3MgQWJzdHJhY3RNb2RlIGltcGxlbWVudHMgSU1vZGUgeyBwdWJsaWMgZ2V0SW5pdGlhbFN0YXRlKCk6IElTdGF0ZSB7IHJldHVybiBudWxsO30gfQoKaW50ZXJmYWNlIElTdGF0ZSB7fQoKaW50ZXJmYWNlIFdpbmRvdyB7CiAgICBvcGVuZXI6IFdpbmRvdzsKfQpkZWNsYXJlIHZhciBzZWxmOiBXaW5kb3c7Cgptb2R1bGUgU2FtcGxlLlRoaW5nLkxhbmd1YWdlcy5QbGFpblRleHQgewoJCglleHBvcnQgY2xhc3MgU3RhdGUgaW1wbGVtZW50cyBJU3RhdGUgewkJCiAgICAgICAgY29uc3RydWN0b3IocHJpdmF0ZSBtb2RlOiBJTW9kZSkgeyB9CgkJcHVibGljIGNsb25lKCk6SVN0YXRlIHsKCQkJcmV0dXJuIHRoaXM7CgkJfQoKCQlwdWJsaWMgZXF1YWxzKG90aGVyOklTdGF0ZSk6Ym9vbGVhbiB7CgkJCXJldHVybiB0aGlzID09PSBvdGhlcjsKCQl9CgkJCgkJcHVibGljIGdldE1vZGUoKTogSU1vZGUgeyByZXR1cm4gbW9kZTsgfQoJfQoJCglleHBvcnQgY2xhc3MgTW9kZSBleHRlbmRzIEFic3RyYWN0TW9kZSB7CgoJCS8vIHNjZW5hcmlvIDIKCQlwdWJsaWMgZ2V0SW5pdGlhbFN0YXRlKCk6IElTdGF0ZSB7CgkJCXJldHVybiBuZXcgU3RhdGUoc2VsZik7CgkJfQoKCgl9Cn0KCg== diff --git a/tests/baselines/reference/recursiveClassReferenceTest.sourcemap.txt b/tests/baselines/reference/recursiveClassReferenceTest.sourcemap.txt index bef310b69d6..fc603c7b168 100644 --- a/tests/baselines/reference/recursiveClassReferenceTest.sourcemap.txt +++ b/tests/baselines/reference/recursiveClassReferenceTest.sourcemap.txt @@ -30,7 +30,7 @@ sourceFile:recursiveClassReferenceTest.ts >>> var extendStatics = function (d, b) { >>> extendStatics = Object.setPrototypeOf || >>> ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || ->>> function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; +>>> function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; >>> return extendStatics(d, b); >>> }; >>> return function (d, b) { diff --git a/tests/baselines/reference/recursiveComplicatedClasses.js b/tests/baselines/reference/recursiveComplicatedClasses.js index aab96bfe740..87edb62c641 100644 --- a/tests/baselines/reference/recursiveComplicatedClasses.js +++ b/tests/baselines/reference/recursiveComplicatedClasses.js @@ -29,7 +29,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/recursivelySpecializedConstructorDeclaration.js b/tests/baselines/reference/recursivelySpecializedConstructorDeclaration.js index bf5c0b583e3..608a8a0f41b 100644 --- a/tests/baselines/reference/recursivelySpecializedConstructorDeclaration.js +++ b/tests/baselines/reference/recursivelySpecializedConstructorDeclaration.js @@ -34,7 +34,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/reexportClassDefinition.js b/tests/baselines/reference/reexportClassDefinition.js index 2e879f06f72..df6deeeb9e2 100644 --- a/tests/baselines/reference/reexportClassDefinition.js +++ b/tests/baselines/reference/reexportClassDefinition.js @@ -37,7 +37,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/reexportDefaultIsCallable.js b/tests/baselines/reference/reexportDefaultIsCallable.js index f31897a88aa..97236d51bac 100644 --- a/tests/baselines/reference/reexportDefaultIsCallable.js +++ b/tests/baselines/reference/reexportDefaultIsCallable.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/reexportedMissingAlias.js b/tests/baselines/reference/reexportedMissingAlias.js index e15775ff33b..7e662140ea1 100644 --- a/tests/baselines/reference/reexportedMissingAlias.js +++ b/tests/baselines/reference/reexportedMissingAlias.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/resolvingClassDeclarationWhenInBaseTypeResolution.js b/tests/baselines/reference/resolvingClassDeclarationWhenInBaseTypeResolution.js index 089ed60b9ed..2081e9d580f 100644 --- a/tests/baselines/reference/resolvingClassDeclarationWhenInBaseTypeResolution.js +++ b/tests/baselines/reference/resolvingClassDeclarationWhenInBaseTypeResolution.js @@ -1024,7 +1024,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/returnInConstructor1.js b/tests/baselines/reference/returnInConstructor1.js index 282d7d2efe5..55c710cf30c 100644 --- a/tests/baselines/reference/returnInConstructor1.js +++ b/tests/baselines/reference/returnInConstructor1.js @@ -71,7 +71,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/returnStatements.js b/tests/baselines/reference/returnStatements.js index cd129389843..a85bb7c7618 100644 --- a/tests/baselines/reference/returnStatements.js +++ b/tests/baselines/reference/returnStatements.js @@ -29,7 +29,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/returnTypePredicateIsInstantiateInContextOfTarget.js b/tests/baselines/reference/returnTypePredicateIsInstantiateInContextOfTarget.js index 8428f81bd05..7745748a91b 100644 --- a/tests/baselines/reference/returnTypePredicateIsInstantiateInContextOfTarget.js +++ b/tests/baselines/reference/returnTypePredicateIsInstantiateInContextOfTarget.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/scopeCheckExtendedClassInsidePublicMethod2.js b/tests/baselines/reference/scopeCheckExtendedClassInsidePublicMethod2.js index d3d3f2a63e3..06c5fb0676c 100644 --- a/tests/baselines/reference/scopeCheckExtendedClassInsidePublicMethod2.js +++ b/tests/baselines/reference/scopeCheckExtendedClassInsidePublicMethod2.js @@ -13,7 +13,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/scopeCheckExtendedClassInsideStaticMethod1.js b/tests/baselines/reference/scopeCheckExtendedClassInsideStaticMethod1.js index c0efe733fd8..2a6f0b427d7 100644 --- a/tests/baselines/reference/scopeCheckExtendedClassInsideStaticMethod1.js +++ b/tests/baselines/reference/scopeCheckExtendedClassInsideStaticMethod1.js @@ -13,7 +13,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/scopeTests.js b/tests/baselines/reference/scopeTests.js index df099bf46e8..78b7f133fc8 100644 --- a/tests/baselines/reference/scopeTests.js +++ b/tests/baselines/reference/scopeTests.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/shadowPrivateMembers.js b/tests/baselines/reference/shadowPrivateMembers.js index e358e6b22f6..06e2c22eace 100644 --- a/tests/baselines/reference/shadowPrivateMembers.js +++ b/tests/baselines/reference/shadowPrivateMembers.js @@ -8,7 +8,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/signaturesUseJSDocForOptionalParameters.symbols b/tests/baselines/reference/signaturesUseJSDocForOptionalParameters.symbols index 2599ea3f207..8b7d84611f3 100644 --- a/tests/baselines/reference/signaturesUseJSDocForOptionalParameters.symbols +++ b/tests/baselines/reference/signaturesUseJSDocForOptionalParameters.symbols @@ -3,6 +3,8 @@ function MyClass() { >MyClass : Symbol(MyClass, Decl(jsDocOptionality.js, 0, 0)) this.prop = null; +>this.prop : Symbol(MyClass.prop, Decl(jsDocOptionality.js, 0, 20)) +>this : Symbol(MyClass, Decl(jsDocOptionality.js, 0, 0)) >prop : Symbol(MyClass.prop, Decl(jsDocOptionality.js, 0, 20)) } /** diff --git a/tests/baselines/reference/signaturesUseJSDocForOptionalParameters.types b/tests/baselines/reference/signaturesUseJSDocForOptionalParameters.types index d1bdb0611bc..7d4bd7cd2b0 100644 --- a/tests/baselines/reference/signaturesUseJSDocForOptionalParameters.types +++ b/tests/baselines/reference/signaturesUseJSDocForOptionalParameters.types @@ -5,7 +5,7 @@ function MyClass() { this.prop = null; >this.prop = null : null >this.prop : any ->this : any +>this : this >prop : any >null : null } diff --git a/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndExtendsClause.js b/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndExtendsClause.js index b013c753b1e..c437b6bd6d0 100644 --- a/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndExtendsClause.js +++ b/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndExtendsClause.js @@ -12,7 +12,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndExtendsClause.js.map b/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndExtendsClause.js.map index d47216ebf51..86960590686 100644 --- a/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndExtendsClause.js.map +++ b/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndExtendsClause.js.map @@ -1,3 +1,3 @@ //// [sourceMapValidationClassWithDefaultConstructorAndExtendsClause.js.map] {"version":3,"file":"sourceMapValidationClassWithDefaultConstructorAndExtendsClause.js","sourceRoot":"","sources":["sourceMapValidationClassWithDefaultConstructorAndExtendsClause.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA;IAAA;IACA,CAAC;IAAD,sBAAC;AAAD,CAAC,AADD,IACC;AAED;IAAsB,2BAAe;IAArC;QAAA,qEAGC;QAFU,OAAC,GAAG,EAAE,CAAC;QACP,WAAK,GAAG,KAAK,CAAC;;IACzB,CAAC;IAAD,cAAC;AAAD,CAAC,AAHD,CAAsB,eAAe,GAGpC"} -//// https://sokra.github.io/source-map-visualization#base64,dmFyIF9fZXh0ZW5kcyA9ICh0aGlzICYmIHRoaXMuX19leHRlbmRzKSB8fCAoZnVuY3Rpb24gKCkgew0KICAgIHZhciBleHRlbmRTdGF0aWNzID0gZnVuY3Rpb24gKGQsIGIpIHsNCiAgICAgICAgZXh0ZW5kU3RhdGljcyA9IE9iamVjdC5zZXRQcm90b3R5cGVPZiB8fA0KICAgICAgICAgICAgKHsgX19wcm90b19fOiBbXSB9IGluc3RhbmNlb2YgQXJyYXkgJiYgZnVuY3Rpb24gKGQsIGIpIHsgZC5fX3Byb3RvX18gPSBiOyB9KSB8fA0KICAgICAgICAgICAgZnVuY3Rpb24gKGQsIGIpIHsgZm9yICh2YXIgcCBpbiBiKSBpZiAoYi5oYXNPd25Qcm9wZXJ0eShwKSkgZFtwXSA9IGJbcF07IH07DQogICAgICAgIHJldHVybiBleHRlbmRTdGF0aWNzKGQsIGIpOw0KICAgIH07DQogICAgcmV0dXJuIGZ1bmN0aW9uIChkLCBiKSB7DQogICAgICAgIGV4dGVuZFN0YXRpY3MoZCwgYik7DQogICAgICAgIGZ1bmN0aW9uIF9fKCkgeyB0aGlzLmNvbnN0cnVjdG9yID0gZDsgfQ0KICAgICAgICBkLnByb3RvdHlwZSA9IGIgPT09IG51bGwgPyBPYmplY3QuY3JlYXRlKGIpIDogKF9fLnByb3RvdHlwZSA9IGIucHJvdG90eXBlLCBuZXcgX18oKSk7DQogICAgfTsNCn0pKCk7DQp2YXIgQWJzdHJhY3RHcmVldGVyID0gLyoqIEBjbGFzcyAqLyAoZnVuY3Rpb24gKCkgew0KICAgIGZ1bmN0aW9uIEFic3RyYWN0R3JlZXRlcigpIHsNCiAgICB9DQogICAgcmV0dXJuIEFic3RyYWN0R3JlZXRlcjsNCn0oKSk7DQp2YXIgR3JlZXRlciA9IC8qKiBAY2xhc3MgKi8gKGZ1bmN0aW9uIChfc3VwZXIpIHsNCiAgICBfX2V4dGVuZHMoR3JlZXRlciwgX3N1cGVyKTsNCiAgICBmdW5jdGlvbiBHcmVldGVyKCkgew0KICAgICAgICB2YXIgX3RoaXMgPSBfc3VwZXIgIT09IG51bGwgJiYgX3N1cGVyLmFwcGx5KHRoaXMsIGFyZ3VtZW50cykgfHwgdGhpczsNCiAgICAgICAgX3RoaXMuYSA9IDEwOw0KICAgICAgICBfdGhpcy5uYW1lQSA9ICJUZW4iOw0KICAgICAgICByZXR1cm4gX3RoaXM7DQogICAgfQ0KICAgIHJldHVybiBHcmVldGVyOw0KfShBYnN0cmFjdEdyZWV0ZXIpKTsNCi8vIyBzb3VyY2VNYXBwaW5nVVJMPXNvdXJjZU1hcFZhbGlkYXRpb25DbGFzc1dpdGhEZWZhdWx0Q29uc3RydWN0b3JBbmRFeHRlbmRzQ2xhdXNlLmpzLm1hcA==,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic291cmNlTWFwVmFsaWRhdGlvbkNsYXNzV2l0aERlZmF1bHRDb25zdHJ1Y3RvckFuZEV4dGVuZHNDbGF1c2UuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJzb3VyY2VNYXBWYWxpZGF0aW9uQ2xhc3NXaXRoRGVmYXVsdENvbnN0cnVjdG9yQW5kRXh0ZW5kc0NsYXVzZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7Ozs7Ozs7Ozs7O0FBQUE7SUFBQTtJQUNBLENBQUM7SUFBRCxzQkFBQztBQUFELENBQUMsQUFERCxJQUNDO0FBRUQ7SUFBc0IsMkJBQWU7SUFBckM7UUFBQSxxRUFHQztRQUZVLE9BQUMsR0FBRyxFQUFFLENBQUM7UUFDUCxXQUFLLEdBQUcsS0FBSyxDQUFDOztJQUN6QixDQUFDO0lBQUQsY0FBQztBQUFELENBQUMsQUFIRCxDQUFzQixlQUFlLEdBR3BDIn0=,Y2xhc3MgQWJzdHJhY3RHcmVldGVyIHsKfQoKY2xhc3MgR3JlZXRlciBleHRlbmRzIEFic3RyYWN0R3JlZXRlciB7CiAgICBwdWJsaWMgYSA9IDEwOwogICAgcHVibGljIG5hbWVBID0gIlRlbiI7Cn0= +//// https://sokra.github.io/source-map-visualization#base64,dmFyIF9fZXh0ZW5kcyA9ICh0aGlzICYmIHRoaXMuX19leHRlbmRzKSB8fCAoZnVuY3Rpb24gKCkgew0KICAgIHZhciBleHRlbmRTdGF0aWNzID0gZnVuY3Rpb24gKGQsIGIpIHsNCiAgICAgICAgZXh0ZW5kU3RhdGljcyA9IE9iamVjdC5zZXRQcm90b3R5cGVPZiB8fA0KICAgICAgICAgICAgKHsgX19wcm90b19fOiBbXSB9IGluc3RhbmNlb2YgQXJyYXkgJiYgZnVuY3Rpb24gKGQsIGIpIHsgZC5fX3Byb3RvX18gPSBiOyB9KSB8fA0KICAgICAgICAgICAgZnVuY3Rpb24gKGQsIGIpIHsgZm9yICh2YXIgcCBpbiBiKSBpZiAoT2JqZWN0LnByb3RvdHlwZS5oYXNPd25Qcm9wZXJ0eS5jYWxsKGIsIHApKSBkW3BdID0gYltwXTsgfTsNCiAgICAgICAgcmV0dXJuIGV4dGVuZFN0YXRpY3MoZCwgYik7DQogICAgfTsNCiAgICByZXR1cm4gZnVuY3Rpb24gKGQsIGIpIHsNCiAgICAgICAgZXh0ZW5kU3RhdGljcyhkLCBiKTsNCiAgICAgICAgZnVuY3Rpb24gX18oKSB7IHRoaXMuY29uc3RydWN0b3IgPSBkOyB9DQogICAgICAgIGQucHJvdG90eXBlID0gYiA9PT0gbnVsbCA/IE9iamVjdC5jcmVhdGUoYikgOiAoX18ucHJvdG90eXBlID0gYi5wcm90b3R5cGUsIG5ldyBfXygpKTsNCiAgICB9Ow0KfSkoKTsNCnZhciBBYnN0cmFjdEdyZWV0ZXIgPSAvKiogQGNsYXNzICovIChmdW5jdGlvbiAoKSB7DQogICAgZnVuY3Rpb24gQWJzdHJhY3RHcmVldGVyKCkgew0KICAgIH0NCiAgICByZXR1cm4gQWJzdHJhY3RHcmVldGVyOw0KfSgpKTsNCnZhciBHcmVldGVyID0gLyoqIEBjbGFzcyAqLyAoZnVuY3Rpb24gKF9zdXBlcikgew0KICAgIF9fZXh0ZW5kcyhHcmVldGVyLCBfc3VwZXIpOw0KICAgIGZ1bmN0aW9uIEdyZWV0ZXIoKSB7DQogICAgICAgIHZhciBfdGhpcyA9IF9zdXBlciAhPT0gbnVsbCAmJiBfc3VwZXIuYXBwbHkodGhpcywgYXJndW1lbnRzKSB8fCB0aGlzOw0KICAgICAgICBfdGhpcy5hID0gMTA7DQogICAgICAgIF90aGlzLm5hbWVBID0gIlRlbiI7DQogICAgICAgIHJldHVybiBfdGhpczsNCiAgICB9DQogICAgcmV0dXJuIEdyZWV0ZXI7DQp9KEFic3RyYWN0R3JlZXRlcikpOw0KLy8jIHNvdXJjZU1hcHBpbmdVUkw9c291cmNlTWFwVmFsaWRhdGlvbkNsYXNzV2l0aERlZmF1bHRDb25zdHJ1Y3RvckFuZEV4dGVuZHNDbGF1c2UuanMubWFw,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic291cmNlTWFwVmFsaWRhdGlvbkNsYXNzV2l0aERlZmF1bHRDb25zdHJ1Y3RvckFuZEV4dGVuZHNDbGF1c2UuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJzb3VyY2VNYXBWYWxpZGF0aW9uQ2xhc3NXaXRoRGVmYXVsdENvbnN0cnVjdG9yQW5kRXh0ZW5kc0NsYXVzZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7Ozs7Ozs7Ozs7O0FBQUE7SUFBQTtJQUNBLENBQUM7SUFBRCxzQkFBQztBQUFELENBQUMsQUFERCxJQUNDO0FBRUQ7SUFBc0IsMkJBQWU7SUFBckM7UUFBQSxxRUFHQztRQUZVLE9BQUMsR0FBRyxFQUFFLENBQUM7UUFDUCxXQUFLLEdBQUcsS0FBSyxDQUFDOztJQUN6QixDQUFDO0lBQUQsY0FBQztBQUFELENBQUMsQUFIRCxDQUFzQixlQUFlLEdBR3BDIn0=,Y2xhc3MgQWJzdHJhY3RHcmVldGVyIHsKfQoKY2xhc3MgR3JlZXRlciBleHRlbmRzIEFic3RyYWN0R3JlZXRlciB7CiAgICBwdWJsaWMgYSA9IDEwOwogICAgcHVibGljIG5hbWVBID0gIlRlbiI7Cn0= diff --git a/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndExtendsClause.sourcemap.txt b/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndExtendsClause.sourcemap.txt index e986b037f28..f772f8350c0 100644 --- a/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndExtendsClause.sourcemap.txt +++ b/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndExtendsClause.sourcemap.txt @@ -12,7 +12,7 @@ sourceFile:sourceMapValidationClassWithDefaultConstructorAndExtendsClause.ts >>> var extendStatics = function (d, b) { >>> extendStatics = Object.setPrototypeOf || >>> ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || ->>> function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; +>>> function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; >>> return extendStatics(d, b); >>> }; >>> return function (d, b) { diff --git a/tests/baselines/reference/specializedInheritedConstructors1.js b/tests/baselines/reference/specializedInheritedConstructors1.js index f219fa5ad18..52efdcc524b 100644 --- a/tests/baselines/reference/specializedInheritedConstructors1.js +++ b/tests/baselines/reference/specializedInheritedConstructors1.js @@ -22,7 +22,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/specializedOverloadWithRestParameters.js b/tests/baselines/reference/specializedOverloadWithRestParameters.js index d39993c9cb1..6a620711fa3 100644 --- a/tests/baselines/reference/specializedOverloadWithRestParameters.js +++ b/tests/baselines/reference/specializedOverloadWithRestParameters.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/spellingSuggestionJSXAttribute.js b/tests/baselines/reference/spellingSuggestionJSXAttribute.js index 00a0835a975..1adc159bd65 100644 --- a/tests/baselines/reference/spellingSuggestionJSXAttribute.js +++ b/tests/baselines/reference/spellingSuggestionJSXAttribute.js @@ -22,7 +22,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/staticFactory1.js b/tests/baselines/reference/staticFactory1.js index d63ea13df37..aeca6de2d36 100644 --- a/tests/baselines/reference/staticFactory1.js +++ b/tests/baselines/reference/staticFactory1.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/staticInheritance.js b/tests/baselines/reference/staticInheritance.js index 1eb96f48cd6..97e7cd6f78b 100644 --- a/tests/baselines/reference/staticInheritance.js +++ b/tests/baselines/reference/staticInheritance.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/staticMemberAccessOffDerivedType1.js b/tests/baselines/reference/staticMemberAccessOffDerivedType1.js index a3dddaffb5d..366b812380d 100644 --- a/tests/baselines/reference/staticMemberAccessOffDerivedType1.js +++ b/tests/baselines/reference/staticMemberAccessOffDerivedType1.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/staticMismatchBecauseOfPrototype.js b/tests/baselines/reference/staticMismatchBecauseOfPrototype.js index 4bc7b248957..ab2dddd34f3 100644 --- a/tests/baselines/reference/staticMismatchBecauseOfPrototype.js +++ b/tests/baselines/reference/staticMismatchBecauseOfPrototype.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/staticPropSuper.js b/tests/baselines/reference/staticPropSuper.js index b6be7f641c6..d7483b59a7c 100644 --- a/tests/baselines/reference/staticPropSuper.js +++ b/tests/baselines/reference/staticPropSuper.js @@ -40,7 +40,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/strictModeInConstructor.js b/tests/baselines/reference/strictModeInConstructor.js index d7e877eda2f..aee08fb16c3 100644 --- a/tests/baselines/reference/strictModeInConstructor.js +++ b/tests/baselines/reference/strictModeInConstructor.js @@ -65,7 +65,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/strictModeReservedWord.js b/tests/baselines/reference/strictModeReservedWord.js index 34c606891fb..12c0c8feaa5 100644 --- a/tests/baselines/reference/strictModeReservedWord.js +++ b/tests/baselines/reference/strictModeReservedWord.js @@ -32,7 +32,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/strictModeReservedWordInClassDeclaration.js b/tests/baselines/reference/strictModeReservedWordInClassDeclaration.js index 45d08b13928..c0f397f1f14 100644 --- a/tests/baselines/reference/strictModeReservedWordInClassDeclaration.js +++ b/tests/baselines/reference/strictModeReservedWordInClassDeclaration.js @@ -33,7 +33,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/stringIndexerConstrainsPropertyDeclarations2.js b/tests/baselines/reference/stringIndexerConstrainsPropertyDeclarations2.js index 900e31ab45b..82dab0a776a 100644 --- a/tests/baselines/reference/stringIndexerConstrainsPropertyDeclarations2.js +++ b/tests/baselines/reference/stringIndexerConstrainsPropertyDeclarations2.js @@ -45,7 +45,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subSubClassCanAccessProtectedConstructor.js b/tests/baselines/reference/subSubClassCanAccessProtectedConstructor.js index 11201f069e5..fb259b8ec8d 100644 --- a/tests/baselines/reference/subSubClassCanAccessProtectedConstructor.js +++ b/tests/baselines/reference/subSubClassCanAccessProtectedConstructor.js @@ -21,7 +21,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subtypesOfTypeParameter.js b/tests/baselines/reference/subtypesOfTypeParameter.js index 49b041b639e..3462785f78d 100644 --- a/tests/baselines/reference/subtypesOfTypeParameter.js +++ b/tests/baselines/reference/subtypesOfTypeParameter.js @@ -111,7 +111,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subtypesOfTypeParameterWithConstraints.js b/tests/baselines/reference/subtypesOfTypeParameterWithConstraints.js index a2d3b35680f..4ca9a95cf8b 100644 --- a/tests/baselines/reference/subtypesOfTypeParameterWithConstraints.js +++ b/tests/baselines/reference/subtypesOfTypeParameterWithConstraints.js @@ -173,7 +173,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subtypesOfTypeParameterWithConstraints4.js b/tests/baselines/reference/subtypesOfTypeParameterWithConstraints4.js index 6038e2cb175..754a842b104 100644 --- a/tests/baselines/reference/subtypesOfTypeParameterWithConstraints4.js +++ b/tests/baselines/reference/subtypesOfTypeParameterWithConstraints4.js @@ -84,7 +84,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subtypesOfTypeParameterWithRecursiveConstraints.js b/tests/baselines/reference/subtypesOfTypeParameterWithRecursiveConstraints.js index 5589dccf77e..e0d42a4a3dd 100644 --- a/tests/baselines/reference/subtypesOfTypeParameterWithRecursiveConstraints.js +++ b/tests/baselines/reference/subtypesOfTypeParameterWithRecursiveConstraints.js @@ -163,7 +163,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subtypingTransitivity.js b/tests/baselines/reference/subtypingTransitivity.js index e1a8fab95c3..60aa4c53bb4 100644 --- a/tests/baselines/reference/subtypingTransitivity.js +++ b/tests/baselines/reference/subtypingTransitivity.js @@ -24,7 +24,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subtypingWithCallSignatures2.js b/tests/baselines/reference/subtypingWithCallSignatures2.js index bd2d50d5b75..844450e2ab8 100644 --- a/tests/baselines/reference/subtypingWithCallSignatures2.js +++ b/tests/baselines/reference/subtypingWithCallSignatures2.js @@ -178,7 +178,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subtypingWithCallSignatures3.js b/tests/baselines/reference/subtypingWithCallSignatures3.js index 048bfb9dad3..a9538091b42 100644 --- a/tests/baselines/reference/subtypingWithCallSignatures3.js +++ b/tests/baselines/reference/subtypingWithCallSignatures3.js @@ -125,7 +125,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subtypingWithCallSignatures4.js b/tests/baselines/reference/subtypingWithCallSignatures4.js index 305c162088d..f32303231bc 100644 --- a/tests/baselines/reference/subtypingWithCallSignatures4.js +++ b/tests/baselines/reference/subtypingWithCallSignatures4.js @@ -117,7 +117,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subtypingWithConstructSignatures2.js b/tests/baselines/reference/subtypingWithConstructSignatures2.js index 1deee7a0bfc..148341cb4b2 100644 --- a/tests/baselines/reference/subtypingWithConstructSignatures2.js +++ b/tests/baselines/reference/subtypingWithConstructSignatures2.js @@ -178,7 +178,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subtypingWithConstructSignatures3.js b/tests/baselines/reference/subtypingWithConstructSignatures3.js index 257422621e9..941b3d02aa7 100644 --- a/tests/baselines/reference/subtypingWithConstructSignatures3.js +++ b/tests/baselines/reference/subtypingWithConstructSignatures3.js @@ -127,7 +127,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subtypingWithConstructSignatures4.js b/tests/baselines/reference/subtypingWithConstructSignatures4.js index 6489ece9b0a..2818263c909 100644 --- a/tests/baselines/reference/subtypingWithConstructSignatures4.js +++ b/tests/baselines/reference/subtypingWithConstructSignatures4.js @@ -117,7 +117,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subtypingWithConstructSignatures5.js b/tests/baselines/reference/subtypingWithConstructSignatures5.js index cbfa0fe360c..7455da5cc8b 100644 --- a/tests/baselines/reference/subtypingWithConstructSignatures5.js +++ b/tests/baselines/reference/subtypingWithConstructSignatures5.js @@ -55,7 +55,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subtypingWithConstructSignatures6.js b/tests/baselines/reference/subtypingWithConstructSignatures6.js index d8a9b66e75d..190fa3b8a4d 100644 --- a/tests/baselines/reference/subtypingWithConstructSignatures6.js +++ b/tests/baselines/reference/subtypingWithConstructSignatures6.js @@ -58,7 +58,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subtypingWithNumericIndexer.js b/tests/baselines/reference/subtypingWithNumericIndexer.js index d26d4298ac5..1953ca68587 100644 --- a/tests/baselines/reference/subtypingWithNumericIndexer.js +++ b/tests/baselines/reference/subtypingWithNumericIndexer.js @@ -45,7 +45,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subtypingWithNumericIndexer3.js b/tests/baselines/reference/subtypingWithNumericIndexer3.js index 087436392d5..ecfb15ab80c 100644 --- a/tests/baselines/reference/subtypingWithNumericIndexer3.js +++ b/tests/baselines/reference/subtypingWithNumericIndexer3.js @@ -49,7 +49,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subtypingWithNumericIndexer4.js b/tests/baselines/reference/subtypingWithNumericIndexer4.js index ec5190315f1..6d3abbdfbc1 100644 --- a/tests/baselines/reference/subtypingWithNumericIndexer4.js +++ b/tests/baselines/reference/subtypingWithNumericIndexer4.js @@ -33,7 +33,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subtypingWithObjectMembers.js b/tests/baselines/reference/subtypingWithObjectMembers.js index 3cc540a1113..66a68a40c2c 100644 --- a/tests/baselines/reference/subtypingWithObjectMembers.js +++ b/tests/baselines/reference/subtypingWithObjectMembers.js @@ -72,7 +72,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subtypingWithObjectMembers4.js b/tests/baselines/reference/subtypingWithObjectMembers4.js index 8a7a32957fe..4adc0c03abd 100644 --- a/tests/baselines/reference/subtypingWithObjectMembers4.js +++ b/tests/baselines/reference/subtypingWithObjectMembers4.js @@ -39,7 +39,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subtypingWithObjectMembersAccessibility.js b/tests/baselines/reference/subtypingWithObjectMembersAccessibility.js index 4108a979bf4..6880044ff79 100644 --- a/tests/baselines/reference/subtypingWithObjectMembersAccessibility.js +++ b/tests/baselines/reference/subtypingWithObjectMembersAccessibility.js @@ -39,7 +39,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subtypingWithObjectMembersAccessibility2.js b/tests/baselines/reference/subtypingWithObjectMembersAccessibility2.js index 97eddfb5800..d8489af13a4 100644 --- a/tests/baselines/reference/subtypingWithObjectMembersAccessibility2.js +++ b/tests/baselines/reference/subtypingWithObjectMembersAccessibility2.js @@ -67,7 +67,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subtypingWithStringIndexer.js b/tests/baselines/reference/subtypingWithStringIndexer.js index 64ccbd20430..01dcf36edf6 100644 --- a/tests/baselines/reference/subtypingWithStringIndexer.js +++ b/tests/baselines/reference/subtypingWithStringIndexer.js @@ -46,7 +46,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subtypingWithStringIndexer3.js b/tests/baselines/reference/subtypingWithStringIndexer3.js index ddcdd02b1bb..1260fec1bae 100644 --- a/tests/baselines/reference/subtypingWithStringIndexer3.js +++ b/tests/baselines/reference/subtypingWithStringIndexer3.js @@ -49,7 +49,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/subtypingWithStringIndexer4.js b/tests/baselines/reference/subtypingWithStringIndexer4.js index 37472f84466..da3a7337a2b 100644 --- a/tests/baselines/reference/subtypingWithStringIndexer4.js +++ b/tests/baselines/reference/subtypingWithStringIndexer4.js @@ -33,7 +33,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/super.js b/tests/baselines/reference/super.js index 21431891f03..36d82ecc446 100644 --- a/tests/baselines/reference/super.js +++ b/tests/baselines/reference/super.js @@ -42,7 +42,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/super1.js b/tests/baselines/reference/super1.js index 90db9eac32d..c82519d62a4 100644 --- a/tests/baselines/reference/super1.js +++ b/tests/baselines/reference/super1.js @@ -71,7 +71,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/super2.js b/tests/baselines/reference/super2.js index e2de1c65f69..c07a451d2eb 100644 --- a/tests/baselines/reference/super2.js +++ b/tests/baselines/reference/super2.js @@ -55,7 +55,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superAccess.js b/tests/baselines/reference/superAccess.js index beb9303aef7..f211171f2e3 100644 --- a/tests/baselines/reference/superAccess.js +++ b/tests/baselines/reference/superAccess.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superAccess2.js b/tests/baselines/reference/superAccess2.js index 468f6594188..8823e0bfe65 100644 --- a/tests/baselines/reference/superAccess2.js +++ b/tests/baselines/reference/superAccess2.js @@ -29,7 +29,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superAccessCastedCall.js b/tests/baselines/reference/superAccessCastedCall.js index f88b0c92a0f..50e72589aff 100644 --- a/tests/baselines/reference/superAccessCastedCall.js +++ b/tests/baselines/reference/superAccessCastedCall.js @@ -25,7 +25,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superAccessInFatArrow1.js b/tests/baselines/reference/superAccessInFatArrow1.js index c04de1b20e1..5529b491177 100644 --- a/tests/baselines/reference/superAccessInFatArrow1.js +++ b/tests/baselines/reference/superAccessInFatArrow1.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallArgsMustMatch.js b/tests/baselines/reference/superCallArgsMustMatch.js index 9f4b848f31f..ce9b133b3af 100644 --- a/tests/baselines/reference/superCallArgsMustMatch.js +++ b/tests/baselines/reference/superCallArgsMustMatch.js @@ -30,7 +30,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallAssignResult.js b/tests/baselines/reference/superCallAssignResult.js index 1e71a043449..1ce3b984ada 100644 --- a/tests/baselines/reference/superCallAssignResult.js +++ b/tests/baselines/reference/superCallAssignResult.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallBeforeThisAccessing1.js b/tests/baselines/reference/superCallBeforeThisAccessing1.js index d31f3a11bb9..fcf151fdb48 100644 --- a/tests/baselines/reference/superCallBeforeThisAccessing1.js +++ b/tests/baselines/reference/superCallBeforeThisAccessing1.js @@ -21,7 +21,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallBeforeThisAccessing2.js b/tests/baselines/reference/superCallBeforeThisAccessing2.js index 597f53f47cb..14b71702e63 100644 --- a/tests/baselines/reference/superCallBeforeThisAccessing2.js +++ b/tests/baselines/reference/superCallBeforeThisAccessing2.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallBeforeThisAccessing3.js b/tests/baselines/reference/superCallBeforeThisAccessing3.js index 9a81390755e..d7831e1cfef 100644 --- a/tests/baselines/reference/superCallBeforeThisAccessing3.js +++ b/tests/baselines/reference/superCallBeforeThisAccessing3.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallBeforeThisAccessing4.js b/tests/baselines/reference/superCallBeforeThisAccessing4.js index 703db9d917f..b4f9f29e47a 100644 --- a/tests/baselines/reference/superCallBeforeThisAccessing4.js +++ b/tests/baselines/reference/superCallBeforeThisAccessing4.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallBeforeThisAccessing5.js b/tests/baselines/reference/superCallBeforeThisAccessing5.js index 9a2ba0ff0f7..d0e3b1ebbbc 100644 --- a/tests/baselines/reference/superCallBeforeThisAccessing5.js +++ b/tests/baselines/reference/superCallBeforeThisAccessing5.js @@ -12,7 +12,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallBeforeThisAccessing6.js b/tests/baselines/reference/superCallBeforeThisAccessing6.js index b86502f7a1d..d651b4ea8d5 100644 --- a/tests/baselines/reference/superCallBeforeThisAccessing6.js +++ b/tests/baselines/reference/superCallBeforeThisAccessing6.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallBeforeThisAccessing7.js b/tests/baselines/reference/superCallBeforeThisAccessing7.js index d3f62d89012..699cc07c2a7 100644 --- a/tests/baselines/reference/superCallBeforeThisAccessing7.js +++ b/tests/baselines/reference/superCallBeforeThisAccessing7.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallBeforeThisAccessing8.js b/tests/baselines/reference/superCallBeforeThisAccessing8.js index f2880d43913..acc057e63d4 100644 --- a/tests/baselines/reference/superCallBeforeThisAccessing8.js +++ b/tests/baselines/reference/superCallBeforeThisAccessing8.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallFromClassThatDerivesFromGenericType1.js b/tests/baselines/reference/superCallFromClassThatDerivesFromGenericType1.js index b123b279dd8..70ca37d5e36 100644 --- a/tests/baselines/reference/superCallFromClassThatDerivesFromGenericType1.js +++ b/tests/baselines/reference/superCallFromClassThatDerivesFromGenericType1.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallFromClassThatDerivesFromGenericType2.js b/tests/baselines/reference/superCallFromClassThatDerivesFromGenericType2.js index f4fc6dc4286..40cac8fe743 100644 --- a/tests/baselines/reference/superCallFromClassThatDerivesFromGenericType2.js +++ b/tests/baselines/reference/superCallFromClassThatDerivesFromGenericType2.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallFromClassThatDerivesFromGenericTypeButWithIncorrectNumberOfTypeArguments1.js b/tests/baselines/reference/superCallFromClassThatDerivesFromGenericTypeButWithIncorrectNumberOfTypeArguments1.js index 2457c4f01ee..7f40d949c5b 100644 --- a/tests/baselines/reference/superCallFromClassThatDerivesFromGenericTypeButWithIncorrectNumberOfTypeArguments1.js +++ b/tests/baselines/reference/superCallFromClassThatDerivesFromGenericTypeButWithIncorrectNumberOfTypeArguments1.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallFromClassThatDerivesFromGenericTypeButWithNoTypeArguments1.js b/tests/baselines/reference/superCallFromClassThatDerivesFromGenericTypeButWithNoTypeArguments1.js index 016dc25a7af..84fda9707a9 100644 --- a/tests/baselines/reference/superCallFromClassThatDerivesFromGenericTypeButWithNoTypeArguments1.js +++ b/tests/baselines/reference/superCallFromClassThatDerivesFromGenericTypeButWithNoTypeArguments1.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallFromClassThatDerivesNonGenericTypeButWithTypeArguments1.js b/tests/baselines/reference/superCallFromClassThatDerivesNonGenericTypeButWithTypeArguments1.js index 6d4cd18013a..1794f99377f 100644 --- a/tests/baselines/reference/superCallFromClassThatDerivesNonGenericTypeButWithTypeArguments1.js +++ b/tests/baselines/reference/superCallFromClassThatDerivesNonGenericTypeButWithTypeArguments1.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallInNonStaticMethod.js b/tests/baselines/reference/superCallInNonStaticMethod.js index fd1bb59b59b..64028c762eb 100644 --- a/tests/baselines/reference/superCallInNonStaticMethod.js +++ b/tests/baselines/reference/superCallInNonStaticMethod.js @@ -55,7 +55,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallInStaticMethod.js b/tests/baselines/reference/superCallInStaticMethod.js index c43746ee34c..00d23ba0d17 100644 --- a/tests/baselines/reference/superCallInStaticMethod.js +++ b/tests/baselines/reference/superCallInStaticMethod.js @@ -51,7 +51,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallInsideClassDeclaration.js b/tests/baselines/reference/superCallInsideClassDeclaration.js index 87caacf123f..117b632796a 100644 --- a/tests/baselines/reference/superCallInsideClassDeclaration.js +++ b/tests/baselines/reference/superCallInsideClassDeclaration.js @@ -21,7 +21,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallInsideClassExpression.js b/tests/baselines/reference/superCallInsideClassExpression.js index 52a96213326..2b372ae0c10 100644 --- a/tests/baselines/reference/superCallInsideClassExpression.js +++ b/tests/baselines/reference/superCallInsideClassExpression.js @@ -21,7 +21,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallInsideObjectLiteralExpression.js b/tests/baselines/reference/superCallInsideObjectLiteralExpression.js index 12da3b03199..1c9d6df2d05 100644 --- a/tests/baselines/reference/superCallInsideObjectLiteralExpression.js +++ b/tests/baselines/reference/superCallInsideObjectLiteralExpression.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallOutsideConstructor.js b/tests/baselines/reference/superCallOutsideConstructor.js index ed780e5e522..824cf40b25c 100644 --- a/tests/baselines/reference/superCallOutsideConstructor.js +++ b/tests/baselines/reference/superCallOutsideConstructor.js @@ -27,7 +27,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallParameterContextualTyping1.js b/tests/baselines/reference/superCallParameterContextualTyping1.js index 78f37bc1000..2e8ace7f081 100644 --- a/tests/baselines/reference/superCallParameterContextualTyping1.js +++ b/tests/baselines/reference/superCallParameterContextualTyping1.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallParameterContextualTyping2.js b/tests/baselines/reference/superCallParameterContextualTyping2.js index 6051c6398b3..cc34cebdc03 100644 --- a/tests/baselines/reference/superCallParameterContextualTyping2.js +++ b/tests/baselines/reference/superCallParameterContextualTyping2.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallParameterContextualTyping3.js b/tests/baselines/reference/superCallParameterContextualTyping3.js index 94518aec56f..f90b45a7522 100644 --- a/tests/baselines/reference/superCallParameterContextualTyping3.js +++ b/tests/baselines/reference/superCallParameterContextualTyping3.js @@ -36,7 +36,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallWithCommentEmit01.js b/tests/baselines/reference/superCallWithCommentEmit01.js index 2cb12c0ecc2..6dde450469e 100644 --- a/tests/baselines/reference/superCallWithCommentEmit01.js +++ b/tests/baselines/reference/superCallWithCommentEmit01.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallWithMissingBaseClass.js b/tests/baselines/reference/superCallWithMissingBaseClass.js index 07d6860e20c..9ef264bf034 100644 --- a/tests/baselines/reference/superCallWithMissingBaseClass.js +++ b/tests/baselines/reference/superCallWithMissingBaseClass.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCalls.js b/tests/baselines/reference/superCalls.js index 3447e4de698..458c4de1b3d 100644 --- a/tests/baselines/reference/superCalls.js +++ b/tests/baselines/reference/superCalls.js @@ -35,7 +35,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superCallsInConstructor.js b/tests/baselines/reference/superCallsInConstructor.js index 46db033c66b..357de2d96b3 100644 --- a/tests/baselines/reference/superCallsInConstructor.js +++ b/tests/baselines/reference/superCallsInConstructor.js @@ -25,7 +25,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superElementAccess.js b/tests/baselines/reference/superElementAccess.js index e8b9c86b844..c7d2e2f554b 100644 --- a/tests/baselines/reference/superElementAccess.js +++ b/tests/baselines/reference/superElementAccess.js @@ -40,7 +40,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superErrors.js b/tests/baselines/reference/superErrors.js index 35673eaa133..181cb9c61b7 100644 --- a/tests/baselines/reference/superErrors.js +++ b/tests/baselines/reference/superErrors.js @@ -56,7 +56,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superHasMethodsFromMergedInterface.js b/tests/baselines/reference/superHasMethodsFromMergedInterface.js index 5d90f38aed6..f0d96d899a2 100644 --- a/tests/baselines/reference/superHasMethodsFromMergedInterface.js +++ b/tests/baselines/reference/superHasMethodsFromMergedInterface.js @@ -13,7 +13,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superInCatchBlock1.js b/tests/baselines/reference/superInCatchBlock1.js index 85395af19df..73652f84f75 100644 --- a/tests/baselines/reference/superInCatchBlock1.js +++ b/tests/baselines/reference/superInCatchBlock1.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superInConstructorParam1.js b/tests/baselines/reference/superInConstructorParam1.js index cba46b1f92a..44cb54143e6 100644 --- a/tests/baselines/reference/superInConstructorParam1.js +++ b/tests/baselines/reference/superInConstructorParam1.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superInLambdas.js b/tests/baselines/reference/superInLambdas.js index 36ac400184f..d9661def121 100644 --- a/tests/baselines/reference/superInLambdas.js +++ b/tests/baselines/reference/superInLambdas.js @@ -72,7 +72,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superInObjectLiterals_ES5.js b/tests/baselines/reference/superInObjectLiterals_ES5.js index 05c6ec1225a..c6d89398599 100644 --- a/tests/baselines/reference/superInObjectLiterals_ES5.js +++ b/tests/baselines/reference/superInObjectLiterals_ES5.js @@ -64,7 +64,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superNewCall1.js b/tests/baselines/reference/superNewCall1.js index 6842c574142..7021548172f 100644 --- a/tests/baselines/reference/superNewCall1.js +++ b/tests/baselines/reference/superNewCall1.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superNoModifiersCrash.js b/tests/baselines/reference/superNoModifiersCrash.js index b00bd719280..d176cdaf462 100644 --- a/tests/baselines/reference/superNoModifiersCrash.js +++ b/tests/baselines/reference/superNoModifiersCrash.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superPropertyAccess.js b/tests/baselines/reference/superPropertyAccess.js index 3410f4d49f9..e0e499275ad 100644 --- a/tests/baselines/reference/superPropertyAccess.js +++ b/tests/baselines/reference/superPropertyAccess.js @@ -40,7 +40,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superPropertyAccess1.js b/tests/baselines/reference/superPropertyAccess1.js index 950b0471de3..df6a81c1646 100644 --- a/tests/baselines/reference/superPropertyAccess1.js +++ b/tests/baselines/reference/superPropertyAccess1.js @@ -32,7 +32,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superPropertyAccess2.js b/tests/baselines/reference/superPropertyAccess2.js index a04769c9d0f..afc4de02e3f 100644 --- a/tests/baselines/reference/superPropertyAccess2.js +++ b/tests/baselines/reference/superPropertyAccess2.js @@ -32,7 +32,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superPropertyAccessInComputedPropertiesOfNestedType_ES5.js b/tests/baselines/reference/superPropertyAccessInComputedPropertiesOfNestedType_ES5.js index 0d20e9d9beb..6f6e5793496 100644 --- a/tests/baselines/reference/superPropertyAccessInComputedPropertiesOfNestedType_ES5.js +++ b/tests/baselines/reference/superPropertyAccessInComputedPropertiesOfNestedType_ES5.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superPropertyAccessInSuperCall01.js b/tests/baselines/reference/superPropertyAccessInSuperCall01.js index 86d3fc872bf..11843b8da5b 100644 --- a/tests/baselines/reference/superPropertyAccessInSuperCall01.js +++ b/tests/baselines/reference/superPropertyAccessInSuperCall01.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superPropertyAccessNoError.js b/tests/baselines/reference/superPropertyAccessNoError.js index b3473eb1fc7..cacce70d858 100644 --- a/tests/baselines/reference/superPropertyAccessNoError.js +++ b/tests/baselines/reference/superPropertyAccessNoError.js @@ -81,7 +81,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superPropertyAccess_ES5.js b/tests/baselines/reference/superPropertyAccess_ES5.js index be1bbf89e0d..9398841b113 100644 --- a/tests/baselines/reference/superPropertyAccess_ES5.js +++ b/tests/baselines/reference/superPropertyAccess_ES5.js @@ -33,7 +33,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superPropertyElementNoUnusedLexicalThisCapture.js b/tests/baselines/reference/superPropertyElementNoUnusedLexicalThisCapture.js index 061c03d4308..1567d5ca95f 100644 --- a/tests/baselines/reference/superPropertyElementNoUnusedLexicalThisCapture.js +++ b/tests/baselines/reference/superPropertyElementNoUnusedLexicalThisCapture.js @@ -22,7 +22,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superPropertyInConstructorBeforeSuperCall.js b/tests/baselines/reference/superPropertyInConstructorBeforeSuperCall.js index 4e9445cea40..8cddd321e66 100644 --- a/tests/baselines/reference/superPropertyInConstructorBeforeSuperCall.js +++ b/tests/baselines/reference/superPropertyInConstructorBeforeSuperCall.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superSymbolIndexedAccess5.js b/tests/baselines/reference/superSymbolIndexedAccess5.js index 2a932b4e69e..8d2b844f034 100644 --- a/tests/baselines/reference/superSymbolIndexedAccess5.js +++ b/tests/baselines/reference/superSymbolIndexedAccess5.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superSymbolIndexedAccess6.js b/tests/baselines/reference/superSymbolIndexedAccess6.js index f26d4e75b5c..4cf2b335aeb 100644 --- a/tests/baselines/reference/superSymbolIndexedAccess6.js +++ b/tests/baselines/reference/superSymbolIndexedAccess6.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superWithGenericSpecialization.js b/tests/baselines/reference/superWithGenericSpecialization.js index 1e92d132eaa..28f44e12e6d 100644 --- a/tests/baselines/reference/superWithGenericSpecialization.js +++ b/tests/baselines/reference/superWithGenericSpecialization.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superWithGenerics.js b/tests/baselines/reference/superWithGenerics.js index 1a5827122eb..5a2f276ffd2 100644 --- a/tests/baselines/reference/superWithGenerics.js +++ b/tests/baselines/reference/superWithGenerics.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superWithTypeArgument.js b/tests/baselines/reference/superWithTypeArgument.js index aa2e41751e0..95dadd00a6a 100644 --- a/tests/baselines/reference/superWithTypeArgument.js +++ b/tests/baselines/reference/superWithTypeArgument.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superWithTypeArgument2.js b/tests/baselines/reference/superWithTypeArgument2.js index 33d6ef13532..decb8f33271 100644 --- a/tests/baselines/reference/superWithTypeArgument2.js +++ b/tests/baselines/reference/superWithTypeArgument2.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/superWithTypeArgument3.js b/tests/baselines/reference/superWithTypeArgument3.js index 940dda49cb7..7e9c9814afd 100644 --- a/tests/baselines/reference/superWithTypeArgument3.js +++ b/tests/baselines/reference/superWithTypeArgument3.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/super_inside-object-literal-getters-and-setters.js b/tests/baselines/reference/super_inside-object-literal-getters-and-setters.js index e45de8de606..ac395100f5e 100644 --- a/tests/baselines/reference/super_inside-object-literal-getters-and-setters.js +++ b/tests/baselines/reference/super_inside-object-literal-getters-and-setters.js @@ -32,7 +32,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/switchStatements.js b/tests/baselines/reference/switchStatements.js index 0491ea02c9c..f0a5a97b9a5 100644 --- a/tests/baselines/reference/switchStatements.js +++ b/tests/baselines/reference/switchStatements.js @@ -60,7 +60,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/symbolLinkDeclarationEmitModuleNames.js b/tests/baselines/reference/symbolLinkDeclarationEmitModuleNames.js index 7474849c1a8..a09ed1e58b5 100644 --- a/tests/baselines/reference/symbolLinkDeclarationEmitModuleNames.js +++ b/tests/baselines/reference/symbolLinkDeclarationEmitModuleNames.js @@ -50,7 +50,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./src/value-promise"), exports); diff --git a/tests/baselines/reference/systemModuleWithSuperClass.js b/tests/baselines/reference/systemModuleWithSuperClass.js index 59be406cc2f..7c2abe79b04 100644 --- a/tests/baselines/reference/systemModuleWithSuperClass.js +++ b/tests/baselines/reference/systemModuleWithSuperClass.js @@ -35,7 +35,7 @@ System.register(["./foo"], function (exports_1, context_1) { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/targetTypeBaseCalls.js b/tests/baselines/reference/targetTypeBaseCalls.js index d52c59ecc1c..d769700b1f3 100644 --- a/tests/baselines/reference/targetTypeBaseCalls.js +++ b/tests/baselines/reference/targetTypeBaseCalls.js @@ -23,7 +23,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/templateLiteralsAndDecoratorMetadata.js b/tests/baselines/reference/templateLiteralsAndDecoratorMetadata.js new file mode 100644 index 00000000000..72cdd31044d --- /dev/null +++ b/tests/baselines/reference/templateLiteralsAndDecoratorMetadata.js @@ -0,0 +1,31 @@ +//// [templateLiteralsAndDecoratorMetadata.ts] +declare var format: any; +export class Greeter { + @format("Hello, %s") + greeting: `boss` | `employee` = `employee`; //template literals on this line cause the issue +} + +//// [templateLiteralsAndDecoratorMetadata.js] +"use strict"; +var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) { + var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d; + if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc); + else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r; + return c > 3 && r && Object.defineProperty(target, key, r), r; +}; +var __metadata = (this && this.__metadata) || function (k, v) { + if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v); +}; +exports.__esModule = true; +exports.Greeter = void 0; +var Greeter = /** @class */ (function () { + function Greeter() { + this.greeting = "employee"; //template literals on this line cause the issue + } + __decorate([ + format("Hello, %s"), + __metadata("design:type", String) + ], Greeter.prototype, "greeting"); + return Greeter; +}()); +exports.Greeter = Greeter; diff --git a/tests/baselines/reference/templateLiteralsAndDecoratorMetadata.symbols b/tests/baselines/reference/templateLiteralsAndDecoratorMetadata.symbols new file mode 100644 index 00000000000..b027618b354 --- /dev/null +++ b/tests/baselines/reference/templateLiteralsAndDecoratorMetadata.symbols @@ -0,0 +1,13 @@ +=== tests/cases/compiler/templateLiteralsAndDecoratorMetadata.ts === +declare var format: any; +>format : Symbol(format, Decl(templateLiteralsAndDecoratorMetadata.ts, 0, 11)) + +export class Greeter { +>Greeter : Symbol(Greeter, Decl(templateLiteralsAndDecoratorMetadata.ts, 0, 24)) + + @format("Hello, %s") +>format : Symbol(format, Decl(templateLiteralsAndDecoratorMetadata.ts, 0, 11)) + + greeting: `boss` | `employee` = `employee`; //template literals on this line cause the issue +>greeting : Symbol(Greeter.greeting, Decl(templateLiteralsAndDecoratorMetadata.ts, 1, 22)) +} diff --git a/tests/baselines/reference/templateLiteralsAndDecoratorMetadata.types b/tests/baselines/reference/templateLiteralsAndDecoratorMetadata.types new file mode 100644 index 00000000000..5d983f8a5e7 --- /dev/null +++ b/tests/baselines/reference/templateLiteralsAndDecoratorMetadata.types @@ -0,0 +1,16 @@ +=== tests/cases/compiler/templateLiteralsAndDecoratorMetadata.ts === +declare var format: any; +>format : any + +export class Greeter { +>Greeter : Greeter + + @format("Hello, %s") +>format("Hello, %s") : any +>format : any +>"Hello, %s" : "Hello, %s" + + greeting: `boss` | `employee` = `employee`; //template literals on this line cause the issue +>greeting : "boss" | "employee" +>`employee` : "employee" +} diff --git a/tests/baselines/reference/thisConditionalOnMethodReturnOfGenericInstance.js b/tests/baselines/reference/thisConditionalOnMethodReturnOfGenericInstance.js index c903864eb67..878edea580f 100644 --- a/tests/baselines/reference/thisConditionalOnMethodReturnOfGenericInstance.js +++ b/tests/baselines/reference/thisConditionalOnMethodReturnOfGenericInstance.js @@ -24,7 +24,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/thisInInvalidContexts.js b/tests/baselines/reference/thisInInvalidContexts.js index 71c0a408c45..62f2f4efa6e 100644 --- a/tests/baselines/reference/thisInInvalidContexts.js +++ b/tests/baselines/reference/thisInInvalidContexts.js @@ -53,7 +53,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/thisInInvalidContextsExternalModule.js b/tests/baselines/reference/thisInInvalidContextsExternalModule.js index e295c49074b..4b8a8f20463 100644 --- a/tests/baselines/reference/thisInInvalidContextsExternalModule.js +++ b/tests/baselines/reference/thisInInvalidContextsExternalModule.js @@ -54,7 +54,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/thisInSuperCall.js b/tests/baselines/reference/thisInSuperCall.js index cd289bb7ea9..de34b7fa073 100644 --- a/tests/baselines/reference/thisInSuperCall.js +++ b/tests/baselines/reference/thisInSuperCall.js @@ -27,7 +27,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/thisInSuperCall1.js b/tests/baselines/reference/thisInSuperCall1.js index 63d111224d8..4138ede129b 100644 --- a/tests/baselines/reference/thisInSuperCall1.js +++ b/tests/baselines/reference/thisInSuperCall1.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/thisInSuperCall2.js b/tests/baselines/reference/thisInSuperCall2.js index 095a6c647f9..2a79507438e 100644 --- a/tests/baselines/reference/thisInSuperCall2.js +++ b/tests/baselines/reference/thisInSuperCall2.js @@ -24,7 +24,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/thisInSuperCall3.js b/tests/baselines/reference/thisInSuperCall3.js index 7fd85c47daa..b70f1e0009b 100644 --- a/tests/baselines/reference/thisInSuperCall3.js +++ b/tests/baselines/reference/thisInSuperCall3.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/thisIndexOnExistingReadonlyFieldIsNotNever.js b/tests/baselines/reference/thisIndexOnExistingReadonlyFieldIsNotNever.js index 4789d0c8022..1be3c24672a 100644 --- a/tests/baselines/reference/thisIndexOnExistingReadonlyFieldIsNotNever.js +++ b/tests/baselines/reference/thisIndexOnExistingReadonlyFieldIsNotNever.js @@ -28,7 +28,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/thisTypeInFunctions.js b/tests/baselines/reference/thisTypeInFunctions.js index 3c1dea3fd51..eef93e761d0 100644 --- a/tests/baselines/reference/thisTypeInFunctions.js +++ b/tests/baselines/reference/thisTypeInFunctions.js @@ -199,7 +199,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/thisTypeInFunctions3.js b/tests/baselines/reference/thisTypeInFunctions3.js index 2f6ff07abcd..ec773e418b8 100644 --- a/tests/baselines/reference/thisTypeInFunctions3.js +++ b/tests/baselines/reference/thisTypeInFunctions3.js @@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/transformApi/transformsCorrectly.transformAddCommentToImport.js b/tests/baselines/reference/transformApi/transformsCorrectly.transformAddCommentToImport.js index aeeee3466a0..8eff7bf8574 100644 --- a/tests/baselines/reference/transformApi/transformsCorrectly.transformAddCommentToImport.js +++ b/tests/baselines/reference/transformApi/transformsCorrectly.transformAddCommentToImport.js @@ -7,7 +7,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; Object.defineProperty(exports, "__esModule", { value: true }); exports.Value = exports.Y = exports.X = void 0; diff --git a/tests/baselines/reference/tsbuild/sample1/initial-build/when-esModuleInterop-option-changes.js b/tests/baselines/reference/tsbuild/sample1/initial-build/when-esModuleInterop-option-changes.js index b4396a7e589..4d598d661a6 100644 --- a/tests/baselines/reference/tsbuild/sample1/initial-build/when-esModuleInterop-option-changes.js +++ b/tests/baselines/reference/tsbuild/sample1/initial-build/when-esModuleInterop-option-changes.js @@ -415,7 +415,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; diff --git a/tests/baselines/reference/tsbuild/watchMode/reexport/Reports-errors-correctly.js b/tests/baselines/reference/tsbuild/watchMode/reexport/Reports-errors-correctly.js index 279cc4d73d5..91f5ed4dfae 100644 --- a/tests/baselines/reference/tsbuild/watchMode/reexport/Reports-errors-correctly.js +++ b/tests/baselines/reference/tsbuild/watchMode/reexport/Reports-errors-correctly.js @@ -163,7 +163,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./session"), exports); diff --git a/tests/baselines/reference/tsc/declarationEmit/when-pkg-references-sibling-package-through-indirect-symlink-moduleCaseChange.js b/tests/baselines/reference/tsc/declarationEmit/when-pkg-references-sibling-package-through-indirect-symlink-moduleCaseChange.js index 8372a0e49f0..51e094a489c 100644 --- a/tests/baselines/reference/tsc/declarationEmit/when-pkg-references-sibling-package-through-indirect-symlink-moduleCaseChange.js +++ b/tests/baselines/reference/tsc/declarationEmit/when-pkg-references-sibling-package-through-indirect-symlink-moduleCaseChange.js @@ -119,7 +119,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; Object.defineProperty(exports, "__esModule", { value: true }); __exportStar(require("./keys"), exports); diff --git a/tests/baselines/reference/tsc/declarationEmit/when-pkg-references-sibling-package-through-indirect-symlink.js b/tests/baselines/reference/tsc/declarationEmit/when-pkg-references-sibling-package-through-indirect-symlink.js index fa893676008..827028e7e34 100644 --- a/tests/baselines/reference/tsc/declarationEmit/when-pkg-references-sibling-package-through-indirect-symlink.js +++ b/tests/baselines/reference/tsc/declarationEmit/when-pkg-references-sibling-package-through-indirect-symlink.js @@ -119,7 +119,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; Object.defineProperty(exports, "__esModule", { value: true }); __exportStar(require("./keys"), exports); diff --git a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/assumeChangesOnlyAffectDirectDependencies/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/assumeChangesOnlyAffectDirectDependencies/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js index ced09b7bee5..93b6c63046f 100644 --- a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/assumeChangesOnlyAffectDirectDependencies/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js +++ b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/assumeChangesOnlyAffectDirectDependencies/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js @@ -130,7 +130,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools.interface"), exports); @@ -146,7 +146,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools/public"), exports); @@ -192,7 +192,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./data"), exports); diff --git a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/assumeChangesOnlyAffectDirectDependencies/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/assumeChangesOnlyAffectDirectDependencies/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js index 861edfaf548..d4ad5d6a31d 100644 --- a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/assumeChangesOnlyAffectDirectDependencies/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js +++ b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/assumeChangesOnlyAffectDirectDependencies/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js @@ -120,7 +120,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools.interface"), exports); @@ -136,7 +136,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools/public"), exports); @@ -170,7 +170,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./data"), exports); diff --git a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/assumeChangesOnlyAffectDirectDependenciesAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/assumeChangesOnlyAffectDirectDependenciesAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js index e3932bd535b..f34a06dd41f 100644 --- a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/assumeChangesOnlyAffectDirectDependenciesAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js +++ b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/assumeChangesOnlyAffectDirectDependenciesAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js @@ -136,7 +136,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools.interface"), exports); @@ -156,7 +156,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools/public"), exports); @@ -222,7 +222,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./data"), exports); diff --git a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/assumeChangesOnlyAffectDirectDependenciesAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/assumeChangesOnlyAffectDirectDependenciesAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js index 02b7ae21fec..9832e39564e 100644 --- a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/assumeChangesOnlyAffectDirectDependenciesAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js +++ b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/assumeChangesOnlyAffectDirectDependenciesAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js @@ -126,7 +126,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools.interface"), exports); @@ -146,7 +146,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools/public"), exports); @@ -191,7 +191,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./data"), exports); diff --git a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/default/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/default/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js index 7da3a7dbe7b..b91e2dbf928 100644 --- a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/default/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js +++ b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/default/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js @@ -130,7 +130,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools.interface"), exports); @@ -146,7 +146,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools/public"), exports); @@ -192,7 +192,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./data"), exports); diff --git a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/default/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/default/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js index 9f3185b89fc..c34ef58922a 100644 --- a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/default/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js +++ b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/default/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js @@ -120,7 +120,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools.interface"), exports); @@ -136,7 +136,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools/public"), exports); @@ -170,7 +170,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./data"), exports); diff --git a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/defaultAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/defaultAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js index fb0b270d9df..fa380715686 100644 --- a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/defaultAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js +++ b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/defaultAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js @@ -136,7 +136,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools.interface"), exports); @@ -156,7 +156,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools/public"), exports); @@ -222,7 +222,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./data"), exports); diff --git a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/defaultAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/defaultAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js index 71b8c163bbc..4919de75898 100644 --- a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/defaultAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js +++ b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/defaultAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js @@ -126,7 +126,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools.interface"), exports); @@ -146,7 +146,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools/public"), exports); @@ -191,7 +191,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./data"), exports); diff --git a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/isolatedModules/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/isolatedModules/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js index 9012a45cbe3..b38fcc390b7 100644 --- a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/isolatedModules/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js +++ b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/isolatedModules/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js @@ -130,7 +130,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools.interface"), exports); @@ -146,7 +146,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools/public"), exports); @@ -192,7 +192,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./data"), exports); diff --git a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/isolatedModules/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/isolatedModules/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js index 1fd4cc8df5b..c629e49a1c7 100644 --- a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/isolatedModules/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js +++ b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/isolatedModules/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js @@ -120,7 +120,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools.interface"), exports); @@ -136,7 +136,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools/public"), exports); @@ -170,7 +170,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./data"), exports); diff --git a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/isolatedModulesAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/isolatedModulesAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js index 6ac5eafcfdd..edd56006dae 100644 --- a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/isolatedModulesAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js +++ b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/isolatedModulesAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-circular-import-and-exports.js @@ -136,7 +136,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools.interface"), exports); @@ -156,7 +156,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools/public"), exports); @@ -222,7 +222,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./data"), exports); diff --git a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/isolatedModulesAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/isolatedModulesAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js index fdfdf054d53..bc590f09736 100644 --- a/tests/baselines/reference/tscWatch/emitAndErrorUpdates/isolatedModulesAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js +++ b/tests/baselines/reference/tscWatch/emitAndErrorUpdates/isolatedModulesAndD/updates-errors-when-file-transitively-exported-file-changes/when-there-are-no-circular-import-and-exports.js @@ -126,7 +126,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools.interface"), exports); @@ -146,7 +146,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./tools/public"), exports); @@ -191,7 +191,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./data"), exports); diff --git a/tests/baselines/reference/tscWatch/programUpdates/changes-in-files-are-reflected-in-project-structure.js b/tests/baselines/reference/tscWatch/programUpdates/changes-in-files-are-reflected-in-project-structure.js index cdd141acda8..332b61e0134 100644 --- a/tests/baselines/reference/tscWatch/programUpdates/changes-in-files-are-reflected-in-project-structure.js +++ b/tests/baselines/reference/tscWatch/programUpdates/changes-in-files-are-reflected-in-project-structure.js @@ -75,7 +75,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./f2"), exports); @@ -137,7 +137,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("../c/f3"), exports); diff --git a/tests/baselines/reference/tscWatch/programUpdates/deleted-files-affect-project-structure-2.js b/tests/baselines/reference/tscWatch/programUpdates/deleted-files-affect-project-structure-2.js index 1475c4730da..186e806fba1 100644 --- a/tests/baselines/reference/tscWatch/programUpdates/deleted-files-affect-project-structure-2.js +++ b/tests/baselines/reference/tscWatch/programUpdates/deleted-files-affect-project-structure-2.js @@ -79,7 +79,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("../c/f3"), exports); @@ -95,7 +95,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./f2"), exports); diff --git a/tests/baselines/reference/tscWatch/programUpdates/deleted-files-affect-project-structure.js b/tests/baselines/reference/tscWatch/programUpdates/deleted-files-affect-project-structure.js index e2b1478004e..018b5272bac 100644 --- a/tests/baselines/reference/tscWatch/programUpdates/deleted-files-affect-project-structure.js +++ b/tests/baselines/reference/tscWatch/programUpdates/deleted-files-affect-project-structure.js @@ -79,7 +79,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("../c/f3"), exports); @@ -95,7 +95,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; exports.__esModule = true; __exportStar(require("./f2"), exports); diff --git a/tests/baselines/reference/tsxAttributeResolution15.js b/tests/baselines/reference/tsxAttributeResolution15.js index 5a3e1ff4d3f..9d7baab6402 100644 --- a/tests/baselines/reference/tsxAttributeResolution15.js +++ b/tests/baselines/reference/tsxAttributeResolution15.js @@ -21,7 +21,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxAttributeResolution16.js b/tests/baselines/reference/tsxAttributeResolution16.js index 17aa001e936..ffe93d5232b 100644 --- a/tests/baselines/reference/tsxAttributeResolution16.js +++ b/tests/baselines/reference/tsxAttributeResolution16.js @@ -30,7 +30,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxCorrectlyParseLessThanComparison1.js b/tests/baselines/reference/tsxCorrectlyParseLessThanComparison1.js index 09cbe9e96d4..37d3fbae344 100644 --- a/tests/baselines/reference/tsxCorrectlyParseLessThanComparison1.js +++ b/tests/baselines/reference/tsxCorrectlyParseLessThanComparison1.js @@ -25,7 +25,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxDefaultAttributesResolution1.js b/tests/baselines/reference/tsxDefaultAttributesResolution1.js index 617b475f713..e435943b79a 100644 --- a/tests/baselines/reference/tsxDefaultAttributesResolution1.js +++ b/tests/baselines/reference/tsxDefaultAttributesResolution1.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxDefaultAttributesResolution2.js b/tests/baselines/reference/tsxDefaultAttributesResolution2.js index 5d74321695f..00f8afd2427 100644 --- a/tests/baselines/reference/tsxDefaultAttributesResolution2.js +++ b/tests/baselines/reference/tsxDefaultAttributesResolution2.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxDefaultAttributesResolution3.js b/tests/baselines/reference/tsxDefaultAttributesResolution3.js index 5a9996e2704..1fecc5c3006 100644 --- a/tests/baselines/reference/tsxDefaultAttributesResolution3.js +++ b/tests/baselines/reference/tsxDefaultAttributesResolution3.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxDynamicTagName5.js b/tests/baselines/reference/tsxDynamicTagName5.js index 14aef6ce1b8..0d0aec6e995 100644 --- a/tests/baselines/reference/tsxDynamicTagName5.js +++ b/tests/baselines/reference/tsxDynamicTagName5.js @@ -24,7 +24,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxDynamicTagName7.js b/tests/baselines/reference/tsxDynamicTagName7.js index 05e2b52a7cd..a22b4e44a24 100644 --- a/tests/baselines/reference/tsxDynamicTagName7.js +++ b/tests/baselines/reference/tsxDynamicTagName7.js @@ -24,7 +24,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxDynamicTagName8.js b/tests/baselines/reference/tsxDynamicTagName8.js index 82dfede8e4f..ec330dd3d59 100644 --- a/tests/baselines/reference/tsxDynamicTagName8.js +++ b/tests/baselines/reference/tsxDynamicTagName8.js @@ -24,7 +24,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxDynamicTagName9.js b/tests/baselines/reference/tsxDynamicTagName9.js index f72c50c1b9c..97a46da91f3 100644 --- a/tests/baselines/reference/tsxDynamicTagName9.js +++ b/tests/baselines/reference/tsxDynamicTagName9.js @@ -24,7 +24,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxExternalModuleEmit1.js b/tests/baselines/reference/tsxExternalModuleEmit1.js index d42e5d5b555..6f06d169783 100644 --- a/tests/baselines/reference/tsxExternalModuleEmit1.js +++ b/tests/baselines/reference/tsxExternalModuleEmit1.js @@ -36,7 +36,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { @@ -65,7 +65,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxFragmentChildrenCheck.js b/tests/baselines/reference/tsxFragmentChildrenCheck.js index a9f57766f70..8507ddb3924 100644 --- a/tests/baselines/reference/tsxFragmentChildrenCheck.js +++ b/tests/baselines/reference/tsxFragmentChildrenCheck.js @@ -42,7 +42,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxGenericAttributesType3.js b/tests/baselines/reference/tsxGenericAttributesType3.js index fb46fe983dc..da6ec20d531 100644 --- a/tests/baselines/reference/tsxGenericAttributesType3.js +++ b/tests/baselines/reference/tsxGenericAttributesType3.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxGenericAttributesType4.js b/tests/baselines/reference/tsxGenericAttributesType4.js index 0b2353e67d9..f004f1763da 100644 --- a/tests/baselines/reference/tsxGenericAttributesType4.js +++ b/tests/baselines/reference/tsxGenericAttributesType4.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxGenericAttributesType5.js b/tests/baselines/reference/tsxGenericAttributesType5.js index ffc320bb4eb..a6e23ea73e7 100644 --- a/tests/baselines/reference/tsxGenericAttributesType5.js +++ b/tests/baselines/reference/tsxGenericAttributesType5.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxGenericAttributesType6.js b/tests/baselines/reference/tsxGenericAttributesType6.js index 7fc020a2683..d1ee242972d 100644 --- a/tests/baselines/reference/tsxGenericAttributesType6.js +++ b/tests/baselines/reference/tsxGenericAttributesType6.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxGenericAttributesType9.js b/tests/baselines/reference/tsxGenericAttributesType9.js index 942dfb9ec7e..2fe5d9126ea 100644 --- a/tests/baselines/reference/tsxGenericAttributesType9.js +++ b/tests/baselines/reference/tsxGenericAttributesType9.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxLibraryManagedAttributes.js b/tests/baselines/reference/tsxLibraryManagedAttributes.js index c5157ea6a89..0b1620a6ac6 100644 --- a/tests/baselines/reference/tsxLibraryManagedAttributes.js +++ b/tests/baselines/reference/tsxLibraryManagedAttributes.js @@ -131,7 +131,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxNotUsingApparentTypeOfSFC.js b/tests/baselines/reference/tsxNotUsingApparentTypeOfSFC.js index 0c15cd0d07c..952d55a3d4a 100644 --- a/tests/baselines/reference/tsxNotUsingApparentTypeOfSFC.js +++ b/tests/baselines/reference/tsxNotUsingApparentTypeOfSFC.js @@ -26,7 +26,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxSpreadAttributesResolution1.js b/tests/baselines/reference/tsxSpreadAttributesResolution1.js index 9742d8348bc..8ea0582e255 100644 --- a/tests/baselines/reference/tsxSpreadAttributesResolution1.js +++ b/tests/baselines/reference/tsxSpreadAttributesResolution1.js @@ -20,7 +20,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxSpreadAttributesResolution10.js b/tests/baselines/reference/tsxSpreadAttributesResolution10.js index 8f8e21a62a6..76899a1247a 100644 --- a/tests/baselines/reference/tsxSpreadAttributesResolution10.js +++ b/tests/baselines/reference/tsxSpreadAttributesResolution10.js @@ -29,7 +29,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxSpreadAttributesResolution11.js b/tests/baselines/reference/tsxSpreadAttributesResolution11.js index 6db169e348e..5ad41ac0d2f 100644 --- a/tests/baselines/reference/tsxSpreadAttributesResolution11.js +++ b/tests/baselines/reference/tsxSpreadAttributesResolution11.js @@ -37,7 +37,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxSpreadAttributesResolution12.js b/tests/baselines/reference/tsxSpreadAttributesResolution12.js index 394f524a960..9aaeb432812 100644 --- a/tests/baselines/reference/tsxSpreadAttributesResolution12.js +++ b/tests/baselines/reference/tsxSpreadAttributesResolution12.js @@ -38,7 +38,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxSpreadAttributesResolution17.js b/tests/baselines/reference/tsxSpreadAttributesResolution17.js index 2534c483cde..894fcc26459 100644 --- a/tests/baselines/reference/tsxSpreadAttributesResolution17.js +++ b/tests/baselines/reference/tsxSpreadAttributesResolution17.js @@ -25,7 +25,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxSpreadAttributesResolution2.js b/tests/baselines/reference/tsxSpreadAttributesResolution2.js index 8d75bae4a19..75c37e0ff4b 100644 --- a/tests/baselines/reference/tsxSpreadAttributesResolution2.js +++ b/tests/baselines/reference/tsxSpreadAttributesResolution2.js @@ -30,7 +30,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxSpreadAttributesResolution3.js b/tests/baselines/reference/tsxSpreadAttributesResolution3.js index 0d094d4aef8..9ac169ef925 100644 --- a/tests/baselines/reference/tsxSpreadAttributesResolution3.js +++ b/tests/baselines/reference/tsxSpreadAttributesResolution3.js @@ -27,7 +27,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxSpreadAttributesResolution4.js b/tests/baselines/reference/tsxSpreadAttributesResolution4.js index 5ccfd8d5f90..5411899a5b0 100644 --- a/tests/baselines/reference/tsxSpreadAttributesResolution4.js +++ b/tests/baselines/reference/tsxSpreadAttributesResolution4.js @@ -40,7 +40,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxSpreadAttributesResolution5.js b/tests/baselines/reference/tsxSpreadAttributesResolution5.js index 2f826f2e59d..89f34c31bbd 100644 --- a/tests/baselines/reference/tsxSpreadAttributesResolution5.js +++ b/tests/baselines/reference/tsxSpreadAttributesResolution5.js @@ -39,7 +39,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxSpreadAttributesResolution6.js b/tests/baselines/reference/tsxSpreadAttributesResolution6.js index 8c78efeedd0..ba2d307ffdc 100644 --- a/tests/baselines/reference/tsxSpreadAttributesResolution6.js +++ b/tests/baselines/reference/tsxSpreadAttributesResolution6.js @@ -23,7 +23,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxSpreadAttributesResolution7.js b/tests/baselines/reference/tsxSpreadAttributesResolution7.js index 6248df6f042..a9e6bb1b5ce 100644 --- a/tests/baselines/reference/tsxSpreadAttributesResolution7.js +++ b/tests/baselines/reference/tsxSpreadAttributesResolution7.js @@ -30,7 +30,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxSpreadAttributesResolution8.js b/tests/baselines/reference/tsxSpreadAttributesResolution8.js index 1b22bb0e17c..5c6b853e084 100644 --- a/tests/baselines/reference/tsxSpreadAttributesResolution8.js +++ b/tests/baselines/reference/tsxSpreadAttributesResolution8.js @@ -32,7 +32,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxSpreadAttributesResolution9.js b/tests/baselines/reference/tsxSpreadAttributesResolution9.js index d92e3cfa16c..694d546ac3c 100644 --- a/tests/baselines/reference/tsxSpreadAttributesResolution9.js +++ b/tests/baselines/reference/tsxSpreadAttributesResolution9.js @@ -30,7 +30,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxSpreadDoesNotReportExcessProps.js b/tests/baselines/reference/tsxSpreadDoesNotReportExcessProps.js index ea9ac663998..5e926a7ec91 100644 --- a/tests/baselines/reference/tsxSpreadDoesNotReportExcessProps.js +++ b/tests/baselines/reference/tsxSpreadDoesNotReportExcessProps.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxStatelessFunctionComponents2.js b/tests/baselines/reference/tsxStatelessFunctionComponents2.js index 50eadb9774d..41f2a6f0622 100644 --- a/tests/baselines/reference/tsxStatelessFunctionComponents2.js +++ b/tests/baselines/reference/tsxStatelessFunctionComponents2.js @@ -43,7 +43,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxUnionElementType3.js b/tests/baselines/reference/tsxUnionElementType3.js index e72b47e3aab..0836684701a 100644 --- a/tests/baselines/reference/tsxUnionElementType3.js +++ b/tests/baselines/reference/tsxUnionElementType3.js @@ -42,7 +42,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxUnionElementType4.js b/tests/baselines/reference/tsxUnionElementType4.js index 5619f8c6d48..a0d956a4f09 100644 --- a/tests/baselines/reference/tsxUnionElementType4.js +++ b/tests/baselines/reference/tsxUnionElementType4.js @@ -41,7 +41,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/tsxUnionTypeComponent1.js b/tests/baselines/reference/tsxUnionTypeComponent1.js index 9e004413575..7d07c62b113 100644 --- a/tests/baselines/reference/tsxUnionTypeComponent1.js +++ b/tests/baselines/reference/tsxUnionTypeComponent1.js @@ -29,7 +29,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typeAliasFunctionTypeSharedSymbol.js b/tests/baselines/reference/typeAliasFunctionTypeSharedSymbol.js index 1eedb2413ea..c9e0d0fd4e8 100644 --- a/tests/baselines/reference/typeAliasFunctionTypeSharedSymbol.js +++ b/tests/baselines/reference/typeAliasFunctionTypeSharedSymbol.js @@ -19,7 +19,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typeAssertions.js b/tests/baselines/reference/typeAssertions.js index 8f37011a273..6b0c52f0685 100644 --- a/tests/baselines/reference/typeAssertions.js +++ b/tests/baselines/reference/typeAssertions.js @@ -56,7 +56,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typeFromJSConstructor.symbols b/tests/baselines/reference/typeFromJSConstructor.symbols index eaaf1f2e176..a2d5866f9ab 100644 --- a/tests/baselines/reference/typeFromJSConstructor.symbols +++ b/tests/baselines/reference/typeFromJSConstructor.symbols @@ -4,25 +4,37 @@ function Installer () { // arg: number this.arg = 0 +>this.arg : Symbol(Installer.arg, Decl(a.js, 0, 23), Decl(a.js, 12, 41), Decl(a.js, 19, 42)) +>this : Symbol(Installer, Decl(a.js, 0, 0)) >arg : Symbol(Installer.arg, Decl(a.js, 0, 23), Decl(a.js, 12, 41), Decl(a.js, 19, 42)) // unknown: string | boolean | null this.unknown = null +>this.unknown : Symbol(Installer.unknown, Decl(a.js, 2, 16), Decl(a.js, 13, 19), Decl(a.js, 20, 20)) +>this : Symbol(Installer, Decl(a.js, 0, 0)) >unknown : Symbol(Installer.unknown, Decl(a.js, 2, 16), Decl(a.js, 13, 19), Decl(a.js, 20, 20)) // twice: string | undefined this.twice = undefined +>this.twice : Symbol(Installer.twice, Decl(a.js, 4, 23), Decl(a.js, 6, 26), Decl(a.js, 15, 24), Decl(a.js, 16, 26), Decl(a.js, 22, 28) ... and 1 more) +>this : Symbol(Installer, Decl(a.js, 0, 0)) >twice : Symbol(Installer.twice, Decl(a.js, 4, 23), Decl(a.js, 6, 26), Decl(a.js, 15, 24), Decl(a.js, 16, 26), Decl(a.js, 22, 28) ... and 1 more) >undefined : Symbol(undefined) this.twice = 'hi' +>this.twice : Symbol(Installer.twice, Decl(a.js, 4, 23), Decl(a.js, 6, 26), Decl(a.js, 15, 24), Decl(a.js, 16, 26), Decl(a.js, 22, 28) ... and 1 more) +>this : Symbol(Installer, Decl(a.js, 0, 0)) >twice : Symbol(Installer.twice, Decl(a.js, 4, 23), Decl(a.js, 6, 26), Decl(a.js, 15, 24), Decl(a.js, 16, 26), Decl(a.js, 22, 28) ... and 1 more) // twices: any[] | null this.twices = [] +>this.twices : Symbol(Installer.twices, Decl(a.js, 7, 21), Decl(a.js, 9, 20)) +>this : Symbol(Installer, Decl(a.js, 0, 0)) >twices : Symbol(Installer.twices, Decl(a.js, 7, 21), Decl(a.js, 9, 20)) this.twices = null +>this.twices : Symbol(Installer.twices, Decl(a.js, 7, 21), Decl(a.js, 9, 20)) +>this : Symbol(Installer, Decl(a.js, 0, 0)) >twices : Symbol(Installer.twices, Decl(a.js, 7, 21), Decl(a.js, 9, 20)) } Installer.prototype.first = function () { diff --git a/tests/baselines/reference/typeFromJSConstructor.types b/tests/baselines/reference/typeFromJSConstructor.types index 68bd498f0f2..e5c951ce3d8 100644 --- a/tests/baselines/reference/typeFromJSConstructor.types +++ b/tests/baselines/reference/typeFromJSConstructor.types @@ -6,7 +6,7 @@ function Installer () { this.arg = 0 >this.arg = 0 : 0 >this.arg : any ->this : any +>this : this >arg : any >0 : 0 @@ -14,7 +14,7 @@ function Installer () { this.unknown = null >this.unknown = null : null >this.unknown : any ->this : any +>this : this >unknown : any >null : null @@ -22,14 +22,14 @@ function Installer () { this.twice = undefined >this.twice = undefined : undefined >this.twice : any ->this : any +>this : this >twice : any >undefined : undefined this.twice = 'hi' >this.twice = 'hi' : "hi" >this.twice : any ->this : any +>this : this >twice : any >'hi' : "hi" @@ -37,14 +37,14 @@ function Installer () { this.twices = [] >this.twices = [] : never[] >this.twices : any ->this : any +>this : this >twices : any >[] : never[] this.twices = null >this.twices = null : null >this.twices : any ->this : any +>this : this >twices : any >null : null } diff --git a/tests/baselines/reference/typeFromJSInitializer.symbols b/tests/baselines/reference/typeFromJSInitializer.symbols index b4bc9950847..2de03afed25 100644 --- a/tests/baselines/reference/typeFromJSInitializer.symbols +++ b/tests/baselines/reference/typeFromJSInitializer.symbols @@ -4,13 +4,19 @@ function A () { // should get any on this-assignments in constructor this.unknown = null +>this.unknown : Symbol(A.unknown, Decl(a.js, 0, 15)) +>this : Symbol(A, Decl(a.js, 0, 0)) >unknown : Symbol(A.unknown, Decl(a.js, 0, 15)) this.unknowable = undefined +>this.unknowable : Symbol(A.unknowable, Decl(a.js, 2, 23)) +>this : Symbol(A, Decl(a.js, 0, 0)) >unknowable : Symbol(A.unknowable, Decl(a.js, 2, 23)) >undefined : Symbol(undefined) this.empty = [] +>this.empty : Symbol(A.empty, Decl(a.js, 3, 31)) +>this : Symbol(A, Decl(a.js, 0, 0)) >empty : Symbol(A.empty, Decl(a.js, 3, 31)) } var a = new A() diff --git a/tests/baselines/reference/typeFromJSInitializer.types b/tests/baselines/reference/typeFromJSInitializer.types index 39bc8a92146..2ed82388598 100644 --- a/tests/baselines/reference/typeFromJSInitializer.types +++ b/tests/baselines/reference/typeFromJSInitializer.types @@ -6,21 +6,21 @@ function A () { this.unknown = null >this.unknown = null : null >this.unknown : any ->this : any +>this : this >unknown : any >null : null this.unknowable = undefined >this.unknowable = undefined : undefined >this.unknowable : any ->this : any +>this : this >unknowable : any >undefined : undefined this.empty = [] >this.empty = [] : never[] >this.empty : any ->this : any +>this : this >empty : any >[] : never[] } diff --git a/tests/baselines/reference/typeFromParamTagForFunction.symbols b/tests/baselines/reference/typeFromParamTagForFunction.symbols index e26674cf331..9f655be0bb9 100644 --- a/tests/baselines/reference/typeFromParamTagForFunction.symbols +++ b/tests/baselines/reference/typeFromParamTagForFunction.symbols @@ -14,6 +14,8 @@ exports.A = function () { >A : Symbol(A, Decl(a-ext.js, 0, 0)) this.x = 1; +>this.x : Symbol(A.x, Decl(a-ext.js, 0, 25)) +>this : Symbol(A, Decl(a-ext.js, 0, 11)) >x : Symbol(A.x, Decl(a-ext.js, 0, 25)) }; @@ -65,6 +67,8 @@ export function C() { >C : Symbol(C, Decl(c-ext.js, 0, 0)) this.x = 1; +>this.x : Symbol(C.x, Decl(c-ext.js, 0, 21)) +>this : Symbol(C, Decl(c-ext.js, 0, 0)) >x : Symbol(C.x, Decl(c-ext.js, 0, 21)) } @@ -87,6 +91,8 @@ export var D = function() { >D : Symbol(D, Decl(d-ext.js, 0, 10)) this.x = 1; +>this.x : Symbol(D.x, Decl(d-ext.js, 0, 27)) +>this : Symbol(D, Decl(d-ext.js, 0, 14)) >x : Symbol(D.x, Decl(d-ext.js, 0, 27)) }; @@ -136,6 +142,8 @@ var F = function () { >F : Symbol(F, Decl(f.js, 0, 3)) this.x = 1; +>this.x : Symbol(F.x, Decl(f.js, 0, 21)) +>this : Symbol(F, Decl(f.js, 0, 7)) >x : Symbol(F.x, Decl(f.js, 0, 21)) }; @@ -153,6 +161,8 @@ function G() { >G : Symbol(G, Decl(g.js, 0, 0)) this.x = 1; +>this.x : Symbol(G.x, Decl(g.js, 0, 14)) +>this : Symbol(G, Decl(g.js, 0, 0)) >x : Symbol(G.x, Decl(g.js, 0, 14)) } diff --git a/tests/baselines/reference/typeFromParamTagForFunction.types b/tests/baselines/reference/typeFromParamTagForFunction.types index 2c454f3e0da..73daa299cf1 100644 --- a/tests/baselines/reference/typeFromParamTagForFunction.types +++ b/tests/baselines/reference/typeFromParamTagForFunction.types @@ -18,7 +18,7 @@ exports.A = function () { this.x = 1; >this.x = 1 : 1 >this.x : any ->this : any +>this : this >x : any >1 : 1 @@ -79,7 +79,7 @@ export function C() { this.x = 1; >this.x = 1 : 1 >this.x : any ->this : any +>this : this >x : any >1 : 1 } @@ -107,7 +107,7 @@ export var D = function() { this.x = 1; >this.x = 1 : 1 >this.x : any ->this : any +>this : this >x : any >1 : 1 @@ -165,7 +165,7 @@ var F = function () { this.x = 1; >this.x = 1 : 1 >this.x : any ->this : any +>this : this >x : any >1 : 1 @@ -186,7 +186,7 @@ function G() { this.x = 1; >this.x = 1 : 1 >this.x : any ->this : any +>this : this >x : any >1 : 1 } diff --git a/tests/baselines/reference/typeFromPropertyAssignment19.symbols b/tests/baselines/reference/typeFromPropertyAssignment19.symbols index 39361e90c5f..4b89af4a62e 100644 --- a/tests/baselines/reference/typeFromPropertyAssignment19.symbols +++ b/tests/baselines/reference/typeFromPropertyAssignment19.symbols @@ -38,5 +38,7 @@ function C() { >C : Symbol(C, Decl(semver.js, 2, 16), Decl(semver.js, 1, 28)) this.p = 1 +>this.p : Symbol(C.p, Decl(semver.js, 3, 14)) +>this : Symbol(C, Decl(semver.js, 2, 16), Decl(semver.js, 1, 28)) >p : Symbol(C.p, Decl(semver.js, 3, 14)) } diff --git a/tests/baselines/reference/typeFromPropertyAssignment19.types b/tests/baselines/reference/typeFromPropertyAssignment19.types index d3ca43ee0e2..d09029fb949 100644 --- a/tests/baselines/reference/typeFromPropertyAssignment19.types +++ b/tests/baselines/reference/typeFromPropertyAssignment19.types @@ -49,7 +49,7 @@ function C() { this.p = 1 >this.p = 1 : 1 >this.p : any ->this : any +>this : this >p : any >1 : 1 } diff --git a/tests/baselines/reference/typeFromPropertyAssignment2.symbols b/tests/baselines/reference/typeFromPropertyAssignment2.symbols index 8b73ba10d3c..76d88fb41b4 100644 --- a/tests/baselines/reference/typeFromPropertyAssignment2.symbols +++ b/tests/baselines/reference/typeFromPropertyAssignment2.symbols @@ -3,6 +3,8 @@ function Outer() { >Outer : Symbol(Outer, Decl(a.js, 0, 0), Decl(a.js, 2, 1)) this.y = 2 +>this.y : Symbol(Outer.y, Decl(a.js, 0, 18)) +>this : Symbol(Outer, Decl(a.js, 0, 0), Decl(a.js, 2, 1)) >y : Symbol(Outer.y, Decl(a.js, 0, 18)) } Outer.Inner = class I { diff --git a/tests/baselines/reference/typeFromPropertyAssignment2.types b/tests/baselines/reference/typeFromPropertyAssignment2.types index aa06b79f484..bd1b69ea668 100644 --- a/tests/baselines/reference/typeFromPropertyAssignment2.types +++ b/tests/baselines/reference/typeFromPropertyAssignment2.types @@ -5,7 +5,7 @@ function Outer() { this.y = 2 >this.y = 2 : 2 >this.y : any ->this : any +>this : this >y : any >2 : 2 } diff --git a/tests/baselines/reference/typeFromPropertyAssignment20.symbols b/tests/baselines/reference/typeFromPropertyAssignment20.symbols index f2a10e59e4d..80bc5c2b6bd 100644 --- a/tests/baselines/reference/typeFromPropertyAssignment20.symbols +++ b/tests/baselines/reference/typeFromPropertyAssignment20.symbols @@ -11,6 +11,8 @@ >Async : Symbol(Async, Decl(bluebird.js, 1, 23)) this._trampolineEnabled = true; +>this._trampolineEnabled : Symbol(Async._trampolineEnabled, Decl(bluebird.js, 2, 26), Decl(bluebird.js, 7, 20)) +>this : Symbol(Async, Decl(bluebird.js, 1, 23)) >_trampolineEnabled : Symbol(Async._trampolineEnabled, Decl(bluebird.js, 2, 26), Decl(bluebird.js, 7, 20)) } diff --git a/tests/baselines/reference/typeFromPropertyAssignment20.types b/tests/baselines/reference/typeFromPropertyAssignment20.types index 32e1b541d7b..314adfa9241 100644 --- a/tests/baselines/reference/typeFromPropertyAssignment20.types +++ b/tests/baselines/reference/typeFromPropertyAssignment20.types @@ -17,7 +17,7 @@ this._trampolineEnabled = true; >this._trampolineEnabled = true : true >this._trampolineEnabled : any ->this : any +>this : this >_trampolineEnabled : any >true : true } diff --git a/tests/baselines/reference/typeFromPropertyAssignment22.symbols b/tests/baselines/reference/typeFromPropertyAssignment22.symbols index fbdfb304f2c..ae7614560cd 100644 --- a/tests/baselines/reference/typeFromPropertyAssignment22.symbols +++ b/tests/baselines/reference/typeFromPropertyAssignment22.symbols @@ -3,6 +3,8 @@ function Installer () { >Installer : Symbol(Installer, Decl(npm-install.js, 0, 0)) this.args = 0 +>this.args : Symbol(Installer.args, Decl(npm-install.js, 0, 23), Decl(npm-install.js, 5, 15)) +>this : Symbol(Installer, Decl(npm-install.js, 0, 0)) >args : Symbol(Installer.args, Decl(npm-install.js, 0, 23), Decl(npm-install.js, 5, 15)) } Installer.prototype.loadArgMetadata = function (next) { diff --git a/tests/baselines/reference/typeFromPropertyAssignment22.types b/tests/baselines/reference/typeFromPropertyAssignment22.types index 1c4d6822578..b5439042e0e 100644 --- a/tests/baselines/reference/typeFromPropertyAssignment22.types +++ b/tests/baselines/reference/typeFromPropertyAssignment22.types @@ -5,7 +5,7 @@ function Installer () { this.args = 0 >this.args = 0 : 0 >this.args : any ->this : any +>this : this >args : any >0 : 0 } diff --git a/tests/baselines/reference/typeFromPropertyAssignment27.symbols b/tests/baselines/reference/typeFromPropertyAssignment27.symbols index e76f61b2bbc..ffefbaa4591 100644 --- a/tests/baselines/reference/typeFromPropertyAssignment27.symbols +++ b/tests/baselines/reference/typeFromPropertyAssignment27.symbols @@ -2,6 +2,8 @@ // mixed prototype-assignment+function declaration function C() { this.p = 1; } >C : Symbol(C, Decl(a.js, 0, 0), Decl(a.js, 1, 28)) +>this.p : Symbol(C.p, Decl(a.js, 1, 14)) +>this : Symbol(C, Decl(a.js, 0, 0), Decl(a.js, 1, 28)) >p : Symbol(C.p, Decl(a.js, 1, 14)) C.prototype = { q: 2 }; diff --git a/tests/baselines/reference/typeFromPropertyAssignment27.types b/tests/baselines/reference/typeFromPropertyAssignment27.types index 956979e805a..b49799d9cae 100644 --- a/tests/baselines/reference/typeFromPropertyAssignment27.types +++ b/tests/baselines/reference/typeFromPropertyAssignment27.types @@ -4,7 +4,7 @@ function C() { this.p = 1; } >C : typeof C >this.p = 1 : 1 >this.p : any ->this : any +>this : this >p : any >1 : 1 diff --git a/tests/baselines/reference/typeFromPropertyAssignment3.symbols b/tests/baselines/reference/typeFromPropertyAssignment3.symbols index b3353e034ad..96ea0270eb0 100644 --- a/tests/baselines/reference/typeFromPropertyAssignment3.symbols +++ b/tests/baselines/reference/typeFromPropertyAssignment3.symbols @@ -4,6 +4,8 @@ var Outer = function O() { >O : Symbol(O, Decl(a.js, 0, 11)) this.y = 2 +>this.y : Symbol(O.y, Decl(a.js, 0, 26)) +>this : Symbol(O, Decl(a.js, 0, 11)) >y : Symbol(O.y, Decl(a.js, 0, 26)) } Outer.Inner = class I { diff --git a/tests/baselines/reference/typeFromPropertyAssignment3.types b/tests/baselines/reference/typeFromPropertyAssignment3.types index 510296439c8..500c290adcf 100644 --- a/tests/baselines/reference/typeFromPropertyAssignment3.types +++ b/tests/baselines/reference/typeFromPropertyAssignment3.types @@ -7,7 +7,7 @@ var Outer = function O() { this.y = 2 >this.y = 2 : 2 >this.y : any ->this : any +>this : this >y : any >2 : 2 } diff --git a/tests/baselines/reference/typeFromPrototypeAssignment3.errors.txt b/tests/baselines/reference/typeFromPrototypeAssignment3.errors.txt index 02ff4ae344c..d6aa97451b2 100644 --- a/tests/baselines/reference/typeFromPrototypeAssignment3.errors.txt +++ b/tests/baselines/reference/typeFromPrototypeAssignment3.errors.txt @@ -1,13 +1,10 @@ -tests/cases/conformance/salsa/bug26885.js(2,5): error TS2683: 'this' implicitly has type 'any' because it does not have a type annotation. tests/cases/conformance/salsa/bug26885.js(11,16): error TS7053: Element implicitly has an 'any' type because expression of type 'string' can't be used to index type '{}'. No index signature with a parameter of type 'string' was found on type '{}'. -==== tests/cases/conformance/salsa/bug26885.js (2 errors) ==== +==== tests/cases/conformance/salsa/bug26885.js (1 errors) ==== function Multimap3() { this._map = {}; - ~~~~ -!!! error TS2683: 'this' implicitly has type 'any' because it does not have a type annotation. }; Multimap3.prototype = { diff --git a/tests/baselines/reference/typeFromPrototypeAssignment3.symbols b/tests/baselines/reference/typeFromPrototypeAssignment3.symbols index aec60e00543..5f7f20e40f5 100644 --- a/tests/baselines/reference/typeFromPrototypeAssignment3.symbols +++ b/tests/baselines/reference/typeFromPrototypeAssignment3.symbols @@ -3,6 +3,8 @@ function Multimap3() { >Multimap3 : Symbol(Multimap3, Decl(bug26885.js, 0, 0), Decl(bug26885.js, 2, 2)) this._map = {}; +>this._map : Symbol(Multimap3._map, Decl(bug26885.js, 0, 22)) +>this : Symbol(Multimap3, Decl(bug26885.js, 0, 0), Decl(bug26885.js, 2, 2)) >_map : Symbol(Multimap3._map, Decl(bug26885.js, 0, 22)) }; diff --git a/tests/baselines/reference/typeFromPrototypeAssignment3.types b/tests/baselines/reference/typeFromPrototypeAssignment3.types index 73eccd53906..ef156d50a2c 100644 --- a/tests/baselines/reference/typeFromPrototypeAssignment3.types +++ b/tests/baselines/reference/typeFromPrototypeAssignment3.types @@ -5,7 +5,7 @@ function Multimap3() { this._map = {}; >this._map = {} : {} >this._map : any ->this : any +>this : this >_map : any >{} : {} diff --git a/tests/baselines/reference/typeFromPrototypeAssignment4.symbols b/tests/baselines/reference/typeFromPrototypeAssignment4.symbols index bc7e816cc94..b0421eff782 100644 --- a/tests/baselines/reference/typeFromPrototypeAssignment4.symbols +++ b/tests/baselines/reference/typeFromPrototypeAssignment4.symbols @@ -3,6 +3,8 @@ function Multimap4() { >Multimap4 : Symbol(Multimap4, Decl(a.js, 0, 0), Decl(a.js, 2, 2)) this._map = {}; +>this._map : Symbol(Multimap4._map, Decl(a.js, 0, 22)) +>this : Symbol(Multimap4, Decl(a.js, 0, 0), Decl(a.js, 2, 2)) >_map : Symbol(Multimap4._map, Decl(a.js, 0, 22)) }; diff --git a/tests/baselines/reference/typeFromPrototypeAssignment4.types b/tests/baselines/reference/typeFromPrototypeAssignment4.types index 42f340ac7a9..c9b6ae04a00 100644 --- a/tests/baselines/reference/typeFromPrototypeAssignment4.types +++ b/tests/baselines/reference/typeFromPrototypeAssignment4.types @@ -5,7 +5,7 @@ function Multimap4() { this._map = {}; >this._map = {} : {} >this._map : any ->this : any +>this : this >_map : any >{} : {} diff --git a/tests/baselines/reference/typeGuardConstructorDerivedClass.js b/tests/baselines/reference/typeGuardConstructorDerivedClass.js index 8ffabcb987a..bb8a3532e4a 100644 --- a/tests/baselines/reference/typeGuardConstructorDerivedClass.js +++ b/tests/baselines/reference/typeGuardConstructorDerivedClass.js @@ -71,7 +71,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typeGuardFunction.js b/tests/baselines/reference/typeGuardFunction.js index 7d762946e30..c195db9b439 100644 --- a/tests/baselines/reference/typeGuardFunction.js +++ b/tests/baselines/reference/typeGuardFunction.js @@ -87,7 +87,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typeGuardFunctionErrors.js b/tests/baselines/reference/typeGuardFunctionErrors.js index 7e640fea6d7..df0bf5d124e 100644 --- a/tests/baselines/reference/typeGuardFunctionErrors.js +++ b/tests/baselines/reference/typeGuardFunctionErrors.js @@ -172,7 +172,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typeGuardFunctionGenerics.js b/tests/baselines/reference/typeGuardFunctionGenerics.js index 13d14fa6bb6..216fb13948d 100644 --- a/tests/baselines/reference/typeGuardFunctionGenerics.js +++ b/tests/baselines/reference/typeGuardFunctionGenerics.js @@ -37,7 +37,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typeGuardFunctionOfFormThis.js b/tests/baselines/reference/typeGuardFunctionOfFormThis.js index 1d52025c9f7..14d390e56bd 100644 --- a/tests/baselines/reference/typeGuardFunctionOfFormThis.js +++ b/tests/baselines/reference/typeGuardFunctionOfFormThis.js @@ -146,7 +146,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typeGuardFunctionOfFormThisErrors.js b/tests/baselines/reference/typeGuardFunctionOfFormThisErrors.js index 6db9d7f6885..0e36a2cf6e8 100644 --- a/tests/baselines/reference/typeGuardFunctionOfFormThisErrors.js +++ b/tests/baselines/reference/typeGuardFunctionOfFormThisErrors.js @@ -64,7 +64,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typeGuardOfFormInstanceOf.js b/tests/baselines/reference/typeGuardOfFormInstanceOf.js index 554e3c0d572..577ff15119f 100644 --- a/tests/baselines/reference/typeGuardOfFormInstanceOf.js +++ b/tests/baselines/reference/typeGuardOfFormInstanceOf.js @@ -77,7 +77,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typeGuardOfFormIsType.js b/tests/baselines/reference/typeGuardOfFormIsType.js index 57c0da2f4e5..be4eb3b8ae8 100644 --- a/tests/baselines/reference/typeGuardOfFormIsType.js +++ b/tests/baselines/reference/typeGuardOfFormIsType.js @@ -41,7 +41,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typeGuardOfFormThisMember.js b/tests/baselines/reference/typeGuardOfFormThisMember.js index 037a0fe2385..b24d5ae25f9 100644 --- a/tests/baselines/reference/typeGuardOfFormThisMember.js +++ b/tests/baselines/reference/typeGuardOfFormThisMember.js @@ -87,7 +87,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typeGuardOfFormThisMemberErrors.js b/tests/baselines/reference/typeGuardOfFormThisMemberErrors.js index 87864e50e3b..5ea24a1e254 100644 --- a/tests/baselines/reference/typeGuardOfFormThisMemberErrors.js +++ b/tests/baselines/reference/typeGuardOfFormThisMemberErrors.js @@ -37,7 +37,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typeMatch2.js b/tests/baselines/reference/typeMatch2.js index cc5073f4563..ce165381006 100644 --- a/tests/baselines/reference/typeMatch2.js +++ b/tests/baselines/reference/typeMatch2.js @@ -49,7 +49,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typeOfSuperCall.js b/tests/baselines/reference/typeOfSuperCall.js index 88be3876544..a839228b6c5 100644 --- a/tests/baselines/reference/typeOfSuperCall.js +++ b/tests/baselines/reference/typeOfSuperCall.js @@ -13,7 +13,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typeParameterAsBaseClass.js b/tests/baselines/reference/typeParameterAsBaseClass.js index 8a963309eab..77cf0dafb02 100644 --- a/tests/baselines/reference/typeParameterAsBaseClass.js +++ b/tests/baselines/reference/typeParameterAsBaseClass.js @@ -7,7 +7,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typeParameterAsBaseType.js b/tests/baselines/reference/typeParameterAsBaseType.js index a6eddf38a38..944ee766ba2 100644 --- a/tests/baselines/reference/typeParameterAsBaseType.js +++ b/tests/baselines/reference/typeParameterAsBaseType.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typeParameterExtendingUnion1.js b/tests/baselines/reference/typeParameterExtendingUnion1.js index 78bcc9f650c..7c70b323f40 100644 --- a/tests/baselines/reference/typeParameterExtendingUnion1.js +++ b/tests/baselines/reference/typeParameterExtendingUnion1.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typeParameterExtendingUnion2.js b/tests/baselines/reference/typeParameterExtendingUnion2.js index 0a55d8fd0d4..5263cafe22e 100644 --- a/tests/baselines/reference/typeParameterExtendingUnion2.js +++ b/tests/baselines/reference/typeParameterExtendingUnion2.js @@ -17,7 +17,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typeRelationships.js b/tests/baselines/reference/typeRelationships.js index 27ba221a281..382cc684f62 100644 --- a/tests/baselines/reference/typeRelationships.js +++ b/tests/baselines/reference/typeRelationships.js @@ -45,7 +45,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typeValueConflict1.js b/tests/baselines/reference/typeValueConflict1.js index 074e73ea014..35d4c105bfb 100644 --- a/tests/baselines/reference/typeValueConflict1.js +++ b/tests/baselines/reference/typeValueConflict1.js @@ -16,7 +16,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typeValueConflict2.js b/tests/baselines/reference/typeValueConflict2.js index 534dfa1cdff..56adc78808e 100644 --- a/tests/baselines/reference/typeValueConflict2.js +++ b/tests/baselines/reference/typeValueConflict2.js @@ -23,7 +23,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typeVariableTypeGuards.js b/tests/baselines/reference/typeVariableTypeGuards.js index 385c8bd55c4..f880f1128eb 100644 --- a/tests/baselines/reference/typeVariableTypeGuards.js +++ b/tests/baselines/reference/typeVariableTypeGuards.js @@ -89,7 +89,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typedefCrossModule.symbols b/tests/baselines/reference/typedefCrossModule.symbols index 6c16284a557..aa3c9d5784a 100644 --- a/tests/baselines/reference/typedefCrossModule.symbols +++ b/tests/baselines/reference/typedefCrossModule.symbols @@ -18,6 +18,8 @@ function C() { >C : Symbol(C, Decl(mod1.js, 4, 18)) this.p = 1 +>this.p : Symbol(C.p, Decl(mod1.js, 5, 14)) +>this : Symbol(C, Decl(mod1.js, 4, 18)) >p : Symbol(C.p, Decl(mod1.js, 5, 14)) } @@ -31,6 +33,8 @@ export function C() { >C : Symbol(C, Decl(mod2.js, 0, 0)) this.p = 1 +>this.p : Symbol(C.p, Decl(mod2.js, 5, 21)) +>this : Symbol(C, Decl(mod2.js, 0, 0)) >p : Symbol(C.p, Decl(mod2.js, 5, 21)) } @@ -46,6 +50,8 @@ exports.C = function() { >C : Symbol(C, Decl(mod3.js, 0, 0)) this.p = 1 +>this.p : Symbol(C.p, Decl(mod3.js, 5, 24)) +>this : Symbol(C, Decl(mod3.js, 5, 11)) >p : Symbol(C.p, Decl(mod3.js, 5, 24)) } diff --git a/tests/baselines/reference/typedefCrossModule.types b/tests/baselines/reference/typedefCrossModule.types index 052ff60fc43..ad9de6c3115 100644 --- a/tests/baselines/reference/typedefCrossModule.types +++ b/tests/baselines/reference/typedefCrossModule.types @@ -21,7 +21,7 @@ function C() { this.p = 1 >this.p = 1 : 1 >this.p : any ->this : any +>this : this >p : any >1 : 1 } @@ -38,7 +38,7 @@ export function C() { this.p = 1 >this.p = 1 : 1 >this.p : any ->this : any +>this : this >p : any >1 : 1 } @@ -59,7 +59,7 @@ exports.C = function() { this.p = 1 >this.p = 1 : 1 >this.p : any ->this : any +>this : this >p : any >1 : 1 } diff --git a/tests/baselines/reference/typeofClass2.js b/tests/baselines/reference/typeofClass2.js index e145a5d9b45..4f3839908d6 100644 --- a/tests/baselines/reference/typeofClass2.js +++ b/tests/baselines/reference/typeofClass2.js @@ -26,7 +26,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typesWithSpecializedCallSignatures.js b/tests/baselines/reference/typesWithSpecializedCallSignatures.js index 6cb2fbaff54..8a9175fcbb5 100644 --- a/tests/baselines/reference/typesWithSpecializedCallSignatures.js +++ b/tests/baselines/reference/typesWithSpecializedCallSignatures.js @@ -47,7 +47,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/typesWithSpecializedConstructSignatures.js b/tests/baselines/reference/typesWithSpecializedConstructSignatures.js index 7bbe983955d..f50d1180708 100644 --- a/tests/baselines/reference/typesWithSpecializedConstructSignatures.js +++ b/tests/baselines/reference/typesWithSpecializedConstructSignatures.js @@ -45,7 +45,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/undeclaredBase.js b/tests/baselines/reference/undeclaredBase.js index efbd2b49b41..b25eb8e3a75 100644 --- a/tests/baselines/reference/undeclaredBase.js +++ b/tests/baselines/reference/undeclaredBase.js @@ -8,7 +8,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/undefinedIsSubtypeOfEverything.js b/tests/baselines/reference/undefinedIsSubtypeOfEverything.js index 40378779e0c..db9cc30e872 100644 --- a/tests/baselines/reference/undefinedIsSubtypeOfEverything.js +++ b/tests/baselines/reference/undefinedIsSubtypeOfEverything.js @@ -127,7 +127,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/underscoreMapFirst.js b/tests/baselines/reference/underscoreMapFirst.js index 4fc0d0bf3ce..5a0a7bf55d7 100644 --- a/tests/baselines/reference/underscoreMapFirst.js +++ b/tests/baselines/reference/underscoreMapFirst.js @@ -53,7 +53,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/underscoreThisInDerivedClass01.js b/tests/baselines/reference/underscoreThisInDerivedClass01.js index c42767ef3bf..3b6dbfdad0e 100644 --- a/tests/baselines/reference/underscoreThisInDerivedClass01.js +++ b/tests/baselines/reference/underscoreThisInDerivedClass01.js @@ -29,7 +29,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/underscoreThisInDerivedClass02.js b/tests/baselines/reference/underscoreThisInDerivedClass02.js index 313b6663d54..f01f1292d4b 100644 --- a/tests/baselines/reference/underscoreThisInDerivedClass02.js +++ b/tests/baselines/reference/underscoreThisInDerivedClass02.js @@ -24,7 +24,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/unionTypeEquivalence.js b/tests/baselines/reference/unionTypeEquivalence.js index 90ebc0ff152..b44f2ad4828 100644 --- a/tests/baselines/reference/unionTypeEquivalence.js +++ b/tests/baselines/reference/unionTypeEquivalence.js @@ -24,7 +24,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/unionTypeFromArrayLiteral.js b/tests/baselines/reference/unionTypeFromArrayLiteral.js index 3c8e461ef18..eb21fe12678 100644 --- a/tests/baselines/reference/unionTypeFromArrayLiteral.js +++ b/tests/baselines/reference/unionTypeFromArrayLiteral.js @@ -32,7 +32,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/unionTypesAssignability.js b/tests/baselines/reference/unionTypesAssignability.js index fc7b0c5020f..d9c47116464 100644 --- a/tests/baselines/reference/unionTypesAssignability.js +++ b/tests/baselines/reference/unionTypesAssignability.js @@ -78,7 +78,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/unknownSymbols1.js b/tests/baselines/reference/unknownSymbols1.js index 64057fe8c71..8e98c329026 100644 --- a/tests/baselines/reference/unknownSymbols1.js +++ b/tests/baselines/reference/unknownSymbols1.js @@ -37,7 +37,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/unspecializedConstraints.js b/tests/baselines/reference/unspecializedConstraints.js index 4f1a9196156..c812fc478ff 100644 --- a/tests/baselines/reference/unspecializedConstraints.js +++ b/tests/baselines/reference/unspecializedConstraints.js @@ -158,7 +158,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/untypedFunctionCallsWithTypeParameters1.js b/tests/baselines/reference/untypedFunctionCallsWithTypeParameters1.js index d685742804f..166126200fa 100644 --- a/tests/baselines/reference/untypedFunctionCallsWithTypeParameters1.js +++ b/tests/baselines/reference/untypedFunctionCallsWithTypeParameters1.js @@ -48,7 +48,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/unusedClassesinNamespace4.js b/tests/baselines/reference/unusedClassesinNamespace4.js index 57517346ea3..3d618fc258f 100644 --- a/tests/baselines/reference/unusedClassesinNamespace4.js +++ b/tests/baselines/reference/unusedClassesinNamespace4.js @@ -18,7 +18,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/unusedIdentifiersConsolidated1.js b/tests/baselines/reference/unusedIdentifiersConsolidated1.js index a26090bb617..1437c2b185f 100644 --- a/tests/baselines/reference/unusedIdentifiersConsolidated1.js +++ b/tests/baselines/reference/unusedIdentifiersConsolidated1.js @@ -106,7 +106,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/unusedInvalidTypeArguments.js b/tests/baselines/reference/unusedInvalidTypeArguments.js index 36ee10aad0f..ae9e88ba116 100644 --- a/tests/baselines/reference/unusedInvalidTypeArguments.js +++ b/tests/baselines/reference/unusedInvalidTypeArguments.js @@ -57,7 +57,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { @@ -104,7 +104,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/useBeforeDeclaration_superClass.js b/tests/baselines/reference/useBeforeDeclaration_superClass.js index 01492e31d89..28a462c3e50 100644 --- a/tests/baselines/reference/useBeforeDeclaration_superClass.js +++ b/tests/baselines/reference/useBeforeDeclaration_superClass.js @@ -33,7 +33,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/user/adonis-framework.log b/tests/baselines/reference/user/adonis-framework.log index 8ec9a7657d4..2ad48ccb79f 100644 --- a/tests/baselines/reference/user/adonis-framework.log +++ b/tests/baselines/reference/user/adonis-framework.log @@ -77,8 +77,8 @@ node_modules/adonis-framework/src/Exceptions/index.js(178,21): error TS2554: Exp node_modules/adonis-framework/src/Exceptions/index.js(191,21): error TS2554: Expected 0 arguments, but got 3. node_modules/adonis-framework/src/Exceptions/index.js(205,21): error TS2554: Expected 0 arguments, but got 3. node_modules/adonis-framework/src/File/index.js(175,5): error TS2322: Type 'Promise' is not assignable to type 'boolean'. -node_modules/adonis-framework/src/File/index.js(273,5): error TS2322: Type 'boolean | ""' is not assignable to type 'boolean'. - Type '""' is not assignable to type 'boolean'. +node_modules/adonis-framework/src/File/index.js(273,5): error TS2322: Type 'string | boolean' is not assignable to type 'boolean'. + Type 'string' is not assignable to type 'boolean'. node_modules/adonis-framework/src/Helpers/index.js(105,3): error TS2322: Type 'null' is not assignable to type 'string'. node_modules/adonis-framework/src/Helpers/index.js(106,3): error TS2322: Type 'null' is not assignable to type 'string'. node_modules/adonis-framework/src/Helpers/index.js(164,18): error TS2554: Expected 3 arguments, but got 2. diff --git a/tests/baselines/reference/user/axios-src.log b/tests/baselines/reference/user/axios-src.log index febddae6ca7..a56050ec608 100644 --- a/tests/baselines/reference/user/axios-src.log +++ b/tests/baselines/reference/user/axios-src.log @@ -8,8 +8,10 @@ lib/adapters/http.js(121,40): error TS2531: Object is possibly 'null'. lib/adapters/http.js(225,23): error TS2345: Argument of type 'null' is not assignable to parameter of type 'string | undefined'. lib/adapters/http.js(231,44): error TS2345: Argument of type 'null' is not assignable to parameter of type 'string | undefined'. lib/adapters/http.js(237,13): error TS2322: Type 'string' is not assignable to type 'Buffer'. -lib/adapters/http.js(249,40): error TS2345: Argument of type 'null' is not assignable to parameter of type 'string | undefined'. -lib/adapters/http.js(278,42): error TS2345: Argument of type 'null' is not assignable to parameter of type 'string | undefined'. +lib/adapters/http.js(239,15): error TS2322: Type 'string' is not assignable to type 'Buffer'. +lib/adapters/http.js(239,45): error TS2345: Argument of type 'Buffer' is not assignable to parameter of type 'string'. +lib/adapters/http.js(252,40): error TS2345: Argument of type 'null' is not assignable to parameter of type 'string | undefined'. +lib/adapters/http.js(281,42): error TS2345: Argument of type 'null' is not assignable to parameter of type 'string | undefined'. lib/adapters/xhr.js(72,7): error TS2322: Type 'null' is not assignable to type 'XMLHttpRequest'. lib/adapters/xhr.js(84,7): error TS2322: Type 'null' is not assignable to type 'XMLHttpRequest'. lib/adapters/xhr.js(91,51): error TS2345: Argument of type 'null' is not assignable to parameter of type 'string | undefined'. diff --git a/tests/baselines/reference/user/chrome-devtools-frontend.log b/tests/baselines/reference/user/chrome-devtools-frontend.log index 908e5343cad..5c2077f2752 100644 --- a/tests/baselines/reference/user/chrome-devtools-frontend.log +++ b/tests/baselines/reference/user/chrome-devtools-frontend.log @@ -1,7 +1,7 @@ Exit Code: 2 Standard output: ../../../../built/local/lib.es5.d.ts(1451,11): error TS2300: Duplicate identifier 'ArrayLike'. -../../../../node_modules/@types/node/globals.d.ts(167,13): error TS2403: Subsequent variable declarations must have the same type. Variable 'module' must be of type '{}', but here has type 'NodeModule'. +../../../../node_modules/@types/node/globals.d.ts(60,13): error TS2403: Subsequent variable declarations must have the same type. Variable 'module' must be of type '{}', but here has type 'NodeModule'. node_modules/chrome-devtools-frontend/front_end/Runtime.js(43,8): error TS2339: Property '_importScriptPathPrefix' does not exist on type 'Window & typeof globalThis'. node_modules/chrome-devtools-frontend/front_end/Runtime.js(77,16): error TS7014: Function type, which lacks return-type annotation, implicitly has an 'any' return type. node_modules/chrome-devtools-frontend/front_end/Runtime.js(78,16): error TS7014: Function type, which lacks return-type annotation, implicitly has an 'any' return type. @@ -11342,7 +11342,7 @@ node_modules/chrome-devtools-frontend/front_end/test_runner/TestRunner.js(503,30 Type 'Function' provides no match for the signature '(value: any[]): any[] | PromiseLike'. node_modules/chrome-devtools-frontend/front_end/test_runner/TestRunner.js(641,59): error TS2551: Property 'testRunner' does not exist on type 'Window & typeof globalThis'. Did you mean 'TestRunner'? node_modules/chrome-devtools-frontend/front_end/test_runner/TestRunner.js(641,92): error TS2551: Property 'testRunner' does not exist on type 'Window & typeof globalThis'. Did you mean 'TestRunner'? -node_modules/chrome-devtools-frontend/front_end/test_runner/TestRunner.js(642,3): error TS2322: Type '1' is not assignable to type 'boolean'. +node_modules/chrome-devtools-frontend/front_end/test_runner/TestRunner.js(642,3): error TS2322: Type 'number' is not assignable to type 'boolean'. node_modules/chrome-devtools-frontend/front_end/test_runner/TestRunner.js(683,28): error TS2363: The right-hand side of an arithmetic operation must be of type 'any', 'number', 'bigint' or an enum type. node_modules/chrome-devtools-frontend/front_end/test_runner/TestRunner.js(777,22): error TS2339: Property 'attributes' does not exist on type 'Node'. node_modules/chrome-devtools-frontend/front_end/test_runner/TestRunner.js(785,14): error TS2339: Property 'shadowRoot' does not exist on type 'Node'. diff --git a/tests/baselines/reference/user/prettier.log b/tests/baselines/reference/user/prettier.log deleted file mode 100644 index 92da1d38965..00000000000 --- a/tests/baselines/reference/user/prettier.log +++ /dev/null @@ -1,8 +0,0 @@ -Exit Code: 2 -Standard output: -src/main/comments.js(325,5): error TS2775: Assertions require every name in the call target to be declared with an explicit type annotation. -src/main/comments.js(326,5): error TS2775: Assertions require every name in the call target to be declared with an explicit type annotation. - - - -Standard error: diff --git a/tests/baselines/reference/user/uglify-js.log b/tests/baselines/reference/user/uglify-js.log index 113e29cbc62..1cafce52c39 100644 --- a/tests/baselines/reference/user/uglify-js.log +++ b/tests/baselines/reference/user/uglify-js.log @@ -62,7 +62,7 @@ node_modules/uglify-js/lib/compress.js(3530,48): error TS2554: Expected 0 argume node_modules/uglify-js/lib/compress.js(3628,48): error TS2554: Expected 0 arguments, but got 1. node_modules/uglify-js/lib/compress.js(3646,33): error TS2532: Object is possibly 'undefined'. node_modules/uglify-js/lib/compress.js(4066,38): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(4092,29): error TS2322: Type '"f"' is not assignable to type 'boolean'. +node_modules/uglify-js/lib/compress.js(4092,29): error TS2322: Type 'string' is not assignable to type 'boolean'. node_modules/uglify-js/lib/compress.js(4275,33): error TS2554: Expected 0 arguments, but got 1. node_modules/uglify-js/lib/compress.js(4276,74): error TS2339: Property 'has_directive' does not exist on type 'TreeWalker'. node_modules/uglify-js/lib/compress.js(4327,29): error TS2554: Expected 0 arguments, but got 1. diff --git a/tests/baselines/reference/user/webpack.log b/tests/baselines/reference/user/webpack.log index 0c2300962f6..ede6c132fda 100644 --- a/tests/baselines/reference/user/webpack.log +++ b/tests/baselines/reference/user/webpack.log @@ -1,7 +1,8 @@ Exit Code: 2 Standard output: -lib/ContextModule.js(352,32): error TS2345: Argument of type 'Pick' is not assignable to parameter of type 'ContextOptions & ContextModuleOptionsExtras'. - Property 'resolveOptions' is missing in type 'Pick' but required in type 'ContextModuleOptionsExtras'. +lib/ContextModule.js(346,32): error TS2345: Argument of type 'Pick' is not assignable to parameter of type 'ContextOptions & ContextModuleOptionsExtras'. + Property 'resolveOptions' is missing in type 'Pick' but required in type 'ContextModuleOptionsExtras'. +lib/dependencies/HarmonyExportImportedSpecifierDependency.js(86,37): error TS1016: A required parameter cannot follow an optional parameter. diff --git a/tests/baselines/reference/validUseOfThisInSuper.js b/tests/baselines/reference/validUseOfThisInSuper.js index d35b84f3df1..0b45f1810e5 100644 --- a/tests/baselines/reference/validUseOfThisInSuper.js +++ b/tests/baselines/reference/validUseOfThisInSuper.js @@ -14,7 +14,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/varArgsOnConstructorTypes.js b/tests/baselines/reference/varArgsOnConstructorTypes.js index 2f328d6a43c..7020a43b8e8 100644 --- a/tests/baselines/reference/varArgsOnConstructorTypes.js +++ b/tests/baselines/reference/varArgsOnConstructorTypes.js @@ -29,7 +29,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/varianceProblingAndZeroOrderIndexSignatureRelationsAlign.js b/tests/baselines/reference/varianceProblingAndZeroOrderIndexSignatureRelationsAlign.js index 91fdb7d3e1a..74abf4a86a9 100644 --- a/tests/baselines/reference/varianceProblingAndZeroOrderIndexSignatureRelationsAlign.js +++ b/tests/baselines/reference/varianceProblingAndZeroOrderIndexSignatureRelationsAlign.js @@ -72,7 +72,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/baselines/reference/varianceProblingAndZeroOrderIndexSignatureRelationsAlign2.js b/tests/baselines/reference/varianceProblingAndZeroOrderIndexSignatureRelationsAlign2.js index 0b39a6176ef..3dad3331424 100644 --- a/tests/baselines/reference/varianceProblingAndZeroOrderIndexSignatureRelationsAlign2.js +++ b/tests/baselines/reference/varianceProblingAndZeroOrderIndexSignatureRelationsAlign2.js @@ -72,7 +72,7 @@ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { diff --git a/tests/cases/compiler/controlFlowArrays.ts b/tests/cases/compiler/controlFlowArrays.ts index 646c85f069f..786b61aea21 100644 --- a/tests/cases/compiler/controlFlowArrays.ts +++ b/tests/cases/compiler/controlFlowArrays.ts @@ -178,4 +178,12 @@ function f18() { x.unshift("hello"); x[2] = true; return x; // (string | number | boolean)[] -} \ No newline at end of file +} + +// Repro from #39470 + +declare function foo(arg: { val: number }[]): void; + +let arr = [] +arr.push({ val: 1, bar: 2 }); +foo(arr); diff --git a/tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts b/tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts index a9b11e29034..f550bd7bb4d 100644 --- a/tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts +++ b/tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts @@ -93,3 +93,9 @@ let rover: Dog = { bark() {} }; declare let map: MyMap; map[rover] = "Rover"; + +interface I { + prop: MyMap +} +declare const m: I; +m.prop['a']; diff --git a/tests/cases/compiler/templateLiteralsAndDecoratorMetadata.ts b/tests/cases/compiler/templateLiteralsAndDecoratorMetadata.ts new file mode 100644 index 00000000000..f9c3ea26003 --- /dev/null +++ b/tests/cases/compiler/templateLiteralsAndDecoratorMetadata.ts @@ -0,0 +1,7 @@ +// @experimentalDecorators: true +// @emitDecoratorMetadata: true +declare var format: any; +export class Greeter { + @format("Hello, %s") + greeting: `boss` | `employee` = `employee`; //template literals on this line cause the issue +} \ No newline at end of file diff --git a/tests/cases/conformance/jsdoc/constructorTagWithThisTag.ts b/tests/cases/conformance/jsdoc/constructorTagWithThisTag.ts new file mode 100644 index 00000000000..0483ca0a8b4 --- /dev/null +++ b/tests/cases/conformance/jsdoc/constructorTagWithThisTag.ts @@ -0,0 +1,13 @@ +// @allowJs: true +// @noEmit: true +// @checkJs: true +// @Filename: classthisboth.js + +/** + * @class + * @this {{ e: number, m: number }} + * this-tag should win, both 'e' and 'm' should be defined. + */ +function C() { + this.e = this.m + 1 +} diff --git a/tests/cases/conformance/jsdoc/declarations/jsDeclarationsClassStaticMethodAugmentation.ts b/tests/cases/conformance/jsdoc/declarations/jsDeclarationsClassStaticMethodAugmentation.ts new file mode 100644 index 00000000000..ff8b56c3ec2 --- /dev/null +++ b/tests/cases/conformance/jsdoc/declarations/jsDeclarationsClassStaticMethodAugmentation.ts @@ -0,0 +1,11 @@ +// @allowJs: true +// @checkJs: true +// @target: es5 +// @outDir: ./out +// @declaration: true +// @filename: source.js +export class Clazz { + static method() { } +} + +Clazz.method.prop = 5; \ No newline at end of file diff --git a/tests/cases/conformance/jsdoc/declarations/jsDeclarationsConstsAsNamespacesWithReferences.ts b/tests/cases/conformance/jsdoc/declarations/jsDeclarationsConstsAsNamespacesWithReferences.ts new file mode 100644 index 00000000000..8534d9e563e --- /dev/null +++ b/tests/cases/conformance/jsdoc/declarations/jsDeclarationsConstsAsNamespacesWithReferences.ts @@ -0,0 +1,13 @@ +// @allowJs: true +// @checkJs: true +// @outDir: ./out +// @target: es6 +// @declaration: true +// @filename: index.js +export const colors = { + royalBlue: "#6400e4", +}; + +export const brandColors = { + purple: colors.royalBlue, +}; \ No newline at end of file diff --git a/tests/cases/conformance/jsdoc/jsdocFunctionType.ts b/tests/cases/conformance/jsdoc/jsdocFunctionType.ts index 95c8f8966f1..48875d52c81 100644 --- a/tests/cases/conformance/jsdoc/jsdocFunctionType.ts +++ b/tests/cases/conformance/jsdoc/jsdocFunctionType.ts @@ -70,3 +70,15 @@ var E = function(n) { var y3 = id2(E); + +// Repro from #39229 + +/** + * @type {(...args: [string, string] | [number, string, string]) => void} + */ +function foo(...args) { + args; +} + +foo('abc', 'def'); +foo(42, 'abc', 'def'); diff --git a/tests/cases/conformance/jsdoc/paramTagTypeResolution2.ts b/tests/cases/conformance/jsdoc/paramTagTypeResolution2.ts new file mode 100644 index 00000000000..a1cd30426b7 --- /dev/null +++ b/tests/cases/conformance/jsdoc/paramTagTypeResolution2.ts @@ -0,0 +1,14 @@ +// @noEmit: true +// @allowJs: true +// @checkJs: true +// @Filename: 38572.js + +/** + * @template T + * @param {T} a + * @param {{[K in keyof T]: (value: T[K]) => void }} b + */ +function f(a, b) { +} + +f({ x: 42 }, { x(param) { param.toFixed() } }); diff --git a/tests/cases/conformance/salsa/expandoOnAlias.ts b/tests/cases/conformance/salsa/expandoOnAlias.ts new file mode 100644 index 00000000000..1a2ecb09f81 --- /dev/null +++ b/tests/cases/conformance/salsa/expandoOnAlias.ts @@ -0,0 +1,24 @@ +// @allowJs: true +// @checkJs: true +// @declaration: true +// @emitDeclarationOnly: true + +// @Filename: vue.js +export class Vue {} +export const config = { x: 0 }; + +// @Filename: test.js +import { Vue, config } from "./vue"; + +// Expando declarations aren't allowed on aliases. +Vue.config = {}; +new Vue(); + +// This is not an expando declaration; it's just a plain property assignment. +config.x = 1; + +// This is not an expando declaration; it works because non-strict JS allows +// loosey goosey assignment on objects. +config.y = {}; +config.x; +config.y; diff --git a/tests/cases/fourslash/codeFixAmbientClassExtendAbstractMethod.ts b/tests/cases/fourslash/codeFixAmbientClassExtendAbstractMethod.ts index 35da0b24faa..7f854405d2f 100644 --- a/tests/cases/fourslash/codeFixAmbientClassExtendAbstractMethod.ts +++ b/tests/cases/fourslash/codeFixAmbientClassExtendAbstractMethod.ts @@ -5,19 +5,27 @@ //// abstract f(a: number, b: string): this; //// abstract f(a: string, b: number): Function; //// abstract f(a: string): Function; +//// +//// abstract f1(this: A): number; +//// abstract f2(this: A, a: number, b: string): number; +//// //// abstract foo(): number; ////} //// ////declare class C extends A {} verify.codeFix({ - description: "Implement inherited abstract class", + description: ts.Diagnostics.Implement_inherited_abstract_class.message, newFileContent: `abstract class A { abstract f(a: number, b: string): boolean; abstract f(a: number, b: string): this; abstract f(a: string, b: number): Function; abstract f(a: string): Function; + + abstract f1(this: A): number; + abstract f2(this: A, a: number, b: string): number; + abstract foo(): number; } @@ -26,6 +34,8 @@ declare class C extends A { f(a: number, b: string): this; f(a: string, b: number): Function; f(a: string): Function; + f1(this: A): number; + f2(this: A, a: number, b: string): number; foo(): number; }` }); diff --git a/tests/cases/fourslash/codeFixClassImplementInterface_noUndefinedOnOptionalParameter.ts b/tests/cases/fourslash/codeFixClassImplementInterface_noUndefinedOnOptionalParameter.ts new file mode 100644 index 00000000000..2d6626e50e8 --- /dev/null +++ b/tests/cases/fourslash/codeFixClassImplementInterface_noUndefinedOnOptionalParameter.ts @@ -0,0 +1,23 @@ +/// + +////interface IFoo { +//// bar(x?: number | string): void; +////} +//// +////class Foo implements IFoo { +////} + +//https://github.com/microsoft/TypeScript/issues/39458 +verify.codeFix({ + description: [ts.Diagnostics.Implement_interface_0.message, "IFoo"], + newFileContent: +`interface IFoo { + bar(x?: number | string): void; +} + +class Foo implements IFoo { + bar(x?: string | number): void { + throw new Error("Method not implemented."); + } +}`, +}); diff --git a/tests/cases/fourslash/codeFixImplicitThis_js_all.ts b/tests/cases/fourslash/codeFixImplicitThis_js_all.ts index f99518afa13..d442252b254 100644 --- a/tests/cases/fourslash/codeFixImplicitThis_js_all.ts +++ b/tests/cases/fourslash/codeFixImplicitThis_js_all.ts @@ -5,10 +5,12 @@ // @noImplicitThis: true // @Filename: /a.js -////function f() { -//// this.x = 1; -////} ////class C { +//// q() { +//// function i() { +//// this; +//// } +//// } //// m() { //// function h() { //// this; @@ -20,13 +22,12 @@ verify.codeFixAll({ fixId: "fixImplicitThis", fixAllDescription: "Fix all implicit-'this' errors", newFileContent: -`/** - * @class - */ -function f() { - this.x = 1; -} -class C { +`class C { + q() { + const i = () => { + this; + } + } m() { const h = () => { this; diff --git a/tests/cases/fourslash/codeFixImplicitThis_js_classTag.ts b/tests/cases/fourslash/codeFixImplicitThis_js_classTag.ts deleted file mode 100644 index 52e7930b481..00000000000 --- a/tests/cases/fourslash/codeFixImplicitThis_js_classTag.ts +++ /dev/null @@ -1,22 +0,0 @@ -/// - -// @allowJs: true -// @checkJs: true -// @noImplicitThis: true - -// @Filename: /a.js -////function f() { -//// this.x = 1; -////} - -verify.codeFix({ - description: "Add '@class' tag", - index: 0, - newFileContent: -`/** - * @class - */ -function f() { - this.x = 1; -}`, -}); diff --git a/tests/cases/fourslash/codeFixImplicitThis_js_classTag_addToComment.ts b/tests/cases/fourslash/codeFixImplicitThis_js_classTag_addToComment.ts deleted file mode 100644 index 9b684512568..00000000000 --- a/tests/cases/fourslash/codeFixImplicitThis_js_classTag_addToComment.ts +++ /dev/null @@ -1,24 +0,0 @@ -/// - -// @allowJs: true -// @checkJs: true -// @noImplicitThis: true - -// @Filename: /a.js -/////** Doc */ -////function f() { -//// this.x = 1; -////} - -verify.codeFix({ - description: "Add '@class' tag", - index: 0, - newFileContent: -`/** - * Doc - * @class - */ -function f() { - this.x = 1; -}`, -}); diff --git a/tests/cases/fourslash/codeFixInferFromUsageContextualImport4.ts b/tests/cases/fourslash/codeFixInferFromUsageContextualImport4.ts index fbb6336a869..037bdc11211 100644 --- a/tests/cases/fourslash/codeFixInferFromUsageContextualImport4.ts +++ b/tests/cases/fourslash/codeFixInferFromUsageContextualImport4.ts @@ -25,8 +25,8 @@ verify.codeFix({ index: 0, description: "Infer parameter types from usage", newFileContent: -`import { getEmail } from './getEmail'; -import { User, Settings } from './a'; +`import { User, Settings } from './a'; +import { getEmail } from './getEmail'; export function f(user: User, settings: Settings) { getEmail(user, settings); diff --git a/tests/cases/fourslash/codeFixUndeclaredMethodFunctionArgs_importArgumentType.ts b/tests/cases/fourslash/codeFixUndeclaredMethodFunctionArgs_importArgumentType.ts index b9410c03583..50f376f9889 100644 --- a/tests/cases/fourslash/codeFixUndeclaredMethodFunctionArgs_importArgumentType.ts +++ b/tests/cases/fourslash/codeFixUndeclaredMethodFunctionArgs_importArgumentType.ts @@ -19,7 +19,7 @@ verify.codeFix({ description: [ts.Diagnostics.Declare_method_0.message, "foo"], index: 0, newFileContent: -`import { create, A } from "./a"; +`import { A, create } from "./a"; class B { bar() { create(args => this.foo(args)); diff --git a/tests/cases/fourslash/codeFixUndeclaredMethodFunctionArgs_importArgumentType1.ts b/tests/cases/fourslash/codeFixUndeclaredMethodFunctionArgs_importArgumentType1.ts index 4a7afe32b53..a95ccbca1d1 100644 --- a/tests/cases/fourslash/codeFixUndeclaredMethodFunctionArgs_importArgumentType1.ts +++ b/tests/cases/fourslash/codeFixUndeclaredMethodFunctionArgs_importArgumentType1.ts @@ -25,8 +25,8 @@ verify.codeFix({ description: [ts.Diagnostics.Declare_method_0.message, "foo"], index: 0, newFileContent: -`import { create, B } from "./b"; -import { A } from "./a"; +`import { A } from "./a"; +import { B, create } from "./b"; class C { bar() { create(args => this.foo(args)); diff --git a/tests/cases/fourslash/codeFixUndeclaredMethodFunctionArgs_importArgumentType2.ts b/tests/cases/fourslash/codeFixUndeclaredMethodFunctionArgs_importArgumentType2.ts index 05755845534..3a6da2fb9dd 100644 --- a/tests/cases/fourslash/codeFixUndeclaredMethodFunctionArgs_importArgumentType2.ts +++ b/tests/cases/fourslash/codeFixUndeclaredMethodFunctionArgs_importArgumentType2.ts @@ -31,9 +31,9 @@ verify.codeFix({ description: [ts.Diagnostics.Declare_method_0.message, "foo"], index: 0, newFileContent: -`import { create, C } from "./c"; +`import { A } from "./a"; import { B } from "./b"; -import { A } from "./a"; +import { C, create } from "./c"; class D { bar() { create(args => this.foo(args)); diff --git a/tests/cases/fourslash/completionsImport_default_alreadyExistedWithRename.ts b/tests/cases/fourslash/completionsImport_default_alreadyExistedWithRename.ts index 2e1fd6003ba..610b4fc73cf 100644 --- a/tests/cases/fourslash/completionsImport_default_alreadyExistedWithRename.ts +++ b/tests/cases/fourslash/completionsImport_default_alreadyExistedWithRename.ts @@ -25,7 +25,7 @@ verify.applyCodeActionFromCompletion("", { name: "foo", source: "/a", description: `Import default 'foo' from module "./a"`, - newFileContent: `import f_o_o from "./a"; -import foo from "./a"; + newFileContent: `import foo from "./a"; +import f_o_o from "./a"; f;`, }); diff --git a/tests/cases/fourslash/completionsImport_named_addToNamedImports.ts b/tests/cases/fourslash/completionsImport_named_addToNamedImports.ts index 8e1ec13df79..55ba68abedd 100644 --- a/tests/cases/fourslash/completionsImport_named_addToNamedImports.ts +++ b/tests/cases/fourslash/completionsImport_named_addToNamedImports.ts @@ -26,6 +26,6 @@ verify.applyCodeActionFromCompletion("", { name: "foo", source: "/a", description: `Add 'foo' to existing import declaration from "./a"`, - newFileContent: `import { x, foo } from "./a"; + newFileContent: `import { foo, x } from "./a"; f;`, }); diff --git a/tests/cases/fourslash/completionsImport_named_didNotExistBefore.ts b/tests/cases/fourslash/completionsImport_named_didNotExistBefore.ts index cb55f859cca..59766f81fcf 100644 --- a/tests/cases/fourslash/completionsImport_named_didNotExistBefore.ts +++ b/tests/cases/fourslash/completionsImport_named_didNotExistBefore.ts @@ -14,21 +14,21 @@ verify.completions({ marker: "", exact: [ { - name: "Test2", - text: "(alias) function Test2(): void\nimport Test2", - kind: "alias" + name: "Test2", + text: "(alias) function Test2(): void\nimport Test2", + kind: "alias" }, completion.globalThisEntry, completion.undefinedVarEntry, { - name: "Test1", - source: "/a", - sourceDisplay: "./a", - text: "function Test1(): void", - kind: "function", - kindModifiers: "export", - hasAction: true, - sortText: completion.SortText.AutoImportSuggestions + name: "Test1", + source: "/a", + sourceDisplay: "./a", + text: "function Test1(): void", + kind: "function", + kindModifiers: "export", + hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, ...completion.statementKeywordsWithTypes, ], @@ -39,6 +39,6 @@ verify.applyCodeActionFromCompletion("", { name: "Test1", source: "/a", description: `Add 'Test1' to existing import declaration from "./a"`, - newFileContent: `import { Test2, Test1 } from "./a"; + newFileContent: `import { Test1, Test2 } from "./a"; t`, }); diff --git a/tests/cases/fourslash/completionsImport_reExport_wrongName.ts b/tests/cases/fourslash/completionsImport_reExport_wrongName.ts index 4080fe5cdb7..1b386e37288 100644 --- a/tests/cases/fourslash/completionsImport_reExport_wrongName.ts +++ b/tests/cases/fourslash/completionsImport_reExport_wrongName.ts @@ -46,8 +46,8 @@ verify.applyCodeActionFromCompletion("", { name: "y", source: "/index", description: `Import 'y' from module "."`, - newFileContent: `import { x } from "./a"; -import { y } from "."; + newFileContent: `import { y } from "."; +import { x } from "./a"; `, }); diff --git a/tests/cases/fourslash/extract-method32.ts b/tests/cases/fourslash/extract-method32.ts index 229561e9795..d2d999fd290 100644 --- a/tests/cases/fourslash/extract-method32.ts +++ b/tests/cases/fourslash/extract-method32.ts @@ -21,7 +21,7 @@ edit.applyRefactor({ actionName: "function_scope_1", actionDescription: "Extract to function in module scope", newContent: -`import { a, A } from "./a"; +`import { A, a } from "./a"; function foo() { const arg = a; diff --git a/tests/cases/fourslash/extract-method33.ts b/tests/cases/fourslash/extract-method33.ts index 96d4216c844..6c3adbd6d18 100644 --- a/tests/cases/fourslash/extract-method33.ts +++ b/tests/cases/fourslash/extract-method33.ts @@ -29,8 +29,8 @@ edit.applyRefactor({ actionName: "function_scope_1", actionDescription: "Extract to function in module scope", newContent: -`import { b, B } from "./b"; -import { A } from "./a"; +`import { A } from "./a"; +import { B, b } from "./b"; function foo() { const prop = b; diff --git a/tests/cases/fourslash/extract-method34.ts b/tests/cases/fourslash/extract-method34.ts index 7ffb72e7af5..74990632685 100644 --- a/tests/cases/fourslash/extract-method34.ts +++ b/tests/cases/fourslash/extract-method34.ts @@ -38,9 +38,9 @@ edit.applyRefactor({ actionName: "function_scope_1", actionDescription: "Extract to function in module scope", newContent: -`import { c, C } from "./c"; +`import { A } from "./a"; import { B } from "./b"; -import { A } from "./a"; +import { C, c } from "./c"; function foo() { const prop = c; diff --git a/tests/cases/fourslash/extract-method35.ts b/tests/cases/fourslash/extract-method35.ts index 67a3edd0b4a..5f6ea76c6da 100644 --- a/tests/cases/fourslash/extract-method35.ts +++ b/tests/cases/fourslash/extract-method35.ts @@ -23,7 +23,7 @@ edit.applyRefactor({ actionName: "function_scope_1", actionDescription: "Extract to method in class 'Foo'", newContent: -`import { a, A } from "./a"; +`import { A, a } from "./a"; class Foo { foo() { diff --git a/tests/cases/fourslash/extract-method36.ts b/tests/cases/fourslash/extract-method36.ts index 0b3e93e2b95..47f9e75a245 100644 --- a/tests/cases/fourslash/extract-method36.ts +++ b/tests/cases/fourslash/extract-method36.ts @@ -31,8 +31,8 @@ edit.applyRefactor({ actionName: "function_scope_1", actionDescription: "Extract to method in class 'Foo'", newContent: -`import { b, B } from "./b"; -import { A } from "./a"; +`import { A } from "./a"; +import { B, b } from "./b"; class Foo { foo() { diff --git a/tests/cases/fourslash/extract-method37.ts b/tests/cases/fourslash/extract-method37.ts index 1f71cd09818..c6a1c485cb6 100644 --- a/tests/cases/fourslash/extract-method37.ts +++ b/tests/cases/fourslash/extract-method37.ts @@ -40,9 +40,9 @@ edit.applyRefactor({ actionName: "function_scope_1", actionDescription: "Extract to method in class 'Foo'", newContent: -`import { c, C } from "./c"; +`import { A } from "./a"; import { B } from "./b"; -import { A } from "./a"; +import { C, c } from "./c"; class Foo { foo() { diff --git a/tests/cases/fourslash/findAllRefsForStaticInstanceMethodInheritance.ts b/tests/cases/fourslash/findAllRefsForStaticInstanceMethodInheritance.ts new file mode 100644 index 00000000000..6e63cc63aad --- /dev/null +++ b/tests/cases/fourslash/findAllRefsForStaticInstanceMethodInheritance.ts @@ -0,0 +1,37 @@ +/// + +////class X{ +//// [|[|{| "isDefinition": true, "contextRangeIndex": 0, "isWriteAccess": true |}foo|](): void{}|] +////} +//// +////class Y extends X{ +//// [|static [|{| "isDefinition": true, "contextRangeIndex": 2, "isWriteAccess": true |}foo|](): void{}|] +////} +//// +////class Z extends Y{ +//// [|static [|{| "isDefinition": true, "contextRangeIndex": 4, "isWriteAccess": true |}foo|](): void{}|] +//// [|[|{| "isDefinition": true, "contextRangeIndex": 6, "isWriteAccess": true |}foo|](): void{}|] +////} +//// +////const x = new X(); +////const y = new Y(); +////const z = new Z(); +////x.[|foo|](); +////y.[|foo|](); +////z.[|foo|](); +////Y.[|foo|](); +////Z.[|foo|](); + +const [r0Def, r0, r1Def, r1, r2Def, r2, r3Def, r3, r4, r5, r6, r7, r8] = test.ranges(); +verify.referenceGroups([r0, r3, r4, r5, r6], [ + { definition: { text: '(method) X.foo(): void', range: r0 }, ranges: [r0, r4, r5] }, + { definition: { text: '(method) Z.foo(): void', range: r3 }, ranges: [r3, r6] }, +]); + +verify.referenceGroups([r1, r7], [ + { definition: { text: '(method) Y.foo(): void', range: r1 }, ranges: [r1, r7] }, +]); + +verify.referenceGroups([r2, r8], [ + { definition: { text: '(method) Z.foo(): void', range: r2 }, ranges: [r2, r8] }, +]); diff --git a/tests/cases/fourslash/findAllRefsForStaticInstancePropertyInheritance.ts b/tests/cases/fourslash/findAllRefsForStaticInstancePropertyInheritance.ts new file mode 100644 index 00000000000..62f2066ed98 --- /dev/null +++ b/tests/cases/fourslash/findAllRefsForStaticInstancePropertyInheritance.ts @@ -0,0 +1,37 @@ +/// + +////class X{ +//// [|[|{| "isDefinition": true, "contextRangeIndex": 0|}foo|]:any|] +////} +//// +////class Y extends X{ +//// [|static [|{| "isDefinition": true, "contextRangeIndex": 2|}foo|]:any|] +////} +//// +////class Z extends Y{ +//// [|static [|{| "isDefinition": true, "contextRangeIndex": 4|}foo|]:any|] +//// [|[|{| "isDefinition": true, "contextRangeIndex": 6|}foo|]:any|] +////} +//// +////const x = new X(); +////const y = new Y(); +////const z = new Z(); +////x.[|foo|]; +////y.[|foo|]; +////z.[|foo|]; +////Y.[|foo|]; +////Z.[|foo|]; + +const [r0Def, r0, r1Def, r1, r2Def, r2, r3Def, r3, r4, r5, r6, r7, r8] = test.ranges(); +verify.referenceGroups([r0, r3, r4, r5, r6], [ + { definition: { text: '(property) X.foo: any', range: r0 }, ranges: [r0, r4, r5] }, + { definition: { text: '(property) Z.foo: any', range: r3 }, ranges: [r3, r6] }, +]); + +verify.referenceGroups([r1, r7], [ + { definition: { text: '(property) Y.foo: any', range: r1 }, ranges: [r1, r7] }, +]); + +verify.referenceGroups([r2, r8], [ + { definition: { text: '(property) Z.foo: any', range: r2 }, ranges: [r2, r8] }, +]); diff --git a/tests/cases/fourslash/findAllRefsReExportStarAs.ts b/tests/cases/fourslash/findAllRefsReExportStarAs.ts new file mode 100644 index 00000000000..a0392048ea8 --- /dev/null +++ b/tests/cases/fourslash/findAllRefsReExportStarAs.ts @@ -0,0 +1,20 @@ +/// + +// @Filename: /leafModule.ts +////[|{| "id": "helloDecl" |}export const [|{| "isWriteAccess": true, "isDefinition": true, "contextRangeId": "helloDecl" |}hello|] = () => 'Hello';|] + +// @Filename: /exporting.ts +////[|{| "id": "leafExportDecl" |}export * as [|{| "isWriteAccess": true, "isDefinition": true, "contextRangeId": "leafExportDecl" |}Leaf|] from './leafModule';|] + +// @Filename: /importing.ts +//// [|{| "id": "leafImportDecl" |}import { [|{| "isWriteAccess": true, "isDefinition": true, "contextRangeId": "leafImportDecl" |}Leaf|] } from './exporting';|] +//// [|Leaf|].[|hello|]() + +verify.noErrors(); +const ranges = test.ranges(); +const [helloDecl, helloDef, leafExportDecl, leafDef, leafImportDecl, leafImportDef, leafUse, helloUse] = ranges; +verify.singleReferenceGroup("const hello: () => string", [helloDef, helloUse]); +const leafExportAsRef = { definition: "import Leaf", ranges: [leafDef] }; +const leafImportRef = { definition: "import Leaf", ranges: [leafImportDef, leafUse] }; +verify.referenceGroups([leafDef], [leafExportAsRef, leafImportRef]); +verify.referenceGroups([leafImportDef, leafUse], [leafImportRef, leafExportAsRef]); diff --git a/tests/cases/fourslash/formatTypeAnnotation1.ts b/tests/cases/fourslash/formatTypeAnnotation1.ts new file mode 100644 index 00000000000..edd3a13ab9b --- /dev/null +++ b/tests/cases/fourslash/formatTypeAnnotation1.ts @@ -0,0 +1,17 @@ +/// + +////function foo(x: number, y?: string): number {} +////interface Foo { +//// x: number; +//// y?: number; +////} + +format.setOption("insertSpaceBeforeTypeAnnotation", true); +format.document(); +verify.currentFileContentIs( +`function foo(x : number, y ?: string) : number { } +interface Foo { + x : number; + y ?: number; +}` +); diff --git a/tests/cases/fourslash/formatTypeAnnotation2.ts b/tests/cases/fourslash/formatTypeAnnotation2.ts new file mode 100644 index 00000000000..a3708a6b668 --- /dev/null +++ b/tests/cases/fourslash/formatTypeAnnotation2.ts @@ -0,0 +1,16 @@ +/// + +////function foo(x : number, y ?: string) : number {} +////interface Foo { +//// x : number; +//// y ?: number; +////} + +format.document(); +verify.currentFileContentIs( +`function foo(x: number, y?: string): number { } +interface Foo { + x: number; + y?: number; +}` +); diff --git a/tests/cases/fourslash/importNameCodeFixExistingImport0.ts b/tests/cases/fourslash/importNameCodeFixExistingImport0.ts index e5b63499878..922285e9afc 100644 --- a/tests/cases/fourslash/importNameCodeFixExistingImport0.ts +++ b/tests/cases/fourslash/importNameCodeFixExistingImport0.ts @@ -7,4 +7,4 @@ //// export function f1() {} //// export var v1 = 5; -verify.importFixAtPosition([`{ v1, f1 }`]); +verify.importFixAtPosition([`{ f1, v1 }`]); diff --git a/tests/cases/fourslash/importNameCodeFixExistingImport1.ts b/tests/cases/fourslash/importNameCodeFixExistingImport1.ts index 49680692b6c..f06ce49f0ea 100644 --- a/tests/cases/fourslash/importNameCodeFixExistingImport1.ts +++ b/tests/cases/fourslash/importNameCodeFixExistingImport1.ts @@ -8,4 +8,4 @@ //// export var v1 = 5; //// export default var d1 = 6; -verify.importFixAtPosition([`{ v1, f1 }`]); +verify.importFixAtPosition([`{ f1, v1 }`]); diff --git a/tests/cases/fourslash/importNameCodeFixExistingImport10.ts b/tests/cases/fourslash/importNameCodeFixExistingImport10.ts index a9525d272da..3faa34deaa9 100644 --- a/tests/cases/fourslash/importNameCodeFixExistingImport10.ts +++ b/tests/cases/fourslash/importNameCodeFixExistingImport10.ts @@ -14,8 +14,8 @@ verify.importFixAtPosition([ `{ + f1, v1, - v2, - f1 + v2 }` ]); diff --git a/tests/cases/fourslash/importNameCodeFixExistingImport11.ts b/tests/cases/fourslash/importNameCodeFixExistingImport11.ts index 786e0e39775..4a414ef9a36 100644 --- a/tests/cases/fourslash/importNameCodeFixExistingImport11.ts +++ b/tests/cases/fourslash/importNameCodeFixExistingImport11.ts @@ -14,8 +14,8 @@ verify.importFixAtPosition([ `{ + f1, v1, v2, - v3, - f1 + v3 }` ]); diff --git a/tests/cases/fourslash/importNameCodeFixExistingImport6.ts b/tests/cases/fourslash/importNameCodeFixExistingImport6.ts index 0d3636e4439..7b2bd7d5383 100644 --- a/tests/cases/fourslash/importNameCodeFixExistingImport6.ts +++ b/tests/cases/fourslash/importNameCodeFixExistingImport6.ts @@ -10,4 +10,4 @@ //// export var v1 = 5; //// export function f1(); -verify.importFixAtPosition([`{ v1, f1 }`]); +verify.importFixAtPosition([`{ f1, v1 }`]); diff --git a/tests/cases/fourslash/importNameCodeFixExistingImport7.ts b/tests/cases/fourslash/importNameCodeFixExistingImport7.ts index f0b1a77f690..8a8ceb926c2 100644 --- a/tests/cases/fourslash/importNameCodeFixExistingImport7.ts +++ b/tests/cases/fourslash/importNameCodeFixExistingImport7.ts @@ -7,4 +7,4 @@ //// export var v1 = 5; //// export function f1(); -verify.importFixAtPosition([`{ v1, f1 }`]); +verify.importFixAtPosition([`{ f1, v1 }`]); diff --git a/tests/cases/fourslash/importNameCodeFixExistingImport8.ts b/tests/cases/fourslash/importNameCodeFixExistingImport8.ts index a1b676a8b83..a365136607d 100644 --- a/tests/cases/fourslash/importNameCodeFixExistingImport8.ts +++ b/tests/cases/fourslash/importNameCodeFixExistingImport8.ts @@ -1,12 +1,12 @@ /// //// import [|{v1, v2, v3,}|] from "./module"; -//// f1/*0*/(); +//// v4/*0*/(); // @Filename: module.ts -//// export function f1() {} +//// export function v4() {} //// export var v1 = 5; //// export var v2 = 5; //// export var v3 = 5; -verify.importFixAtPosition([`{v1, v2, v3, f1,}`]); +verify.importFixAtPosition([`{v1, v2, v3, v4,}`]); diff --git a/tests/cases/fourslash/importNameCodeFixExistingImport9.ts b/tests/cases/fourslash/importNameCodeFixExistingImport9.ts index 67960de32d4..bc9701032bb 100644 --- a/tests/cases/fourslash/importNameCodeFixExistingImport9.ts +++ b/tests/cases/fourslash/importNameCodeFixExistingImport9.ts @@ -11,6 +11,7 @@ verify.importFixAtPosition([ `{ - v1, f1 + f1, + v1 }` ]); diff --git a/tests/cases/fourslash/importNameCodeFixExistingImportEquals0.ts b/tests/cases/fourslash/importNameCodeFixExistingImportEquals0.ts index de86ed13cd5..4165cdae93b 100644 --- a/tests/cases/fourslash/importNameCodeFixExistingImportEquals0.ts +++ b/tests/cases/fourslash/importNameCodeFixExistingImportEquals0.ts @@ -12,7 +12,7 @@ verify.importFixAtPosition([ `import ns = require("ambient-module"); var x = ns.v1 + 5;`, -`import ns = require("ambient-module"); -import { v1 } from "ambient-module"; +`import { v1 } from "ambient-module"; +import ns = require("ambient-module"); var x = v1 + 5;`, ]); diff --git a/tests/cases/fourslash/importNameCodeFixNewImportAmbient1.ts b/tests/cases/fourslash/importNameCodeFixNewImportAmbient1.ts index 835850306f6..5966800667e 100644 --- a/tests/cases/fourslash/importNameCodeFixNewImportAmbient1.ts +++ b/tests/cases/fourslash/importNameCodeFixNewImportAmbient1.ts @@ -1,8 +1,8 @@ /// //// import d from "other-ambient-module"; -//// [|import * as ns from "yet-another-ambient-module"; -//// var x = v1/*0*/ + 5;|] +//// import * as ns from "yet-another-ambient-module"; +//// var x = v1/*0*/ + 5; // @Filename: ambientModule.ts //// declare module "ambient-module" { @@ -22,7 +22,8 @@ //// } verify.importFixAtPosition([ -`import * as ns from "yet-another-ambient-module"; -import { v1 } from "ambient-module"; +`import { v1 } from "ambient-module"; +import d from "other-ambient-module"; +import * as ns from "yet-another-ambient-module"; var x = v1 + 5;` ]); diff --git a/tests/cases/fourslash/importNameCodeFixNewImportAmbient3.ts b/tests/cases/fourslash/importNameCodeFixNewImportAmbient3.ts index dbd6c4ef26a..0b596e45533 100644 --- a/tests/cases/fourslash/importNameCodeFixNewImportAmbient3.ts +++ b/tests/cases/fourslash/importNameCodeFixNewImportAmbient3.ts @@ -2,8 +2,8 @@ //// let a = "I am a non-trivial statement that appears before imports"; //// import d from "other-ambient-module" -//// [|import * as ns from "yet-another-ambient-module" -//// var x = v1/*0*/ + 5;|] +//// import * as ns from "yet-another-ambient-module" +//// var x = v1/*0*/ + 5; // @Filename: ambientModule.ts //// declare module "ambient-module" { @@ -24,7 +24,9 @@ // test cases when there are no semicolons at the line end verify.importFixAtPosition([ -`import * as ns from "yet-another-ambient-module" +`let a = "I am a non-trivial statement that appears before imports"; import { v1 } from "ambient-module"; +import d from "other-ambient-module" +import * as ns from "yet-another-ambient-module" var x = v1 + 5;` ]); diff --git a/tests/cases/fourslash/importNameCodeFixNewImportFileQuoteStyle0.ts b/tests/cases/fourslash/importNameCodeFixNewImportFileQuoteStyle0.ts index 6b5ef958e05..4a7f109c7b1 100644 --- a/tests/cases/fourslash/importNameCodeFixNewImportFileQuoteStyle0.ts +++ b/tests/cases/fourslash/importNameCodeFixNewImportFileQuoteStyle0.ts @@ -11,8 +11,8 @@ //// export var v2 = 6; verify.importFixAtPosition([ -`import { v2 } from './module2'; -import { f1 } from './module1'; +`import { f1 } from './module1'; +import { v2 } from './module2'; f1();` ]); diff --git a/tests/cases/fourslash/importNameCodeFixNewImportFileQuoteStyle1.ts b/tests/cases/fourslash/importNameCodeFixNewImportFileQuoteStyle1.ts index a9a12c41958..ea131406ac2 100644 --- a/tests/cases/fourslash/importNameCodeFixNewImportFileQuoteStyle1.ts +++ b/tests/cases/fourslash/importNameCodeFixNewImportFileQuoteStyle1.ts @@ -11,8 +11,8 @@ //// export var v2 = 6; verify.importFixAtPosition([ -`import { v2 } from "./module2"; -import { f1 } from "./module1"; +`import { f1 } from "./module1"; +import { v2 } from "./module2"; f1();` ]); diff --git a/tests/cases/fourslash/importNameCodeFixNewImportFileQuoteStyle2.ts b/tests/cases/fourslash/importNameCodeFixNewImportFileQuoteStyle2.ts index c356e239ee8..663670d6307 100644 --- a/tests/cases/fourslash/importNameCodeFixNewImportFileQuoteStyle2.ts +++ b/tests/cases/fourslash/importNameCodeFixNewImportFileQuoteStyle2.ts @@ -11,8 +11,8 @@ //// export var v2 = 6; verify.importFixAtPosition([ -`import m2 = require('./module2'); -import { f1 } from './module1'; +`import { f1 } from './module1'; +import m2 = require('./module2'); f1();` ]); diff --git a/tests/cases/fourslash/importNameCodeFixNewImportFileQuoteStyleMixed0.ts b/tests/cases/fourslash/importNameCodeFixNewImportFileQuoteStyleMixed0.ts index 2f17780df7f..95e437bbe71 100644 --- a/tests/cases/fourslash/importNameCodeFixNewImportFileQuoteStyleMixed0.ts +++ b/tests/cases/fourslash/importNameCodeFixNewImportFileQuoteStyleMixed0.ts @@ -15,9 +15,9 @@ //// export var v3 = 6; verify.importFixAtPosition([ -`import { v2 } from "./module2"; +`import { f1 } from "./module1"; +import { v2 } from "./module2"; import { v3 } from './module3'; -import { f1 } from "./module1"; f1();` ]); diff --git a/tests/cases/fourslash/importNameCodeFixNewImportFileQuoteStyleMixed1.ts b/tests/cases/fourslash/importNameCodeFixNewImportFileQuoteStyleMixed1.ts index ec68b3be0d8..310583671e3 100644 --- a/tests/cases/fourslash/importNameCodeFixNewImportFileQuoteStyleMixed1.ts +++ b/tests/cases/fourslash/importNameCodeFixNewImportFileQuoteStyleMixed1.ts @@ -15,9 +15,9 @@ //// export var v3 = 6; verify.importFixAtPosition([ -`import { v2 } from './module2'; +`import { f1 } from './module1'; +import { v2 } from './module2'; import { v3 } from "./module3"; -import { f1 } from './module1'; f1();` ]); diff --git a/tests/cases/fourslash/importNameCodeFixUMDGlobal1.ts b/tests/cases/fourslash/importNameCodeFixUMDGlobal1.ts index 1beebb0477c..f94ecf1c75a 100644 --- a/tests/cases/fourslash/importNameCodeFixUMDGlobal1.ts +++ b/tests/cases/fourslash/importNameCodeFixUMDGlobal1.ts @@ -14,8 +14,8 @@ //// export as namespace bar1; verify.importFixAtPosition([ -`import { bar } from "./foo"; -import * as bar1 from "./foo"; +`import * as bar1 from "./foo"; +import { bar } from "./foo"; export function test() { }; bar1.bar();` diff --git a/tests/cases/fourslash/importNameCodeFixUMDGlobalReact0.ts b/tests/cases/fourslash/importNameCodeFixUMDGlobalReact0.ts index 6fc3ce54988..f630deb2a33 100644 --- a/tests/cases/fourslash/importNameCodeFixUMDGlobalReact0.ts +++ b/tests/cases/fourslash/importNameCodeFixUMDGlobalReact0.ts @@ -29,8 +29,8 @@ goTo.file("/a.tsx"); verify.importFixAtPosition([ - `import { Component } from "react"; -import * as React from "react"; + `import * as React from "react"; +import { Component } from "react"; export class MyMap extends Component { } ;`]); @@ -38,6 +38,6 @@ export class MyMap extends Component { } goTo.file("/b.tsx"); verify.importFixAtPosition([ -`import { Component } from "react"; -import * as React from "react"; +`import * as React from "react"; +import { Component } from "react"; <>;`]); diff --git a/tests/cases/fourslash/importNameCodeFixUMDGlobalReact1.ts b/tests/cases/fourslash/importNameCodeFixUMDGlobalReact1.ts index 9dba0f39882..247b48e99cc 100644 --- a/tests/cases/fourslash/importNameCodeFixUMDGlobalReact1.ts +++ b/tests/cases/fourslash/importNameCodeFixUMDGlobalReact1.ts @@ -25,7 +25,7 @@ goTo.file("/a.tsx"); verify.importFixAtPosition([ -`import { Component } from "react"; -import * as React from "react"; +`import * as React from "react"; +import { Component } from "react"; export class MyMap extends Component { } ;`]); diff --git a/tests/cases/fourslash/importNameCodeFix_all.ts b/tests/cases/fourslash/importNameCodeFix_all.ts index d5bb525900a..f76a5d1aa69 100644 --- a/tests/cases/fourslash/importNameCodeFix_all.ts +++ b/tests/cases/fourslash/importNameCodeFix_all.ts @@ -37,10 +37,10 @@ verify.codeFixAll({ fixId: "fixMissingImport", fixAllDescription: "Add all missing imports", newFileContent: -`import bd, * as b from "./b"; +`import ad, { a0 } from "./a"; +import bd, * as b from "./b"; import cd, { c0 } from "./c"; import dd, { d0, d1 } from "./d"; -import ad, { a0 } from "./a"; import e = require("./e"); ad; ad; a0; a0; diff --git a/tests/cases/fourslash/importNameCodeFix_all2.ts b/tests/cases/fourslash/importNameCodeFix_all2.ts index 6f7a9b3403c..68c1e5d5106 100644 --- a/tests/cases/fourslash/importNameCodeFix_all2.ts +++ b/tests/cases/fourslash/importNameCodeFix_all2.ts @@ -15,8 +15,8 @@ goTo.file("/index.ts"); verify.codeFixAll({ fixId: "fixMissingImport", fixAllDescription: "Add all missing imports", - newFileContent: `import { join } from "./path"; -import { homedir } from "./os"; + newFileContent: `import { homedir } from "./os"; +import { join } from "./path"; join(); homedir();` diff --git a/tests/cases/fourslash/importNameCodeFix_avoidRelativeNodeModules.ts b/tests/cases/fourslash/importNameCodeFix_avoidRelativeNodeModules.ts index bff7fec2908..71a406a3b91 100644 --- a/tests/cases/fourslash/importNameCodeFix_avoidRelativeNodeModules.ts +++ b/tests/cases/fourslash/importNameCodeFix_avoidRelativeNodeModules.ts @@ -21,7 +21,7 @@ goTo.file("/c/foo.ts"); verify.importFixAtPosition([ -`import { b } from "b"; -import { a } from "a"; +`import { a } from "a"; +import { b } from "b"; a;`, ]); diff --git a/tests/cases/fourslash/importNameCodeFix_fileWithNoTrailingNewline.ts b/tests/cases/fourslash/importNameCodeFix_fileWithNoTrailingNewline.ts index 89d6398a553..f596de2691a 100644 --- a/tests/cases/fourslash/importNameCodeFix_fileWithNoTrailingNewline.ts +++ b/tests/cases/fourslash/importNameCodeFix_fileWithNoTrailingNewline.ts @@ -13,7 +13,6 @@ goTo.file("/c.ts"); verify.importFixAtPosition([ `foo; -import { bar } from "./b"; import { foo } from "./a"; -`, +import { bar } from "./b";`, ]); diff --git a/tests/cases/fourslash/importNameCodeFix_jsx.ts b/tests/cases/fourslash/importNameCodeFix_jsx.ts index 5e09074ba1c..27373611338 100644 --- a/tests/cases/fourslash/importNameCodeFix_jsx.ts +++ b/tests/cases/fourslash/importNameCodeFix_jsx.ts @@ -33,6 +33,6 @@ import { Foo } from "./Foo"; // When JSX namespace is missing, provide fix for that goTo.file("/d.tsx"); verify.importFixAtPosition([ -`import { Foo } from "./Foo"; -import { React } from "react"; +`import { React } from "react"; +import { Foo } from "./Foo"; ;`]); diff --git a/tests/cases/fourslash/importNameCodeFix_order.ts b/tests/cases/fourslash/importNameCodeFix_order.ts index 888b440e928..e4363a42997 100644 --- a/tests/cases/fourslash/importNameCodeFix_order.ts +++ b/tests/cases/fourslash/importNameCodeFix_order.ts @@ -15,7 +15,7 @@ goTo.file("/c.ts"); verify.importFixAtPosition([ `import { bar, foo } from "./b"; foo;`, -`import { bar } from "./b"; -import { foo } from "./a"; +`import { foo } from "./a"; +import { bar } from "./b"; foo;`, ]); diff --git a/tests/cases/fourslash/importNameCodeFix_require.ts b/tests/cases/fourslash/importNameCodeFix_require.ts index c682c469246..74687bf3e36 100644 --- a/tests/cases/fourslash/importNameCodeFix_require.ts +++ b/tests/cases/fourslash/importNameCodeFix_require.ts @@ -25,9 +25,9 @@ verify.codeFixAll({ fixId: "fixMissingImport", fixAllDescription: "Add all missing imports", newFileContent: -`const foo = require("./foo"); +`const { default: Blah } = require("./blah"); +const foo = require("./foo"); const { util1, util2 } = require("./utils"); -const { default: Blah } = require("./blah"); foo(); util1(); diff --git a/tests/cases/fourslash/importNameCodeFix_withJson.ts b/tests/cases/fourslash/importNameCodeFix_withJson.ts index 49d449b7b04..cc643240265 100644 --- a/tests/cases/fourslash/importNameCodeFix_withJson.ts +++ b/tests/cases/fourslash/importNameCodeFix_withJson.ts @@ -9,7 +9,7 @@ ////a/**/ goTo.file("/b.ts"); -verify.importFixAtPosition([`import "./anything.json"; -import { a } from "./a"; +verify.importFixAtPosition([`import { a } from "./a"; +import "./anything.json"; a`]); diff --git a/tests/cases/fourslash/quickfixImplementInterfaceUnreachableTypeUsesRelativeImport.ts b/tests/cases/fourslash/quickfixImplementInterfaceUnreachableTypeUsesRelativeImport.ts index 5db90470355..d81500d489b 100644 --- a/tests/cases/fourslash/quickfixImplementInterfaceUnreachableTypeUsesRelativeImport.ts +++ b/tests/cases/fourslash/quickfixImplementInterfaceUnreachableTypeUsesRelativeImport.ts @@ -18,8 +18,8 @@ verify.codeFix({ description: "Implement interface 'Foo'", newFileContent: { "/tests/cases/fourslash/index.ts": -`import { Foo } from './interface'; -import { Class } from './class'; +`import { Class } from './class'; +import { Foo } from './interface'; class X implements Foo { x: Class; diff --git a/tests/cases/fourslash/referencesForStatementKeywords.ts b/tests/cases/fourslash/referencesForStatementKeywords.ts index e5a171f0d9f..f089e9d1000 100644 --- a/tests/cases/fourslash/referencesForStatementKeywords.ts +++ b/tests/cases/fourslash/referencesForStatementKeywords.ts @@ -17,7 +17,7 @@ //// ////// export ... from ... ////[|{| "id": "exportDecl1" |}[|export|] [|type|] * [|from|] "[|{| "isWriteAccess": false, "isDefinition": false, "contextRangeId": "exportDecl1" |}./g|]";|] -////[|{| "id": "exportDecl2" |}[|export|] [|type|] [|{| "id": "exportDecl2_namespaceExport" |}* [|as|] [|{| "isWriteAccess": true, "isDefinition": true, "contextRangeId": "exportDecl2_namespaceExport" |}H|]|] [|from|] "[|{| "isWriteAccess": false, "isDefinition": false, "contextRangeId": "exportDecl2" |}./h|]";|] +////[|{| "id": "exportDecl2" |}[|export|] [|type|] [|{| "id": "exportDecl2_namespaceExport" |}* [|as|] [|{| "isWriteAccess": true, "isDefinition": true, "contextRangeId": "exportDecl2" |}H|]|] [|from|] "[|{| "isWriteAccess": false, "isDefinition": false, "contextRangeId": "exportDecl2" |}./h|]";|] ////[|{| "id": "exportDecl3" |}[|export|] [|type|] { [|{| "isWriteAccess": true, "isDefinition": true, "contextRangeId": "exportDecl3" |}I|] } [|from|] "[|{| "isWriteAccess": false, "isDefinition": false, "contextRangeId": "exportDecl3" |}./i|]";|] ////[|{| "id": "exportDecl4" |}[|export|] [|type|] { j1, j2 [|as|] [|{| "isWriteAccess": true, "isDefinition": true, "contextRangeId": "exportDecl4" |}j3|] } [|from|] "[|{| "isWriteAccess": false, "isDefinition": false, "contextRangeId": "exportDecl4" |}./j|]";|] ////[|{| "id": "typeDecl1" |}type [|{| "isWriteAccess": true, "isDefinition": true, "contextRangeId": "typeDecl1" |}Z1|] = 1;|] diff --git a/tests/cases/fourslash/renameRestBindingElement.ts b/tests/cases/fourslash/renameRestBindingElement.ts new file mode 100644 index 00000000000..59e58c37f4a --- /dev/null +++ b/tests/cases/fourslash/renameRestBindingElement.ts @@ -0,0 +1,13 @@ +/// + +////interface I { +//// a: number; +//// b: number; +//// c: number; +////} +////function foo([|{ a, ...[|{| "contextRangeIndex": 0 |}rest|] }: I|]) { +//// [|rest|]; +////} + +const [r0Def, r0, r1] = test.ranges(); +verify.renameLocations(r0, { ranges: [r0, r1], providePrefixAndSuffixTextForRename: true });