mirror of
https://github.com/microsoft/TypeScript.git
synced 2025-11-18 17:21:48 +00:00
Update lib types to mark Annex B as deprecated (#43710)
* Mark properties defined in Annex B as deprecated * Tweak * Update baselines * Update fourslash tests * Add completionsStringMethods.ts test * Fix sortText value in fourslash test for deprecated tags * Update package-lock.json * Update package-lock.json * Mark Non-standard RegExp Constructor properties as deprecated * Update baselines Co-authored-by: TypeScript Bot <typescriptbot@microsoft.com>
This commit is contained in:
co-authored by
TypeScript Bot
parent
7849342c7c
commit
d699bcdaae
@@ -971,6 +971,12 @@ namespace FourSlashInterface {
|
||||
kindModifiers: "declare",
|
||||
sortText: SortText.GlobalsOrKeywords
|
||||
});
|
||||
const deprecatedFunctionEntry = (name: string): ExpectedCompletionEntryObject => ({
|
||||
name,
|
||||
kind: "function",
|
||||
kindModifiers: "deprecated,declare",
|
||||
sortText: SortText.DeprecatedGlobalsOrKeywords
|
||||
});
|
||||
const varEntry = (name: string): ExpectedCompletionEntryObject => ({
|
||||
name,
|
||||
kind: "var",
|
||||
@@ -994,6 +1000,12 @@ namespace FourSlashInterface {
|
||||
kindModifiers: "declare",
|
||||
sortText: SortText.LocationPriority
|
||||
});
|
||||
const deprecatedMethodEntry = (name: string): ExpectedCompletionEntryObject => ({
|
||||
name,
|
||||
kind: "method",
|
||||
kindModifiers: "deprecated,declare",
|
||||
sortText: SortText.DeprecatedLocationPriority
|
||||
});
|
||||
const propertyEntry = (name: string): ExpectedCompletionEntryObject => ({
|
||||
name,
|
||||
kind: "property",
|
||||
@@ -1227,7 +1239,7 @@ namespace FourSlashInterface {
|
||||
methodEntry("toLocaleUpperCase"),
|
||||
methodEntry("trim"),
|
||||
propertyEntry("length"),
|
||||
methodEntry("substr"),
|
||||
deprecatedMethodEntry("substr"),
|
||||
methodEntry("valueOf"),
|
||||
];
|
||||
|
||||
@@ -1331,8 +1343,8 @@ namespace FourSlashInterface {
|
||||
functionEntry("decodeURIComponent"),
|
||||
functionEntry("encodeURI"),
|
||||
functionEntry("encodeURIComponent"),
|
||||
functionEntry("escape"),
|
||||
functionEntry("unescape"),
|
||||
deprecatedFunctionEntry("escape"),
|
||||
deprecatedFunctionEntry("unescape"),
|
||||
varEntry("NaN"),
|
||||
varEntry("Infinity"),
|
||||
varEntry("Object"),
|
||||
|
||||
Vendored
+53
-13
@@ -435,47 +435,87 @@ interface String {
|
||||
|
||||
/**
|
||||
* Returns an `<a>` HTML anchor element and sets the name attribute to the text value
|
||||
* @deprecated A legacy feature for browser compatibility
|
||||
* @param name
|
||||
*/
|
||||
anchor(name: string): string;
|
||||
|
||||
/** Returns a `<big>` HTML element */
|
||||
/**
|
||||
* Returns a `<big>` HTML element
|
||||
* @deprecated A legacy feature for browser compatibility
|
||||
*/
|
||||
big(): string;
|
||||
|
||||
/** Returns a `<blink>` HTML element */
|
||||
/**
|
||||
* Returns a `<blink>` HTML element
|
||||
* @deprecated A legacy feature for browser compatibility
|
||||
*/
|
||||
blink(): string;
|
||||
|
||||
/** Returns a `<b>` HTML element */
|
||||
/**
|
||||
* Returns a `<b>` HTML element
|
||||
* @deprecated A legacy feature for browser compatibility
|
||||
*/
|
||||
bold(): string;
|
||||
|
||||
/** Returns a `<tt>` HTML element */
|
||||
/**
|
||||
* Returns a `<tt>` HTML element
|
||||
* @deprecated A legacy feature for browser compatibility
|
||||
*/
|
||||
fixed(): string;
|
||||
|
||||
/** Returns a `<font>` HTML element and sets the color attribute value */
|
||||
/**
|
||||
* Returns a `<font>` HTML element and sets the color attribute value
|
||||
* @deprecated A legacy feature for browser compatibility
|
||||
*/
|
||||
fontcolor(color: string): string;
|
||||
|
||||
/** Returns a `<font>` HTML element and sets the size attribute value */
|
||||
/**
|
||||
* Returns a `<font>` HTML element and sets the size attribute value
|
||||
* @deprecated A legacy feature for browser compatibility
|
||||
*/
|
||||
fontsize(size: number): string;
|
||||
|
||||
/** Returns a `<font>` HTML element and sets the size attribute value */
|
||||
/**
|
||||
* Returns a `<font>` HTML element and sets the size attribute value
|
||||
* @deprecated A legacy feature for browser compatibility
|
||||
*/
|
||||
fontsize(size: string): string;
|
||||
|
||||
/** Returns an `<i>` HTML element */
|
||||
/**
|
||||
* Returns an `<i>` HTML element
|
||||
* @deprecated A legacy feature for browser compatibility
|
||||
*/
|
||||
italics(): string;
|
||||
|
||||
/** Returns an `<a>` HTML element and sets the href attribute value */
|
||||
/**
|
||||
* Returns an `<a>` HTML element and sets the href attribute value
|
||||
* @deprecated A legacy feature for browser compatibility
|
||||
*/
|
||||
link(url: string): string;
|
||||
|
||||
/** Returns a `<small>` HTML element */
|
||||
/**
|
||||
* Returns a `<small>` HTML element
|
||||
* @deprecated A legacy feature for browser compatibility
|
||||
*/
|
||||
small(): string;
|
||||
|
||||
/** Returns a `<strike>` HTML element */
|
||||
/**
|
||||
* Returns a `<strike>` HTML element
|
||||
* @deprecated A legacy feature for browser compatibility
|
||||
*/
|
||||
strike(): string;
|
||||
|
||||
/** Returns a `<sub>` HTML element */
|
||||
/**
|
||||
* Returns a `<sub>` HTML element
|
||||
* @deprecated A legacy feature for browser compatibility
|
||||
*/
|
||||
sub(): string;
|
||||
|
||||
/** Returns a `<sup>` HTML element */
|
||||
/**
|
||||
* Returns a `<sup>` HTML element
|
||||
* @deprecated A legacy feature for browser compatibility
|
||||
*/
|
||||
sup(): string;
|
||||
}
|
||||
|
||||
|
||||
Vendored
+8
-2
@@ -5,9 +5,15 @@ interface String {
|
||||
/** Removes the leading white space and line terminator characters from a string. */
|
||||
trimStart(): string;
|
||||
|
||||
/** Removes the leading white space and line terminator characters from a string. */
|
||||
/**
|
||||
* Removes the leading white space and line terminator characters from a string.
|
||||
* @deprecated A legacy feature for browser compatibility. Use `trimStart` instead
|
||||
*/
|
||||
trimLeft(): string;
|
||||
|
||||
/** Removes the trailing white space and line terminator characters from a string. */
|
||||
/**
|
||||
* Removes the trailing white space and line terminator characters from a string.
|
||||
* @deprecated A legacy feature for browser compatibility. Use `trimEnd` instead
|
||||
*/
|
||||
trimRight(): string;
|
||||
}
|
||||
|
||||
Vendored
+32
@@ -64,12 +64,14 @@ declare function encodeURIComponent(uriComponent: string | number | boolean): st
|
||||
|
||||
/**
|
||||
* Computes a new string in which certain characters have been replaced by a hexadecimal escape sequence.
|
||||
* @deprecated A legacy feature for browser compatibility
|
||||
* @param string A string value
|
||||
*/
|
||||
declare function escape(string: string): string;
|
||||
|
||||
/**
|
||||
* Computes a new string in which hexadecimal escape sequences are replaced with the character that it represents.
|
||||
* @deprecated A legacy feature for browser compatibility
|
||||
* @param string A string value
|
||||
*/
|
||||
declare function unescape(string: string): string;
|
||||
@@ -483,6 +485,7 @@ interface String {
|
||||
// IE extensions
|
||||
/**
|
||||
* Gets a substring beginning at the specified location and having the specified length.
|
||||
* @deprecated A legacy feature for browser compatibility
|
||||
* @param from The starting position of the desired substring. The index of the first character in the string is zero.
|
||||
* @param length The number of characters to include in the returned substring.
|
||||
*/
|
||||
@@ -924,6 +927,7 @@ interface RegExp {
|
||||
lastIndex: number;
|
||||
|
||||
// Non-standard extensions
|
||||
/** @deprecated A legacy feature for browser compatibility */
|
||||
compile(): this;
|
||||
}
|
||||
|
||||
@@ -935,16 +939,44 @@ interface RegExpConstructor {
|
||||
readonly prototype: RegExp;
|
||||
|
||||
// Non-standard extensions
|
||||
/** @deprecated A legacy feature for browser compatibility */
|
||||
$1: string;
|
||||
/** @deprecated A legacy feature for browser compatibility */
|
||||
$2: string;
|
||||
/** @deprecated A legacy feature for browser compatibility */
|
||||
$3: string;
|
||||
/** @deprecated A legacy feature for browser compatibility */
|
||||
$4: string;
|
||||
/** @deprecated A legacy feature for browser compatibility */
|
||||
$5: string;
|
||||
/** @deprecated A legacy feature for browser compatibility */
|
||||
$6: string;
|
||||
/** @deprecated A legacy feature for browser compatibility */
|
||||
$7: string;
|
||||
/** @deprecated A legacy feature for browser compatibility */
|
||||
$8: string;
|
||||
/** @deprecated A legacy feature for browser compatibility */
|
||||
$9: string;
|
||||
/** @deprecated A legacy feature for browser compatibility */
|
||||
input: string;
|
||||
/** @deprecated A legacy feature for browser compatibility */
|
||||
$_: string;
|
||||
/** @deprecated A legacy feature for browser compatibility */
|
||||
lastMatch: string;
|
||||
/** @deprecated A legacy feature for browser compatibility */
|
||||
"$&": string;
|
||||
/** @deprecated A legacy feature for browser compatibility */
|
||||
lastParen: string;
|
||||
/** @deprecated A legacy feature for browser compatibility */
|
||||
"$+": string;
|
||||
/** @deprecated A legacy feature for browser compatibility */
|
||||
leftContext: string;
|
||||
/** @deprecated A legacy feature for browser compatibility */
|
||||
"$`": string;
|
||||
/** @deprecated A legacy feature for browser compatibility */
|
||||
rightContext: string;
|
||||
/** @deprecated A legacy feature for browser compatibility */
|
||||
"$'": string;
|
||||
}
|
||||
|
||||
declare var RegExp: RegExpConstructor;
|
||||
|
||||
@@ -840,8 +840,8 @@
|
||||
{
|
||||
"name": "escape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -899,6 +899,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -921,8 +930,8 @@
|
||||
{
|
||||
"name": "unescape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -980,6 +989,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1015,8 +1015,8 @@
|
||||
{
|
||||
"name": "escape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -1074,6 +1074,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -1096,8 +1105,8 @@
|
||||
{
|
||||
"name": "unescape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -1155,6 +1164,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -6473,8 +6491,8 @@
|
||||
{
|
||||
"name": "escape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -6532,6 +6550,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -6554,8 +6581,8 @@
|
||||
{
|
||||
"name": "unescape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -6613,6 +6640,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -13045,8 +13081,8 @@
|
||||
{
|
||||
"name": "escape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -13104,6 +13140,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -13126,8 +13171,8 @@
|
||||
{
|
||||
"name": "unescape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -13185,6 +13230,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -18499,8 +18553,8 @@
|
||||
{
|
||||
"name": "escape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -18558,6 +18612,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -18580,8 +18643,8 @@
|
||||
{
|
||||
"name": "unescape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -18639,6 +18702,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -24439,8 +24511,8 @@
|
||||
{
|
||||
"name": "escape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -24498,6 +24570,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -24520,8 +24601,8 @@
|
||||
{
|
||||
"name": "unescape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -24579,6 +24660,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -29897,8 +29987,8 @@
|
||||
{
|
||||
"name": "escape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -29956,6 +30046,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -29978,8 +30077,8 @@
|
||||
{
|
||||
"name": "unescape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -30037,6 +30136,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -36318,8 +36426,8 @@
|
||||
{
|
||||
"name": "escape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -36377,6 +36485,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -36399,8 +36516,8 @@
|
||||
{
|
||||
"name": "unescape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -36458,6 +36575,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
|
||||
@@ -844,8 +844,8 @@
|
||||
{
|
||||
"name": "escape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -903,6 +903,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -925,8 +934,8 @@
|
||||
{
|
||||
"name": "unescape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -984,6 +993,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -5269,8 +5287,8 @@
|
||||
{
|
||||
"name": "escape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -5328,6 +5346,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -5350,8 +5377,8 @@
|
||||
{
|
||||
"name": "unescape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -5409,6 +5436,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -8594,8 +8630,8 @@
|
||||
{
|
||||
"name": "escape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -8653,6 +8689,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -8675,8 +8720,8 @@
|
||||
{
|
||||
"name": "unescape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -8734,6 +8779,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
|
||||
@@ -936,8 +936,8 @@
|
||||
{
|
||||
"name": "escape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -995,6 +995,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -1017,8 +1026,8 @@
|
||||
{
|
||||
"name": "unescape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -1076,6 +1085,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -4661,8 +4679,8 @@
|
||||
{
|
||||
"name": "escape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -4720,6 +4738,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -4742,8 +4769,8 @@
|
||||
{
|
||||
"name": "unescape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -4801,6 +4828,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -9492,8 +9528,8 @@
|
||||
{
|
||||
"name": "escape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -9551,6 +9587,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -9573,8 +9618,8 @@
|
||||
{
|
||||
"name": "unescape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -9632,6 +9677,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -13001,8 +13055,8 @@
|
||||
{
|
||||
"name": "escape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -13060,6 +13114,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
@@ -13082,8 +13145,8 @@
|
||||
{
|
||||
"name": "unescape",
|
||||
"kind": "function",
|
||||
"kindModifiers": "declare",
|
||||
"sortText": "15",
|
||||
"kindModifiers": "deprecated,declare",
|
||||
"sortText": "23",
|
||||
"displayParts": [
|
||||
{
|
||||
"text": "function",
|
||||
@@ -13141,6 +13204,15 @@
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"name": "deprecated",
|
||||
"text": [
|
||||
{
|
||||
"text": "A legacy feature for browser compatibility",
|
||||
"kind": "text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "param",
|
||||
"text": [
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -41,7 +41,7 @@ tests/cases/conformance/es6/destructuring/destructuringParameterDeclaration4.ts(
|
||||
a1(...array2); // Error parameter type is (number|string)[]
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name 'array2'. Did you mean 'Array'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1415:13: 'Array' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1447:13: 'Array' is declared here.
|
||||
a5([1, 2, "string", false, true]); // Error, parameter type is [any, any, [[any]]]
|
||||
~~~~~~~~
|
||||
!!! error TS2322: Type 'string' is not assignable to type '[[any]]'.
|
||||
|
||||
@@ -33,8 +33,8 @@ tests/cases/compiler/destructuringTuple.ts(11,60): error TS2769: No overload mat
|
||||
!!! error TS2769: Overload 2 of 3, '(callbackfn: (previousValue: [], currentValue: number, currentIndex: number, array: number[]) => [], initialValue: []): []', gave the following error.
|
||||
!!! error TS2769: Type 'never[]' is not assignable to type '[]'.
|
||||
!!! error TS2769: Target allows only 0 element(s) but source may have more.
|
||||
!!! related TS6502 /.ts/lib.es5.d.ts:1380:24: The expected type comes from the return type of this signature.
|
||||
!!! related TS6502 /.ts/lib.es5.d.ts:1386:27: The expected type comes from the return type of this signature.
|
||||
!!! related TS6502 /.ts/lib.es5.d.ts:1412:24: The expected type comes from the return type of this signature.
|
||||
!!! related TS6502 /.ts/lib.es5.d.ts:1418:27: The expected type comes from the return type of this signature.
|
||||
~~
|
||||
!!! error TS2769: No overload matches this call.
|
||||
!!! error TS2769: Overload 1 of 2, '(...items: ConcatArray<never>[]): never[]', gave the following error.
|
||||
|
||||
@@ -10,8 +10,8 @@ tests/cases/conformance/types/members/duplicateNumericIndexers.ts(24,5): error T
|
||||
tests/cases/conformance/types/members/duplicateNumericIndexers.ts(25,5): error TS2374: Duplicate index signature for type 'number'.
|
||||
tests/cases/conformance/types/members/duplicateNumericIndexers.ts(29,5): error TS2374: Duplicate index signature for type 'number'.
|
||||
tests/cases/conformance/types/members/duplicateNumericIndexers.ts(30,5): error TS2374: Duplicate index signature for type 'number'.
|
||||
lib.es5.d.ts(514,5): error TS2374: Duplicate index signature for type 'number'.
|
||||
lib.es5.d.ts(1401,5): error TS2374: Duplicate index signature for type 'number'.
|
||||
lib.es5.d.ts(517,5): error TS2374: Duplicate index signature for type 'number'.
|
||||
lib.es5.d.ts(1433,5): error TS2374: Duplicate index signature for type 'number'.
|
||||
|
||||
|
||||
==== tests/cases/conformance/types/members/duplicateNumericIndexers.ts (12 errors) ====
|
||||
|
||||
@@ -13,4 +13,4 @@ tests/cases/compiler/errorMessageOnObjectLiteralType.ts(6,8): error TS2551: Prop
|
||||
Object.getOwnPropertyNamess(null);
|
||||
~~~~~~~~~~~~~~~~~~~~
|
||||
!!! error TS2551: Property 'getOwnPropertyNamess' does not exist on type 'ObjectConstructor'. Did you mean 'getOwnPropertyNames'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:179:5: 'getOwnPropertyNames' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:181:5: 'getOwnPropertyNames' is declared here.
|
||||
@@ -66,20 +66,20 @@ tests/cases/compiler/externModule.ts(37,3): error TS2552: Cannot find name 'XDat
|
||||
var d=new XDate();
|
||||
~~~~~
|
||||
!!! error TS2552: Cannot find name 'XDate'. Did you mean 'Date'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:907:13: 'Date' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:910:13: 'Date' is declared here.
|
||||
d.getDay();
|
||||
d=new XDate(1978,2);
|
||||
~~~~~
|
||||
!!! error TS2552: Cannot find name 'XDate'. Did you mean 'Date'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:907:13: 'Date' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:910:13: 'Date' is declared here.
|
||||
d.getXDate();
|
||||
var n=XDate.parse("3/2/2004");
|
||||
~~~~~
|
||||
!!! error TS2552: Cannot find name 'XDate'. Did you mean 'Date'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:907:13: 'Date' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:910:13: 'Date' is declared here.
|
||||
n=XDate.UTC(1964,2,1);
|
||||
~~~~~
|
||||
!!! error TS2552: Cannot find name 'XDate'. Did you mean 'Date'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:907:13: 'Date' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:910:13: 'Date' is declared here.
|
||||
|
||||
|
||||
@@ -36,7 +36,7 @@ tests/cases/conformance/types/specifyingTypes/typeQueries/invalidTypeOfTarget.ts
|
||||
var x7: typeof function f() { };
|
||||
~~~~~~~~
|
||||
!!! error TS2552: Cannot find name 'function'. Did you mean 'Function'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:316:13: 'Function' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:318:13: 'Function' is declared here.
|
||||
~
|
||||
!!! error TS1005: ',' expected.
|
||||
~
|
||||
|
||||
@@ -7,5 +7,5 @@ tests/cases/compiler/mappedTypeWithAsClauseAndLateBoundProperty.ts(3,1): error T
|
||||
tgt2 = src2; // Should error
|
||||
~~~~
|
||||
!!! error TS2741: Property 'length' is missing in type '{ [x: number]: number; toString: () => string; toLocaleString: () => string; pop: () => number; push: (...items: number[]) => number; concat: { (...items: ConcatArray<number>[]): number[]; (...items: (number | ConcatArray<number>)[]): number[]; }; join: (separator?: string) => string; reverse: () => number[]; shift: () => number; slice: (start?: number, end?: number) => number[]; sort: (compareFn?: (a: number, b: number) => number) => number[]; splice: { (start: number, deleteCount?: number): number[]; (start: number, deleteCount: number, ...items: number[]): number[]; }; unshift: (...items: number[]) => number; indexOf: (searchElement: number, fromIndex?: number) => number; lastIndexOf: (searchElement: number, fromIndex?: number) => number; every: { <S extends number>(predicate: (value: number, index: number, array: number[]) => value is S, thisArg?: any): this is S[]; (predicate: (value: number, index: number, array: number[]) => unknown, thisArg?: any): boolean; }; some: (predicate: (value: number, index: number, array: number[]) => unknown, thisArg?: any) => boolean; forEach: (callbackfn: (value: number, index: number, array: number[]) => void, thisArg?: any) => void; map: <U>(callbackfn: (value: number, index: number, array: number[]) => U, thisArg?: any) => U[]; filter: { <S extends number>(predicate: (value: number, index: number, array: number[]) => value is S, thisArg?: any): S[]; (predicate: (value: number, index: number, array: number[]) => unknown, thisArg?: any): number[]; }; reduce: { (callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: number[]) => number): number; (callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: number[]) => number, initialValue: number): number; <U>(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: number[]) => U, initialValue: U): U; }; reduceRight: { (callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: number[]) => number): number; (callbackfn: (previousValue: number, currentValue: number, currentIndex: number, array: number[]) => number, initialValue: number): number; <U>(callbackfn: (previousValue: U, currentValue: number, currentIndex: number, array: number[]) => U, initialValue: U): U; }; find: { <S extends number>(predicate: (this: void, value: number, index: number, obj: number[]) => value is S, thisArg?: any): S; (predicate: (value: number, index: number, obj: number[]) => unknown, thisArg?: any): number; }; findIndex: (predicate: (value: number, index: number, obj: number[]) => unknown, thisArg?: any) => number; fill: (value: number, start?: number, end?: number) => number[]; copyWithin: (target: number, start: number, end?: number) => number[]; entries: () => IterableIterator<[number, number]>; keys: () => IterableIterator<number>; values: () => IterableIterator<number>; includes: (searchElement: number, fromIndex?: number) => boolean; flatMap: <U, This = undefined>(callback: (this: This, value: number, index: number, array: number[]) => U | readonly U[], thisArg?: This) => U[]; flat: <A, D extends number = 1>(this: A, depth?: D) => FlatArray<A, D>[]; [iterator]: () => IterableIterator<number>; [unscopables]: () => { copyWithin: boolean; entries: boolean; fill: boolean; find: boolean; findIndex: boolean; keys: boolean; values: boolean; }; }' but required in type 'number[]'.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1224:5: 'length' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1256:5: 'length' is declared here.
|
||||
|
||||
@@ -24,7 +24,7 @@ tests/cases/conformance/types/any/narrowExceptionVariableInCatchClause.ts(16,17)
|
||||
err.massage; // ERROR: Property 'massage' does not exist on type 'Error'
|
||||
~~~~~~~
|
||||
!!! error TS2551: Property 'massage' does not exist on type 'Error'. Did you mean 'message'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:974:5: 'message' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1006:5: 'message' is declared here.
|
||||
}
|
||||
|
||||
else {
|
||||
|
||||
@@ -22,7 +22,7 @@ tests/cases/conformance/types/any/narrowFromAnyWithInstanceof.ts(22,7): error TS
|
||||
x.mesage;
|
||||
~~~~~~
|
||||
!!! error TS2551: Property 'mesage' does not exist on type 'Error'. Did you mean 'message'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:974:5: 'message' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1006:5: 'message' is declared here.
|
||||
}
|
||||
|
||||
if (x instanceof Date) {
|
||||
@@ -30,6 +30,6 @@ tests/cases/conformance/types/any/narrowFromAnyWithInstanceof.ts(22,7): error TS
|
||||
x.getHuors();
|
||||
~~~~~~~~
|
||||
!!! error TS2551: Property 'getHuors' does not exist on type 'Date'. Did you mean 'getHours'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:763:5: 'getHours' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:766:5: 'getHours' is declared here.
|
||||
}
|
||||
|
||||
@@ -41,7 +41,7 @@ tests/cases/conformance/types/any/narrowFromAnyWithTypePredicate.ts(33,7): error
|
||||
x.mesage;
|
||||
~~~~~~
|
||||
!!! error TS2551: Property 'mesage' does not exist on type 'Error'. Did you mean 'message'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:974:5: 'message' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1006:5: 'message' is declared here.
|
||||
}
|
||||
|
||||
if (isDate(x)) {
|
||||
@@ -49,6 +49,6 @@ tests/cases/conformance/types/any/narrowFromAnyWithTypePredicate.ts(33,7): error
|
||||
x.getHuors();
|
||||
~~~~~~~~
|
||||
!!! error TS2551: Property 'getHuors' does not exist on type 'Date'. Did you mean 'getHours'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:763:5: 'getHours' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:766:5: 'getHours' is declared here.
|
||||
}
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
tests/cases/conformance/types/members/objectTypeHidingMembersOfExtendedObject.ts(10,5): error TS2411: Property 'data' of type 'A' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(122,5): error TS2411: Property 'constructor' of type 'Function' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(125,5): error TS2411: Property 'toString' of type '() => string' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(128,5): error TS2411: Property 'toLocaleString' of type '() => string' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(131,5): error TS2411: Property 'valueOf' of type '() => Object' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(137,5): error TS2411: Property 'hasOwnProperty' of type '(v: PropertyKey) => boolean' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(143,5): error TS2411: Property 'isPrototypeOf' of type '(v: Object) => boolean' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(149,5): error TS2411: Property 'propertyIsEnumerable' of type '(v: PropertyKey) => boolean' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(124,5): error TS2411: Property 'constructor' of type 'Function' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(127,5): error TS2411: Property 'toString' of type '() => string' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(130,5): error TS2411: Property 'toLocaleString' of type '() => string' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(133,5): error TS2411: Property 'valueOf' of type '() => Object' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(139,5): error TS2411: Property 'hasOwnProperty' of type '(v: PropertyKey) => boolean' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(145,5): error TS2411: Property 'isPrototypeOf' of type '(v: Object) => boolean' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(151,5): error TS2411: Property 'propertyIsEnumerable' of type '(v: PropertyKey) => boolean' is not assignable to 'string' index type 'Object'.
|
||||
|
||||
|
||||
==== tests/cases/conformance/types/members/objectTypeHidingMembersOfExtendedObject.ts (1 errors) ====
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
lib.es5.d.ts(122,5): error TS2411: Property 'constructor' of type 'Function' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(125,5): error TS2411: Property 'toString' of type '() => string' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(128,5): error TS2411: Property 'toLocaleString' of type '() => string' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(131,5): error TS2411: Property 'valueOf' of type '() => Object' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(137,5): error TS2411: Property 'hasOwnProperty' of type '(v: PropertyKey) => boolean' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(143,5): error TS2411: Property 'isPrototypeOf' of type '(v: Object) => boolean' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(149,5): error TS2411: Property 'propertyIsEnumerable' of type '(v: PropertyKey) => boolean' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(124,5): error TS2411: Property 'constructor' of type 'Function' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(127,5): error TS2411: Property 'toString' of type '() => string' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(130,5): error TS2411: Property 'toLocaleString' of type '() => string' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(133,5): error TS2411: Property 'valueOf' of type '() => Object' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(139,5): error TS2411: Property 'hasOwnProperty' of type '(v: PropertyKey) => boolean' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(145,5): error TS2411: Property 'isPrototypeOf' of type '(v: Object) => boolean' is not assignable to 'string' index type 'Object'.
|
||||
lib.es5.d.ts(151,5): error TS2411: Property 'propertyIsEnumerable' of type '(v: PropertyKey) => boolean' is not assignable to 'string' index type 'Object'.
|
||||
|
||||
|
||||
==== tests/cases/conformance/types/members/objectTypeWithStringIndexerHidingObjectIndexer.ts (0 errors) ====
|
||||
|
||||
@@ -11,4 +11,4 @@ tests/cases/conformance/parser/ecmascript5/Expressions/parserMemberAccessAfterPo
|
||||
!!! error TS1005: ';' expected.
|
||||
~~~~~~~~
|
||||
!!! error TS2552: Cannot find name 'toString'. Did you mean 'String'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:527:13: 'String' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:530:13: 'String' is declared here.
|
||||
@@ -19,7 +19,7 @@ tests/cases/conformance/parser/ecmascript5/parserS7.2_A1.5_T2.ts(20,3): error TS
|
||||
$ERROR('#1: eval("\\u00A0var x\\u00A0= 1\\u00A0"); x === 1. Actual: ' + (x));
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
|
||||
//CHECK#2
|
||||
@@ -28,7 +28,7 @@ tests/cases/conformance/parser/ecmascript5/parserS7.2_A1.5_T2.ts(20,3): error TS
|
||||
$ERROR('#2: var x = 1 ; x === 1. Actual: ' + (x));
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -21,7 +21,7 @@ tests/cases/conformance/parser/ecmascript5/parserS7.3_A1.1_T2.ts(17,3): error TS
|
||||
$ERROR('#1: var\\nx\\n=\\n1\\n; x === 1. Actual: ' + (x));
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
|
||||
|
||||
@@ -50,70 +50,70 @@ tests/cases/conformance/parser/ecmascript5/parserS7.6_A4.2_T1.ts(142,3): error T
|
||||
$ERROR('#А');
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
var \u0411 = 1;
|
||||
if (Б !== 1) {
|
||||
$ERROR('#Б');
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
var \u0412 = 1;
|
||||
if (В !== 1) {
|
||||
$ERROR('#В');
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
var \u0413 = 1;
|
||||
if (Г !== 1) {
|
||||
$ERROR('#Г');
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
var \u0414 = 1;
|
||||
if (Д !== 1) {
|
||||
$ERROR('#Д');
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
var \u0415 = 1;
|
||||
if (Е !== 1) {
|
||||
$ERROR('#Е');
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
var \u0416 = 1;
|
||||
if (Ж !== 1) {
|
||||
$ERROR('#Ж');
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
var \u0417 = 1;
|
||||
if (З !== 1) {
|
||||
$ERROR('#З');
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
var \u0418 = 1;
|
||||
if (И !== 1) {
|
||||
$ERROR('#И');
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
var \u0419 = 1;
|
||||
if (Й !== 1) {
|
||||
$ERROR('#Й');
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
var \u041A = 1;
|
||||
if (К !== 1) {
|
||||
|
||||
@@ -11,13 +11,13 @@ tests/cases/conformance/parser/ecmascript5/parserUnicode1.ts(10,5): error TS2552
|
||||
$ERROR('#6.1: var \\u0078x = 1; xx === 6. Actual: ' + (xx));
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
}
|
||||
catch (e) {
|
||||
$ERROR('#6.2: var \\u0078x = 1; xx === 6. Actual: ' + (xx));
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
|
||||
}
|
||||
@@ -447,7 +447,7 @@ tests/cases/compiler/promisePermutations.ts(160,21): error TS2769: No overload m
|
||||
!!! error TS2769: The last overload gave the following error.
|
||||
!!! error TS2769: Argument of type '(x: any) => IPromise<string>' is not assignable to parameter of type '(error: any) => Promise<number>'.
|
||||
!!! error TS2769: Property 'catch' is missing in type 'IPromise<string>' but required in type 'Promise<number>'.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1460:5: 'catch' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1492:5: 'catch' is declared here.
|
||||
!!! related TS2771 tests/cases/compiler/promisePermutations.ts:5:5: The last overload is declared here.
|
||||
var s10g = s10.then(testFunctionP, nIPromise, sIPromise).then(sPromise, sIPromise, sIPromise); // ok
|
||||
|
||||
|
||||
@@ -351,7 +351,7 @@ tests/cases/compiler/promisePermutations2.ts(159,21): error TS2345: Argument of
|
||||
~~~~~~~~~
|
||||
!!! error TS2345: Argument of type '(x: any) => IPromise<string>' is not assignable to parameter of type '(error: any) => Promise<number>'.
|
||||
!!! error TS2345: Property 'catch' is missing in type 'IPromise<string>' but required in type 'Promise<number>'.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1460:5: 'catch' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1492:5: 'catch' is declared here.
|
||||
var s10g = s10.then(testFunctionP, nIPromise, sIPromise).then(sPromise, sIPromise, sIPromise); // ok
|
||||
|
||||
var r11: IPromise<number>;
|
||||
|
||||
@@ -398,7 +398,7 @@ tests/cases/compiler/promisePermutations3.ts(165,21): error TS2345: Argument of
|
||||
!!! error TS2769: The last overload gave the following error.
|
||||
!!! error TS2769: Argument of type '(x: any) => IPromise<string>' is not assignable to parameter of type '(error: any) => Promise<number>'.
|
||||
!!! error TS2769: Property 'catch' is missing in type 'IPromise<string>' but required in type 'Promise<number>'.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1460:5: 'catch' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1492:5: 'catch' is declared here.
|
||||
!!! related TS2771 tests/cases/compiler/promisePermutations3.ts:7:5: The last overload is declared here.
|
||||
var s10g = s10.then(testFunctionP, nIPromise, sIPromise).then(sPromise, sIPromise, sIPromise); // ok
|
||||
|
||||
@@ -445,5 +445,5 @@ tests/cases/compiler/promisePermutations3.ts(165,21): error TS2345: Argument of
|
||||
~~~~~~~~~~~~~~~
|
||||
!!! error TS2345: Argument of type '{ <T>(x: T): IPromise<T>; <T>(x: T, y: T): Promise<T>; }' is not assignable to parameter of type '(value: (x: any) => any) => Promise<unknown>'.
|
||||
!!! error TS2345: Property 'catch' is missing in type 'IPromise<any>' but required in type 'Promise<unknown>'.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1460:5: 'catch' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1492:5: 'catch' is declared here.
|
||||
var s12c = s12.then(testFunction12P, testFunction12, testFunction12); // ok
|
||||
@@ -5,4 +5,4 @@ tests/cases/compiler/redefineArray.ts(1,1): error TS2741: Property 'isArray' is
|
||||
Array = function (n:number, s:string) {return n;};
|
||||
~~~~~
|
||||
!!! error TS2741: Property 'isArray' is missing in type '<T>(n: number, s: string) => number' but required in type 'ArrayConstructor'.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1411:5: 'isArray' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1443:5: 'isArray' is declared here.
|
||||
@@ -19,7 +19,7 @@ tests/cases/conformance/scanner/ecmascript5/scannerS7.2_A1.5_T2.ts(20,3): error
|
||||
$ERROR('#1: eval("\\u00A0var x\\u00A0= 1\\u00A0"); x === 1. Actual: ' + (x));
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
|
||||
//CHECK#2
|
||||
@@ -28,7 +28,7 @@ tests/cases/conformance/scanner/ecmascript5/scannerS7.2_A1.5_T2.ts(20,3): error
|
||||
$ERROR('#2: var x = 1 ; x === 1. Actual: ' + (x));
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -21,7 +21,7 @@ tests/cases/conformance/scanner/ecmascript5/scannerS7.3_A1.1_T2.ts(17,3): error
|
||||
$ERROR('#1: var\\nx\\n=\\n1\\n; x === 1. Actual: ' + (x));
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
|
||||
|
||||
@@ -50,70 +50,70 @@ tests/cases/conformance/scanner/ecmascript5/scannerS7.6_A4.2_T1.ts(142,3): error
|
||||
$ERROR('#А');
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
var \u0411 = 1;
|
||||
if (Б !== 1) {
|
||||
$ERROR('#Б');
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
var \u0412 = 1;
|
||||
if (В !== 1) {
|
||||
$ERROR('#В');
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
var \u0413 = 1;
|
||||
if (Г !== 1) {
|
||||
$ERROR('#Г');
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
var \u0414 = 1;
|
||||
if (Д !== 1) {
|
||||
$ERROR('#Д');
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
var \u0415 = 1;
|
||||
if (Е !== 1) {
|
||||
$ERROR('#Е');
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
var \u0416 = 1;
|
||||
if (Ж !== 1) {
|
||||
$ERROR('#Ж');
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
var \u0417 = 1;
|
||||
if (З !== 1) {
|
||||
$ERROR('#З');
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
var \u0418 = 1;
|
||||
if (И !== 1) {
|
||||
$ERROR('#И');
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
var \u0419 = 1;
|
||||
if (Й !== 1) {
|
||||
$ERROR('#Й');
|
||||
~~~~~~
|
||||
!!! error TS2552: Cannot find name '$ERROR'. Did you mean 'Error'?
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:984:13: 'Error' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:1016:13: 'Error' is declared here.
|
||||
}
|
||||
var \u041A = 1;
|
||||
if (К !== 1) {
|
||||
|
||||
@@ -38,7 +38,7 @@ tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolutio
|
||||
~~
|
||||
!!! error TS2345: Argument of type 'undefined[]' is not assignable to parameter of type 'TemplateStringsArray'.
|
||||
!!! error TS2345: Property 'raw' is missing in type 'undefined[]' but required in type 'TemplateStringsArray'.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:605:14: 'raw' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:608:14: 'raw' is declared here.
|
||||
!!! related TS2793 tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution1.ts:5:10: The call would have succeeded against this implementation, but implementation signatures of overloads are not externally visible.
|
||||
var b = foo([], 1); // string
|
||||
~~
|
||||
|
||||
+1
-1
@@ -38,7 +38,7 @@ tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolutio
|
||||
~~
|
||||
!!! error TS2345: Argument of type 'undefined[]' is not assignable to parameter of type 'TemplateStringsArray'.
|
||||
!!! error TS2345: Property 'raw' is missing in type 'undefined[]' but required in type 'TemplateStringsArray'.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:605:14: 'raw' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es5.d.ts:608:14: 'raw' is declared here.
|
||||
!!! related TS2793 tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution1_ES6.ts:5:10: The call would have succeeded against this implementation, but implementation signatures of overloads are not externally visible.
|
||||
var b = foo([], 1); // string
|
||||
~~
|
||||
|
||||
+1
-1
@@ -113,7 +113,7 @@ tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolutio
|
||||
fn5 `${ (n) => n.toFixed() }`; // will error; 'n' should have type 'string'.
|
||||
~~~~~~~
|
||||
!!! error TS2551: Property 'toFixed' does not exist on type 'string'. Did you mean 'fixed'?
|
||||
!!! related TS2728 /.ts/lib.es2015.core.d.ts:472:5: 'fixed' is declared here.
|
||||
!!! related TS2728 /.ts/lib.es2015.core.d.ts:485:5: 'fixed' is declared here.
|
||||
fn5 `${ (n) => n.substr(0) }`;
|
||||
|
||||
|
||||
@@ -8,5 +8,10 @@ verify.completions({
|
||||
completion.globalThisEntry,
|
||||
...completion.globalsVars,
|
||||
completion.undefinedVarEntry
|
||||
].map(e => ({ ...e, sortText: completion.SortText.LocationPriority }))
|
||||
].map(e => {
|
||||
if (e.sortText === completion.SortText.DeprecatedGlobalsOrKeywords) {
|
||||
return { ...e, sortText: completion.SortText.DeprecatedLocationPriority };
|
||||
}
|
||||
return { ...e, sortText: completion.SortText.LocationPriority };
|
||||
})
|
||||
});
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
////let v = 100;
|
||||
/////a/./**/
|
||||
|
||||
verify.completions({ marker: "", exact: ["exec", "test", "source", "global", "ignoreCase", "multiline", "lastIndex", "compile"] });
|
||||
verify.completions({ marker: "", exact: ["exec", "test", "source", "global", "ignoreCase", "multiline", "lastIndex", { name: "compile", sortText: completion.SortText.DeprecatedLocationPriority }] });
|
||||
|
||||
@@ -2,4 +2,4 @@
|
||||
|
||||
/////a/./**/
|
||||
|
||||
verify.completions({ marker: "", exact: ["exec", "test", "source", "global", "ignoreCase", "multiline", "lastIndex", "compile"] });
|
||||
verify.completions({ marker: "", exact: ["exec", "test", "source", "global", "ignoreCase", "multiline", "lastIndex", { name: "compile", sortText: completion.SortText.DeprecatedLocationPriority }] });
|
||||
|
||||
@@ -6,6 +6,6 @@ verify.completions({
|
||||
marker: "",
|
||||
exact: [
|
||||
"toString", "charAt", "charCodeAt", "concat", "indexOf", "lastIndexOf", "localeCompare", "match", "replace", "search", "slice",
|
||||
"split", "substring", "toLowerCase", "toLocaleLowerCase", "toUpperCase", "toLocaleUpperCase", "trim", "length", "substr", "valueOf",
|
||||
"split", "substring", "toLowerCase", "toLocaleLowerCase", "toUpperCase", "toLocaleUpperCase", "trim", "length", { name: "substr", sortText: completion.SortText.DeprecatedLocationPriority }, "valueOf",
|
||||
],
|
||||
});
|
||||
|
||||
@@ -0,0 +1,5 @@
|
||||
/// <reference path='fourslash.ts' />
|
||||
|
||||
//// var s = "foo"./*1*/
|
||||
|
||||
verify.baselineCompletions()
|
||||
@@ -17,4 +17,4 @@ verify.completions({ includes: { name: "toFixed", kind: "method", kindModifiers:
|
||||
|
||||
goTo.marker('b');
|
||||
edit.insert('.');
|
||||
verify.completions({ includes: { name: "substr", kind: "method", kindModifiers: "declare" } });
|
||||
verify.completions({ includes: { name: "substring", kind: "method", kindModifiers: "declare" } });
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
|
||||
goTo.marker('str');
|
||||
edit.insert('.');
|
||||
verify.completions({ includes: { name: "substr", kind: "method", kindModifiers: "declare" } });
|
||||
verify.completions({ includes: { name: "substring", kind: "method", kindModifiers: "declare" } });
|
||||
|
||||
goTo.marker('num');
|
||||
edit.insert('.');
|
||||
|
||||
@@ -26,4 +26,4 @@ edit.backspace();
|
||||
|
||||
goTo.marker('2');
|
||||
edit.insert('.');
|
||||
verify.completions({ includes: { name: "substr", kind: "method", kindModifiers: "declare" } });
|
||||
verify.completions({ includes: { name: "substring", kind: "method", kindModifiers: "declare" } });
|
||||
|
||||
@@ -30,7 +30,7 @@ verify.completions({
|
||||
});
|
||||
|
||||
edit.insert('bar.');
|
||||
verify.completions({ includes: ["substr"] });
|
||||
verify.completions({ includes: ["substring"] });
|
||||
edit.backspace('bar.'.length);
|
||||
|
||||
edit.insert('union.');
|
||||
|
||||
@@ -18,4 +18,4 @@
|
||||
|
||||
goTo.marker();
|
||||
edit.insert('.baz.');
|
||||
verify.completions({ includes: { name: "substr", kind: "method", kindModifiers: "declare" } });
|
||||
verify.completions({ includes: { name: "substring", kind: "method", kindModifiers: "declare" } });
|
||||
|
||||
@@ -34,10 +34,10 @@ edit.backspace();
|
||||
// Members of the invocation of a class method (1)
|
||||
goTo.marker('3');
|
||||
edit.insert('.');
|
||||
verify.completions({ includes: "toFixed", excludes: "substr" });
|
||||
verify.completions({ includes: "toFixed", excludes: "substring" });
|
||||
edit.backspace();
|
||||
|
||||
// Members of the invocation of a class method (2)
|
||||
goTo.marker('4');
|
||||
edit.insert('.');
|
||||
verify.completions({ includes: "substr", excludes: "toFixed" });
|
||||
verify.completions({ includes: "substring", excludes: "toFixed" });
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
|
||||
goTo.marker('1');
|
||||
edit.insert('.');
|
||||
verify.completions({ includes: { name: "substr", kind: "method", kindModifiers: "declare" } });
|
||||
verify.completions({ includes: { name: "substring", kind: "method", kindModifiers: "declare" } });
|
||||
edit.backspace();
|
||||
|
||||
goTo.marker('2');
|
||||
|
||||
Reference in New Issue
Block a user