diff --git a/src/lib/es2015.core.d.ts b/src/lib/es2015.core.d.ts index 032a7afc0ecf9..b202f3e01decd 100644 --- a/src/lib/es2015.core.d.ts +++ b/src/lib/es2015.core.d.ts @@ -248,8 +248,8 @@ interface NumberConstructor { /** * Converts A string to an integer. - * @param s A string to convert into a number. - * @param radix A value between 2 and 36 that specifies the base of the number in numString. + * @param string A string to convert into a number. + * @param radix A value between 2 and 36 that specifies the base of the number in `string`. * If this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal. * All other strings are considered decimal. */ diff --git a/src/lib/es5.d.ts b/src/lib/es5.d.ts index 98bb0ee676e5d..b8c0c0d6bda39 100644 --- a/src/lib/es5.d.ts +++ b/src/lib/es5.d.ts @@ -13,12 +13,12 @@ declare function eval(x: string): any; /** * Converts a string to an integer. - * @param s A string to convert into a number. - * @param radix A value between 2 and 36 that specifies the base of the number in numString. + * @param string A string to convert into a number. + * @param radix A value between 2 and 36 that specifies the base of the number in `string`. * If this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal. * All other strings are considered decimal. */ -declare function parseInt(s: string, radix?: number): number; +declare function parseInt(string: string, radix?: number): number; /** * Converts a string to a floating-point number. diff --git a/tests/baselines/reference/abstractPropertyInConstructor.types b/tests/baselines/reference/abstractPropertyInConstructor.types index 8c8bd40aff09c..e63737006c6bf 100644 --- a/tests/baselines/reference/abstractPropertyInConstructor.types +++ b/tests/baselines/reference/abstractPropertyInConstructor.types @@ -12,7 +12,7 @@ abstract class AbstractClass { >this : this >method : (num: number) => void >parseInt(str) : number ->parseInt : (s: string, radix?: number) => number +>parseInt : (string: string, radix?: number) => number >str : string let val = this.prop.toLowerCase(); diff --git a/tests/baselines/reference/completionsCommentsClass.baseline b/tests/baselines/reference/completionsCommentsClass.baseline index 7b6471500b37e..8348d644b7f3f 100644 --- a/tests/baselines/reference/completionsCommentsClass.baseline +++ b/tests/baselines/reference/completionsCommentsClass.baseline @@ -122,7 +122,7 @@ "kind": "punctuation" }, { - "text": "s", + "text": "string", "kind": "parameterName" }, { @@ -191,11 +191,11 @@ "tags": [ { "name": "param", - "text": "s A string to convert into a number." + "text": "string A string to convert into a number." }, { "name": "param", - "text": "radix A value between 2 and 36 that specifies the base of the number in numString.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." + "text": "radix A value between 2 and 36 that specifies the base of the number in `string`.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." } ] }, diff --git a/tests/baselines/reference/completionsCommentsClassMembers.baseline b/tests/baselines/reference/completionsCommentsClassMembers.baseline index d2a5cf992bfa8..f5ab0284565e8 100644 --- a/tests/baselines/reference/completionsCommentsClassMembers.baseline +++ b/tests/baselines/reference/completionsCommentsClassMembers.baseline @@ -9061,7 +9061,7 @@ "kind": "punctuation" }, { - "text": "s", + "text": "string", "kind": "parameterName" }, { @@ -9130,11 +9130,11 @@ "tags": [ { "name": "param", - "text": "s A string to convert into a number." + "text": "string A string to convert into a number." }, { "name": "param", - "text": "radix A value between 2 and 36 that specifies the base of the number in numString.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." + "text": "radix A value between 2 and 36 that specifies the base of the number in `string`.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." } ] }, @@ -14051,7 +14051,7 @@ "kind": "punctuation" }, { - "text": "s", + "text": "string", "kind": "parameterName" }, { @@ -14120,11 +14120,11 @@ "tags": [ { "name": "param", - "text": "s A string to convert into a number." + "text": "string A string to convert into a number." }, { "name": "param", - "text": "radix A value between 2 and 36 that specifies the base of the number in numString.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." + "text": "radix A value between 2 and 36 that specifies the base of the number in `string`.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." } ] }, @@ -22449,7 +22449,7 @@ "kind": "punctuation" }, { - "text": "s", + "text": "string", "kind": "parameterName" }, { @@ -22518,11 +22518,11 @@ "tags": [ { "name": "param", - "text": "s A string to convert into a number." + "text": "string A string to convert into a number." }, { "name": "param", - "text": "radix A value between 2 and 36 that specifies the base of the number in numString.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." + "text": "radix A value between 2 and 36 that specifies the base of the number in `string`.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." } ] }, @@ -26299,7 +26299,7 @@ "kind": "punctuation" }, { - "text": "s", + "text": "string", "kind": "parameterName" }, { @@ -26368,11 +26368,11 @@ "tags": [ { "name": "param", - "text": "s A string to convert into a number." + "text": "string A string to convert into a number." }, { "name": "param", - "text": "radix A value between 2 and 36 that specifies the base of the number in numString.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." + "text": "radix A value between 2 and 36 that specifies the base of the number in `string`.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." } ] }, @@ -30149,7 +30149,7 @@ "kind": "punctuation" }, { - "text": "s", + "text": "string", "kind": "parameterName" }, { @@ -30218,11 +30218,11 @@ "tags": [ { "name": "param", - "text": "s A string to convert into a number." + "text": "string A string to convert into a number." }, { "name": "param", - "text": "radix A value between 2 and 36 that specifies the base of the number in numString.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." + "text": "radix A value between 2 and 36 that specifies the base of the number in `string`.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." } ] }, @@ -33999,7 +33999,7 @@ "kind": "punctuation" }, { - "text": "s", + "text": "string", "kind": "parameterName" }, { @@ -34068,11 +34068,11 @@ "tags": [ { "name": "param", - "text": "s A string to convert into a number." + "text": "string A string to convert into a number." }, { "name": "param", - "text": "radix A value between 2 and 36 that specifies the base of the number in numString.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." + "text": "radix A value between 2 and 36 that specifies the base of the number in `string`.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." } ] }, @@ -37849,7 +37849,7 @@ "kind": "punctuation" }, { - "text": "s", + "text": "string", "kind": "parameterName" }, { @@ -37918,11 +37918,11 @@ "tags": [ { "name": "param", - "text": "s A string to convert into a number." + "text": "string A string to convert into a number." }, { "name": "param", - "text": "radix A value between 2 and 36 that specifies the base of the number in numString.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." + "text": "radix A value between 2 and 36 that specifies the base of the number in `string`.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." } ] }, @@ -41699,7 +41699,7 @@ "kind": "punctuation" }, { - "text": "s", + "text": "string", "kind": "parameterName" }, { @@ -41768,11 +41768,11 @@ "tags": [ { "name": "param", - "text": "s A string to convert into a number." + "text": "string A string to convert into a number." }, { "name": "param", - "text": "radix A value between 2 and 36 that specifies the base of the number in numString.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." + "text": "radix A value between 2 and 36 that specifies the base of the number in `string`.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." } ] }, diff --git a/tests/baselines/reference/completionsCommentsCommentParsing.baseline b/tests/baselines/reference/completionsCommentsCommentParsing.baseline index 3c316e03108d7..ebc1f3ab60986 100644 --- a/tests/baselines/reference/completionsCommentsCommentParsing.baseline +++ b/tests/baselines/reference/completionsCommentsCommentParsing.baseline @@ -122,7 +122,7 @@ "kind": "punctuation" }, { - "text": "s", + "text": "string", "kind": "parameterName" }, { @@ -191,11 +191,11 @@ "tags": [ { "name": "param", - "text": "s A string to convert into a number." + "text": "string A string to convert into a number." }, { "name": "param", - "text": "radix A value between 2 and 36 that specifies the base of the number in numString.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." + "text": "radix A value between 2 and 36 that specifies the base of the number in `string`.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." } ] }, @@ -5358,7 +5358,7 @@ "kind": "punctuation" }, { - "text": "s", + "text": "string", "kind": "parameterName" }, { @@ -5427,11 +5427,11 @@ "tags": [ { "name": "param", - "text": "s A string to convert into a number." + "text": "string A string to convert into a number." }, { "name": "param", - "text": "radix A value between 2 and 36 that specifies the base of the number in numString.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." + "text": "radix A value between 2 and 36 that specifies the base of the number in `string`.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." } ] }, @@ -11327,7 +11327,7 @@ "kind": "punctuation" }, { - "text": "s", + "text": "string", "kind": "parameterName" }, { @@ -11396,11 +11396,11 @@ "tags": [ { "name": "param", - "text": "s A string to convert into a number." + "text": "string A string to convert into a number." }, { "name": "param", - "text": "radix A value between 2 and 36 that specifies the base of the number in numString.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." + "text": "radix A value between 2 and 36 that specifies the base of the number in `string`.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." } ] }, @@ -16347,7 +16347,7 @@ "kind": "punctuation" }, { - "text": "s", + "text": "string", "kind": "parameterName" }, { @@ -16416,11 +16416,11 @@ "tags": [ { "name": "param", - "text": "s A string to convert into a number." + "text": "string A string to convert into a number." }, { "name": "param", - "text": "radix A value between 2 and 36 that specifies the base of the number in numString.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." + "text": "radix A value between 2 and 36 that specifies the base of the number in `string`.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." } ] }, @@ -21345,7 +21345,7 @@ "kind": "punctuation" }, { - "text": "s", + "text": "string", "kind": "parameterName" }, { @@ -21414,11 +21414,11 @@ "tags": [ { "name": "param", - "text": "s A string to convert into a number." + "text": "string A string to convert into a number." }, { "name": "param", - "text": "radix A value between 2 and 36 that specifies the base of the number in numString.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." + "text": "radix A value between 2 and 36 that specifies the base of the number in `string`.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." } ] }, @@ -26593,7 +26593,7 @@ "kind": "punctuation" }, { - "text": "s", + "text": "string", "kind": "parameterName" }, { @@ -26662,11 +26662,11 @@ "tags": [ { "name": "param", - "text": "s A string to convert into a number." + "text": "string A string to convert into a number." }, { "name": "param", - "text": "radix A value between 2 and 36 that specifies the base of the number in numString.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." + "text": "radix A value between 2 and 36 that specifies the base of the number in `string`.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." } ] }, @@ -32562,7 +32562,7 @@ "kind": "punctuation" }, { - "text": "s", + "text": "string", "kind": "parameterName" }, { @@ -32631,11 +32631,11 @@ "tags": [ { "name": "param", - "text": "s A string to convert into a number." + "text": "string A string to convert into a number." }, { "name": "param", - "text": "radix A value between 2 and 36 that specifies the base of the number in numString.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." + "text": "radix A value between 2 and 36 that specifies the base of the number in `string`.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." } ] }, diff --git a/tests/baselines/reference/completionsCommentsFunctionDeclaration.baseline b/tests/baselines/reference/completionsCommentsFunctionDeclaration.baseline index de8e747d5d953..81d93102a3209 100644 --- a/tests/baselines/reference/completionsCommentsFunctionDeclaration.baseline +++ b/tests/baselines/reference/completionsCommentsFunctionDeclaration.baseline @@ -122,7 +122,7 @@ "kind": "punctuation" }, { - "text": "s", + "text": "string", "kind": "parameterName" }, { @@ -191,11 +191,11 @@ "tags": [ { "name": "param", - "text": "s A string to convert into a number." + "text": "string A string to convert into a number." }, { "name": "param", - "text": "radix A value between 2 and 36 that specifies the base of the number in numString.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." + "text": "radix A value between 2 and 36 that specifies the base of the number in `string`.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." } ] }, @@ -4461,7 +4461,7 @@ "kind": "punctuation" }, { - "text": "s", + "text": "string", "kind": "parameterName" }, { @@ -4530,11 +4530,11 @@ "tags": [ { "name": "param", - "text": "s A string to convert into a number." + "text": "string A string to convert into a number." }, { "name": "param", - "text": "radix A value between 2 and 36 that specifies the base of the number in numString.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." + "text": "radix A value between 2 and 36 that specifies the base of the number in `string`.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." } ] }, @@ -7635,7 +7635,7 @@ "kind": "punctuation" }, { - "text": "s", + "text": "string", "kind": "parameterName" }, { @@ -7704,11 +7704,11 @@ "tags": [ { "name": "param", - "text": "s A string to convert into a number." + "text": "string A string to convert into a number." }, { "name": "param", - "text": "radix A value between 2 and 36 that specifies the base of the number in numString.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." + "text": "radix A value between 2 and 36 that specifies the base of the number in `string`.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." } ] }, diff --git a/tests/baselines/reference/completionsCommentsFunctionExpression.baseline b/tests/baselines/reference/completionsCommentsFunctionExpression.baseline index 8c8c35f524aa8..bc2ddeff0c2cf 100644 --- a/tests/baselines/reference/completionsCommentsFunctionExpression.baseline +++ b/tests/baselines/reference/completionsCommentsFunctionExpression.baseline @@ -122,7 +122,7 @@ "kind": "punctuation" }, { - "text": "s", + "text": "string", "kind": "parameterName" }, { @@ -191,11 +191,11 @@ "tags": [ { "name": "param", - "text": "s A string to convert into a number." + "text": "string A string to convert into a number." }, { "name": "param", - "text": "radix A value between 2 and 36 that specifies the base of the number in numString.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." + "text": "radix A value between 2 and 36 that specifies the base of the number in `string`.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." } ] }, @@ -3667,7 +3667,7 @@ "kind": "punctuation" }, { - "text": "s", + "text": "string", "kind": "parameterName" }, { @@ -3736,11 +3736,11 @@ "tags": [ { "name": "param", - "text": "s A string to convert into a number." + "text": "string A string to convert into a number." }, { "name": "param", - "text": "radix A value between 2 and 36 that specifies the base of the number in numString.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." + "text": "radix A value between 2 and 36 that specifies the base of the number in `string`.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." } ] }, @@ -8167,7 +8167,7 @@ "kind": "punctuation" }, { - "text": "s", + "text": "string", "kind": "parameterName" }, { @@ -8236,11 +8236,11 @@ "tags": [ { "name": "param", - "text": "s A string to convert into a number." + "text": "string A string to convert into a number." }, { "name": "param", - "text": "radix A value between 2 and 36 that specifies the base of the number in numString.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." + "text": "radix A value between 2 and 36 that specifies the base of the number in `string`.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." } ] }, @@ -11712,7 +11712,7 @@ "kind": "punctuation" }, { - "text": "s", + "text": "string", "kind": "parameterName" }, { @@ -11781,11 +11781,11 @@ "tags": [ { "name": "param", - "text": "s A string to convert into a number." + "text": "string A string to convert into a number." }, { "name": "param", - "text": "radix A value between 2 and 36 that specifies the base of the number in numString.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." + "text": "radix A value between 2 and 36 that specifies the base of the number in `string`.\r\nIf this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.\r\nAll other strings are considered decimal." } ] }, diff --git a/tests/baselines/reference/externFunc.types b/tests/baselines/reference/externFunc.types index 5cda004d4cf55..5e758c05bede0 100644 --- a/tests/baselines/reference/externFunc.types +++ b/tests/baselines/reference/externFunc.types @@ -1,10 +1,10 @@ === tests/cases/compiler/externFunc.ts === declare function parseInt(s:string):number; ->parseInt : { (s: string, radix?: number): number; (s: string): number; } +>parseInt : { (string: string, radix?: number): number; (s: string): number; } >s : string parseInt("2"); >parseInt("2") : number ->parseInt : { (s: string, radix?: number): number; (s: string): number; } +>parseInt : { (string: string, radix?: number): number; (s: string): number; } >"2" : "2" diff --git a/tests/baselines/reference/parserRealSource11.types b/tests/baselines/reference/parserRealSource11.types index 133ee1fc27a66..7e8b3431e63a2 100644 --- a/tests/baselines/reference/parserRealSource11.types +++ b/tests/baselines/reference/parserRealSource11.types @@ -733,7 +733,7 @@ module TypeScript { var charCode = parseInt(name.substr(i + 2, 4), 16); >charCode : number >parseInt(name.substr(i + 2, 4), 16) : number ->parseInt : (s: string, radix?: number) => number +>parseInt : (string: string, radix?: number) => number >name.substr(i + 2, 4) : string >name.substr : (from: number, length?: number) => string >name : string