From a72e34d30eaf3557f9b76ced9605a95759ce8eca Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Sun, 24 Feb 2019 12:26:17 -0400 Subject: Got new-luxc to compile/build again. --- .../source/luxc/lang/translation/jvm/case.jvm.lux | 25 +++++++++++----------- 1 file changed, 13 insertions(+), 12 deletions(-) (limited to 'new-luxc/source/luxc/lang/translation/jvm/case.jvm.lux') diff --git a/new-luxc/source/luxc/lang/translation/jvm/case.jvm.lux b/new-luxc/source/luxc/lang/translation/jvm/case.jvm.lux index 78ef508e8..72c316d83 100644 --- a/new-luxc/source/luxc/lang/translation/jvm/case.jvm.lux +++ b/new-luxc/source/luxc/lang/translation/jvm/case.jvm.lux @@ -1,14 +1,15 @@ (.module: [lux (#- if let case) + ["." function] [control [monad (#+ do)] ["ex" exception (#+ exception:)]] [data [text format]] - [platform + [tool [compiler - ["." phase ("operation/." Monad) + ["." phase ("operation/." monad) ["." synthesis (#+ Path Synthesis)]]]]] [luxc [lang @@ -22,7 +23,7 @@ (def: (pop-altI stack-depth) (-> Nat Inst) (.case stack-depth - 0 id + 0 function.identity 1 _.POP 2 _.POP2 _ ## (n/> 2) @@ -99,7 +100,7 @@ (_.IFEQ @else))) (#synthesis.Then bodyS) - (do phase.Monad + (do phase.monad [bodyI (phase bodyS)] (wrap (|>> (pop-altI stack-depth) bodyI @@ -127,7 +128,7 @@ (_.GOTO @else) (_.label @success) pushI)))) - ([synthesis.side/left _.NULL .id] + ([synthesis.side/left _.NULL function.identity] [synthesis.side/right (_.string "") .inc]) (^template [ ] @@ -151,11 +152,11 @@ (list)) #0) pushI)))) - ([synthesis.member/left "pm_left" id] + ([synthesis.member/left "pm_left" function.identity] [synthesis.member/right "pm_right" inc]) (#synthesis.Alt leftP rightP) - (do phase.Monad + (do phase.monad [@alt-else _.make-label leftI (path' phase (inc stack-depth) @alt-else @end leftP) rightI (path' phase stack-depth @else @end rightP)] @@ -166,7 +167,7 @@ rightI))) (#synthesis.Seq leftP rightP) - (do phase.Monad + (do phase.monad [leftI (path' phase stack-depth @else @end leftP) rightI (path' phase stack-depth @else @end rightP)] (wrap (|>> leftI @@ -175,7 +176,7 @@ (def: (path phase path @end) (-> Phase Path Label (Operation Inst)) - (do phase.Monad + (do phase.monad [@else _.make-label pathI (..path' phase 1 @else @end path)] (wrap (|>> pathI @@ -190,7 +191,7 @@ (def: #export (if phase testS thenS elseS) (-> Phase Synthesis Synthesis Synthesis (Operation Inst)) - (do phase.Monad + (do phase.monad [testI (phase testS) thenI (phase thenS) elseI (phase elseS)] @@ -207,7 +208,7 @@ (def: #export (let phase inputS register exprS) (-> Phase Synthesis Nat Synthesis (Operation Inst)) - (do phase.Monad + (do phase.monad [inputI (phase inputS) exprI (phase exprS)] (wrap (|>> inputI @@ -216,7 +217,7 @@ (def: #export (case phase valueS path) (-> Phase Synthesis Path (Operation Inst)) - (do phase.Monad + (do phase.monad [@end _.make-label valueI (phase valueS) pathI (..path phase path @end)] -- cgit v1.2.3