From ec29b735396a656862ab9dcdde3627e234c938b0 Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Sun, 28 Jun 2020 19:58:12 -0400 Subject: Re-added & u[dated packaging machinery. --- .../source/luxc/lang/translation/jvm/program.lux | 24 ++++++++++++++-------- 1 file changed, 16 insertions(+), 8 deletions(-) (limited to 'lux-jvm/source/luxc/lang/translation/jvm/program.lux') diff --git a/lux-jvm/source/luxc/lang/translation/jvm/program.lux b/lux-jvm/source/luxc/lang/translation/jvm/program.lux index 7ac897009..2c4f1d3f2 100644 --- a/lux-jvm/source/luxc/lang/translation/jvm/program.lux +++ b/lux-jvm/source/luxc/lang/translation/jvm/program.lux @@ -1,8 +1,17 @@ (.module: [lux #* + [data + [text + ["%" format (#+ format)]]] [target [jvm - ["$t" type]]]] + ["$t" type]]] + [tool + [compiler + [language + [lux + [generation (#+ Context)] + [program (#+ Program)]]]]]] [luxc [lang [host @@ -13,12 +22,10 @@ ["." jvm ["." runtime]]]]]) -(def: #export class "LuxProgram") - (def: ^Object ($t.class "java.lang.Object" (list))) -(def: #export (program programI) - (-> _.Inst _.Definition) +(def: #export (program artifact-name context programI) + (-> (-> Context Text) (Program _.Inst _.Definition)) (let [nilI runtime.noneI num-inputsI (|>> ($i.ALOAD 0) $i.ARRAYLENGTH) decI (|>> ($i.int +1) $i.ISUB) @@ -67,11 +74,12 @@ ($i.INVOKEVIRTUAL jvm.$Function runtime.apply-method (runtime.apply-signature 1))) main-type ($t.method [(list ($t.array ($t.class "java.lang.String" (list)))) $t.void - (list)])] - [..class + (list)]) + class (artifact-name context)] + [class ($d.class #_.V1_6 #_.Public _.finalC - ..class + class (list) ..^Object (list) (|>> ($d.method #_.Public _.staticM "main" main-type -- cgit v1.2.3