aboutsummaryrefslogtreecommitdiff
path: root/new-luxc/source/luxc/generator/function.jvm.lux
diff options
context:
space:
mode:
Diffstat (limited to 'new-luxc/source/luxc/generator/function.jvm.lux')
-rw-r--r--new-luxc/source/luxc/generator/function.jvm.lux19
1 files changed, 10 insertions, 9 deletions
diff --git a/new-luxc/source/luxc/generator/function.jvm.lux b/new-luxc/source/luxc/generator/function.jvm.lux
index 97d3a7c91..ce92b9010 100644
--- a/new-luxc/source/luxc/generator/function.jvm.lux
+++ b/new-luxc/source/luxc/generator/function.jvm.lux
@@ -5,6 +5,7 @@
(coll [list "list/" Functor<List> Monoid<List>]))
[meta])
(luxc ["&" base]
+ [";L" host]
(lang ["la" analysis]
["ls" synthesis])
["&;" analyser]
@@ -58,7 +59,7 @@
(def: get-amount-of-partialsI
$;Inst
(|>. ($i;ALOAD +0)
- ($i;GETFIELD &runtime;function-class &runtime;partials-field $t;int)))
+ ($i;GETFIELD hostL;function-class &runtime;partials-field $t;int)))
(def: (load-fieldI class field)
(-> Text Text $;Inst)
@@ -77,9 +78,9 @@
later-applysI (if (n.> &runtime;num-apply-variants amount)
(applysI (n.+ &runtime;num-apply-variants start) (n.- &runtime;num-apply-variants amount))
id)]
- (|>. ($i;CHECKCAST &runtime;function-class)
+ (|>. ($i;CHECKCAST hostL;function-class)
(inputsI start max-args)
- ($i;INVOKEVIRTUAL &runtime;function-class &runtime;apply-method (&runtime;apply-signature max-args) false)
+ ($i;INVOKEVIRTUAL hostL;function-class &runtime;apply-method (&runtime;apply-signature max-args) false)
later-applysI)))
(def: (inc-intI by)
@@ -167,9 +168,9 @@
(-> ls;Arity Nat $;Inst)
(if (n.= +1 arity)
(|>. ($i;int 0)
- ($i;INVOKESPECIAL &runtime;function-class "<init>" function-init-method false))
+ ($i;INVOKESPECIAL hostL;function-class "<init>" function-init-method false))
(|>. ($i;ILOAD (n.inc env-size))
- ($i;INVOKESPECIAL &runtime;function-class "<init>" function-init-method false))))
+ ($i;INVOKESPECIAL hostL;function-class "<init>" function-init-method false))))
(def: (with-init class env arity)
(-> Text (List ls;Variable) ls;Arity $;Def)
@@ -262,7 +263,7 @@
($i;TABLESWITCH 0 (|> num-partials n.dec nat-to-int)
@default @labels)
casesI
- ($i;INVOKESTATIC &runtime;runtime-class "apply_fail" ($t;method (list) #;None (list)) false)
+ ($i;INVOKESTATIC hostL;runtime-class "apply_fail" ($t;method (list) #;None (list)) false)
$i;NULL
$i;ARETURN
))))
@@ -306,7 +307,7 @@
_ (&common;store-class function-class
($d;class #$;V1.6 #$;Public $;finalC
function-class (list)
- ($;simple-class &runtime;function-class) (list)
+ ($;simple-class hostL;function-class) (list)
functionD))]
(wrap instanceI)))
@@ -326,9 +327,9 @@
argsI (monad;map @ generate argsS)
#let [applyI (|> (segment &runtime;num-apply-variants argsI)
(list/map (function [chunkI+]
- (|>. ($i;CHECKCAST &runtime;function-class)
+ (|>. ($i;CHECKCAST hostL;function-class)
($i;fuse chunkI+)
- ($i;INVOKEVIRTUAL &runtime;function-class &runtime;apply-method (&runtime;apply-signature (list;size chunkI+)) false))))
+ ($i;INVOKEVIRTUAL hostL;function-class &runtime;apply-method (&runtime;apply-signature (list;size chunkI+)) false))))
$i;fuse)]]
(wrap (|>. functionI
applyI))))