mirror of
https://github.com/microsoft/TypeScript.git
synced 2025-11-18 17:21:48 +00:00
Merge pull request #15507 from Microsoft/spelling-correction
Spelling correction
This commit is contained in:
+170
-48
@@ -205,6 +205,8 @@ namespace ts {
|
||||
return tryFindAmbientModule(moduleName, /*withAugmentations*/ false);
|
||||
},
|
||||
getApparentType,
|
||||
getSuggestionForNonexistentProperty,
|
||||
getSuggestionForNonexistentSymbol,
|
||||
getBaseConstraintOfType,
|
||||
};
|
||||
|
||||
@@ -317,6 +319,8 @@ namespace ts {
|
||||
const resolutionResults: boolean[] = [];
|
||||
const resolutionPropertyNames: TypeSystemPropertyName[] = [];
|
||||
|
||||
let suggestionCount = 0;
|
||||
const maximumSuggestionCount = 10;
|
||||
const mergedSymbols: Symbol[] = [];
|
||||
const symbolLinks: SymbolLinks[] = [];
|
||||
const nodeLinks: NodeLinks[] = [];
|
||||
@@ -841,7 +845,25 @@ namespace ts {
|
||||
// Resolve a given name for a given meaning at a given location. An error is reported if the name was not found and
|
||||
// the nameNotFoundMessage argument is not undefined. Returns the resolved symbol, or undefined if no symbol with
|
||||
// the given name can be found.
|
||||
function resolveName(location: Node | undefined, name: string, meaning: SymbolFlags, nameNotFoundMessage: DiagnosticMessage, nameArg: string | Identifier): Symbol {
|
||||
function resolveName(
|
||||
location: Node | undefined,
|
||||
name: string,
|
||||
meaning: SymbolFlags,
|
||||
nameNotFoundMessage: DiagnosticMessage,
|
||||
nameArg: string | Identifier,
|
||||
suggestedNameNotFoundMessage?: DiagnosticMessage): Symbol {
|
||||
return resolveNameHelper(location, name, meaning, nameNotFoundMessage, nameArg, getSymbol, suggestedNameNotFoundMessage);
|
||||
}
|
||||
|
||||
function resolveNameHelper(
|
||||
location: Node | undefined,
|
||||
name: string,
|
||||
meaning: SymbolFlags,
|
||||
nameNotFoundMessage: DiagnosticMessage,
|
||||
nameArg: string | Identifier,
|
||||
lookup: (symbols: SymbolTable, name: string, meaning: SymbolFlags) => Symbol,
|
||||
suggestedNameNotFoundMessage?: DiagnosticMessage): Symbol {
|
||||
const originalLocation = location; // needed for did-you-mean error reporting, which gathers candidates starting from the original location
|
||||
let result: Symbol;
|
||||
let lastLocation: Node;
|
||||
let propertyWithInvalidInitializer: Node;
|
||||
@@ -852,7 +874,7 @@ namespace ts {
|
||||
loop: while (location) {
|
||||
// Locals of a source file are not in scope (because they get merged into the global symbol table)
|
||||
if (location.locals && !isGlobalSourceFile(location)) {
|
||||
if (result = getSymbol(location.locals, name, meaning)) {
|
||||
if (result = lookup(location.locals, name, meaning)) {
|
||||
let useResult = true;
|
||||
if (isFunctionLike(location) && lastLocation && lastLocation !== (<FunctionLikeDeclaration>location).body) {
|
||||
// symbol lookup restrictions for function-like declarations
|
||||
@@ -930,12 +952,12 @@ namespace ts {
|
||||
}
|
||||
}
|
||||
|
||||
if (result = getSymbol(moduleExports, name, meaning & SymbolFlags.ModuleMember)) {
|
||||
if (result = lookup(moduleExports, name, meaning & SymbolFlags.ModuleMember)) {
|
||||
break loop;
|
||||
}
|
||||
break;
|
||||
case SyntaxKind.EnumDeclaration:
|
||||
if (result = getSymbol(getSymbolOfNode(location).exports, name, meaning & SymbolFlags.EnumMember)) {
|
||||
if (result = lookup(getSymbolOfNode(location).exports, name, meaning & SymbolFlags.EnumMember)) {
|
||||
break loop;
|
||||
}
|
||||
break;
|
||||
@@ -950,7 +972,7 @@ namespace ts {
|
||||
if (isClassLike(location.parent) && !(getModifierFlags(location) & ModifierFlags.Static)) {
|
||||
const ctor = findConstructorDeclaration(<ClassLikeDeclaration>location.parent);
|
||||
if (ctor && ctor.locals) {
|
||||
if (getSymbol(ctor.locals, name, meaning & SymbolFlags.Value)) {
|
||||
if (lookup(ctor.locals, name, meaning & SymbolFlags.Value)) {
|
||||
// Remember the property node, it will be used later to report appropriate error
|
||||
propertyWithInvalidInitializer = location;
|
||||
}
|
||||
@@ -960,7 +982,7 @@ namespace ts {
|
||||
case SyntaxKind.ClassDeclaration:
|
||||
case SyntaxKind.ClassExpression:
|
||||
case SyntaxKind.InterfaceDeclaration:
|
||||
if (result = getSymbol(getSymbolOfNode(location).members, name, meaning & SymbolFlags.Type)) {
|
||||
if (result = lookup(getSymbolOfNode(location).members, name, meaning & SymbolFlags.Type)) {
|
||||
if (!isTypeParameterSymbolDeclaredInContainer(result, location)) {
|
||||
// ignore type parameters not declared in this container
|
||||
result = undefined;
|
||||
@@ -996,7 +1018,7 @@ namespace ts {
|
||||
grandparent = location.parent.parent;
|
||||
if (isClassLike(grandparent) || grandparent.kind === SyntaxKind.InterfaceDeclaration) {
|
||||
// A reference to this grandparent's type parameters would be an error
|
||||
if (result = getSymbol(getSymbolOfNode(grandparent).members, name, meaning & SymbolFlags.Type)) {
|
||||
if (result = lookup(getSymbolOfNode(grandparent).members, name, meaning & SymbolFlags.Type)) {
|
||||
error(errorLocation, Diagnostics.A_computed_property_name_cannot_reference_a_type_parameter_from_its_containing_type);
|
||||
return undefined;
|
||||
}
|
||||
@@ -1060,7 +1082,7 @@ namespace ts {
|
||||
}
|
||||
|
||||
if (!result) {
|
||||
result = getSymbol(globals, name, meaning);
|
||||
result = lookup(globals, name, meaning);
|
||||
}
|
||||
|
||||
if (!result) {
|
||||
@@ -1071,7 +1093,17 @@ namespace ts {
|
||||
!checkAndReportErrorForUsingTypeAsNamespace(errorLocation, name, meaning) &&
|
||||
!checkAndReportErrorForUsingTypeAsValue(errorLocation, name, meaning) &&
|
||||
!checkAndReportErrorForUsingNamespaceModuleAsValue(errorLocation, name, meaning)) {
|
||||
error(errorLocation, nameNotFoundMessage, typeof nameArg === "string" ? nameArg : declarationNameToString(nameArg));
|
||||
let suggestion: string | undefined;
|
||||
if (suggestedNameNotFoundMessage && suggestionCount < maximumSuggestionCount) {
|
||||
suggestion = getSuggestionForNonexistentSymbol(originalLocation, name, meaning);
|
||||
if (suggestion) {
|
||||
suggestionCount++;
|
||||
error(errorLocation, suggestedNameNotFoundMessage, typeof nameArg === "string" ? nameArg : declarationNameToString(nameArg), suggestion);
|
||||
}
|
||||
}
|
||||
if (!suggestion) {
|
||||
error(errorLocation, nameNotFoundMessage, typeof nameArg === "string" ? nameArg : declarationNameToString(nameArg));
|
||||
}
|
||||
}
|
||||
}
|
||||
return undefined;
|
||||
@@ -1205,6 +1237,10 @@ namespace ts {
|
||||
|
||||
function checkAndReportErrorForUsingTypeAsValue(errorLocation: Node, name: string, meaning: SymbolFlags): boolean {
|
||||
if (meaning & (SymbolFlags.Value & ~SymbolFlags.NamespaceModule)) {
|
||||
if (name === "any" || name === "string" || name === "number" || name === "boolean" || name === "never") {
|
||||
error(errorLocation, Diagnostics._0_only_refers_to_a_type_but_is_being_used_as_a_value_here, name);
|
||||
return true;
|
||||
}
|
||||
const symbol = resolveSymbol(resolveName(errorLocation, name, SymbolFlags.Type & ~SymbolFlags.Value, /*nameNotFoundMessage*/undefined, /*nameArg*/ undefined));
|
||||
if (symbol && !(symbol.flags & SymbolFlags.NamespaceModule)) {
|
||||
error(errorLocation, Diagnostics._0_only_refers_to_a_type_but_is_being_used_as_a_value_here, name);
|
||||
@@ -10402,7 +10438,7 @@ namespace ts {
|
||||
function getResolvedSymbol(node: Identifier): Symbol {
|
||||
const links = getNodeLinks(node);
|
||||
if (!links.resolvedSymbol) {
|
||||
links.resolvedSymbol = !nodeIsMissing(node) && resolveName(node, node.text, SymbolFlags.Value | SymbolFlags.ExportValue, Diagnostics.Cannot_find_name_0, node) || unknownSymbol;
|
||||
links.resolvedSymbol = !nodeIsMissing(node) && resolveName(node, node.text, SymbolFlags.Value | SymbolFlags.ExportValue, Diagnostics.Cannot_find_name_0, node, Diagnostics.Cannot_find_name_0_Did_you_mean_1) || unknownSymbol;
|
||||
}
|
||||
return links.resolvedSymbol;
|
||||
}
|
||||
@@ -14118,44 +14154,6 @@ namespace ts {
|
||||
return checkPropertyAccessExpressionOrQualifiedName(node, node.left, node.right);
|
||||
}
|
||||
|
||||
function reportNonexistentProperty(propNode: Identifier, containingType: Type) {
|
||||
let errorInfo: DiagnosticMessageChain;
|
||||
if (containingType.flags & TypeFlags.Union && !(containingType.flags & TypeFlags.Primitive)) {
|
||||
for (const subtype of (containingType as UnionType).types) {
|
||||
if (!getPropertyOfType(subtype, propNode.text)) {
|
||||
errorInfo = chainDiagnosticMessages(errorInfo, Diagnostics.Property_0_does_not_exist_on_type_1, declarationNameToString(propNode), typeToString(subtype));
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
errorInfo = chainDiagnosticMessages(errorInfo, Diagnostics.Property_0_does_not_exist_on_type_1, declarationNameToString(propNode), typeToString(containingType));
|
||||
diagnostics.add(createDiagnosticForNodeFromMessageChain(propNode, errorInfo));
|
||||
}
|
||||
|
||||
function markPropertyAsReferenced(prop: Symbol) {
|
||||
if (prop &&
|
||||
noUnusedIdentifiers &&
|
||||
(prop.flags & SymbolFlags.ClassMember) &&
|
||||
prop.valueDeclaration && (getModifierFlags(prop.valueDeclaration) & ModifierFlags.Private)) {
|
||||
if (getCheckFlags(prop) & CheckFlags.Instantiated) {
|
||||
getSymbolLinks(prop).target.isReferenced = true;
|
||||
}
|
||||
else {
|
||||
prop.isReferenced = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function isInPropertyInitializer(node: Node): boolean {
|
||||
while (node) {
|
||||
if (node.parent && node.parent.kind === SyntaxKind.PropertyDeclaration && (node.parent as PropertyDeclaration).initializer === node) {
|
||||
return true;
|
||||
}
|
||||
node = node.parent;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
function checkPropertyAccessExpressionOrQualifiedName(node: PropertyAccessExpression | QualifiedName, left: Expression | QualifiedName, right: Identifier) {
|
||||
const type = checkNonNullExpression(left);
|
||||
if (isTypeAny(type) || type === silentNeverType) {
|
||||
@@ -14219,6 +14217,130 @@ namespace ts {
|
||||
return assignmentKind ? getBaseTypeOfLiteralType(flowType) : flowType;
|
||||
}
|
||||
|
||||
function reportNonexistentProperty(propNode: Identifier, containingType: Type) {
|
||||
let errorInfo: DiagnosticMessageChain;
|
||||
if (containingType.flags & TypeFlags.Union && !(containingType.flags & TypeFlags.Primitive)) {
|
||||
for (const subtype of (containingType as UnionType).types) {
|
||||
if (!getPropertyOfType(subtype, propNode.text)) {
|
||||
errorInfo = chainDiagnosticMessages(errorInfo, Diagnostics.Property_0_does_not_exist_on_type_1, declarationNameToString(propNode), typeToString(subtype));
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
const suggestion = getSuggestionForNonexistentProperty(propNode, containingType);
|
||||
if (suggestion) {
|
||||
errorInfo = chainDiagnosticMessages(errorInfo, Diagnostics.Property_0_does_not_exist_on_type_1_Did_you_mean_2, declarationNameToString(propNode), typeToString(containingType), suggestion);
|
||||
}
|
||||
else {
|
||||
errorInfo = chainDiagnosticMessages(errorInfo, Diagnostics.Property_0_does_not_exist_on_type_1, declarationNameToString(propNode), typeToString(containingType));
|
||||
}
|
||||
diagnostics.add(createDiagnosticForNodeFromMessageChain(propNode, errorInfo));
|
||||
}
|
||||
|
||||
function getSuggestionForNonexistentProperty(node: Identifier, containingType: Type): string | undefined {
|
||||
const suggestion = getSpellingSuggestionForName(node.text, getPropertiesOfObjectType(containingType), SymbolFlags.Value);
|
||||
return suggestion && suggestion.name;
|
||||
}
|
||||
|
||||
function getSuggestionForNonexistentSymbol(location: Node, name: string, meaning: SymbolFlags): string {
|
||||
const result = resolveNameHelper(location, name, meaning, /*nameNotFoundMessage*/ undefined, name, (symbols, name, meaning) => {
|
||||
const symbol = getSymbol(symbols, name, meaning);
|
||||
if (symbol) {
|
||||
// Sometimes the symbol is found when location is a return type of a function: `typeof x` and `x` is declared in the body of the function
|
||||
// So the table *contains* `x` but `x` isn't actually in scope.
|
||||
// However, resolveNameHelper will continue and call this callback again, so we'll eventually get a correct suggestion.
|
||||
return symbol;
|
||||
}
|
||||
return getSpellingSuggestionForName(name, arrayFrom(symbols.values()), meaning);
|
||||
});
|
||||
if (result) {
|
||||
return result.name;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Given a name and a list of symbols whose names are *not* equal to the name, return a spelling suggestion if there is one that is close enough.
|
||||
* Names less than length 3 only check for case-insensitive equality, not levenshtein distance.
|
||||
*
|
||||
* If there is a candidate that's the same except for case, return that.
|
||||
* If there is a candidate that's within one edit of the name, return that.
|
||||
* Otherwise, return the candidate with the smallest Levenshtein distance,
|
||||
* except for candidates:
|
||||
* * With no name
|
||||
* * Whose meaning doesn't match the `meaning` parameter.
|
||||
* * Whose length differs from the target name by more than 0.3 of the length of the name.
|
||||
* * Whose levenshtein distance is more than 0.4 of the length of the name
|
||||
* (0.4 allows 1 substitution/transposition for every 5 characters,
|
||||
* and 1 insertion/deletion at 3 characters)
|
||||
* Names longer than 30 characters don't get suggestions because Levenshtein distance is an n**2 algorithm.
|
||||
*/
|
||||
function getSpellingSuggestionForName(name: string, symbols: Symbol[], meaning: SymbolFlags): Symbol | undefined {
|
||||
const worstDistance = name.length * 0.4;
|
||||
const maximumLengthDifference = Math.min(3, name.length * 0.34);
|
||||
let bestDistance = Number.MAX_VALUE;
|
||||
let bestCandidate = undefined;
|
||||
if (name.length > 30) {
|
||||
return undefined;
|
||||
}
|
||||
name = name.toLowerCase();
|
||||
for (const candidate of symbols) {
|
||||
if (candidate.flags & meaning &&
|
||||
candidate.name &&
|
||||
Math.abs(candidate.name.length - name.length) < maximumLengthDifference) {
|
||||
const candidateName = candidate.name.toLowerCase();
|
||||
if (candidateName === name) {
|
||||
return candidate;
|
||||
}
|
||||
if (candidateName.length < 3 ||
|
||||
name.length < 3 ||
|
||||
candidateName === "eval" ||
|
||||
candidateName === "intl" ||
|
||||
candidateName === "undefined" ||
|
||||
candidateName === "map" ||
|
||||
candidateName === "nan" ||
|
||||
candidateName === "set") {
|
||||
continue;
|
||||
}
|
||||
const distance = levenshtein(name, candidateName);
|
||||
if (distance > worstDistance) {
|
||||
continue;
|
||||
}
|
||||
if (distance < 3) {
|
||||
return candidate;
|
||||
}
|
||||
else if (distance < bestDistance) {
|
||||
bestDistance = distance;
|
||||
bestCandidate = candidate;
|
||||
}
|
||||
}
|
||||
}
|
||||
return bestCandidate;
|
||||
}
|
||||
|
||||
function markPropertyAsReferenced(prop: Symbol) {
|
||||
if (prop &&
|
||||
noUnusedIdentifiers &&
|
||||
(prop.flags & SymbolFlags.ClassMember) &&
|
||||
prop.valueDeclaration && (getModifierFlags(prop.valueDeclaration) & ModifierFlags.Private)) {
|
||||
if (getCheckFlags(prop) & CheckFlags.Instantiated) {
|
||||
getSymbolLinks(prop).target.isReferenced = true;
|
||||
}
|
||||
else {
|
||||
prop.isReferenced = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function isInPropertyInitializer(node: Node): boolean {
|
||||
while (node) {
|
||||
if (node.parent && node.parent.kind === SyntaxKind.PropertyDeclaration && (node.parent as PropertyDeclaration).initializer === node) {
|
||||
return true;
|
||||
}
|
||||
node = node.parent;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
function isValidPropertyAccess(node: PropertyAccessExpression | QualifiedName, propertyName: string): boolean {
|
||||
const left = node.kind === SyntaxKind.PropertyAccessExpression
|
||||
? (<PropertyAccessExpression>node).expression
|
||||
|
||||
@@ -1843,6 +1843,14 @@
|
||||
"category": "Error",
|
||||
"code": 2550
|
||||
},
|
||||
"Property '{0}' does not exist on type '{1}'. Did you mean '{2}'?": {
|
||||
"category": "Error",
|
||||
"code": 2551
|
||||
},
|
||||
"Cannot find name '{0}'. Did you mean '{1}'?": {
|
||||
"category": "Error",
|
||||
"code": 2552
|
||||
},
|
||||
"JSX element attributes type '{0}' may not be a union type.": {
|
||||
"category": "Error",
|
||||
"code": 2600
|
||||
@@ -3539,7 +3547,10 @@
|
||||
"category": "Message",
|
||||
"code": 90021
|
||||
},
|
||||
|
||||
"Change spelling to '{0}'.": {
|
||||
"category": "Message",
|
||||
"code": 90022
|
||||
},
|
||||
|
||||
"Octal literal types must use ES2015 syntax. Use the syntax '{0}'.": {
|
||||
"category": "Error",
|
||||
|
||||
@@ -2552,6 +2552,8 @@ namespace ts {
|
||||
|
||||
tryGetMemberInModuleExports(memberName: string, moduleSymbol: Symbol): Symbol | undefined;
|
||||
getApparentType(type: Type): Type;
|
||||
getSuggestionForNonexistentProperty(node: Identifier, containingType: Type): string | undefined;
|
||||
getSuggestionForNonexistentSymbol(location: Node, name: string, meaning: SymbolFlags): string;
|
||||
/* @internal */ getBaseConstraintOfType(type: Type): Type;
|
||||
|
||||
/* @internal */ tryFindAmbientModuleWithoutAugmentations(moduleName: string): Symbol;
|
||||
|
||||
@@ -4641,4 +4641,27 @@ namespace ts {
|
||||
export function unescapeIdentifier(identifier: string): string {
|
||||
return identifier.length >= 3 && identifier.charCodeAt(0) === CharacterCodes._ && identifier.charCodeAt(1) === CharacterCodes._ && identifier.charCodeAt(2) === CharacterCodes._ ? identifier.substr(1) : identifier;
|
||||
}
|
||||
|
||||
export function levenshtein(s1: string, s2: string): number {
|
||||
let previous: number[] = new Array(s2.length + 1);
|
||||
let current: number[] = new Array(s2.length + 1);
|
||||
for (let i = 0; i < s2.length + 1; i++) {
|
||||
previous[i] = i;
|
||||
current[i] = -1;
|
||||
}
|
||||
for (let i = 1; i < s1.length + 1; i++) {
|
||||
current[0] = i;
|
||||
for (let j = 1; j < s2.length + 1; j++) {
|
||||
current[j] = Math.min(
|
||||
previous[j] + 1,
|
||||
current[j - 1] + 1,
|
||||
previous[j - 1] + (s1[i - 1] === s2[j - 1] ? 0 : 2));
|
||||
}
|
||||
// shift current back to previous, and then reuse previous' array
|
||||
const tmp = previous;
|
||||
previous = current;
|
||||
current = tmp;
|
||||
}
|
||||
return previous[previous.length - 1];
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
/* @internal */
|
||||
namespace ts.codefix {
|
||||
registerCodeFix({
|
||||
errorCodes: [Diagnostics.Property_0_does_not_exist_on_type_1.code],
|
||||
errorCodes: [Diagnostics.Property_0_does_not_exist_on_type_1.code,
|
||||
Diagnostics.Property_0_does_not_exist_on_type_1_Did_you_mean_2.code],
|
||||
getCodeActions: getActionsForAddMissingMember
|
||||
});
|
||||
|
||||
@@ -135,4 +136,4 @@ namespace ts.codefix {
|
||||
return actions;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,53 @@
|
||||
/* @internal */
|
||||
namespace ts.codefix {
|
||||
registerCodeFix({
|
||||
errorCodes: [Diagnostics.Property_0_does_not_exist_on_type_1_Did_you_mean_2.code,
|
||||
Diagnostics.Cannot_find_name_0_Did_you_mean_1.code],
|
||||
getCodeActions: getActionsForCorrectSpelling
|
||||
});
|
||||
|
||||
function getActionsForCorrectSpelling(context: CodeFixContext): CodeAction[] | undefined {
|
||||
const sourceFile = context.sourceFile;
|
||||
|
||||
// This is the identifier of the misspelled word. eg:
|
||||
// this.speling = 1;
|
||||
// ^^^^^^^
|
||||
const node = getTokenAtPosition(sourceFile, context.span.start);
|
||||
const checker = context.program.getTypeChecker();
|
||||
let suggestion: string;
|
||||
if (node.kind === SyntaxKind.Identifier && isPropertyAccessExpression(node.parent)) {
|
||||
const containingType = checker.getTypeAtLocation(node.parent.expression);
|
||||
suggestion = checker.getSuggestionForNonexistentProperty(node as Identifier, containingType);
|
||||
}
|
||||
else {
|
||||
const meaning = getMeaningFromLocation(node);
|
||||
suggestion = checker.getSuggestionForNonexistentSymbol(node, getTextOfNode(node), convertSemanticMeaningToSymbolFlags(meaning));
|
||||
}
|
||||
if (suggestion) {
|
||||
return [{
|
||||
description: formatStringFromArgs(getLocaleSpecificMessage(Diagnostics.Change_spelling_to_0), [suggestion]),
|
||||
changes: [{
|
||||
fileName: sourceFile.fileName,
|
||||
textChanges: [{
|
||||
span: { start: node.getStart(), length: node.getWidth() },
|
||||
newText: suggestion
|
||||
}],
|
||||
}],
|
||||
}];
|
||||
}
|
||||
}
|
||||
|
||||
function convertSemanticMeaningToSymbolFlags(meaning: SemanticMeaning): SymbolFlags {
|
||||
let flags = 0;
|
||||
if (meaning & SemanticMeaning.Namespace) {
|
||||
flags |= SymbolFlags.Namespace;
|
||||
}
|
||||
if (meaning & SemanticMeaning.Type) {
|
||||
flags |= SymbolFlags.Type;
|
||||
}
|
||||
if (meaning & SemanticMeaning.Value) {
|
||||
flags |= SymbolFlags.Value;
|
||||
}
|
||||
return flags;
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,6 @@
|
||||
/// <reference path="fixClassIncorrectlyImplementsInterface.ts" />
|
||||
/// <reference path="fixAddMissingMember.ts" />
|
||||
/// <reference path="fixSpelling.ts" />
|
||||
/// <reference path="fixClassDoesntImplementInheritedAbstractMember.ts" />
|
||||
/// <reference path="fixClassSuperMustPrecedeThisAccess.ts" />
|
||||
/// <reference path="fixConstructorForDerivedNeedSuperCall.ts" />
|
||||
|
||||
@@ -3,6 +3,7 @@ namespace ts.codefix {
|
||||
registerCodeFix({
|
||||
errorCodes: [
|
||||
Diagnostics.Cannot_find_name_0.code,
|
||||
Diagnostics.Cannot_find_name_0_Did_you_mean_1.code,
|
||||
Diagnostics.Cannot_find_namespace_0.code,
|
||||
Diagnostics._0_refers_to_a_UMD_global_but_the_current_file_is_a_module_Consider_adding_an_import_instead.code
|
||||
],
|
||||
|
||||
@@ -82,6 +82,7 @@
|
||||
"formatting/tokenRange.ts",
|
||||
"codeFixProvider.ts",
|
||||
"codefixes/fixAddMissingMember.ts",
|
||||
"codefixes/fixSpelling.ts",
|
||||
"codefixes/fixExtendsInterfaceBecomesImplements.ts",
|
||||
"codefixes/fixClassIncorrectlyImplementsInterface.ts",
|
||||
"codefixes/fixClassDoesntImplementInheritedAbstractMember.ts",
|
||||
@@ -94,4 +95,4 @@
|
||||
"codefixes/unusedIdentifierFixes.ts",
|
||||
"codefixes/disableJsDiagnostics.ts"
|
||||
]
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
tests/cases/conformance/internalModules/exportDeclarations/ModuleWithExportedAndNonExportedFunctions.ts(28,13): error TS2339: Property 'fn2' does not exist on type 'typeof A'.
|
||||
tests/cases/conformance/internalModules/exportDeclarations/ModuleWithExportedAndNonExportedFunctions.ts(29,14): error TS2339: Property 'fng2' does not exist on type 'typeof A'.
|
||||
tests/cases/conformance/internalModules/exportDeclarations/ModuleWithExportedAndNonExportedFunctions.ts(29,14): error TS2551: Property 'fng2' does not exist on type 'typeof A'. Did you mean 'fng'?
|
||||
|
||||
|
||||
==== tests/cases/conformance/internalModules/exportDeclarations/ModuleWithExportedAndNonExportedFunctions.ts (2 errors) ====
|
||||
@@ -35,4 +35,4 @@ tests/cases/conformance/internalModules/exportDeclarations/ModuleWithExportedAnd
|
||||
!!! error TS2339: Property 'fn2' does not exist on type 'typeof A'.
|
||||
var fng2 = A.fng2;
|
||||
~~~~
|
||||
!!! error TS2339: Property 'fng2' does not exist on type 'typeof A'.
|
||||
!!! error TS2551: Property 'fng2' does not exist on type 'typeof A'. Did you mean 'fng'?
|
||||
@@ -1,4 +1,4 @@
|
||||
tests/cases/compiler/anonymousClassExpression2.ts(13,18): error TS2339: Property 'methodA' does not exist on type 'B'.
|
||||
tests/cases/compiler/anonymousClassExpression2.ts(13,18): error TS2551: Property 'methodA' does not exist on type 'B'. Did you mean 'methodB'?
|
||||
|
||||
|
||||
==== tests/cases/compiler/anonymousClassExpression2.ts (1 errors) ====
|
||||
@@ -16,7 +16,7 @@ tests/cases/compiler/anonymousClassExpression2.ts(13,18): error TS2339: Property
|
||||
methodB() {
|
||||
this.methodA; // error
|
||||
~~~~~~~
|
||||
!!! error TS2339: Property 'methodA' does not exist on type 'B'.
|
||||
!!! error TS2551: Property 'methodA' does not exist on type 'B'. Did you mean 'methodB'?
|
||||
this.methodB; // ok
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
tests/cases/compiler/assignmentRestElementWithErrorSourceType.ts(2,5): error TS2304: Cannot find name 'c'.
|
||||
tests/cases/compiler/assignmentRestElementWithErrorSourceType.ts(2,10): error TS2304: Cannot find name 'tupel'.
|
||||
tests/cases/compiler/assignmentRestElementWithErrorSourceType.ts(2,10): error TS2552: Cannot find name 'tupel'. Did you mean 'tuple'?
|
||||
|
||||
|
||||
==== tests/cases/compiler/assignmentRestElementWithErrorSourceType.ts (2 errors) ====
|
||||
@@ -8,4 +8,4 @@ tests/cases/compiler/assignmentRestElementWithErrorSourceType.ts(2,10): error TS
|
||||
~
|
||||
!!! error TS2304: Cannot find name 'c'.
|
||||
~~~~~
|
||||
!!! error TS2304: Cannot find name 'tupel'.
|
||||
!!! error TS2552: Cannot find name 'tupel'. Did you mean 'tuple'?
|
||||
@@ -1,9 +1,9 @@
|
||||
tests/cases/compiler/autoLift2.ts(5,14): error TS2339: Property 'foo' does not exist on type 'A'.
|
||||
tests/cases/compiler/autoLift2.ts(5,17): error TS1005: ';' expected.
|
||||
tests/cases/compiler/autoLift2.ts(5,19): error TS2304: Cannot find name 'any'.
|
||||
tests/cases/compiler/autoLift2.ts(5,19): error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/autoLift2.ts(6,14): error TS2339: Property 'bar' does not exist on type 'A'.
|
||||
tests/cases/compiler/autoLift2.ts(6,17): error TS1005: ';' expected.
|
||||
tests/cases/compiler/autoLift2.ts(6,19): error TS2304: Cannot find name 'any'.
|
||||
tests/cases/compiler/autoLift2.ts(6,19): error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/autoLift2.ts(12,11): error TS2339: Property 'foo' does not exist on type 'A'.
|
||||
tests/cases/compiler/autoLift2.ts(14,11): error TS2339: Property 'bar' does not exist on type 'A'.
|
||||
tests/cases/compiler/autoLift2.ts(16,33): error TS2339: Property 'foo' does not exist on type 'A'.
|
||||
@@ -21,14 +21,14 @@ tests/cases/compiler/autoLift2.ts(18,33): error TS2339: Property 'bar' does not
|
||||
~
|
||||
!!! error TS1005: ';' expected.
|
||||
~~~
|
||||
!!! error TS2304: Cannot find name 'any'.
|
||||
!!! error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
this.bar: any;
|
||||
~~~
|
||||
!!! error TS2339: Property 'bar' does not exist on type 'A'.
|
||||
~
|
||||
!!! error TS1005: ';' expected.
|
||||
~~~
|
||||
!!! error TS2304: Cannot find name 'any'.
|
||||
!!! error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
tests/cases/compiler/badArrayIndex.ts(1,15): error TS2304: Cannot find name 'number'.
|
||||
tests/cases/compiler/badArrayIndex.ts(1,15): error TS2693: 'number' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/badArrayIndex.ts(1,22): error TS1109: Expression expected.
|
||||
|
||||
|
||||
==== tests/cases/compiler/badArrayIndex.ts (2 errors) ====
|
||||
var results = number[];
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'number'.
|
||||
!!! error TS2693: 'number' only refers to a type, but is being used as a value here.
|
||||
~
|
||||
!!! error TS1109: Expression expected.
|
||||
@@ -1,4 +1,4 @@
|
||||
tests/cases/compiler/baseCheck.ts(9,18): error TS2304: Cannot find name 'loc'.
|
||||
tests/cases/compiler/baseCheck.ts(9,18): error TS2552: Cannot find name 'loc'. Did you mean 'ELoc'?
|
||||
tests/cases/compiler/baseCheck.ts(17,53): error TS2346: Supplied parameters do not match any signature of call target.
|
||||
tests/cases/compiler/baseCheck.ts(17,59): error TS17009: 'super' must be called before accessing 'this' in the constructor of a derived class.
|
||||
tests/cases/compiler/baseCheck.ts(18,62): error TS17009: 'super' must be called before accessing 'this' in the constructor of a derived class.
|
||||
@@ -20,7 +20,7 @@ tests/cases/compiler/baseCheck.ts(26,9): error TS2304: Cannot find name 'x'.
|
||||
constructor(x: number) {
|
||||
super(0, loc);
|
||||
~~~
|
||||
!!! error TS2304: Cannot find name 'loc'.
|
||||
!!! error TS2552: Cannot find name 'loc'. Did you mean 'ELoc'?
|
||||
}
|
||||
|
||||
m() {
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
tests/cases/compiler/bases.ts(7,14): error TS2339: Property 'y' does not exist on type 'B'.
|
||||
tests/cases/compiler/bases.ts(7,15): error TS1005: ';' expected.
|
||||
tests/cases/compiler/bases.ts(7,17): error TS2304: Cannot find name 'any'.
|
||||
tests/cases/compiler/bases.ts(7,17): error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/bases.ts(11,7): error TS2420: Class 'C' incorrectly implements interface 'I'.
|
||||
Property 'x' is missing in type 'C'.
|
||||
tests/cases/compiler/bases.ts(12,5): error TS2377: Constructors for derived classes must contain a 'super' call.
|
||||
tests/cases/compiler/bases.ts(13,9): error TS17009: 'super' must be called before accessing 'this' in the constructor of a derived class.
|
||||
tests/cases/compiler/bases.ts(13,14): error TS2339: Property 'x' does not exist on type 'C'.
|
||||
tests/cases/compiler/bases.ts(13,15): error TS1005: ';' expected.
|
||||
tests/cases/compiler/bases.ts(13,17): error TS2304: Cannot find name 'any'.
|
||||
tests/cases/compiler/bases.ts(13,17): error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/bases.ts(17,9): error TS2339: Property 'x' does not exist on type 'C'.
|
||||
tests/cases/compiler/bases.ts(18,9): error TS2339: Property 'y' does not exist on type 'C'.
|
||||
|
||||
@@ -25,7 +25,7 @@ tests/cases/compiler/bases.ts(18,9): error TS2339: Property 'y' does not exist o
|
||||
~
|
||||
!!! error TS1005: ';' expected.
|
||||
~~~
|
||||
!!! error TS2304: Cannot find name 'any'.
|
||||
!!! error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
}
|
||||
}
|
||||
|
||||
@@ -44,7 +44,7 @@ tests/cases/compiler/bases.ts(18,9): error TS2339: Property 'y' does not exist o
|
||||
~
|
||||
!!! error TS1005: ';' expected.
|
||||
~~~
|
||||
!!! error TS2304: Cannot find name 'any'.
|
||||
!!! error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
}
|
||||
~~~~~
|
||||
!!! error TS2377: Constructors for derived classes must contain a 'super' call.
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
tests/cases/compiler/cannotInvokeNewOnIndexExpression.ts(1,23): error TS2304: Cannot find name 'any'.
|
||||
tests/cases/compiler/cannotInvokeNewOnIndexExpression.ts(1,23): error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
|
||||
|
||||
==== tests/cases/compiler/cannotInvokeNewOnIndexExpression.ts (1 errors) ====
|
||||
var test: any[] = new any[1];
|
||||
~~~
|
||||
!!! error TS2304: Cannot find name 'any'.
|
||||
!!! error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
@@ -1,4 +1,4 @@
|
||||
tests/cases/conformance/jsx/file.tsx(24,28): error TS2339: Property 'NAme' does not exist on type 'IUser'.
|
||||
tests/cases/conformance/jsx/file.tsx(24,28): error TS2551: Property 'NAme' does not exist on type 'IUser'. Did you mean 'Name'?
|
||||
tests/cases/conformance/jsx/file.tsx(32,9): error TS2322: Type '{ children: ((user: IUser) => Element)[]; }' is not assignable to type 'IntrinsicAttributes & IntrinsicClassAttributes<FetchUser> & IFetchUserProps & { children?: ReactNode; }'.
|
||||
Type '{ children: ((user: IUser) => Element)[]; }' is not assignable to type 'IFetchUserProps'.
|
||||
Types of property 'children' are incompatible.
|
||||
@@ -32,7 +32,7 @@ tests/cases/conformance/jsx/file.tsx(32,9): error TS2322: Type '{ children: ((us
|
||||
{ user => (
|
||||
<h1>{ user.NAme }</h1>
|
||||
~~~~
|
||||
!!! error TS2339: Property 'NAme' does not exist on type 'IUser'.
|
||||
!!! error TS2551: Property 'NAme' does not exist on type 'IUser'. Did you mean 'Name'?
|
||||
) }
|
||||
</FetchUser>
|
||||
);
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendingPrimitive.ts(3,17): error TS2304: Cannot find name 'number'.
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendingPrimitive.ts(4,18): error TS2304: Cannot find name 'string'.
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendingPrimitive.ts(5,18): error TS2304: Cannot find name 'boolean'.
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendingPrimitive.ts(3,17): error TS2693: 'number' only refers to a type, but is being used as a value here.
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendingPrimitive.ts(4,18): error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendingPrimitive.ts(5,18): error TS2693: 'boolean' only refers to a type, but is being used as a value here.
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendingPrimitive.ts(6,18): error TS2304: Cannot find name 'Void'.
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendingPrimitive.ts(7,19): error TS1109: Expression expected.
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendingPrimitive.ts(8,18): error TS2304: Cannot find name 'Null'.
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendingPrimitive.ts(10,18): error TS2507: Type 'undefined' is not a constructor function type.
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendingPrimitive.ts(11,18): error TS2304: Cannot find name 'Undefined'.
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendingPrimitive.ts(11,18): error TS2552: Cannot find name 'Undefined'. Did you mean 'undefined'?
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendingPrimitive.ts(14,18): error TS2507: Type 'typeof E' is not a constructor function type.
|
||||
|
||||
|
||||
@@ -14,13 +14,13 @@ tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/cla
|
||||
|
||||
class C extends number { }
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'number'.
|
||||
!!! error TS2693: 'number' only refers to a type, but is being used as a value here.
|
||||
class C2 extends string { }
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'string'.
|
||||
!!! error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
class C3 extends boolean { }
|
||||
~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'boolean'.
|
||||
!!! error TS2693: 'boolean' only refers to a type, but is being used as a value here.
|
||||
class C4 extends Void { }
|
||||
~~~~
|
||||
!!! error TS2304: Cannot find name 'Void'.
|
||||
@@ -36,7 +36,7 @@ tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/cla
|
||||
!!! error TS2507: Type 'undefined' is not a constructor function type.
|
||||
class C7 extends Undefined { }
|
||||
~~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'Undefined'.
|
||||
!!! error TS2552: Cannot find name 'Undefined'. Did you mean 'undefined'?
|
||||
|
||||
enum E { A }
|
||||
class C8 extends E { }
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendsEveryObjectType.ts(4,17): error TS2689: Cannot extend an interface 'I'. Did you mean 'implements'?
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendsEveryObjectType.ts(6,18): error TS2507: Type '{ foo: any; }' is not a constructor function type.
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendsEveryObjectType.ts(6,25): error TS2304: Cannot find name 'string'.
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendsEveryObjectType.ts(6,25): error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendsEveryObjectType.ts(6,31): error TS1005: ',' expected.
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendsEveryObjectType.ts(8,18): error TS2507: Type '{ foo: string; }' is not a constructor function type.
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendsEveryObjectType.ts(11,18): error TS2507: Type 'typeof M' is not a constructor function type.
|
||||
@@ -20,7 +20,7 @@ tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/cla
|
||||
~~~~~~~~~~~~~~~~
|
||||
!!! error TS2507: Type '{ foo: any; }' is not a constructor function type.
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'string'.
|
||||
!!! error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
~
|
||||
!!! error TS1005: ',' expected.
|
||||
var x: { foo: string; }
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendsEveryObjectType2.ts(1,18): error TS2507: Type '{ foo: any; }' is not a constructor function type.
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendsEveryObjectType2.ts(1,25): error TS2304: Cannot find name 'string'.
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendsEveryObjectType2.ts(1,25): error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendsEveryObjectType2.ts(1,31): error TS1005: ',' expected.
|
||||
tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/classExtendsEveryObjectType2.ts(3,18): error TS2507: Type 'undefined[]' is not a constructor function type.
|
||||
|
||||
@@ -9,7 +9,7 @@ tests/cases/conformance/classes/classDeclarations/classHeritageSpecification/cla
|
||||
~~~~~~~~~~~~~~~~
|
||||
!!! error TS2507: Type '{ foo: any; }' is not a constructor function type.
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'string'.
|
||||
!!! error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
~
|
||||
!!! error TS1005: ',' expected.
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@ tests/cases/compiler/classMemberWithMissingIdentifier2.ts(2,11): error TS1146: D
|
||||
tests/cases/compiler/classMemberWithMissingIdentifier2.ts(2,12): error TS1005: '=' expected.
|
||||
tests/cases/compiler/classMemberWithMissingIdentifier2.ts(2,14): error TS2304: Cannot find name 'name'.
|
||||
tests/cases/compiler/classMemberWithMissingIdentifier2.ts(2,18): error TS1005: ']' expected.
|
||||
tests/cases/compiler/classMemberWithMissingIdentifier2.ts(2,19): error TS2304: Cannot find name 'string'.
|
||||
tests/cases/compiler/classMemberWithMissingIdentifier2.ts(2,19): error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/classMemberWithMissingIdentifier2.ts(2,25): error TS1005: ',' expected.
|
||||
tests/cases/compiler/classMemberWithMissingIdentifier2.ts(2,26): error TS1136: Property assignment expected.
|
||||
tests/cases/compiler/classMemberWithMissingIdentifier2.ts(2,27): error TS2304: Cannot find name 'VariableDeclaration'.
|
||||
@@ -20,7 +20,7 @@ tests/cases/compiler/classMemberWithMissingIdentifier2.ts(2,27): error TS2304: C
|
||||
~
|
||||
!!! error TS1005: ']' expected.
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'string'.
|
||||
!!! error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
~
|
||||
!!! error TS1005: ',' expected.
|
||||
~
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
tests/cases/compiler/complicatedPrivacy.ts(11,24): error TS1054: A 'get' accessor cannot have parameters.
|
||||
tests/cases/compiler/complicatedPrivacy.ts(35,5): error TS1170: A computed property name in a type literal must directly refer to a built-in symbol.
|
||||
tests/cases/compiler/complicatedPrivacy.ts(35,6): error TS2304: Cannot find name 'number'.
|
||||
tests/cases/compiler/complicatedPrivacy.ts(35,6): error TS2693: 'number' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/complicatedPrivacy.ts(73,55): error TS2694: Namespace 'mglo5' has no exported member 'i6'.
|
||||
|
||||
|
||||
@@ -45,7 +45,7 @@ tests/cases/compiler/complicatedPrivacy.ts(73,55): error TS2694: Namespace 'mglo
|
||||
~~~~~~~~
|
||||
!!! error TS1170: A computed property name in a type literal must directly refer to a built-in symbol.
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'number'.
|
||||
!!! error TS2693: 'number' only refers to a type, but is being used as a value here.
|
||||
}) {
|
||||
}
|
||||
|
||||
|
||||
@@ -52,13 +52,13 @@ tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(235,9): error TS
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(235,16): error TS2304: Cannot find name 'method1'.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(235,24): error TS2304: Cannot find name 'val'.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(235,27): error TS1005: ',' expected.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(235,28): error TS2304: Cannot find name 'number'.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(235,28): error TS2693: 'number' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(235,36): error TS1005: ';' expected.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(238,9): error TS1128: Declaration or statement expected.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(238,16): error TS2304: Cannot find name 'method2'.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(238,26): error TS1005: ';' expected.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(241,5): error TS1128: Declaration or statement expected.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(246,25): error TS2339: Property 'method1' does not exist on type 'B'.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(246,25): error TS2551: Property 'method1' does not exist on type 'B'. Did you mean 'method2'?
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(254,9): error TS2390: Constructor implementation is missing.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(254,21): error TS2369: A parameter property is only allowed in a constructor implementation.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(254,44): error TS2369: A parameter property is only allowed in a constructor implementation.
|
||||
@@ -67,14 +67,14 @@ tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(256,9): error TS
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(256,16): error TS2304: Cannot find name 'Overloads'.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(256,26): error TS2304: Cannot find name 'value'.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(256,31): error TS1005: ',' expected.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(256,33): error TS2304: Cannot find name 'string'.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(256,33): error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(257,9): error TS1128: Declaration or statement expected.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(257,16): error TS2304: Cannot find name 'Overloads'.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(257,27): error TS1135: Argument expression expected.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(257,33): error TS1005: '(' expected.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(257,35): error TS2304: Cannot find name 'string'.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(257,35): error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(257,43): error TS1109: Expression expected.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(257,52): error TS2304: Cannot find name 'string'.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(257,52): error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(257,60): error TS1005: ';' expected.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(257,65): error TS1109: Expression expected.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(259,9): error TS2304: Cannot find name 'public'.
|
||||
@@ -82,7 +82,7 @@ tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(259,16): error T
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(259,16): error TS2304: Cannot find name 'DefaultValue'.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(259,29): error TS2304: Cannot find name 'value'.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(259,35): error TS1109: Expression expected.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(259,37): error TS2304: Cannot find name 'string'.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(259,37): error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(259,55): error TS1005: ';' expected.
|
||||
tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(261,1): error TS1128: Declaration or statement expected.
|
||||
|
||||
@@ -435,7 +435,7 @@ tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(261,1): error TS
|
||||
~
|
||||
!!! error TS1005: ',' expected.
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'number'.
|
||||
!!! error TS2693: 'number' only refers to a type, but is being used as a value here.
|
||||
~
|
||||
!!! error TS1005: ';' expected.
|
||||
return val;
|
||||
@@ -458,7 +458,7 @@ tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(261,1): error TS
|
||||
public method2() {
|
||||
return this.method1(2);
|
||||
~~~~~~~
|
||||
!!! error TS2339: Property 'method1' does not exist on type 'B'.
|
||||
!!! error TS2551: Property 'method1' does not exist on type 'B'. Did you mean 'method2'?
|
||||
}
|
||||
}
|
||||
|
||||
@@ -486,7 +486,7 @@ tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(261,1): error TS
|
||||
~
|
||||
!!! error TS1005: ',' expected.
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'string'.
|
||||
!!! error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
public Overloads( while : string, ...rest: string[]) { &
|
||||
~~~~~~
|
||||
!!! error TS1128: Declaration or statement expected.
|
||||
@@ -497,11 +497,11 @@ tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(261,1): error TS
|
||||
~
|
||||
!!! error TS1005: '(' expected.
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'string'.
|
||||
!!! error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
~~~
|
||||
!!! error TS1109: Expression expected.
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'string'.
|
||||
!!! error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
~
|
||||
!!! error TS1005: ';' expected.
|
||||
~
|
||||
@@ -519,7 +519,7 @@ tests/cases/compiler/constructorWithIncompleteTypeAnnotation.ts(261,1): error TS
|
||||
~
|
||||
!!! error TS1109: Expression expected.
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'string'.
|
||||
!!! error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
~
|
||||
!!! error TS1005: ';' expected.
|
||||
}
|
||||
|
||||
@@ -1,16 +1,16 @@
|
||||
tests/cases/compiler/createArray.ts(1,12): error TS2304: Cannot find name 'number'.
|
||||
tests/cases/compiler/createArray.ts(1,12): error TS2693: 'number' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/createArray.ts(1,18): error TS1150: 'new T[]' cannot be used to create an array. Use 'new Array<T>()' instead.
|
||||
tests/cases/compiler/createArray.ts(6,6): error TS1150: 'new T[]' cannot be used to create an array. Use 'new Array<T>()' instead.
|
||||
tests/cases/compiler/createArray.ts(7,12): error TS2304: Cannot find name 'boolean'.
|
||||
tests/cases/compiler/createArray.ts(7,12): error TS2693: 'boolean' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/createArray.ts(7,19): error TS1150: 'new T[]' cannot be used to create an array. Use 'new Array<T>()' instead.
|
||||
tests/cases/compiler/createArray.ts(8,12): error TS2304: Cannot find name 'string'.
|
||||
tests/cases/compiler/createArray.ts(8,12): error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/createArray.ts(8,18): error TS1150: 'new T[]' cannot be used to create an array. Use 'new Array<T>()' instead.
|
||||
|
||||
|
||||
==== tests/cases/compiler/createArray.ts (7 errors) ====
|
||||
var na=new number[];
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'number'.
|
||||
!!! error TS2693: 'number' only refers to a type, but is being used as a value here.
|
||||
~~
|
||||
!!! error TS1150: 'new T[]' cannot be used to create an array. Use 'new Array<T>()' instead.
|
||||
|
||||
@@ -22,12 +22,12 @@ tests/cases/compiler/createArray.ts(8,18): error TS1150: 'new T[]' cannot be use
|
||||
!!! error TS1150: 'new T[]' cannot be used to create an array. Use 'new Array<T>()' instead.
|
||||
var ba=new boolean[];
|
||||
~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'boolean'.
|
||||
!!! error TS2693: 'boolean' only refers to a type, but is being used as a value here.
|
||||
~~
|
||||
!!! error TS1150: 'new T[]' cannot be used to create an array. Use 'new Array<T>()' instead.
|
||||
var sa=new string[];
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'string'.
|
||||
!!! error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
~~
|
||||
!!! error TS1150: 'new T[]' cannot be used to create an array. Use 'new Array<T>()' instead.
|
||||
function f(s:string):number { return 0;
|
||||
|
||||
@@ -3,7 +3,7 @@ tests/cases/conformance/es6/destructuring/destructuringParameterDeclaration4.ts(
|
||||
tests/cases/conformance/es6/destructuring/destructuringParameterDeclaration4.ts(14,17): error TS1047: A rest parameter cannot be optional.
|
||||
tests/cases/conformance/es6/destructuring/destructuringParameterDeclaration4.ts(15,16): error TS1048: A rest parameter cannot have an initializer.
|
||||
tests/cases/conformance/es6/destructuring/destructuringParameterDeclaration4.ts(20,19): error TS2345: Argument of type 'true' is not assignable to parameter of type 'string | number'.
|
||||
tests/cases/conformance/es6/destructuring/destructuringParameterDeclaration4.ts(21,7): error TS2304: Cannot find name 'array2'.
|
||||
tests/cases/conformance/es6/destructuring/destructuringParameterDeclaration4.ts(21,7): error TS2552: Cannot find name 'array2'. Did you mean 'Array'?
|
||||
tests/cases/conformance/es6/destructuring/destructuringParameterDeclaration4.ts(22,4): error TS2345: Argument of type '[number, number, string, boolean, boolean]' is not assignable to parameter of type '[any, any, [[any]]]'.
|
||||
Types of property '2' are incompatible.
|
||||
Type 'string' is not assignable to type '[[any]]'.
|
||||
@@ -50,7 +50,7 @@ tests/cases/conformance/es6/destructuring/destructuringParameterDeclaration4.ts(
|
||||
!!! error TS2345: Argument of type 'true' is not assignable to parameter of type 'string | number'.
|
||||
a1(...array2); // Error parameter type is (number|string)[]
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'array2'.
|
||||
!!! error TS2552: Cannot find name 'array2'. Did you mean 'Array'?
|
||||
a5([1, 2, "string", false, true]); // Error, parameter type is [any, any, [[any]]]
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
!!! error TS2345: Argument of type '[number, number, string, boolean, boolean]' is not assignable to parameter of type '[any, any, [[any]]]'.
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
tests/cases/compiler/dottedModuleName.ts(3,29): error TS1144: '{' or ';' expected.
|
||||
tests/cases/compiler/dottedModuleName.ts(3,33): error TS2304: Cannot find name 'x'.
|
||||
tests/cases/compiler/dottedModuleName.ts(3,33): error TS2552: Cannot find name 'x'. Did you mean 'X'?
|
||||
|
||||
|
||||
==== tests/cases/compiler/dottedModuleName.ts (2 errors) ====
|
||||
@@ -9,7 +9,7 @@ tests/cases/compiler/dottedModuleName.ts(3,33): error TS2304: Cannot find name '
|
||||
~~
|
||||
!!! error TS1144: '{' or ';' expected.
|
||||
~
|
||||
!!! error TS2304: Cannot find name 'x'.
|
||||
!!! error TS2552: Cannot find name 'x'. Did you mean 'X'?
|
||||
export module X.Y.Z {
|
||||
export var v2=f(v);
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
tests/cases/compiler/errorLocationForInterfaceExtension.ts(3,21): error TS2304: Cannot find name 'string'.
|
||||
tests/cases/compiler/errorLocationForInterfaceExtension.ts(3,21): error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
|
||||
|
||||
==== tests/cases/compiler/errorLocationForInterfaceExtension.ts (1 errors) ====
|
||||
@@ -6,5 +6,5 @@ tests/cases/compiler/errorLocationForInterfaceExtension.ts(3,21): error TS2304:
|
||||
|
||||
interface x extends string { }
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'string'.
|
||||
!!! error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
tests/cases/compiler/errorMessageOnObjectLiteralType.ts(5,3): error TS2339: Property 'getOwnPropertyNamess' does not exist on type '{ a: string; b: number; }'.
|
||||
tests/cases/compiler/errorMessageOnObjectLiteralType.ts(6,8): error TS2339: Property 'getOwnPropertyNamess' does not exist on type 'ObjectConstructor'.
|
||||
tests/cases/compiler/errorMessageOnObjectLiteralType.ts(6,8): error TS2551: Property 'getOwnPropertyNamess' does not exist on type 'ObjectConstructor'. Did you mean 'getOwnPropertyNames'?
|
||||
|
||||
|
||||
==== tests/cases/compiler/errorMessageOnObjectLiteralType.ts (2 errors) ====
|
||||
@@ -12,4 +12,4 @@ tests/cases/compiler/errorMessageOnObjectLiteralType.ts(6,8): error TS2339: Prop
|
||||
!!! error TS2339: Property 'getOwnPropertyNamess' does not exist on type '{ a: string; b: number; }'.
|
||||
Object.getOwnPropertyNamess(null);
|
||||
~~~~~~~~~~~~~~~~~~~~
|
||||
!!! error TS2339: Property 'getOwnPropertyNamess' does not exist on type 'ObjectConstructor'.
|
||||
!!! error TS2551: Property 'getOwnPropertyNamess' does not exist on type 'ObjectConstructor'. Did you mean 'getOwnPropertyNames'?
|
||||
@@ -8,10 +8,10 @@ tests/cases/compiler/externModule.ts(18,6): error TS2390: Constructor implementa
|
||||
tests/cases/compiler/externModule.ts(20,13): error TS2391: Function implementation is missing or not immediately following the declaration.
|
||||
tests/cases/compiler/externModule.ts(26,13): error TS2391: Function implementation is missing or not immediately following the declaration.
|
||||
tests/cases/compiler/externModule.ts(28,13): error TS2391: Function implementation is missing or not immediately following the declaration.
|
||||
tests/cases/compiler/externModule.ts(32,11): error TS2304: Cannot find name 'XDate'.
|
||||
tests/cases/compiler/externModule.ts(34,7): error TS2304: Cannot find name 'XDate'.
|
||||
tests/cases/compiler/externModule.ts(36,7): error TS2304: Cannot find name 'XDate'.
|
||||
tests/cases/compiler/externModule.ts(37,3): error TS2304: Cannot find name 'XDate'.
|
||||
tests/cases/compiler/externModule.ts(32,11): error TS2552: Cannot find name 'XDate'. Did you mean 'Date'?
|
||||
tests/cases/compiler/externModule.ts(34,7): error TS2552: Cannot find name 'XDate'. Did you mean 'Date'?
|
||||
tests/cases/compiler/externModule.ts(36,7): error TS2552: Cannot find name 'XDate'. Did you mean 'Date'?
|
||||
tests/cases/compiler/externModule.ts(37,3): error TS2552: Cannot find name 'XDate'. Did you mean 'Date'?
|
||||
|
||||
|
||||
==== tests/cases/compiler/externModule.ts (14 errors) ====
|
||||
@@ -68,17 +68,17 @@ tests/cases/compiler/externModule.ts(37,3): error TS2304: Cannot find name 'XDat
|
||||
|
||||
var d=new XDate();
|
||||
~~~~~
|
||||
!!! error TS2304: Cannot find name 'XDate'.
|
||||
!!! error TS2552: Cannot find name 'XDate'. Did you mean 'Date'?
|
||||
d.getDay();
|
||||
d=new XDate(1978,2);
|
||||
~~~~~
|
||||
!!! error TS2304: Cannot find name 'XDate'.
|
||||
!!! error TS2552: Cannot find name 'XDate'. Did you mean 'Date'?
|
||||
d.getXDate();
|
||||
var n=XDate.parse("3/2/2004");
|
||||
~~~~~
|
||||
!!! error TS2304: Cannot find name 'XDate'.
|
||||
!!! error TS2552: Cannot find name 'XDate'. Did you mean 'Date'?
|
||||
n=XDate.UTC(1964,2,1);
|
||||
~~~~~
|
||||
!!! error TS2304: Cannot find name 'XDate'.
|
||||
!!! error TS2552: Cannot find name 'XDate'. Did you mean 'Date'?
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
tests/cases/compiler/letDeclarations-scopes2.ts(8,5): error TS2304: Cannot find name 'local2'.
|
||||
tests/cases/compiler/letDeclarations-scopes2.ts(20,5): error TS2304: Cannot find name 'local2'.
|
||||
tests/cases/compiler/letDeclarations-scopes2.ts(8,5): error TS2552: Cannot find name 'local2'. Did you mean 'local'?
|
||||
tests/cases/compiler/letDeclarations-scopes2.ts(20,5): error TS2552: Cannot find name 'local2'. Did you mean 'local'?
|
||||
tests/cases/compiler/letDeclarations-scopes2.ts(23,1): error TS2304: Cannot find name 'local'.
|
||||
tests/cases/compiler/letDeclarations-scopes2.ts(25,1): error TS2304: Cannot find name 'local2'.
|
||||
|
||||
@@ -14,7 +14,7 @@ tests/cases/compiler/letDeclarations-scopes2.ts(25,1): error TS2304: Cannot find
|
||||
global; // OK
|
||||
local2; // Error
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'local2'.
|
||||
!!! error TS2552: Cannot find name 'local2'. Did you mean 'local'?
|
||||
|
||||
{
|
||||
let local2 = 0;
|
||||
@@ -28,7 +28,7 @@ tests/cases/compiler/letDeclarations-scopes2.ts(25,1): error TS2304: Cannot find
|
||||
global; // OK
|
||||
local2; // Error
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'local2'.
|
||||
!!! error TS2552: Cannot find name 'local2'. Did you mean 'local'?
|
||||
}
|
||||
|
||||
local; // Error
|
||||
|
||||
@@ -0,0 +1,45 @@
|
||||
tests/cases/compiler/maximum10SpellingSuggestions.ts(4,1): error TS2552: Cannot find name 'bob'. Did you mean 'blob'?
|
||||
tests/cases/compiler/maximum10SpellingSuggestions.ts(4,6): error TS2552: Cannot find name 'bob'. Did you mean 'blob'?
|
||||
tests/cases/compiler/maximum10SpellingSuggestions.ts(4,11): error TS2552: Cannot find name 'bob'. Did you mean 'blob'?
|
||||
tests/cases/compiler/maximum10SpellingSuggestions.ts(4,16): error TS2552: Cannot find name 'bob'. Did you mean 'blob'?
|
||||
tests/cases/compiler/maximum10SpellingSuggestions.ts(4,21): error TS2552: Cannot find name 'bob'. Did you mean 'blob'?
|
||||
tests/cases/compiler/maximum10SpellingSuggestions.ts(4,26): error TS2552: Cannot find name 'bob'. Did you mean 'blob'?
|
||||
tests/cases/compiler/maximum10SpellingSuggestions.ts(4,31): error TS2552: Cannot find name 'bob'. Did you mean 'blob'?
|
||||
tests/cases/compiler/maximum10SpellingSuggestions.ts(4,36): error TS2552: Cannot find name 'bob'. Did you mean 'blob'?
|
||||
tests/cases/compiler/maximum10SpellingSuggestions.ts(4,41): error TS2552: Cannot find name 'bob'. Did you mean 'blob'?
|
||||
tests/cases/compiler/maximum10SpellingSuggestions.ts(4,46): error TS2552: Cannot find name 'bob'. Did you mean 'blob'?
|
||||
tests/cases/compiler/maximum10SpellingSuggestions.ts(5,1): error TS2304: Cannot find name 'bob'.
|
||||
tests/cases/compiler/maximum10SpellingSuggestions.ts(5,6): error TS2304: Cannot find name 'bob'.
|
||||
|
||||
|
||||
==== tests/cases/compiler/maximum10SpellingSuggestions.ts (12 errors) ====
|
||||
// 10 bobs on the first line
|
||||
// the last two bobs should not have did-you-mean spelling suggestions
|
||||
var blob;
|
||||
bob; bob; bob; bob; bob; bob; bob; bob; bob; bob;
|
||||
~~~
|
||||
!!! error TS2552: Cannot find name 'bob'. Did you mean 'blob'?
|
||||
~~~
|
||||
!!! error TS2552: Cannot find name 'bob'. Did you mean 'blob'?
|
||||
~~~
|
||||
!!! error TS2552: Cannot find name 'bob'. Did you mean 'blob'?
|
||||
~~~
|
||||
!!! error TS2552: Cannot find name 'bob'. Did you mean 'blob'?
|
||||
~~~
|
||||
!!! error TS2552: Cannot find name 'bob'. Did you mean 'blob'?
|
||||
~~~
|
||||
!!! error TS2552: Cannot find name 'bob'. Did you mean 'blob'?
|
||||
~~~
|
||||
!!! error TS2552: Cannot find name 'bob'. Did you mean 'blob'?
|
||||
~~~
|
||||
!!! error TS2552: Cannot find name 'bob'. Did you mean 'blob'?
|
||||
~~~
|
||||
!!! error TS2552: Cannot find name 'bob'. Did you mean 'blob'?
|
||||
~~~
|
||||
!!! error TS2552: Cannot find name 'bob'. Did you mean 'blob'?
|
||||
bob; bob;
|
||||
~~~
|
||||
!!! error TS2304: Cannot find name 'bob'.
|
||||
~~~
|
||||
!!! error TS2304: Cannot find name 'bob'.
|
||||
|
||||
@@ -0,0 +1,24 @@
|
||||
//// [maximum10SpellingSuggestions.ts]
|
||||
// 10 bobs on the first line
|
||||
// the last two bobs should not have did-you-mean spelling suggestions
|
||||
var blob;
|
||||
bob; bob; bob; bob; bob; bob; bob; bob; bob; bob;
|
||||
bob; bob;
|
||||
|
||||
|
||||
//// [maximum10SpellingSuggestions.js]
|
||||
// 10 bobs on the first line
|
||||
// the last two bobs should not have did-you-mean spelling suggestions
|
||||
var blob;
|
||||
bob;
|
||||
bob;
|
||||
bob;
|
||||
bob;
|
||||
bob;
|
||||
bob;
|
||||
bob;
|
||||
bob;
|
||||
bob;
|
||||
bob;
|
||||
bob;
|
||||
bob;
|
||||
+2
-2
@@ -1,7 +1,7 @@
|
||||
tests/cases/compiler/modularizeLibrary_ErrorFromUsingES6FeaturesWithOnlyES5Lib.ts(4,18): error TS2339: Property 'from' does not exist on type 'ArrayConstructor'.
|
||||
tests/cases/compiler/modularizeLibrary_ErrorFromUsingES6FeaturesWithOnlyES5Lib.ts(10,13): error TS2304: Cannot find name 'Map'.
|
||||
tests/cases/compiler/modularizeLibrary_ErrorFromUsingES6FeaturesWithOnlyES5Lib.ts(17,5): error TS2339: Property 'name' does not exist on type '() => void'.
|
||||
tests/cases/compiler/modularizeLibrary_ErrorFromUsingES6FeaturesWithOnlyES5Lib.ts(20,6): error TS2339: Property 'sign' does not exist on type 'Math'.
|
||||
tests/cases/compiler/modularizeLibrary_ErrorFromUsingES6FeaturesWithOnlyES5Lib.ts(20,6): error TS2551: Property 'sign' does not exist on type 'Math'. Did you mean 'sin'?
|
||||
tests/cases/compiler/modularizeLibrary_ErrorFromUsingES6FeaturesWithOnlyES5Lib.ts(25,6): error TS2304: Cannot find name 'Symbol'.
|
||||
tests/cases/compiler/modularizeLibrary_ErrorFromUsingES6FeaturesWithOnlyES5Lib.ts(29,18): error TS2304: Cannot find name 'Symbol'.
|
||||
tests/cases/compiler/modularizeLibrary_ErrorFromUsingES6FeaturesWithOnlyES5Lib.ts(33,13): error TS2304: Cannot find name 'Proxy'.
|
||||
@@ -40,7 +40,7 @@ tests/cases/compiler/modularizeLibrary_ErrorFromUsingES6FeaturesWithOnlyES5Lib.t
|
||||
// Using ES6 math
|
||||
Math.sign(1);
|
||||
~~~~
|
||||
!!! error TS2339: Property 'sign' does not exist on type 'Math'.
|
||||
!!! error TS2551: Property 'sign' does not exist on type 'Math'. Did you mean 'sin'?
|
||||
|
||||
// Using ES6 object
|
||||
var o = {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
tests/cases/conformance/types/any/narrowExceptionVariableInCatchClause.ts(11,17): error TS2339: Property 'doPanic' does not exist on type '{ type: "foo"; dontPanic(): any; }'.
|
||||
tests/cases/conformance/types/any/narrowExceptionVariableInCatchClause.ts(16,17): error TS2339: Property 'massage' does not exist on type 'Error'.
|
||||
tests/cases/conformance/types/any/narrowExceptionVariableInCatchClause.ts(11,17): error TS2551: Property 'doPanic' does not exist on type '{ type: "foo"; dontPanic(): any; }'. Did you mean 'dontPanic'?
|
||||
tests/cases/conformance/types/any/narrowExceptionVariableInCatchClause.ts(16,17): error TS2551: Property 'massage' does not exist on type 'Error'. Did you mean 'message'?
|
||||
|
||||
|
||||
==== tests/cases/conformance/types/any/narrowExceptionVariableInCatchClause.ts (2 errors) ====
|
||||
@@ -15,14 +15,14 @@ tests/cases/conformance/types/any/narrowExceptionVariableInCatchClause.ts(16,17)
|
||||
err.dontPanic(); // OK
|
||||
err.doPanic(); // ERROR: Property 'doPanic' does not exist on type '{...}'
|
||||
~~~~~~~
|
||||
!!! error TS2339: Property 'doPanic' does not exist on type '{ type: "foo"; dontPanic(): any; }'.
|
||||
!!! error TS2551: Property 'doPanic' does not exist on type '{ type: "foo"; dontPanic(): any; }'. Did you mean 'dontPanic'?
|
||||
}
|
||||
|
||||
else if (err instanceof Error) {
|
||||
err.message;
|
||||
err.massage; // ERROR: Property 'massage' does not exist on type 'Error'
|
||||
~~~~~~~
|
||||
!!! error TS2339: Property 'massage' does not exist on type 'Error'.
|
||||
!!! error TS2551: Property 'massage' does not exist on type 'Error'. Did you mean 'message'?
|
||||
}
|
||||
|
||||
else {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
tests/cases/conformance/types/any/narrowFromAnyWithInstanceof.ts(17,7): error TS2339: Property 'mesage' does not exist on type 'Error'.
|
||||
tests/cases/conformance/types/any/narrowFromAnyWithInstanceof.ts(22,7): error TS2339: Property 'getHuors' does not exist on type 'Date'.
|
||||
tests/cases/conformance/types/any/narrowFromAnyWithInstanceof.ts(17,7): error TS2551: Property 'mesage' does not exist on type 'Error'. Did you mean 'message'?
|
||||
tests/cases/conformance/types/any/narrowFromAnyWithInstanceof.ts(22,7): error TS2551: Property 'getHuors' does not exist on type 'Date'. Did you mean 'getHours'?
|
||||
|
||||
|
||||
==== tests/cases/conformance/types/any/narrowFromAnyWithInstanceof.ts (2 errors) ====
|
||||
@@ -21,13 +21,13 @@ tests/cases/conformance/types/any/narrowFromAnyWithInstanceof.ts(22,7): error TS
|
||||
x.message;
|
||||
x.mesage;
|
||||
~~~~~~
|
||||
!!! error TS2339: Property 'mesage' does not exist on type 'Error'.
|
||||
!!! error TS2551: Property 'mesage' does not exist on type 'Error'. Did you mean 'message'?
|
||||
}
|
||||
|
||||
if (x instanceof Date) {
|
||||
x.getDate();
|
||||
x.getHuors();
|
||||
~~~~~~~~
|
||||
!!! error TS2339: Property 'getHuors' does not exist on type 'Date'.
|
||||
!!! error TS2551: Property 'getHuors' does not exist on type 'Date'. Did you mean 'getHours'?
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
tests/cases/conformance/types/any/narrowFromAnyWithTypePredicate.ts(22,7): error TS2339: Property 'method' does not exist on type '{}'.
|
||||
tests/cases/conformance/types/any/narrowFromAnyWithTypePredicate.ts(23,5): error TS2349: Cannot invoke an expression whose type lacks a call signature. Type '{}' has no compatible call signatures.
|
||||
tests/cases/conformance/types/any/narrowFromAnyWithTypePredicate.ts(28,7): error TS2339: Property 'mesage' does not exist on type 'Error'.
|
||||
tests/cases/conformance/types/any/narrowFromAnyWithTypePredicate.ts(33,7): error TS2339: Property 'getHuors' does not exist on type 'Date'.
|
||||
tests/cases/conformance/types/any/narrowFromAnyWithTypePredicate.ts(28,7): error TS2551: Property 'mesage' does not exist on type 'Error'. Did you mean 'message'?
|
||||
tests/cases/conformance/types/any/narrowFromAnyWithTypePredicate.ts(33,7): error TS2551: Property 'getHuors' does not exist on type 'Date'. Did you mean 'getHours'?
|
||||
|
||||
|
||||
==== tests/cases/conformance/types/any/narrowFromAnyWithTypePredicate.ts (4 errors) ====
|
||||
@@ -38,13 +38,13 @@ tests/cases/conformance/types/any/narrowFromAnyWithTypePredicate.ts(33,7): error
|
||||
x.message;
|
||||
x.mesage;
|
||||
~~~~~~
|
||||
!!! error TS2339: Property 'mesage' does not exist on type 'Error'.
|
||||
!!! error TS2551: Property 'mesage' does not exist on type 'Error'. Did you mean 'message'?
|
||||
}
|
||||
|
||||
if (isDate(x)) {
|
||||
x.getDate();
|
||||
x.getHuors();
|
||||
~~~~~~~~
|
||||
!!! error TS2339: Property 'getHuors' does not exist on type 'Date'.
|
||||
!!! error TS2551: Property 'getHuors' does not exist on type 'Date'. Did you mean 'getHours'?
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
tests/cases/compiler/newExpressionWithCast.ts(3,12): error TS7009: 'new' expression, whose target lacks a construct signature, implicitly has an 'any' type.
|
||||
tests/cases/compiler/newExpressionWithCast.ts(7,13): error TS2365: Operator '>' cannot be applied to types 'boolean' and 'void'.
|
||||
tests/cases/compiler/newExpressionWithCast.ts(7,17): error TS1109: Expression expected.
|
||||
tests/cases/compiler/newExpressionWithCast.ts(7,18): error TS2304: Cannot find name 'any'.
|
||||
tests/cases/compiler/newExpressionWithCast.ts(7,18): error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
|
||||
|
||||
==== tests/cases/compiler/newExpressionWithCast.ts (4 errors) ====
|
||||
@@ -19,7 +19,7 @@ tests/cases/compiler/newExpressionWithCast.ts(7,18): error TS2304: Cannot find n
|
||||
~
|
||||
!!! error TS1109: Expression expected.
|
||||
~~~
|
||||
!!! error TS2304: Cannot find name 'any'.
|
||||
!!! error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
|
||||
function Test3() { }
|
||||
// valid with noImplicitAny
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
tests/cases/compiler/newNonReferenceType.ts(1,13): error TS2304: Cannot find name 'any'.
|
||||
tests/cases/compiler/newNonReferenceType.ts(2,13): error TS2304: Cannot find name 'boolean'.
|
||||
tests/cases/compiler/newNonReferenceType.ts(1,13): error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/newNonReferenceType.ts(2,13): error TS2693: 'boolean' only refers to a type, but is being used as a value here.
|
||||
|
||||
|
||||
==== tests/cases/compiler/newNonReferenceType.ts (2 errors) ====
|
||||
var a = new any();
|
||||
~~~
|
||||
!!! error TS2304: Cannot find name 'any'.
|
||||
!!! error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
var b = new boolean(); // error
|
||||
~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'boolean'.
|
||||
!!! error TS2693: 'boolean' only refers to a type, but is being used as a value here.
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
tests/cases/compiler/newOperator.ts(3,13): error TS2693: 'ifc' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/newOperator.ts(10,10): error TS2351: Cannot use 'new' with an expression whose type lacks a call or construct signature.
|
||||
tests/cases/compiler/newOperator.ts(11,10): error TS2351: Cannot use 'new' with an expression whose type lacks a call or construct signature.
|
||||
tests/cases/compiler/newOperator.ts(12,5): error TS2304: Cannot find name 'string'.
|
||||
tests/cases/compiler/newOperator.ts(18,14): error TS2304: Cannot find name 'string'.
|
||||
tests/cases/compiler/newOperator.ts(12,5): error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/newOperator.ts(18,14): error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/newOperator.ts(18,20): error TS1150: 'new T[]' cannot be used to create an array. Use 'new Array<T>()' instead.
|
||||
tests/cases/compiler/newOperator.ts(21,1): error TS2304: Cannot find name 'string'.
|
||||
tests/cases/compiler/newOperator.ts(21,1): error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/newOperator.ts(22,1): error TS1150: 'new T[]' cannot be used to create an array. Use 'new Array<T>()' instead.
|
||||
tests/cases/compiler/newOperator.ts(28,13): error TS2304: Cannot find name 'q'.
|
||||
tests/cases/compiler/newOperator.ts(31,10): error TS2351: Cannot use 'new' with an expression whose type lacks a call or construct signature.
|
||||
@@ -32,7 +32,7 @@ tests/cases/compiler/newOperator.ts(45,23): error TS1150: 'new T[]' cannot be us
|
||||
!!! error TS2351: Cannot use 'new' with an expression whose type lacks a call or construct signature.
|
||||
new string;
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'string'.
|
||||
!!! error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
|
||||
// Use in LHS of expression?
|
||||
(new Date()).toString();
|
||||
@@ -40,14 +40,14 @@ tests/cases/compiler/newOperator.ts(45,23): error TS1150: 'new T[]' cannot be us
|
||||
// Various spacing
|
||||
var t3 = new string[]( );
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'string'.
|
||||
!!! error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
~~
|
||||
!!! error TS1150: 'new T[]' cannot be used to create an array. Use 'new Array<T>()' instead.
|
||||
var t4 =
|
||||
new
|
||||
string
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'string'.
|
||||
!!! error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
[
|
||||
~
|
||||
]
|
||||
|
||||
@@ -5,12 +5,12 @@ tests/cases/compiler/overloadingStaticFunctionsInFunctions.ts(3,3): error TS1128
|
||||
tests/cases/compiler/overloadingStaticFunctionsInFunctions.ts(3,10): error TS2304: Cannot find name 'test'.
|
||||
tests/cases/compiler/overloadingStaticFunctionsInFunctions.ts(3,15): error TS2304: Cannot find name 'name'.
|
||||
tests/cases/compiler/overloadingStaticFunctionsInFunctions.ts(3,19): error TS1005: ',' expected.
|
||||
tests/cases/compiler/overloadingStaticFunctionsInFunctions.ts(3,20): error TS2304: Cannot find name 'string'.
|
||||
tests/cases/compiler/overloadingStaticFunctionsInFunctions.ts(3,20): error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/overloadingStaticFunctionsInFunctions.ts(4,3): error TS1128: Declaration or statement expected.
|
||||
tests/cases/compiler/overloadingStaticFunctionsInFunctions.ts(4,10): error TS2304: Cannot find name 'test'.
|
||||
tests/cases/compiler/overloadingStaticFunctionsInFunctions.ts(4,15): error TS2304: Cannot find name 'name'.
|
||||
tests/cases/compiler/overloadingStaticFunctionsInFunctions.ts(4,20): error TS1109: Expression expected.
|
||||
tests/cases/compiler/overloadingStaticFunctionsInFunctions.ts(4,21): error TS2304: Cannot find name 'any'.
|
||||
tests/cases/compiler/overloadingStaticFunctionsInFunctions.ts(4,21): error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/overloadingStaticFunctionsInFunctions.ts(4,25): error TS1005: ';' expected.
|
||||
|
||||
|
||||
@@ -33,7 +33,7 @@ tests/cases/compiler/overloadingStaticFunctionsInFunctions.ts(4,25): error TS100
|
||||
~
|
||||
!!! error TS1005: ',' expected.
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'string'.
|
||||
!!! error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
static test(name?:any){ }
|
||||
~~~~~~
|
||||
!!! error TS1128: Declaration or statement expected.
|
||||
@@ -44,7 +44,7 @@ tests/cases/compiler/overloadingStaticFunctionsInFunctions.ts(4,25): error TS100
|
||||
~
|
||||
!!! error TS1109: Expression expected.
|
||||
~~~
|
||||
!!! error TS2304: Cannot find name 'any'.
|
||||
!!! error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
~
|
||||
!!! error TS1005: ';' expected.
|
||||
}
|
||||
@@ -1,44 +1,44 @@
|
||||
tests/cases/compiler/parameterNamesInTypeParameterList.ts(1,30): error TS2304: Cannot find name 'a'.
|
||||
tests/cases/compiler/parameterNamesInTypeParameterList.ts(5,30): error TS2304: Cannot find name 'a'.
|
||||
tests/cases/compiler/parameterNamesInTypeParameterList.ts(9,30): error TS2304: Cannot find name 'a'.
|
||||
tests/cases/compiler/parameterNamesInTypeParameterList.ts(14,22): error TS2304: Cannot find name 'a'.
|
||||
tests/cases/compiler/parameterNamesInTypeParameterList.ts(17,22): error TS2304: Cannot find name 'a'.
|
||||
tests/cases/compiler/parameterNamesInTypeParameterList.ts(20,22): error TS2304: Cannot find name 'a'.
|
||||
tests/cases/compiler/parameterNamesInTypeParameterList.ts(1,30): error TS2552: Cannot find name 'a'. Did you mean 'A'?
|
||||
tests/cases/compiler/parameterNamesInTypeParameterList.ts(5,30): error TS2552: Cannot find name 'a'. Did you mean 'A'?
|
||||
tests/cases/compiler/parameterNamesInTypeParameterList.ts(9,30): error TS2552: Cannot find name 'a'. Did you mean 'A'?
|
||||
tests/cases/compiler/parameterNamesInTypeParameterList.ts(14,22): error TS2552: Cannot find name 'a'. Did you mean 'A'?
|
||||
tests/cases/compiler/parameterNamesInTypeParameterList.ts(17,22): error TS2552: Cannot find name 'a'. Did you mean 'A'?
|
||||
tests/cases/compiler/parameterNamesInTypeParameterList.ts(20,22): error TS2552: Cannot find name 'a'. Did you mean 'A'?
|
||||
|
||||
|
||||
==== tests/cases/compiler/parameterNamesInTypeParameterList.ts (6 errors) ====
|
||||
function f0<T extends typeof a>(a: T) {
|
||||
~
|
||||
!!! error TS2304: Cannot find name 'a'.
|
||||
!!! error TS2552: Cannot find name 'a'. Did you mean 'A'?
|
||||
a.b;
|
||||
}
|
||||
|
||||
function f1<T extends typeof a>({a}: {a:T}) {
|
||||
~
|
||||
!!! error TS2304: Cannot find name 'a'.
|
||||
!!! error TS2552: Cannot find name 'a'. Did you mean 'A'?
|
||||
a.b;
|
||||
}
|
||||
|
||||
function f2<T extends typeof a>([a]: T[]) {
|
||||
~
|
||||
!!! error TS2304: Cannot find name 'a'.
|
||||
!!! error TS2552: Cannot find name 'a'. Did you mean 'A'?
|
||||
a.b;
|
||||
}
|
||||
|
||||
class A {
|
||||
m0<T extends typeof a>(a: T) {
|
||||
~
|
||||
!!! error TS2304: Cannot find name 'a'.
|
||||
!!! error TS2552: Cannot find name 'a'. Did you mean 'A'?
|
||||
a.b
|
||||
}
|
||||
m1<T extends typeof a>({a}: {a:T}) {
|
||||
~
|
||||
!!! error TS2304: Cannot find name 'a'.
|
||||
!!! error TS2552: Cannot find name 'a'. Did you mean 'A'?
|
||||
a.b
|
||||
}
|
||||
m2<T extends typeof a>([a]: T[]) {
|
||||
~
|
||||
!!! error TS2304: Cannot find name 'a'.
|
||||
!!! error TS2552: Cannot find name 'a'. Did you mean 'A'?
|
||||
a.b
|
||||
}
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
tests/cases/conformance/parser/ecmascript5/Expressions/parserMemberAccessAfterPostfixExpression1.ts(1,1): error TS2304: Cannot find name 'a'.
|
||||
tests/cases/conformance/parser/ecmascript5/Expressions/parserMemberAccessAfterPostfixExpression1.ts(1,4): error TS1005: ';' expected.
|
||||
tests/cases/conformance/parser/ecmascript5/Expressions/parserMemberAccessAfterPostfixExpression1.ts(1,5): error TS2304: Cannot find name 'toString'.
|
||||
tests/cases/conformance/parser/ecmascript5/Expressions/parserMemberAccessAfterPostfixExpression1.ts(1,5): error TS2552: Cannot find name 'toString'. Did you mean 'String'?
|
||||
|
||||
|
||||
==== tests/cases/conformance/parser/ecmascript5/Expressions/parserMemberAccessAfterPostfixExpression1.ts (3 errors) ====
|
||||
@@ -10,4 +10,4 @@ tests/cases/conformance/parser/ecmascript5/Expressions/parserMemberAccessAfterPo
|
||||
~
|
||||
!!! error TS1005: ';' expected.
|
||||
~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'toString'.
|
||||
!!! error TS2552: Cannot find name 'toString'. Did you mean 'String'?
|
||||
@@ -1,11 +1,11 @@
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource10.ts(4,1): error TS6053: File 'tests/cases/conformance/parser/ecmascript5/typescript.ts' not found.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource10.ts(127,33): error TS2449: Class 'TokenInfo' used before its declaration.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource10.ts(127,42): error TS1150: 'new T[]' cannot be used to create an array. Use 'new Array<T>()' instead.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource10.ts(128,36): error TS2304: Cannot find name 'string'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource10.ts(128,36): error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource10.ts(128,42): error TS1150: 'new T[]' cannot be used to create an array. Use 'new Array<T>()' instead.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource10.ts(129,41): error TS2304: Cannot find name 'number'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource10.ts(129,41): error TS2693: 'number' only refers to a type, but is being used as a value here.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource10.ts(129,47): error TS1150: 'new T[]' cannot be used to create an array. Use 'new Array<T>()' instead.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource10.ts(130,35): error TS2304: Cannot find name 'boolean'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource10.ts(130,35): error TS2693: 'boolean' only refers to a type, but is being used as a value here.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource10.ts(130,42): error TS1150: 'new T[]' cannot be used to create an array. Use 'new Array<T>()' instead.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource10.ts(179,54): error TS2304: Cannot find name 'ErrorRecoverySet'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource10.ts(184,28): error TS2304: Cannot find name 'ErrorRecoverySet'.
|
||||
@@ -479,17 +479,17 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource10.ts(449,40): error
|
||||
!!! error TS1150: 'new T[]' cannot be used to create an array. Use 'new Array<T>()' instead.
|
||||
export var nodeTypeTable = new string[];
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'string'.
|
||||
!!! error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
~~
|
||||
!!! error TS1150: 'new T[]' cannot be used to create an array. Use 'new Array<T>()' instead.
|
||||
export var nodeTypeToTokTable = new number[];
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'number'.
|
||||
!!! error TS2693: 'number' only refers to a type, but is being used as a value here.
|
||||
~~
|
||||
!!! error TS1150: 'new T[]' cannot be used to create an array. Use 'new Array<T>()' instead.
|
||||
export var noRegexTable = new boolean[];
|
||||
~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'boolean'.
|
||||
!!! error TS2693: 'boolean' only refers to a type, but is being used as a value here.
|
||||
~~
|
||||
!!! error TS1150: 'new T[]' cannot be used to create an array. Use 'new Array<T>()' instead.
|
||||
|
||||
|
||||
@@ -46,7 +46,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(199,42): error
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(219,33): error TS2304: Cannot find name 'NodeType'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(231,30): error TS2304: Cannot find name 'Emitter'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(231,48): error TS2304: Cannot find name 'TokenID'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(233,52): error TS2304: Cannot find name 'TokenID'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(233,52): error TS2552: Cannot find name 'TokenID'. Did you mean 'tokenId'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(237,36): error TS2304: Cannot find name 'TypeFlow'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(251,21): error TS2304: Cannot find name 'Symbol'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(268,19): error TS2304: Cannot find name 'NodeType'.
|
||||
@@ -85,27 +85,27 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(427,22): error
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(441,30): error TS2304: Cannot find name 'Emitter'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(441,48): error TS2304: Cannot find name 'TokenID'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(445,22): error TS2304: Cannot find name 'NodeType'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(446,58): error TS2304: Cannot find name 'TokenID'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(446,58): error TS2552: Cannot find name 'TokenID'. Did you mean 'tokenId'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(449,22): error TS2304: Cannot find name 'NodeType'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(451,58): error TS2304: Cannot find name 'TokenID'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(451,58): error TS2552: Cannot find name 'TokenID'. Did you mean 'tokenId'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(453,22): error TS2304: Cannot find name 'NodeType'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(454,58): error TS2304: Cannot find name 'TokenID'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(454,58): error TS2552: Cannot find name 'TokenID'. Did you mean 'tokenId'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(457,22): error TS2304: Cannot find name 'NodeType'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(460,22): error TS2304: Cannot find name 'NodeType'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(463,22): error TS2304: Cannot find name 'NodeType'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(465,58): error TS2304: Cannot find name 'TokenID'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(465,58): error TS2552: Cannot find name 'TokenID'. Did you mean 'tokenId'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(467,22): error TS2304: Cannot find name 'NodeType'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(469,50): error TS2304: Cannot find name 'NodeType'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(472,58): error TS2304: Cannot find name 'TokenID'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(472,58): error TS2552: Cannot find name 'TokenID'. Did you mean 'tokenId'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(474,22): error TS2304: Cannot find name 'NodeType'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(476,50): error TS2304: Cannot find name 'NodeType'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(479,58): error TS2304: Cannot find name 'TokenID'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(479,58): error TS2552: Cannot find name 'TokenID'. Did you mean 'tokenId'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(481,22): error TS2304: Cannot find name 'NodeType'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(483,58): error TS2304: Cannot find name 'TokenID'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(483,58): error TS2552: Cannot find name 'TokenID'. Did you mean 'tokenId'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(485,22): error TS2304: Cannot find name 'NodeType'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(487,58): error TS2304: Cannot find name 'TokenID'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(487,58): error TS2552: Cannot find name 'TokenID'. Did you mean 'tokenId'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(489,22): error TS2304: Cannot find name 'NodeType'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(491,58): error TS2304: Cannot find name 'TokenID'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(491,58): error TS2552: Cannot find name 'TokenID'. Did you mean 'tokenId'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(494,22): error TS2304: Cannot find name 'NodeType'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(496,58): error TS2304: Cannot find name 'TokenID'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(498,22): error TS2304: Cannot find name 'NodeType'.
|
||||
@@ -848,7 +848,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(2356,48): error
|
||||
emitter.recordSourceMappingStart(this);
|
||||
emitter.emitJavascriptList(this, null, TokenID.Semicolon, startLine, false, false);
|
||||
~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TokenID'.
|
||||
!!! error TS2552: Cannot find name 'TokenID'. Did you mean 'tokenId'?
|
||||
emitter.recordSourceMappingEnd(this);
|
||||
}
|
||||
|
||||
@@ -1139,7 +1139,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(2356,48): error
|
||||
!!! error TS2304: Cannot find name 'NodeType'.
|
||||
emitter.emitJavascript(this.operand, TokenID.PlusPlus, false);
|
||||
~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TokenID'.
|
||||
!!! error TS2552: Cannot find name 'TokenID'. Did you mean 'tokenId'?
|
||||
emitter.writeToOutput("++");
|
||||
break;
|
||||
case NodeType.LogNot:
|
||||
@@ -1148,14 +1148,14 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(2356,48): error
|
||||
emitter.writeToOutput("!");
|
||||
emitter.emitJavascript(this.operand, TokenID.Exclamation, false);
|
||||
~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TokenID'.
|
||||
!!! error TS2552: Cannot find name 'TokenID'. Did you mean 'tokenId'?
|
||||
break;
|
||||
case NodeType.DecPost:
|
||||
~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'NodeType'.
|
||||
emitter.emitJavascript(this.operand, TokenID.MinusMinus, false);
|
||||
~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TokenID'.
|
||||
!!! error TS2552: Cannot find name 'TokenID'. Did you mean 'tokenId'?
|
||||
emitter.writeToOutput("--");
|
||||
break;
|
||||
case NodeType.ObjectLit:
|
||||
@@ -1174,7 +1174,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(2356,48): error
|
||||
emitter.writeToOutput("~");
|
||||
emitter.emitJavascript(this.operand, TokenID.Tilde, false);
|
||||
~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TokenID'.
|
||||
!!! error TS2552: Cannot find name 'TokenID'. Did you mean 'tokenId'?
|
||||
break;
|
||||
case NodeType.Neg:
|
||||
~~~~~~~~
|
||||
@@ -1187,7 +1187,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(2356,48): error
|
||||
}
|
||||
emitter.emitJavascript(this.operand, TokenID.Minus, false);
|
||||
~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TokenID'.
|
||||
!!! error TS2552: Cannot find name 'TokenID'. Did you mean 'tokenId'?
|
||||
break;
|
||||
case NodeType.Pos:
|
||||
~~~~~~~~
|
||||
@@ -1200,7 +1200,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(2356,48): error
|
||||
}
|
||||
emitter.emitJavascript(this.operand, TokenID.Plus, false);
|
||||
~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TokenID'.
|
||||
!!! error TS2552: Cannot find name 'TokenID'. Did you mean 'tokenId'?
|
||||
break;
|
||||
case NodeType.IncPre:
|
||||
~~~~~~~~
|
||||
@@ -1208,7 +1208,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(2356,48): error
|
||||
emitter.writeToOutput("++");
|
||||
emitter.emitJavascript(this.operand, TokenID.PlusPlus, false);
|
||||
~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TokenID'.
|
||||
!!! error TS2552: Cannot find name 'TokenID'. Did you mean 'tokenId'?
|
||||
break;
|
||||
case NodeType.DecPre:
|
||||
~~~~~~~~
|
||||
@@ -1216,7 +1216,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(2356,48): error
|
||||
emitter.writeToOutput("--");
|
||||
emitter.emitJavascript(this.operand, TokenID.MinusMinus, false);
|
||||
~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TokenID'.
|
||||
!!! error TS2552: Cannot find name 'TokenID'. Did you mean 'tokenId'?
|
||||
break;
|
||||
case NodeType.Throw:
|
||||
~~~~~~~~
|
||||
@@ -1224,7 +1224,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource11.ts(2356,48): error
|
||||
emitter.writeToOutput("throw ");
|
||||
emitter.emitJavascript(this.operand, TokenID.Tilde, false);
|
||||
~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TokenID'.
|
||||
!!! error TS2552: Cannot find name 'TokenID'. Did you mean 'tokenId'?
|
||||
emitter.writeToOutput(";");
|
||||
break;
|
||||
case NodeType.Typeof:
|
||||
|
||||
@@ -113,7 +113,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource13.ts(123,26): error
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource13.ts(123,39): error TS2304: Cannot find name 'AST'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource13.ts(128,33): error TS2339: Property 'getAstWalkerFactory' does not exist on type 'typeof TypeScript'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource13.ts(132,51): error TS2304: Cannot find name 'AST'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource13.ts(135,36): error TS2304: Cannot find name 'NodeType'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource13.ts(135,36): error TS2552: Cannot find name 'NodeType'. Did you mean 'nodeType'?
|
||||
|
||||
|
||||
==== tests/cases/conformance/parser/ecmascript5/parserRealSource13.ts (116 errors) ====
|
||||
@@ -483,7 +483,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource13.ts(135,36): error
|
||||
var nodeType = ast.nodeType;
|
||||
var callbackString = (<any>NodeType)._map[nodeType] + "Callback";
|
||||
~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'NodeType'.
|
||||
!!! error TS2552: Cannot find name 'NodeType'. Did you mean 'nodeType'?
|
||||
if (callback[callbackString]) {
|
||||
return callback[callbackString](pre, ast);
|
||||
}
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(4,1): error TS6053: File 'tests/cases/conformance/parser/ecmascript5/typescript.ts' not found.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(12,38): error TS2304: Cannot find name 'ASTList'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(12,62): error TS2304: Cannot find name 'TypeLink'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(16,37): error TS2304: Cannot find name 'TypeLink'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(16,37): error TS2552: Cannot find name 'TypeLink'. Did you mean 'typeLink'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(16,45): error TS1150: 'new T[]' cannot be used to create an array. Use 'new Array<T>()' instead.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(21,36): error TS2304: Cannot find name 'TypeLink'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(21,36): error TS2552: Cannot find name 'TypeLink'. Did you mean 'typeLink'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(29,29): error TS2304: Cannot find name 'Type'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(29,45): error TS2304: Cannot find name 'TypeDeclaration'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(34,43): error TS2304: Cannot find name 'Type'.
|
||||
@@ -11,11 +11,11 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(34,54): error TS
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(34,68): error TS2304: Cannot find name 'TypeCollectionContext'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(35,25): error TS2304: Cannot find name 'ValueLocation'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(36,30): error TS2304: Cannot find name 'TypeLink'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(41,17): error TS2304: Cannot find name 'FieldSymbol'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(41,17): error TS2552: Cannot find name 'FieldSymbol'. Did you mean 'fieldSymbol'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(43,31): error TS2304: Cannot find name 'SymbolFlags'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(43,54): error TS2304: Cannot find name 'SymbolFlags'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(49,58): error TS2304: Cannot find name 'Type'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(50,29): error TS2304: Cannot find name 'Signature'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(50,29): error TS2552: Cannot find name 'Signature'. Did you mean 'signature'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(51,36): error TS2304: Cannot find name 'TypeLink'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(55,30): error TS2304: Cannot find name 'SignatureGroup'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(59,66): error TS2304: Cannot find name 'Type'.
|
||||
@@ -46,7 +46,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(154,27): error T
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(155,26): error TS2304: Cannot find name 'hasFlag'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(155,55): error TS2304: Cannot find name 'VarFlags'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(165,28): error TS2304: Cannot find name 'ModuleType'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(169,26): error TS2304: Cannot find name 'TypeSymbol'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(169,26): error TS2552: Cannot find name 'TypeSymbol'. Did you mean 'typeSymbol'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(186,48): error TS2304: Cannot find name 'AST'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(186,61): error TS2304: Cannot find name 'AST'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(186,75): error TS2304: Cannot find name 'TypeCollectionContext'.
|
||||
@@ -81,8 +81,8 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(212,46): error T
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(212,64): error TS2304: Cannot find name 'DualStringHashTable'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(212,88): error TS2304: Cannot find name 'StringHashTable'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(212,111): error TS2304: Cannot find name 'StringHashTable'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(216,30): error TS2304: Cannot find name 'TypeSymbol'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(231,72): error TS2304: Cannot find name 'NodeType'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(216,30): error TS2552: Cannot find name 'TypeSymbol'. Did you mean 'typeSymbol'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(231,72): error TS2552: Cannot find name 'NodeType'. Did you mean 'modType'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(234,27): error TS2304: Cannot find name 'TypeSymbol'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(238,80): error TS2304: Cannot find name 'StringHashTable'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(239,37): error TS2304: Cannot find name 'ScopedMembers'.
|
||||
@@ -142,7 +142,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(349,47): error T
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(349,65): error TS2304: Cannot find name 'DualStringHashTable'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(349,89): error TS2304: Cannot find name 'StringHashTable'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(349,112): error TS2304: Cannot find name 'StringHashTable'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(350,30): error TS2304: Cannot find name 'TypeSymbol'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(350,30): error TS2552: Cannot find name 'TypeSymbol'. Did you mean 'typeSymbol'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(360,37): error TS2304: Cannot find name 'SymbolFlags'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(364,37): error TS2304: Cannot find name 'SymbolFlags'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(368,37): error TS2304: Cannot find name 'SymbolFlags'.
|
||||
@@ -196,7 +196,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(476,57): error T
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(477,29): error TS2304: Cannot find name 'ValueLocation'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(478,29): error TS2304: Cannot find name 'hasFlag'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(478,55): error TS2304: Cannot find name 'VarFlags'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(480,21): error TS2304: Cannot find name 'FieldSymbol'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(480,21): error TS2552: Cannot find name 'FieldSymbol'. Did you mean 'fieldSymbol'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(482,34): error TS2304: Cannot find name 'hasFlag'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(482,60): error TS2304: Cannot find name 'VarFlags'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(492,30): error TS2304: Cannot find name 'getTypeLink'.
|
||||
@@ -218,7 +218,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(507,26): error T
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(507,52): error TS2304: Cannot find name 'ASTFlags'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(518,22): error TS2304: Cannot find name 'FieldSymbol'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(531,29): error TS2304: Cannot find name 'ValueLocation'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(533,21): error TS2304: Cannot find name 'FieldSymbol'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(533,21): error TS2552: Cannot find name 'FieldSymbol'. Did you mean 'fieldSymbol'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(535,53): error TS2304: Cannot find name 'VarFlags'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(535,75): error TS2304: Cannot find name 'VarFlags'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(539,38): error TS2304: Cannot find name 'SymbolFlags'.
|
||||
@@ -327,7 +327,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(828,13): error T
|
||||
if (baseTypeLinks == null) {
|
||||
baseTypeLinks = new TypeLink[];
|
||||
~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TypeLink'.
|
||||
!!! error TS2552: Cannot find name 'TypeLink'. Did you mean 'typeLink'?
|
||||
~~
|
||||
!!! error TS1150: 'new T[]' cannot be used to create an array. Use 'new Array<T>()' instead.
|
||||
}
|
||||
@@ -336,7 +336,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(828,13): error T
|
||||
var name = baseExpr;
|
||||
var typeLink = new TypeLink();
|
||||
~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TypeLink'.
|
||||
!!! error TS2552: Cannot find name 'TypeLink'. Did you mean 'typeLink'?
|
||||
typeLink.ast = name;
|
||||
baseTypeLinks[baseTypeLinks.length] = typeLink;
|
||||
}
|
||||
@@ -372,7 +372,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(828,13): error T
|
||||
var fieldSymbol =
|
||||
new FieldSymbol("prototype", ast.minChar,
|
||||
~~~~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'FieldSymbol'.
|
||||
!!! error TS2552: Cannot find name 'FieldSymbol'. Did you mean 'fieldSymbol'?
|
||||
context.checker.locationInfo.unitIndex, true, field);
|
||||
fieldSymbol.flags |= (SymbolFlags.Property | SymbolFlags.BuiltIn);
|
||||
~~~~~~~~~~~
|
||||
@@ -389,7 +389,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(828,13): error T
|
||||
!!! error TS2304: Cannot find name 'Type'.
|
||||
var signature = new Signature();
|
||||
~~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'Signature'.
|
||||
!!! error TS2552: Cannot find name 'Signature'. Did you mean 'signature'?
|
||||
signature.returnType = new TypeLink();
|
||||
~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TypeLink'.
|
||||
@@ -570,7 +570,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(828,13): error T
|
||||
|
||||
typeSymbol = new TypeSymbol(importDecl.id.text, importDecl.minChar,
|
||||
~~~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TypeSymbol'.
|
||||
!!! error TS2552: Cannot find name 'TypeSymbol'. Did you mean 'typeSymbol'?
|
||||
context.checker.locationInfo.unitIndex, modType);
|
||||
|
||||
typeSymbol.aliasLink = importDecl;
|
||||
@@ -687,7 +687,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(828,13): error T
|
||||
|
||||
typeSymbol = new TypeSymbol(modName, moduleDecl.minChar,
|
||||
~~~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TypeSymbol'.
|
||||
!!! error TS2552: Cannot find name 'TypeSymbol'. Did you mean 'typeSymbol'?
|
||||
context.checker.locationInfo.unitIndex, modType);
|
||||
|
||||
if (context.scopeChain.moduleDecl) {
|
||||
@@ -704,7 +704,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(828,13): error T
|
||||
else {
|
||||
if (symbol && symbol.declAST && symbol.declAST.nodeType != NodeType.ModuleDeclaration) {
|
||||
~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'NodeType'.
|
||||
!!! error TS2552: Cannot find name 'NodeType'. Did you mean 'modType'?
|
||||
context.checker.errorReporter.simpleError(moduleDecl, "Conflicting symbol name for module '" + modName + "'");
|
||||
}
|
||||
typeSymbol = <TypeSymbol>symbol;
|
||||
@@ -943,7 +943,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(828,13): error T
|
||||
!!! error TS2304: Cannot find name 'StringHashTable'.
|
||||
typeSymbol = new TypeSymbol(className, classDecl.minChar,
|
||||
~~~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TypeSymbol'.
|
||||
!!! error TS2552: Cannot find name 'TypeSymbol'. Did you mean 'typeSymbol'?
|
||||
context.checker.locationInfo.unitIndex, classType);
|
||||
typeSymbol.declAST = classDecl;
|
||||
typeSymbol.instanceType = instanceType;
|
||||
@@ -1181,7 +1181,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(828,13): error T
|
||||
var fieldSymbol =
|
||||
new FieldSymbol(argDecl.id.text, argDecl.minChar,
|
||||
~~~~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'FieldSymbol'.
|
||||
!!! error TS2552: Cannot find name 'FieldSymbol'. Did you mean 'fieldSymbol'?
|
||||
context.checker.locationInfo.unitIndex,
|
||||
!hasFlag(argDecl.varFlags, VarFlags.Readonly),
|
||||
~~~~~~~
|
||||
@@ -1278,7 +1278,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource7.ts(828,13): error T
|
||||
var fieldSymbol =
|
||||
new FieldSymbol(varDecl.id.text, varDecl.minChar,
|
||||
~~~~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'FieldSymbol'.
|
||||
!!! error TS2552: Cannot find name 'FieldSymbol'. Did you mean 'fieldSymbol'?
|
||||
context.checker.locationInfo.unitIndex,
|
||||
(varDecl.varFlags & VarFlags.Readonly) == VarFlags.None,
|
||||
~~~~~~~~
|
||||
|
||||
@@ -47,7 +47,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource8.ts(160,52): error T
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource8.ts(160,76): error TS2304: Cannot find name 'StringHashTable'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource8.ts(160,99): error TS2304: Cannot find name 'StringHashTable'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource8.ts(162,28): error TS2304: Cannot find name 'Type'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource8.ts(163,30): error TS2304: Cannot find name 'WithSymbol'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource8.ts(163,30): error TS2552: Cannot find name 'WithSymbol'. Did you mean 'withSymbol'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource8.ts(170,40): error TS2339: Property 'SymbolScopeBuilder' does not exist on type 'typeof TypeScript'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource8.ts(176,50): error TS2304: Cannot find name 'AST'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserRealSource8.ts(177,25): error TS2304: Cannot find name 'FuncDecl'.
|
||||
@@ -397,7 +397,7 @@ tests/cases/conformance/parser/ecmascript5/parserRealSource8.ts(454,35): error T
|
||||
!!! error TS2304: Cannot find name 'Type'.
|
||||
var withSymbol = new WithSymbol(withStmt.minChar, context.typeFlow.checker.locationInfo.unitIndex, withType);
|
||||
~~~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'WithSymbol'.
|
||||
!!! error TS2552: Cannot find name 'WithSymbol'. Did you mean 'withSymbol'?
|
||||
withType.members = members;
|
||||
withType.ambientMembers = ambientMembers;
|
||||
withType.symbol = withSymbol;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.2_A1.5_T2.ts(14,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.2_A1.5_T2.ts(20,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.2_A1.5_T2.ts(14,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.2_A1.5_T2.ts(20,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
|
||||
|
||||
==== tests/cases/conformance/parser/ecmascript5/parserS7.2_A1.5_T2.ts (2 errors) ====
|
||||
@@ -18,7 +18,7 @@ tests/cases/conformance/parser/ecmascript5/parserS7.2_A1.5_T2.ts(20,3): error TS
|
||||
if (x !== 1) {
|
||||
$ERROR('#1: eval("\\u00A0var x\\u00A0= 1\\u00A0"); x === 1. Actual: ' + (x));
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
|
||||
//CHECK#2
|
||||
@@ -26,7 +26,7 @@ tests/cases/conformance/parser/ecmascript5/parserS7.2_A1.5_T2.ts(20,3): error TS
|
||||
if (x !== 1) {
|
||||
$ERROR('#2: var x = 1 ; x === 1. Actual: ' + (x));
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.3_A1.1_T2.ts(17,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.3_A1.1_T2.ts(17,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
|
||||
|
||||
==== tests/cases/conformance/parser/ecmascript5/parserS7.3_A1.1_T2.ts (1 errors) ====
|
||||
@@ -20,7 +20,7 @@ tests/cases/conformance/parser/ecmascript5/parserS7.3_A1.1_T2.ts(17,3): error TS
|
||||
if (x !== 1) {
|
||||
$ERROR('#1: var\\nx\\n=\\n1\\n; x === 1. Actual: ' + (x));
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(14,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(18,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(22,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(26,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(30,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(34,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(38,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(42,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(46,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(50,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(14,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(18,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(22,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(26,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(30,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(34,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(38,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(42,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(46,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(50,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(54,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(58,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(62,3): error TS2304: Cannot find name '$ERROR'.
|
||||
@@ -49,61 +49,61 @@ tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(142,3): error T
|
||||
if (А !== 1) {
|
||||
$ERROR('#А');
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
var \u0411 = 1;
|
||||
if (Б !== 1) {
|
||||
$ERROR('#Б');
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
var \u0412 = 1;
|
||||
if (В !== 1) {
|
||||
$ERROR('#В');
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
var \u0413 = 1;
|
||||
if (Г !== 1) {
|
||||
$ERROR('#Г');
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
var \u0414 = 1;
|
||||
if (Д !== 1) {
|
||||
$ERROR('#Д');
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
var \u0415 = 1;
|
||||
if (Е !== 1) {
|
||||
$ERROR('#Е');
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
var \u0416 = 1;
|
||||
if (Ж !== 1) {
|
||||
$ERROR('#Ж');
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
var \u0417 = 1;
|
||||
if (З !== 1) {
|
||||
$ERROR('#З');
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
var \u0418 = 1;
|
||||
if (И !== 1) {
|
||||
$ERROR('#И');
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
var \u0419 = 1;
|
||||
if (Й !== 1) {
|
||||
$ERROR('#Й');
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
var \u041A = 1;
|
||||
if (К !== 1) {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
tests/cases/conformance/parser/ecmascript5/SkippedTokens/parserSkippedTokens16.ts(1,1): error TS2304: Cannot find name 'foo'.
|
||||
tests/cases/conformance/parser/ecmascript5/SkippedTokens/parserSkippedTokens16.ts(1,1): error TS2552: Cannot find name 'foo'. Did you mean 'Foo'?
|
||||
tests/cases/conformance/parser/ecmascript5/SkippedTokens/parserSkippedTokens16.ts(1,6): error TS1005: ';' expected.
|
||||
tests/cases/conformance/parser/ecmascript5/SkippedTokens/parserSkippedTokens16.ts(1,8): error TS2304: Cannot find name 'Bar'.
|
||||
tests/cases/conformance/parser/ecmascript5/SkippedTokens/parserSkippedTokens16.ts(1,12): error TS1005: ';' expected.
|
||||
@@ -11,7 +11,7 @@ tests/cases/conformance/parser/ecmascript5/SkippedTokens/parserSkippedTokens16.t
|
||||
==== tests/cases/conformance/parser/ecmascript5/SkippedTokens/parserSkippedTokens16.ts (8 errors) ====
|
||||
foo(): Bar { }
|
||||
~~~
|
||||
!!! error TS2304: Cannot find name 'foo'.
|
||||
!!! error TS2552: Cannot find name 'foo'. Did you mean 'Foo'?
|
||||
~
|
||||
!!! error TS1005: ';' expected.
|
||||
~~~
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
tests/cases/conformance/parser/ecmascript6/Symbols/parserSymbolIndexer5.ts(2,6): error TS2304: Cannot find name 's'.
|
||||
tests/cases/conformance/parser/ecmascript6/Symbols/parserSymbolIndexer5.ts(2,7): error TS1005: ']' expected.
|
||||
tests/cases/conformance/parser/ecmascript6/Symbols/parserSymbolIndexer5.ts(2,9): error TS2304: Cannot find name 'symbol'.
|
||||
tests/cases/conformance/parser/ecmascript6/Symbols/parserSymbolIndexer5.ts(2,9): error TS2552: Cannot find name 'symbol'. Did you mean 'Symbol'?
|
||||
tests/cases/conformance/parser/ecmascript6/Symbols/parserSymbolIndexer5.ts(2,15): error TS1005: ',' expected.
|
||||
tests/cases/conformance/parser/ecmascript6/Symbols/parserSymbolIndexer5.ts(2,16): error TS1136: Property assignment expected.
|
||||
tests/cases/conformance/parser/ecmascript6/Symbols/parserSymbolIndexer5.ts(3,1): error TS1005: ':' expected.
|
||||
@@ -14,7 +14,7 @@ tests/cases/conformance/parser/ecmascript6/Symbols/parserSymbolIndexer5.ts(3,1):
|
||||
~
|
||||
!!! error TS1005: ']' expected.
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'symbol'.
|
||||
!!! error TS2552: Cannot find name 'symbol'. Did you mean 'Symbol'?
|
||||
~
|
||||
!!! error TS1005: ',' expected.
|
||||
~
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
tests/cases/conformance/parser/ecmascript5/parserUnicode1.ts(6,5): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserUnicode1.ts(10,5): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/parser/ecmascript5/parserUnicode1.ts(6,5): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
tests/cases/conformance/parser/ecmascript5/parserUnicode1.ts(10,5): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
|
||||
|
||||
==== tests/cases/conformance/parser/ecmascript5/parserUnicode1.ts (2 errors) ====
|
||||
@@ -10,12 +10,12 @@ tests/cases/conformance/parser/ecmascript5/parserUnicode1.ts(10,5): error TS2304
|
||||
|
||||
$ERROR('#6.1: var \\u0078x = 1; xx === 6. Actual: ' + (xx));
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
}
|
||||
catch (e) {
|
||||
$ERROR('#6.2: var \\u0078x = 1; xx === 6. Actual: ' + (xx));
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
|
||||
}
|
||||
@@ -4,12 +4,12 @@ tests/cases/conformance/parser/ecmascript5/ErrorRecovery/parserUnterminatedGener
|
||||
tests/cases/conformance/parser/ecmascript5/ErrorRecovery/parserUnterminatedGeneric2.ts(4,9): error TS2304: Cannot find name 'assign'.
|
||||
tests/cases/conformance/parser/ecmascript5/ErrorRecovery/parserUnterminatedGeneric2.ts(4,16): error TS2304: Cannot find name 'context'.
|
||||
tests/cases/conformance/parser/ecmascript5/ErrorRecovery/parserUnterminatedGeneric2.ts(4,23): error TS1005: ',' expected.
|
||||
tests/cases/conformance/parser/ecmascript5/ErrorRecovery/parserUnterminatedGeneric2.ts(4,25): error TS2304: Cannot find name 'any'.
|
||||
tests/cases/conformance/parser/ecmascript5/ErrorRecovery/parserUnterminatedGeneric2.ts(4,25): error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
tests/cases/conformance/parser/ecmascript5/ErrorRecovery/parserUnterminatedGeneric2.ts(4,30): error TS2304: Cannot find name 'value'.
|
||||
tests/cases/conformance/parser/ecmascript5/ErrorRecovery/parserUnterminatedGeneric2.ts(4,35): error TS1005: ',' expected.
|
||||
tests/cases/conformance/parser/ecmascript5/ErrorRecovery/parserUnterminatedGeneric2.ts(4,37): error TS2304: Cannot find name 'any'.
|
||||
tests/cases/conformance/parser/ecmascript5/ErrorRecovery/parserUnterminatedGeneric2.ts(4,37): error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
tests/cases/conformance/parser/ecmascript5/ErrorRecovery/parserUnterminatedGeneric2.ts(4,41): error TS1005: ';' expected.
|
||||
tests/cases/conformance/parser/ecmascript5/ErrorRecovery/parserUnterminatedGeneric2.ts(4,43): error TS2304: Cannot find name 'any'.
|
||||
tests/cases/conformance/parser/ecmascript5/ErrorRecovery/parserUnterminatedGeneric2.ts(4,43): error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
tests/cases/conformance/parser/ecmascript5/ErrorRecovery/parserUnterminatedGeneric2.ts(8,23): error TS2304: Cannot find name 'IPromise'.
|
||||
tests/cases/conformance/parser/ecmascript5/ErrorRecovery/parserUnterminatedGeneric2.ts(8,45): error TS2304: Cannot find name 'IPromise'.
|
||||
tests/cases/conformance/parser/ecmascript5/ErrorRecovery/parserUnterminatedGeneric2.ts(8,54): error TS1005: '>' expected.
|
||||
@@ -33,17 +33,17 @@ tests/cases/conformance/parser/ecmascript5/ErrorRecovery/parserUnterminatedGener
|
||||
~
|
||||
!!! error TS1005: ',' expected.
|
||||
~~~
|
||||
!!! error TS2304: Cannot find name 'any'.
|
||||
!!! error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
~~~~~
|
||||
!!! error TS2304: Cannot find name 'value'.
|
||||
~
|
||||
!!! error TS1005: ',' expected.
|
||||
~~~
|
||||
!!! error TS2304: Cannot find name 'any'.
|
||||
!!! error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
~
|
||||
!!! error TS1005: ';' expected.
|
||||
~~~
|
||||
!!! error TS2304: Cannot find name 'any'.
|
||||
!!! error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
}
|
||||
|
||||
interface IQService {
|
||||
|
||||
@@ -16,19 +16,19 @@ tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(691,50): e
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(716,47): error TS2503: Cannot find namespace 'TypeScript'.
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(721,62): error TS2304: Cannot find name 'ITextWriter'.
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(724,29): error TS2304: Cannot find name 'ITextWriter'.
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(754,53): error TS2304: Cannot find name 'TypeScript'.
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(754,53): error TS2552: Cannot find name 'TypeScript'. Did you mean 'TypeScriptLS'?
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(764,56): error TS2503: Cannot find namespace 'TypeScript'.
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(765,37): error TS2304: Cannot find name 'TypeScript'.
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(767,47): error TS2304: Cannot find name 'TypeScript'.
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(776,13): error TS2304: Cannot find name 'TypeScript'.
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(776,42): error TS2304: Cannot find name 'TypeScript'.
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(765,37): error TS2552: Cannot find name 'TypeScript'. Did you mean 'TypeScriptLS'?
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(767,47): error TS2552: Cannot find name 'TypeScript'. Did you mean 'TypeScriptLS'?
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(776,13): error TS2552: Cannot find name 'TypeScript'. Did you mean 'TypeScriptLS'?
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(776,42): error TS2552: Cannot find name 'TypeScript'. Did you mean 'TypeScriptLS'?
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(781,23): error TS2503: Cannot find namespace 'TypeScript'.
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(794,49): error TS2304: Cannot find name 'TypeScript'.
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(795,49): error TS2304: Cannot find name 'TypeScript'.
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(987,53): error TS2304: Cannot find name 'TypeScript'.
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(987,89): error TS2304: Cannot find name 'TypeScript'.
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(794,49): error TS2552: Cannot find name 'TypeScript'. Did you mean 'TypeScriptLS'?
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(795,49): error TS2552: Cannot find name 'TypeScript'. Did you mean 'TypeScriptLS'?
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(987,53): error TS2552: Cannot find name 'TypeScript'. Did you mean 'TypeScriptLS'?
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(987,89): error TS2552: Cannot find name 'TypeScript'. Did you mean 'TypeScriptLS'?
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(987,115): error TS2503: Cannot find namespace 'TypeScript'.
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(987,145): error TS2304: Cannot find name 'TypeScript'.
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(987,145): error TS2552: Cannot find name 'TypeScript'. Did you mean 'TypeScriptLS'?
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(988,43): error TS2304: Cannot find name 'TypeScript'.
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(999,40): error TS2503: Cannot find namespace 'TypeScript'.
|
||||
tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(1041,43): error TS2503: Cannot find namespace 'TypeScript'.
|
||||
@@ -902,7 +902,7 @@ tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(2030,32):
|
||||
|
||||
var libFolder: string = global['WScript'] ? TypeScript.filePath(global['WScript'].ScriptFullName) : (__dirname + '/');
|
||||
~~~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TypeScript'.
|
||||
!!! error TS2552: Cannot find name 'TypeScript'. Did you mean 'TypeScriptLS'?
|
||||
export var libText = IO ? IO.readFile(libFolder + "lib.d.ts") : '';
|
||||
|
||||
var stdout = new EmitterIOHost();
|
||||
@@ -917,11 +917,11 @@ tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(2030,32):
|
||||
!!! error TS2503: Cannot find namespace 'TypeScript'.
|
||||
var compiler = c || new TypeScript.TypeScriptCompiler(stderr);
|
||||
~~~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TypeScript'.
|
||||
!!! error TS2552: Cannot find name 'TypeScript'. Did you mean 'TypeScriptLS'?
|
||||
compiler.parser.errorRecovery = true;
|
||||
compiler.settings.codeGenTarget = TypeScript.CodeGenTarget.ES5;
|
||||
~~~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TypeScript'.
|
||||
!!! error TS2552: Cannot find name 'TypeScript'. Did you mean 'TypeScriptLS'?
|
||||
compiler.settings.controlFlow = true;
|
||||
compiler.settings.controlFlowUseDef = true;
|
||||
if (Harness.usePull) {
|
||||
@@ -932,9 +932,9 @@ tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(2030,32):
|
||||
compiler.parseEmitOption(stdout);
|
||||
TypeScript.moduleGenTarget = TypeScript.ModuleGenTarget.Synchronous;
|
||||
~~~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TypeScript'.
|
||||
!!! error TS2552: Cannot find name 'TypeScript'. Did you mean 'TypeScriptLS'?
|
||||
~~~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TypeScript'.
|
||||
!!! error TS2552: Cannot find name 'TypeScript'. Did you mean 'TypeScriptLS'?
|
||||
compiler.addUnit(Harness.Compiler.libText, "lib.d.ts", true);
|
||||
return compiler;
|
||||
}
|
||||
@@ -956,10 +956,10 @@ tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(2030,32):
|
||||
// requires unit to already exist in the compiler
|
||||
compiler.pullUpdateUnit(new TypeScript.StringSourceText(""), filename, true);
|
||||
~~~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TypeScript'.
|
||||
!!! error TS2552: Cannot find name 'TypeScript'. Did you mean 'TypeScriptLS'?
|
||||
compiler.pullUpdateUnit(new TypeScript.StringSourceText(code), filename, true);
|
||||
~~~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TypeScript'.
|
||||
!!! error TS2552: Cannot find name 'TypeScript'. Did you mean 'TypeScriptLS'?
|
||||
}
|
||||
}
|
||||
else {
|
||||
@@ -1153,13 +1153,13 @@ tests/cases/conformance/parser/ecmascript5/RealWorld/parserharness.ts(2030,32):
|
||||
var script = compiler.scripts.members[m];
|
||||
var enclosingScopeContext = TypeScript.findEnclosingScopeAt(new TypeScript.NullLogger(), <TypeScript.Script>script, new TypeScript.StringSourceText(code), 0, false);
|
||||
~~~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TypeScript'.
|
||||
!!! error TS2552: Cannot find name 'TypeScript'. Did you mean 'TypeScriptLS'?
|
||||
~~~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TypeScript'.
|
||||
!!! error TS2552: Cannot find name 'TypeScript'. Did you mean 'TypeScriptLS'?
|
||||
~~~~~~~~~~
|
||||
!!! error TS2503: Cannot find namespace 'TypeScript'.
|
||||
~~~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TypeScript'.
|
||||
!!! error TS2552: Cannot find name 'TypeScript'. Did you mean 'TypeScriptLS'?
|
||||
var entries = new TypeScript.ScopeTraversal(compiler).getScopeEntries(enclosingScopeContext);
|
||||
~~~~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'TypeScript'.
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
tests/cases/compiler/primitiveTypeAssignment.ts(1,9): error TS2304: Cannot find name 'any'.
|
||||
tests/cases/compiler/primitiveTypeAssignment.ts(3,9): error TS2304: Cannot find name 'number'.
|
||||
tests/cases/compiler/primitiveTypeAssignment.ts(5,9): error TS2304: Cannot find name 'boolean'.
|
||||
tests/cases/compiler/primitiveTypeAssignment.ts(1,9): error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/primitiveTypeAssignment.ts(3,9): error TS2693: 'number' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/primitiveTypeAssignment.ts(5,9): error TS2693: 'boolean' only refers to a type, but is being used as a value here.
|
||||
|
||||
|
||||
==== tests/cases/compiler/primitiveTypeAssignment.ts (3 errors) ====
|
||||
var x = any;
|
||||
~~~
|
||||
!!! error TS2304: Cannot find name 'any'.
|
||||
!!! error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
|
||||
var y = number;
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'number'.
|
||||
!!! error TS2693: 'number' only refers to a type, but is being used as a value here.
|
||||
|
||||
var z = boolean;
|
||||
~~~~~~~
|
||||
!!! error TS2304: Cannot find name 'boolean'.
|
||||
!!! error TS2693: 'boolean' only refers to a type, but is being used as a value here.
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
tests/cases/conformance/classes/indexMemberDeclarations/privateIndexer2.ts(4,15): error TS1005: ']' expected.
|
||||
tests/cases/conformance/classes/indexMemberDeclarations/privateIndexer2.ts(4,17): error TS2304: Cannot find name 'string'.
|
||||
tests/cases/conformance/classes/indexMemberDeclarations/privateIndexer2.ts(4,17): error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
tests/cases/conformance/classes/indexMemberDeclarations/privateIndexer2.ts(4,23): error TS1005: ',' expected.
|
||||
tests/cases/conformance/classes/indexMemberDeclarations/privateIndexer2.ts(4,24): error TS1136: Property assignment expected.
|
||||
tests/cases/conformance/classes/indexMemberDeclarations/privateIndexer2.ts(4,32): error TS1005: ':' expected.
|
||||
@@ -13,7 +13,7 @@ tests/cases/conformance/classes/indexMemberDeclarations/privateIndexer2.ts(4,32)
|
||||
~
|
||||
!!! error TS1005: ']' expected.
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'string'.
|
||||
!!! error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
~
|
||||
!!! error TS1005: ',' expected.
|
||||
~
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
tests/cases/compiler/propertyOrdering.ts(6,23): error TS2304: Cannot find name 'store'.
|
||||
tests/cases/compiler/propertyOrdering.ts(9,34): error TS2339: Property 'store' does not exist on type 'Foo'.
|
||||
tests/cases/compiler/propertyOrdering.ts(9,34): error TS2551: Property 'store' does not exist on type 'Foo'. Did you mean '_store'?
|
||||
tests/cases/compiler/propertyOrdering.ts(16,25): error TS2339: Property '_store' does not exist on type 'Bar'.
|
||||
tests/cases/compiler/propertyOrdering.ts(20,14): error TS2339: Property '_store' does not exist on type 'Bar'.
|
||||
|
||||
@@ -17,7 +17,7 @@ tests/cases/compiler/propertyOrdering.ts(20,14): error TS2339: Property '_store'
|
||||
|
||||
public bar() { return this.store; } // should be an error
|
||||
~~~~~
|
||||
!!! error TS2339: Property 'store' does not exist on type 'Foo'.
|
||||
!!! error TS2551: Property 'store' does not exist on type 'Foo'. Did you mean '_store'?
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
tests/cases/compiler/propertySignatures.ts(2,13): error TS2300: Duplicate identifier 'a'.
|
||||
tests/cases/compiler/propertySignatures.ts(2,23): error TS2300: Duplicate identifier 'a'.
|
||||
tests/cases/compiler/propertySignatures.ts(14,12): error TS2304: Cannot find name 'foo'.
|
||||
tests/cases/compiler/propertySignatures.ts(14,12): error TS2552: Cannot find name 'foo'. Did you mean 'foo1'?
|
||||
|
||||
|
||||
==== tests/cases/compiler/propertySignatures.ts (3 errors) ====
|
||||
@@ -23,7 +23,7 @@ tests/cases/compiler/propertySignatures.ts(14,12): error TS2304: Cannot find nam
|
||||
var foo4: { (): void; };
|
||||
var test = foo();
|
||||
~~~
|
||||
!!! error TS2304: Cannot find name 'foo'.
|
||||
!!! error TS2552: Cannot find name 'foo'. Did you mean 'foo1'?
|
||||
|
||||
// Should be OK
|
||||
var foo5: {();};
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.2_A1.5_T2.ts(14,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.2_A1.5_T2.ts(20,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.2_A1.5_T2.ts(14,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.2_A1.5_T2.ts(20,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
|
||||
|
||||
==== tests/cases/conformance/scanner/ecmascript5/scannerS7.2_A1.5_T2.ts (2 errors) ====
|
||||
@@ -18,7 +18,7 @@ tests/cases/conformance/scanner/ecmascript5/scannerS7.2_A1.5_T2.ts(20,3): error
|
||||
if (x !== 1) {
|
||||
$ERROR('#1: eval("\\u00A0var x\\u00A0= 1\\u00A0"); x === 1. Actual: ' + (x));
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
|
||||
//CHECK#2
|
||||
@@ -26,7 +26,7 @@ tests/cases/conformance/scanner/ecmascript5/scannerS7.2_A1.5_T2.ts(20,3): error
|
||||
if (x !== 1) {
|
||||
$ERROR('#2: var x = 1 ; x === 1. Actual: ' + (x));
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.3_A1.1_T2.ts(17,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.3_A1.1_T2.ts(17,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
|
||||
|
||||
==== tests/cases/conformance/scanner/ecmascript5/scannerS7.3_A1.1_T2.ts (1 errors) ====
|
||||
@@ -20,7 +20,7 @@ tests/cases/conformance/scanner/ecmascript5/scannerS7.3_A1.1_T2.ts(17,3): error
|
||||
if (x !== 1) {
|
||||
$ERROR('#1: var\\nx\\n=\\n1\\n; x === 1. Actual: ' + (x));
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(14,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(18,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(22,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(26,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(30,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(34,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(38,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(42,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(46,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(50,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(14,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(18,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(22,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(26,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(30,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(34,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(38,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(42,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(46,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(50,3): error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(54,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(58,3): error TS2304: Cannot find name '$ERROR'.
|
||||
tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(62,3): error TS2304: Cannot find name '$ERROR'.
|
||||
@@ -49,61 +49,61 @@ tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(142,3): error
|
||||
if (А !== 1) {
|
||||
$ERROR('#А');
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
var \u0411 = 1;
|
||||
if (Б !== 1) {
|
||||
$ERROR('#Б');
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
var \u0412 = 1;
|
||||
if (В !== 1) {
|
||||
$ERROR('#В');
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
var \u0413 = 1;
|
||||
if (Г !== 1) {
|
||||
$ERROR('#Г');
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
var \u0414 = 1;
|
||||
if (Д !== 1) {
|
||||
$ERROR('#Д');
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
var \u0415 = 1;
|
||||
if (Е !== 1) {
|
||||
$ERROR('#Е');
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
var \u0416 = 1;
|
||||
if (Ж !== 1) {
|
||||
$ERROR('#Ж');
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
var \u0417 = 1;
|
||||
if (З !== 1) {
|
||||
$ERROR('#З');
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
var \u0418 = 1;
|
||||
if (И !== 1) {
|
||||
$ERROR('#И');
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
var \u0419 = 1;
|
||||
if (Й !== 1) {
|
||||
$ERROR('#Й');
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name '$ERROR'.
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
}
|
||||
var \u041A = 1;
|
||||
if (К !== 1) {
|
||||
|
||||
@@ -5,12 +5,12 @@ tests/cases/compiler/staticsInAFunction.ts(3,4): error TS1128: Declaration or st
|
||||
tests/cases/compiler/staticsInAFunction.ts(3,11): error TS2304: Cannot find name 'test'.
|
||||
tests/cases/compiler/staticsInAFunction.ts(3,16): error TS2304: Cannot find name 'name'.
|
||||
tests/cases/compiler/staticsInAFunction.ts(3,20): error TS1005: ',' expected.
|
||||
tests/cases/compiler/staticsInAFunction.ts(3,21): error TS2304: Cannot find name 'string'.
|
||||
tests/cases/compiler/staticsInAFunction.ts(3,21): error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/staticsInAFunction.ts(4,4): error TS1128: Declaration or statement expected.
|
||||
tests/cases/compiler/staticsInAFunction.ts(4,11): error TS2304: Cannot find name 'test'.
|
||||
tests/cases/compiler/staticsInAFunction.ts(4,16): error TS2304: Cannot find name 'name'.
|
||||
tests/cases/compiler/staticsInAFunction.ts(4,21): error TS1109: Expression expected.
|
||||
tests/cases/compiler/staticsInAFunction.ts(4,22): error TS2304: Cannot find name 'any'.
|
||||
tests/cases/compiler/staticsInAFunction.ts(4,22): error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
tests/cases/compiler/staticsInAFunction.ts(4,26): error TS1005: ';' expected.
|
||||
|
||||
|
||||
@@ -33,7 +33,7 @@ tests/cases/compiler/staticsInAFunction.ts(4,26): error TS1005: ';' expected.
|
||||
~
|
||||
!!! error TS1005: ',' expected.
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'string'.
|
||||
!!! error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
static test(name?:any){}
|
||||
~~~~~~
|
||||
!!! error TS1128: Declaration or statement expected.
|
||||
@@ -44,7 +44,7 @@ tests/cases/compiler/staticsInAFunction.ts(4,26): error TS1005: ';' expected.
|
||||
~
|
||||
!!! error TS1109: Expression expected.
|
||||
~~~
|
||||
!!! error TS2304: Cannot find name 'any'.
|
||||
!!! error TS2693: 'any' only refers to a type, but is being used as a value here.
|
||||
~
|
||||
!!! error TS1005: ';' expected.
|
||||
}
|
||||
|
||||
@@ -38,7 +38,7 @@ tests/cases/compiler/strictModeReservedWord.ts(22,12): error TS1212: Identifier
|
||||
tests/cases/compiler/strictModeReservedWord.ts(22,12): error TS2503: Cannot find namespace 'interface'.
|
||||
tests/cases/compiler/strictModeReservedWord.ts(22,22): error TS1212: Identifier expected. 'package' is a reserved word in strict mode.
|
||||
tests/cases/compiler/strictModeReservedWord.ts(22,30): error TS1212: Identifier expected. 'implements' is a reserved word in strict mode.
|
||||
tests/cases/compiler/strictModeReservedWord.ts(23,5): error TS2304: Cannot find name 'ublic'.
|
||||
tests/cases/compiler/strictModeReservedWord.ts(23,5): error TS2552: Cannot find name 'ublic'. Did you mean 'public'?
|
||||
tests/cases/compiler/strictModeReservedWord.ts(24,5): error TS1212: Identifier expected. 'static' is a reserved word in strict mode.
|
||||
tests/cases/compiler/strictModeReservedWord.ts(24,5): error TS2349: Cannot invoke an expression whose type lacks a call signature. Type 'String' has no compatible call signatures.
|
||||
|
||||
@@ -148,7 +148,7 @@ tests/cases/compiler/strictModeReservedWord.ts(24,5): error TS2349: Cannot invok
|
||||
!!! error TS1212: Identifier expected. 'implements' is a reserved word in strict mode.
|
||||
ublic();
|
||||
~~~~~
|
||||
!!! error TS2304: Cannot find name 'ublic'.
|
||||
!!! error TS2552: Cannot find name 'ublic'. Did you mean 'public'?
|
||||
static();
|
||||
~~~~~~
|
||||
!!! error TS1212: Identifier expected. 'static' is a reserved word in strict mode.
|
||||
|
||||
@@ -91,7 +91,7 @@ tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(172,30): e
|
||||
tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(172,32): error TS1138: Parameter declaration expected.
|
||||
tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(172,39): error TS1005: ';' expected.
|
||||
tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(172,40): error TS1128: Declaration or statement expected.
|
||||
tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(172,42): error TS2304: Cannot find name 'number'.
|
||||
tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(172,42): error TS2693: 'number' only refers to a type, but is being used as a value here.
|
||||
tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(172,49): error TS1005: ';' expected.
|
||||
tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(175,1): error TS7027: Unreachable code detected.
|
||||
tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(175,29): error TS2304: Cannot find name 'm'.
|
||||
@@ -425,7 +425,7 @@ tests/cases/conformance/types/thisType/thisTypeInFunctionsNegative.ts(175,35): e
|
||||
~
|
||||
!!! error TS1128: Declaration or statement expected.
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'number'.
|
||||
!!! error TS2693: 'number' only refers to a type, but is being used as a value here.
|
||||
~
|
||||
!!! error TS1005: ';' expected.
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@ tests/cases/conformance/expressions/typeAssertions/typeAssertions.ts(44,5): erro
|
||||
tests/cases/conformance/expressions/typeAssertions/typeAssertions.ts(44,14): error TS1005: '>' expected.
|
||||
tests/cases/conformance/expressions/typeAssertions/typeAssertions.ts(44,14): error TS2304: Cannot find name 'is'.
|
||||
tests/cases/conformance/expressions/typeAssertions/typeAssertions.ts(44,17): error TS1005: ')' expected.
|
||||
tests/cases/conformance/expressions/typeAssertions/typeAssertions.ts(44,17): error TS2304: Cannot find name 'string'.
|
||||
tests/cases/conformance/expressions/typeAssertions/typeAssertions.ts(44,17): error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
tests/cases/conformance/expressions/typeAssertions/typeAssertions.ts(44,48): error TS1005: ';' expected.
|
||||
tests/cases/conformance/expressions/typeAssertions/typeAssertions.ts(45,2): error TS2322: Type 'string | number' is not assignable to type 'string'.
|
||||
Type 'number' is not assignable to type 'string'.
|
||||
@@ -19,7 +19,7 @@ tests/cases/conformance/expressions/typeAssertions/typeAssertions.ts(48,32): err
|
||||
tests/cases/conformance/expressions/typeAssertions/typeAssertions.ts(48,41): error TS1005: ')' expected.
|
||||
tests/cases/conformance/expressions/typeAssertions/typeAssertions.ts(48,41): error TS2304: Cannot find name 'is'.
|
||||
tests/cases/conformance/expressions/typeAssertions/typeAssertions.ts(48,44): error TS1005: ';' expected.
|
||||
tests/cases/conformance/expressions/typeAssertions/typeAssertions.ts(48,44): error TS2304: Cannot find name 'string'.
|
||||
tests/cases/conformance/expressions/typeAssertions/typeAssertions.ts(48,44): error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
tests/cases/conformance/expressions/typeAssertions/typeAssertions.ts(48,50): error TS1005: ';' expected.
|
||||
|
||||
|
||||
@@ -91,7 +91,7 @@ tests/cases/conformance/expressions/typeAssertions/typeAssertions.ts(48,50): err
|
||||
~~~~~~
|
||||
!!! error TS1005: ')' expected.
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'string'.
|
||||
!!! error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
~
|
||||
!!! error TS1005: ';' expected.
|
||||
str = numOrStr; // Error, no narrowing occurred
|
||||
@@ -110,7 +110,7 @@ tests/cases/conformance/expressions/typeAssertions/typeAssertions.ts(48,50): err
|
||||
~~~~~~
|
||||
!!! error TS1005: ';' expected.
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'string'.
|
||||
!!! error TS2693: 'string' only refers to a type, but is being used as a value here.
|
||||
~
|
||||
!!! error TS1005: ';' expected.
|
||||
}
|
||||
|
||||
@@ -19,9 +19,9 @@ tests/cases/conformance/expressions/typeGuards/typeGuardFunctionErrors.ts(41,56)
|
||||
Type 'number' is not assignable to type 'string'.
|
||||
tests/cases/conformance/expressions/typeGuards/typeGuardFunctionErrors.ts(45,56): error TS2677: A type predicate's type must be assignable to its parameter's type.
|
||||
Type 'T[]' is not assignable to type 'string'.
|
||||
tests/cases/conformance/expressions/typeGuards/typeGuardFunctionErrors.ts(59,7): error TS2339: Property 'propB' does not exist on type 'A'.
|
||||
tests/cases/conformance/expressions/typeGuards/typeGuardFunctionErrors.ts(64,7): error TS2339: Property 'propB' does not exist on type 'A'.
|
||||
tests/cases/conformance/expressions/typeGuards/typeGuardFunctionErrors.ts(69,7): error TS2339: Property 'propB' does not exist on type 'A'.
|
||||
tests/cases/conformance/expressions/typeGuards/typeGuardFunctionErrors.ts(59,7): error TS2551: Property 'propB' does not exist on type 'A'. Did you mean 'propA'?
|
||||
tests/cases/conformance/expressions/typeGuards/typeGuardFunctionErrors.ts(64,7): error TS2551: Property 'propB' does not exist on type 'A'. Did you mean 'propA'?
|
||||
tests/cases/conformance/expressions/typeGuards/typeGuardFunctionErrors.ts(69,7): error TS2551: Property 'propB' does not exist on type 'A'. Did you mean 'propA'?
|
||||
tests/cases/conformance/expressions/typeGuards/typeGuardFunctionErrors.ts(74,46): error TS2345: Argument of type '(p1: any) => p1 is C' is not assignable to parameter of type '(p1: any) => p1 is B'.
|
||||
Type predicate 'p1 is C' is not assignable to 'p1 is B'.
|
||||
Type 'C' is not assignable to type 'B'.
|
||||
@@ -163,21 +163,21 @@ tests/cases/conformance/expressions/typeGuards/typeGuardFunctionErrors.ts(136,39
|
||||
if (isB(b)) {
|
||||
a.propB;
|
||||
~~~~~
|
||||
!!! error TS2339: Property 'propB' does not exist on type 'A'.
|
||||
!!! error TS2551: Property 'propB' does not exist on type 'A'. Did you mean 'propA'?
|
||||
}
|
||||
|
||||
// Parameter index and argument index for the type guard target is not matching.
|
||||
if (funA(0, a)) {
|
||||
a.propB; // Error
|
||||
~~~~~
|
||||
!!! error TS2339: Property 'propB' does not exist on type 'A'.
|
||||
!!! error TS2551: Property 'propB' does not exist on type 'A'. Did you mean 'propA'?
|
||||
}
|
||||
|
||||
// No type guard in if statement
|
||||
if (hasNoTypeGuard(a)) {
|
||||
a.propB;
|
||||
~~~~~
|
||||
!!! error TS2339: Property 'propB' does not exist on type 'A'.
|
||||
!!! error TS2551: Property 'propB' does not exist on type 'A'. Did you mean 'propA'?
|
||||
}
|
||||
|
||||
// Type predicate type is not assignable
|
||||
|
||||
@@ -22,8 +22,8 @@ tests/cases/conformance/expressions/typeGuards/typeGuardsWithInstanceOfByConstru
|
||||
tests/cases/conformance/expressions/typeGuards/typeGuardsWithInstanceOfByConstructorSignature.ts(160,11): error TS2339: Property 'foo2' does not exist on type 'G1'.
|
||||
tests/cases/conformance/expressions/typeGuards/typeGuardsWithInstanceOfByConstructorSignature.ts(166,11): error TS2339: Property 'foo2' does not exist on type 'G1'.
|
||||
tests/cases/conformance/expressions/typeGuards/typeGuardsWithInstanceOfByConstructorSignature.ts(182,11): error TS2339: Property 'bar' does not exist on type 'H'.
|
||||
tests/cases/conformance/expressions/typeGuards/typeGuardsWithInstanceOfByConstructorSignature.ts(187,11): error TS2339: Property 'foo1' does not exist on type 'H'.
|
||||
tests/cases/conformance/expressions/typeGuards/typeGuardsWithInstanceOfByConstructorSignature.ts(188,11): error TS2339: Property 'foo2' does not exist on type 'H'.
|
||||
tests/cases/conformance/expressions/typeGuards/typeGuardsWithInstanceOfByConstructorSignature.ts(187,11): error TS2551: Property 'foo1' does not exist on type 'H'. Did you mean 'foo'?
|
||||
tests/cases/conformance/expressions/typeGuards/typeGuardsWithInstanceOfByConstructorSignature.ts(188,11): error TS2551: Property 'foo2' does not exist on type 'H'. Did you mean 'foo'?
|
||||
|
||||
|
||||
==== tests/cases/conformance/expressions/typeGuards/typeGuardsWithInstanceOfByConstructorSignature.ts (20 errors) ====
|
||||
@@ -257,10 +257,10 @@ tests/cases/conformance/expressions/typeGuards/typeGuardsWithInstanceOfByConstru
|
||||
if (obj16 instanceof H) {
|
||||
obj16.foo1;
|
||||
~~~~
|
||||
!!! error TS2339: Property 'foo1' does not exist on type 'H'.
|
||||
!!! error TS2551: Property 'foo1' does not exist on type 'H'. Did you mean 'foo'?
|
||||
obj16.foo2;
|
||||
~~~~
|
||||
!!! error TS2339: Property 'foo2' does not exist on type 'H'.
|
||||
!!! error TS2551: Property 'foo2' does not exist on type 'H'. Did you mean 'foo'?
|
||||
}
|
||||
|
||||
var obj17: any;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
tests/cases/compiler/typeParametersAndParametersInComputedNames.ts(6,10): error TS2304: Cannot find name 'T'.
|
||||
tests/cases/compiler/typeParametersAndParametersInComputedNames.ts(6,13): error TS2304: Cannot find name 'a'.
|
||||
tests/cases/compiler/typeParametersAndParametersInComputedNames.ts(6,13): error TS2552: Cannot find name 'a'. Did you mean 'A'?
|
||||
|
||||
|
||||
==== tests/cases/compiler/typeParametersAndParametersInComputedNames.ts (2 errors) ====
|
||||
@@ -12,6 +12,6 @@ tests/cases/compiler/typeParametersAndParametersInComputedNames.ts(6,13): error
|
||||
~
|
||||
!!! error TS2304: Cannot find name 'T'.
|
||||
~
|
||||
!!! error TS2304: Cannot find name 'a'.
|
||||
!!! error TS2552: Cannot find name 'a'. Did you mean 'A'?
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
tests/cases/compiler/undeclaredVarEmit.ts(1,1): error TS7028: Unused label.
|
||||
tests/cases/compiler/undeclaredVarEmit.ts(1,4): error TS2304: Cannot find name 'number'.
|
||||
tests/cases/compiler/undeclaredVarEmit.ts(1,4): error TS2693: 'number' only refers to a type, but is being used as a value here.
|
||||
|
||||
|
||||
==== tests/cases/compiler/undeclaredVarEmit.ts (2 errors) ====
|
||||
@@ -7,4 +7,4 @@ tests/cases/compiler/undeclaredVarEmit.ts(1,4): error TS2304: Cannot find name '
|
||||
~
|
||||
!!! error TS7028: Unused label.
|
||||
~~~~~~
|
||||
!!! error TS2304: Cannot find name 'number'.
|
||||
!!! error TS2693: 'number' only refers to a type, but is being used as a value here.
|
||||
@@ -0,0 +1,5 @@
|
||||
// 10 bobs on the first line
|
||||
// the last two bobs should not have did-you-mean spelling suggestions
|
||||
var blob;
|
||||
bob; bob; bob; bob; bob; bob; bob; bob; bob; bob;
|
||||
bob; bob;
|
||||
@@ -11,4 +11,4 @@ verify.rangeAfterCodeFix(`class C {
|
||||
static method() {
|
||||
this.foo = 10;
|
||||
}
|
||||
}`);
|
||||
}`, /*includeWhiteSpace*/false, /*errorCode*/ undefined, /*index*/ 0);
|
||||
|
||||
@@ -7,4 +7,4 @@
|
||||
//// export function f1() {}
|
||||
//// export var v1 = 5;
|
||||
|
||||
verify.importFixAtPosition([`{ v1, f1 }`]);
|
||||
verify.importFixAtPosition([`{ v1, f1 }`]);
|
||||
|
||||
@@ -8,4 +8,4 @@
|
||||
//// export var v1 = 5;
|
||||
//// export default var d1 = 6;
|
||||
|
||||
verify.importFixAtPosition([`{ v1, f1 }`]);
|
||||
verify.importFixAtPosition([`{ v1, f1 }`]);
|
||||
|
||||
@@ -18,4 +18,4 @@ verify.importFixAtPosition([
|
||||
v2,
|
||||
f1
|
||||
}`
|
||||
]);
|
||||
]);
|
||||
|
||||
@@ -18,4 +18,4 @@ verify.importFixAtPosition([
|
||||
v3,
|
||||
f1
|
||||
}`
|
||||
]);
|
||||
]);
|
||||
|
||||
@@ -9,4 +9,4 @@
|
||||
//// export var v2 = 5;
|
||||
//// export var v3 = 5;
|
||||
|
||||
verify.importFixAtPosition([`{ f1 }`]);
|
||||
verify.importFixAtPosition([`{ f1 }`]);
|
||||
|
||||
@@ -12,5 +12,5 @@ verify.importFixAtPosition([
|
||||
import { f1 } from "./module";
|
||||
f1();`,
|
||||
`import * as ns from "./module";
|
||||
ns.f1();`
|
||||
]);
|
||||
ns.f1();`,
|
||||
]);
|
||||
|
||||
@@ -14,5 +14,5 @@ verify.importFixAtPosition([
|
||||
ns.f1();`,
|
||||
`import d, * as ns from "./module" ;
|
||||
import { f1 } from "./module";
|
||||
f1();`,
|
||||
]);
|
||||
f1();`
|
||||
]);
|
||||
|
||||
@@ -11,4 +11,4 @@
|
||||
verify.importFixAtPosition([
|
||||
`import d, { f1 } from "./module";
|
||||
f1();`
|
||||
]);
|
||||
]);
|
||||
|
||||
@@ -9,4 +9,4 @@
|
||||
|
||||
verify.importFixAtPosition([`import "./module";
|
||||
import { f1 } from "./module";
|
||||
f1();`]);
|
||||
f1();`]);
|
||||
|
||||
@@ -10,4 +10,4 @@
|
||||
//// export var v1 = 5;
|
||||
//// export function f1();
|
||||
|
||||
verify.importFixAtPosition([`{ v1, f1 }`]);
|
||||
verify.importFixAtPosition([`{ v1, f1 }`]);
|
||||
|
||||
@@ -7,4 +7,4 @@
|
||||
//// export var v1 = 5;
|
||||
//// export function f1();
|
||||
|
||||
verify.importFixAtPosition([`{ v1, f1 }`]);
|
||||
verify.importFixAtPosition([`{ v1, f1 }`]);
|
||||
|
||||
@@ -9,4 +9,4 @@
|
||||
//// export var v2 = 5;
|
||||
//// export var v3 = 5;
|
||||
|
||||
verify.importFixAtPosition([`{v1, v2, v3, f1,}`]);
|
||||
verify.importFixAtPosition([`{v1, v2, v3, f1,}`]);
|
||||
|
||||
@@ -13,4 +13,4 @@ verify.importFixAtPosition([
|
||||
`{
|
||||
v1, f1
|
||||
}`
|
||||
]);
|
||||
]);
|
||||
|
||||
@@ -15,4 +15,4 @@ var x = ns.v1 + 5;`,
|
||||
`import ns = require("ambient-module");
|
||||
import { v1 } from "ambient-module";
|
||||
var x = v1 + 5;`,
|
||||
]);
|
||||
]);
|
||||
|
||||
@@ -12,4 +12,4 @@ verify.importFixAtPosition([
|
||||
`import { f1 } from "ambient-module";
|
||||
|
||||
f1();`
|
||||
]);
|
||||
]);
|
||||
|
||||
@@ -25,4 +25,4 @@ verify.importFixAtPosition([
|
||||
`import * as ns from "yet-another-ambient-module";
|
||||
import { v1 } from "ambient-module";
|
||||
var x = v1 + 5;`
|
||||
]);
|
||||
]);
|
||||
|
||||
@@ -18,4 +18,4 @@ verify.importFixAtPosition([
|
||||
import { f1 } from "ambient-module";
|
||||
|
||||
f1();`
|
||||
]);
|
||||
]);
|
||||
|
||||
@@ -27,4 +27,4 @@ verify.importFixAtPosition([
|
||||
`import * as ns from "yet-another-ambient-module"
|
||||
import { v1 } from "ambient-module";
|
||||
var x = v1 + 5;`
|
||||
]);
|
||||
]);
|
||||
|
||||
@@ -16,4 +16,4 @@ verify.importFixAtPosition([
|
||||
`import { f1 } from "b";
|
||||
|
||||
f1();`
|
||||
]);
|
||||
]);
|
||||
|
||||
@@ -9,4 +9,4 @@ verify.importFixAtPosition([
|
||||
`import f1 from "./module";
|
||||
|
||||
f1();`
|
||||
]);
|
||||
]);
|
||||
|
||||
@@ -10,4 +10,4 @@ verify.importFixAtPosition([
|
||||
`import { f1 } from "./module";
|
||||
|
||||
f1();`
|
||||
]);
|
||||
]);
|
||||
|
||||
@@ -15,4 +15,4 @@ verify.importFixAtPosition([
|
||||
import { f1 } from "./Module";
|
||||
|
||||
f1();`
|
||||
]);
|
||||
]);
|
||||
|
||||
@@ -10,4 +10,4 @@ verify.importFixAtPosition([
|
||||
`import { f1 } from "../../other_dir/module";
|
||||
|
||||
f1();`
|
||||
]);
|
||||
]);
|
||||
|
||||
@@ -13,4 +13,4 @@ verify.importFixAtPosition([
|
||||
`import { f1 } from "fake-module/nested";
|
||||
|
||||
f1();`
|
||||
]);
|
||||
]);
|
||||
|
||||
@@ -22,4 +22,4 @@ verify.importFixAtPosition([
|
||||
`import { f1 } from "fake-module";
|
||||
|
||||
f1();`
|
||||
]);
|
||||
]);
|
||||
|
||||
@@ -11,4 +11,4 @@ verify.importFixAtPosition([
|
||||
`import { f1 } from "random";
|
||||
|
||||
f1();`
|
||||
]);
|
||||
]);
|
||||
|
||||
@@ -19,4 +19,4 @@ verify.importFixAtPosition([
|
||||
`import { foo } from "a";
|
||||
|
||||
foo();`
|
||||
]);
|
||||
]);
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user