aboutsummaryrefslogtreecommitdiff
path: root/new-luxc/source/luxc/eval.lux
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--new-luxc/source/luxc/eval.lux17
1 files changed, 17 insertions, 0 deletions
diff --git a/new-luxc/source/luxc/eval.lux b/new-luxc/source/luxc/eval.lux
new file mode 100644
index 000000000..266becee6
--- /dev/null
+++ b/new-luxc/source/luxc/eval.lux
@@ -0,0 +1,17 @@
+(;module:
+ lux
+ (lux (control [monad #+ do])
+ [macro])
+ [../base]
+ (.. [analyser]
+ [synthesizer]
+ (generator [expr]
+ [eval])))
+
+(def: #export (eval type exprC)
+ ../base;Eval
+ (do macro;Monad<Lux>
+ [exprA (../base;with-expected-type type
+ (analyser;analyser eval exprC))
+ #let [exprS (synthesizer;synthesize exprA)]]
+ (eval;eval (expr;generate exprS))))