From ce87687bbc9586ae0ecb1ea646596a76410ef568 Mon Sep 17 00:00:00 2001 From: henesy Date: Mon, 11 Mar 2019 22:32:42 -0500 Subject: add beginnings of exceptions example --- Exceptions/exceptions.b | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 Exceptions/exceptions.b (limited to 'Exceptions/exceptions.b') diff --git a/Exceptions/exceptions.b b/Exceptions/exceptions.b new file mode 100644 index 0000000..336c448 --- /dev/null +++ b/Exceptions/exceptions.b @@ -0,0 +1,21 @@ +implement Exceptions; + +include "sys.m"; +include "draw.m"; + +sys: Sys; +print: import sys; + +Exceptions: module { + init: fn(nil: ref Draw->Context, nil: list of string); +}; + +init(nil: ref Draw->Context, nil: list of string) { + sys = load Sys Sys->PATH; + + + + raise "going down!"; + + exit; +} -- cgit v1.2.3