File tree Expand file tree Collapse file tree 1 file changed +0
-16
lines changed Expand file tree Collapse file tree 1 file changed +0
-16
lines changed Original file line number Diff line number Diff line change @@ -468,22 +468,6 @@ export function assertNotNullish<T>(
468468 }
469469}
470470
471- function intMax ( args : bigint [ ] ) : bigint ;
472- function intMax ( args : number [ ] ) : number ;
473- function intMax ( args : bigint [ ] | number [ ] ) : any {
474- if ( args . length === 0 ) {
475- throw new Error ( `empty array not supported in intMax` ) ;
476- } else if ( typeof args [ 0 ] === 'bigint' ) {
477- return ( args as bigint [ ] ) . reduce ( ( m , e ) => ( e > m ? e : m ) ) ;
478- } else if ( typeof args [ 0 ] === 'number' ) {
479- return Math . max ( ...( args as number [ ] ) ) ;
480- } else {
481- // eslint-disable-next-line @typescript-eslint/ban-types
482- throw new Error ( `Unsupported type for intMax: ${ ( args [ 0 ] as object ) . constructor . name } ` ) ;
483- }
484- }
485- export { intMax } ;
486-
487471export class BigIntMath {
488472 static abs ( a : bigint ) : bigint {
489473 return a < 0n ? - a : a ;
You can’t perform that action at this time.
0 commit comments