diff options
author | Eduardo Julian | 2018-07-22 02:52:46 -0400 |
---|---|---|
committer | Eduardo Julian | 2018-07-22 02:52:46 -0400 |
commit | b14102eaa2a80f51f160ba293ec01928dbe683c3 (patch) | |
tree | bf2640c4503de8c9f0a8f6b048548ef1a0bd4e83 /new-luxc/source/luxc/lang/translation/jvm/reference.jvm.lux | |
parent | 9671d6064dd02dfe6c32492f5b9907b096e5bd89 (diff) |
- Some fixes due to recent changes in stdlib.
- Removed some (now) useless modules.
Diffstat (limited to '')
-rw-r--r-- | new-luxc/source/luxc/lang/translation/jvm/reference.jvm.lux | 35 |
1 files changed, 18 insertions, 17 deletions
diff --git a/new-luxc/source/luxc/lang/translation/jvm/reference.jvm.lux b/new-luxc/source/luxc/lang/translation/jvm/reference.jvm.lux index 3686b9210..ba606a437 100644 --- a/new-luxc/source/luxc/lang/translation/jvm/reference.jvm.lux +++ b/new-luxc/source/luxc/lang/translation/jvm/reference.jvm.lux @@ -3,19 +3,20 @@ [control [monad (#+ do)]] [data - [text ("text/" Hash<Text>) + [text ("text/." Hash<Text>) format]] - [language - ["." name] - ["." reference (#+ Register Variable)] - ["." compiler ("operation/" Monad<Operation>) - ["." translation]]]] + [compiler + [default + ["." name] + ["." reference (#+ Register Variable)] + ["." phase ("operation/." Monad<Operation>) + ["." translation]]]]] [luxc [lang [host [jvm (#+ Inst Operation) ["$t" type] - ["$i" inst]]]]] + ["_" inst]]]]] ["." //]) (do-template [<name> <prefix>] @@ -29,16 +30,16 @@ (def: (foreign variable) (-> Register (Operation Inst)) - (do compiler.Monad<Operation> + (do phase.Monad<Operation> [function-class translation.context] - (wrap (|>> ($i.ALOAD +0) - ($i.GETFIELD function-class - (|> variable .nat foreign-name) - //.$Object))))) + (wrap (|>> (_.ALOAD +0) + (_.GETFIELD function-class + (|> variable .nat foreign-name) + //.$Object))))) (def: local (-> Register (Operation Inst)) - (|>> $i.ALOAD operation/wrap)) + (|>> _.ALOAD operation/wrap)) (def: #export (variable variable) (-> Variable (Operation Inst)) @@ -49,7 +50,7 @@ (#reference.Foreign variable) (foreign variable))) -(def: #export (constant [def-module def-name]) - (-> Ident (Operation Inst)) - (let [bytecode-name (format def-module "/" (name.normalize def-name) (%n (text/hash def-name)))] - (operation/wrap ($i.GETSTATIC bytecode-name //.value-field //.$Object)))) +(def: #export (constant [module short]) + (-> Name (Operation Inst)) + (let [bytecode-name (format module "/" (name.normalize short) (%n (text/hash short)))] + (operation/wrap (_.GETSTATIC bytecode-name //.value-field //.$Object)))) |