aboutsummaryrefslogtreecommitdiff
path: root/new-luxc/source/luxc/lang/translation/jvm/reference.jvm.lux
diff options
context:
space:
mode:
Diffstat (limited to 'new-luxc/source/luxc/lang/translation/jvm/reference.jvm.lux')
-rw-r--r--new-luxc/source/luxc/lang/translation/jvm/reference.jvm.lux57
1 files changed, 0 insertions, 57 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
deleted file mode 100644
index c821a9de2..000000000
--- a/new-luxc/source/luxc/lang/translation/jvm/reference.jvm.lux
+++ /dev/null
@@ -1,57 +0,0 @@
-(.module:
- [lux #*
- [abstract
- [monad (#+ do)]]
- [data
- [text
- format]]
- [tool
- [compiler
- ["." name]
- ["." reference (#+ Register Variable)]
- ["." phase ("operation/." monad)
- ["." generation]]]]]
- [luxc
- [lang
- [host
- [jvm (#+ Inst Operation)
- ["$t" type]
- ["_" inst]]]]]
- ["." //])
-
-(template [<name> <prefix>]
- [(def: #export (<name> idx)
- (-> Nat Text)
- (|> idx %n (format <prefix>)))]
-
- [foreign-name "f"]
- [partial-name "p"]
- )
-
-(def: (foreign variable)
- (-> Register (Operation Inst))
- (do phase.monad
- [function-class generation.context]
- (wrap (|>> (_.ALOAD 0)
- (_.GETFIELD function-class
- (|> variable .nat foreign-name)
- //.$Object)))))
-
-(def: local
- (-> Register (Operation Inst))
- (|>> _.ALOAD operation/wrap))
-
-(def: #export (variable variable)
- (-> Variable (Operation Inst))
- (case variable
- (#reference.Local variable)
- (local variable)
-
- (#reference.Foreign variable)
- (foreign variable)))
-
-(def: #export (constant name)
- (-> Name (Operation Inst))
- (do phase.monad
- [bytecode-name (generation.remember name)]
- (operation/wrap (_.GETSTATIC bytecode-name //.value-field //.$Object))))