aboutsummaryrefslogtreecommitdiff
path: root/new-luxc/source/luxc/generator/common.jvm.lux
diff options
context:
space:
mode:
Diffstat (limited to 'new-luxc/source/luxc/generator/common.jvm.lux')
-rw-r--r--new-luxc/source/luxc/generator/common.jvm.lux24
1 files changed, 12 insertions, 12 deletions
diff --git a/new-luxc/source/luxc/generator/common.jvm.lux b/new-luxc/source/luxc/generator/common.jvm.lux
index 054d11098..150e68e4f 100644
--- a/new-luxc/source/luxc/generator/common.jvm.lux
+++ b/new-luxc/source/luxc/generator/common.jvm.lux
@@ -3,7 +3,7 @@
(lux (control ["ex" exception #+ exception:])
[io]
(concurrency ["A" atom])
- (data ["R" result]
+ (data ["e" error]
(coll ["d" dict]))
[host])
(luxc (generator (host ["$" jvm]
@@ -35,27 +35,27 @@
(exception: No-Function-Being-Compiled)
(def: #export (store-class name byte-code)
- (-> Text Bytecode (Lux Unit))
+ (-> Text Bytecode (Meta Unit))
(;function [compiler]
(let [store (|> (get@ #;host compiler)
(:! Host)
(get@ #store))]
(if (d;contains? name (|> store A;get io;run))
(ex;throw Class-Already-Stored name)
- (#R;Success [compiler (io;run (A;update (d;put name byte-code) store))])
+ (#e;Success [compiler (io;run (A;update (d;put name byte-code) store))])
))))
(def: #export (load-class name)
- (-> Text (Lux (Class Object)))
+ (-> Text (Meta (Class Object)))
(;function [compiler]
(let [host (:! Host (get@ #;host compiler))
store (|> host (get@ #store) A;get io;run)]
(if (d;contains? name store)
- (#R;Success [compiler (ClassLoader.loadClass [name] (get@ #loader host))])
+ (#e;Success [compiler (ClassLoader.loadClass [name] (get@ #loader host))])
(ex;throw Unknown-Class name)))))
(def: #export (with-function class expr)
- (All [a] (-> Text (Lux a) (Lux a)))
+ (All [a] (-> Text (Meta a) (Meta a)))
(;function [compiler]
(let [host (:! Host (get@ #;host compiler))
old-function-class (get@ #function-class host)]
@@ -64,19 +64,19 @@
(#;Some class)
host))
compiler))
- (#R;Success [compiler' output])
- (#R;Success [(update@ #;host
+ (#e;Success [compiler' output])
+ (#e;Success [(update@ #;host
(|>. (:! Host)
(set@ #function-class old-function-class)
(:! Void))
compiler')
output])
- (#R;Error error)
- (#R;Error error)))))
+ (#e;Error error)
+ (#e;Error error)))))
(def: #export function
- (Lux Text)
+ (Meta Text)
(;function [compiler]
(let [host (:! Host (get@ #;host compiler))]
(case (get@ #function-class host)
@@ -84,6 +84,6 @@
(ex;throw No-Function-Being-Compiled "")
(#;Some function-class)
- (#R;Success [compiler function-class])))))
+ (#e;Success [compiler function-class])))))
(def: #export bytecode-version Int Opcodes.V1_6)