blob: 08cb33505dc0d907dbdc37a00ddf289f0e2c9ef1 [file] [log] [blame]
Leo Repp58b9f112021-11-22 11:57:47 +01001export as namespace stable;
2export = stable;
3
4type Comparator<T> = ((a : T, b : T)=>boolean) | ((a: T, b : T)=>number);
5
6declare function stable<T>(array : T[], comparator? : Comparator<T>) : T[];
7declare namespace stable {
8 export function inplace<T>(array: T[], comparator? : Comparator<T>) : T[];
9}