diff options
Diffstat (limited to '')
-rw-r--r-- | new-luxc/source/luxc/lang/translation/jvm/function.lux | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/new-luxc/source/luxc/lang/translation/jvm/function.lux b/new-luxc/source/luxc/lang/translation/jvm/function.lux index 0fea18acd..ae876c3fc 100644 --- a/new-luxc/source/luxc/lang/translation/jvm/function.lux +++ b/new-luxc/source/luxc/lang/translation/jvm/function.lux @@ -1,5 +1,5 @@ (.module: - [lux (#- function) + [lux (#- Type function) [abstract ["." monad (#+ do)]] [control @@ -10,6 +10,9 @@ format] [collection ["." list ("#/." functor monoid)]]] + [target + [jvm + ["." type (#+ Type Method)]]] [tool [compiler [analysis (#+ Arity)] @@ -21,7 +24,6 @@ [lang [host ["$" jvm (#+ Label Inst Def Operation Phase) - ["." type] ["." def] ["_" inst]]]]] ["." // @@ -30,22 +32,22 @@ (def: arity-field Text "arity") -(def: $Object $.Type (type.class "java.lang.Object" (list))) +(def: $Object Type (type.class "java.lang.Object" (list))) (def: (poly-arg? arity) (-> Arity Bit) (n/> 1 arity)) (def: (reset-method class) - (-> Text $.Method) + (-> Text Method) (type.method (list) (#.Some (type.class class (list))) (list))) (def: (captured-args env) - (-> (List Variable) (List $.Type)) + (-> (List Variable) (List Type)) (list.repeat (list.size env) $Object)) (def: (init-method env arity) - (-> (List Variable) Arity $.Method) + (-> (List Variable) Arity Method) (if (poly-arg? arity) (type.method (list.concat (list (captured-args env) (list type.int) @@ -158,7 +160,7 @@ _.ARETURN))) (def: function-init-method - $.Method + Method (type.method (list type.int) #.None (list))) (def: (function-init arity env-size) |