mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-06-16 07:13:43 -05:00
Update parseInt parameter name and jsdoc (#42756)
* feat(lib): improve parseInt type definition and docstring * Accepted baselines * update tests
This commit is contained in:
4
src/lib/es2015.core.d.ts
vendored
4
src/lib/es2015.core.d.ts
vendored
@@ -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.
|
||||
*/
|
||||
|
||||
6
src/lib/es5.d.ts
vendored
6
src/lib/es5.d.ts
vendored
@@ -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.
|
||||
|
||||
Reference in New Issue
Block a user