aboutsummaryrefslogtreecommitdiff
path: root/lib/SATS
diff options
context:
space:
mode:
authorXander <xander@biltopia.org>2023-08-08 22:17:40 +0200
committerXander <xander@biltopia.org>2023-08-08 22:17:40 +0200
commit245f24890cd78304cf0fd397dda8e72b0a7fbe6b (patch)
tree7210e4d4489b7281fb9213745b4776846402103b /lib/SATS
parentcef3f6bdddfe768e7a1a84edcec76c11c1634941 (diff)
downloadats-os-245f24890cd78304cf0fd397dda8e72b0a7fbe6b.tar.xz
ats-os-245f24890cd78304cf0fd397dda8e72b0a7fbe6b.zip
more refactoring and implemented exec_init
Diffstat (limited to 'lib/SATS')
-rw-r--r--lib/SATS/init.sats3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/SATS/init.sats b/lib/SATS/init.sats
index 69c6c9a..9fe8581 100644
--- a/lib/SATS/init.sats
+++ b/lib/SATS/init.sats
@@ -6,6 +6,9 @@ fun {vt:viewt@ype} uninitialized (v : opt(vt,false)): initializable vt
fun {vt:viewt@ype} exec_void (r: ref(initializable vt)):<!refwrt> void
fun {vt:viewt@ype} exec_void$fwork (v : &vt):<!wrt> void
+// function will also inialize if not yet initalized
+fun {vt:viewt@ype} exec_init (r: ref(initializable vt)):<!refwrt> void
+
fun {vt:viewt@ype} {a: t@ype} exec (r: ref(initializable vt)):<!refwrt> a
fun {vt:viewt@ype} {a: t@ype} exec$fwork (v : &vt):<!wrt> a