diff options
author | Eduardo Julian | 2017-10-18 12:42:46 -0400 |
---|---|---|
committer | Eduardo Julian | 2017-10-18 12:42:46 -0400 |
commit | 901b09dada43ec6f3b21618800ec7400fda54a0d (patch) | |
tree | d62dde3df2ce4fd7d7cd8d0b177f6592f87817cb /new-luxc/source/luxc/analyser/function.lux | |
parent | 14e381de130f0c8d3e333cf0523c6c98b9aa84b1 (diff) |
- Updated to the latest changes in stdlib.
Diffstat (limited to '')
-rw-r--r-- | new-luxc/source/luxc/analyser/function.lux | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/new-luxc/source/luxc/analyser/function.lux b/new-luxc/source/luxc/analyser/function.lux index f9fde0eab..424a3188f 100644 --- a/new-luxc/source/luxc/analyser/function.lux +++ b/new-luxc/source/luxc/analyser/function.lux @@ -5,9 +5,9 @@ [text] text/format (coll [list "list/" Fold<List> Monoid<List> Monad<List>])) - [macro #+ Monad<Lux>] - [type] - (type ["tc" check])) + [meta #+ Monad<Meta>] + (meta [type] + (type ["tc" check]))) (luxc ["&" base] (lang ["la" analysis #+ Analysis]) ["&;" scope] @@ -16,9 +16,9 @@ ## [Analysers] (def: #export (analyse-function analyse func-name arg-name body) - (-> &;Analyser Text Text Code (Lux Analysis)) - (do Monad<Lux> - [functionT macro;expected-type] + (-> &;Analyser Text Text Code (Meta Analysis)) + (do Monad<Meta> + [functionT meta;expected-type] (loop [expected functionT] (&;with-stacked-errors (function [_] (format "Functions require function types: " (type;to-text expected))) @@ -90,12 +90,12 @@ ))))) (def: #export (analyse-apply analyse funcT funcA args) - (-> &;Analyser Type Analysis (List Code) (Lux Analysis)) + (-> &;Analyser Type Analysis (List Code) (Meta Analysis)) (&;with-stacked-errors (function [_] (format "Cannot apply function " (%type funcT) " to args: " (|> args (list/map %code) (text;join-with " ")))) - (do Monad<Lux> - [expected macro;expected-type + (do Monad<Meta> + [expected meta;expected-type [applyT argsA] (&inference;apply-function analyse funcT args) _ (&;with-type-env (tc;check expected applyT))] |