blob: 229ec8804c84eb4a1f10fba76b8c68306f8dff6d (
plain)
1
2
3
4
5
6
7
8
9
10
|
class NebPanic(BaseException):
pass
class InterpretPanic(NebPanic):
def __init__(self, sym, msg, arg=None):
big_message = f"[{sym.line}] '{sym.name}': {msg}"
if arg is not None:
big_message += f" (got {arg})"
super().__init__(big_message)
|