diff options
Diffstat (limited to 'kernel/prelude/DATS/print.dats')
-rw-r--r-- | kernel/prelude/DATS/print.dats | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/kernel/prelude/DATS/print.dats b/kernel/prelude/DATS/print.dats index ac864ad..c6907a1 100644 --- a/kernel/prelude/DATS/print.dats +++ b/kernel/prelude/DATS/print.dats @@ -4,14 +4,15 @@ staload "lib/SATS/writer.sats" staload "lib/DATS/itoa.dats" +staload "lib/SATS/panic.sats" staload UN = "prelude/SATS/unsafe.sats" extern fun print_newline() :<!wrt> void implement print_newline() = put_string("\n") -extern fun assert_errmsg(b: bool, msg: string) :<!wrt> void -implement assert_errmsg(b,msg) = if (~b) then put_string(msg) +extern fun assert_errmsg(b: bool, string) :<> void +implement assert_errmsg(b,loc) = if (~b) then panic_loc(loc,"Assert fail") extern fun print_int (n : int) :<!wrt> void implement print_int(n) = put_string(itoa(n,10)) |