From 28bdf77ac0619ee8a21d94d6039b1d7483cac37f Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Fri, 26 Apr 2019 22:28:25 -0400 Subject: - Ported pattern-matching tests. - Ported function tests. --- stdlib/source/spec/compositor.lux | 26 ++------------------------ 1 file changed, 2 insertions(+), 24 deletions(-) (limited to 'stdlib/source/spec/compositor.lux') diff --git a/stdlib/source/spec/compositor.lux b/stdlib/source/spec/compositor.lux index a62d2efa9..4967c0f8c 100644 --- a/stdlib/source/spec/compositor.lux +++ b/stdlib/source/spec/compositor.lux @@ -28,46 +28,24 @@ (generation.State+ anchor expression statement) what))) -## (def: #export (runner generate-runtime translate bundle state) -## (-> (Operation Any) Phase Bundle (IO State) -## Runner) -## (function (_ valueS) -## (|> (do phase.Monad -## [_ generate-runtime -## program (translate valueS)] -## (translation.evaluate! "runner" program)) -## translation.with-buffer -## (phase.run [bundle (io.run state)])))) - (def: (runner (^slots [#platform.runtime #platform.phase #platform.host]) state) (Instancer Runner) (function (_ evaluation-name expressionS) (do error.monad [expressionG (<| (phase.run state) + generation.with-buffer (do phase.monad [_ runtime] (phase expressionS)))] (:: host evaluate! evaluation-name expressionG)))) -## (def: #export (definer generate-runtime translate bundle state) -## (-> (Operation Any) Phase Bundle (IO State) Definer) -## (function (_ lux-name valueS) -## (|> (do phase.Monad -## [_ generate-runtime -## valueH (translate valueS) -## [host-name host-value] (translation.define! lux-name valueH) -## _ (translation.learn lux-name host-name) -## program (translate (synthesis.constant lux-name))] -## (translation.evaluate! "definer" program)) -## translation.with-buffer -## (phase.run [bundle (io.run state)])))) - (def: (definer (^slots [#platform.runtime #platform.phase #platform.host]) state) (Instancer Definer) (function (_ lux-name expressionS) (do error.monad [definitionG (<| (phase.run state) + generation.with-buffer (do phase.monad [_ runtime expressionG (phase expressionS) -- cgit v1.2.3