slige/compiler/util.ts
2025-01-22 22:40:29 +01:00

10 lines
231 B
TypeScript

export function todo<T>(msg?: string): T {
class NotImplemented extends Error {}
throw new NotImplemented(msg);
}
export function exhausted(_: never) {
class Unexhausted extends Error {}
throw new Unexhausted();
}