slige/compiler/util.ts

10 lines
231 B
TypeScript
Raw Normal View History

2025-01-22 21:40:29 +00:00
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();
}