From 36cf0c61991bda395e224fa2d435fa6b6f5090e5 Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Tue, 27 Jun 2017 17:52:52 -0400 Subject: - Adapted compiler to the latest stdlib changes. --- new-luxc/source/luxc/analyser/function.lux | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) (limited to 'new-luxc/source/luxc/analyser/function.lux') diff --git a/new-luxc/source/luxc/analyser/function.lux b/new-luxc/source/luxc/analyser/function.lux index 5144534fb..f1d7fdd31 100644 --- a/new-luxc/source/luxc/analyser/function.lux +++ b/new-luxc/source/luxc/analyser/function.lux @@ -25,26 +25,24 @@ (#;Named name unnamedT) (recur unnamedT) - (#;App funT argT) - (do @ - [fully-applied (case (type;apply-type funT argT) - (#;Some value) - (wrap value) + (#;Apply argT funT) + (case (type;apply (list argT) funT) + (#;Some value) + (recur value) - #;None - (&;fail (format "Cannot apply type " (%type funT) " to type " (%type argT))))] - (recur fully-applied)) + #;None + (&;fail (format "Cannot apply type " (%type funT) " to type " (%type argT)))) (#;UnivQ _) (do @ [[var-id var] (&;within-type-env TC;existential)] - (recur (assume (type;apply-type expected var)))) + (recur (assume (type;apply (list var) expected)))) (#;ExQ _) (&common;with-var (function [[var-id var]] - (recur (assume (type;apply-type expected var))))) + (recur (assume (type;apply (list var) expected))))) (#;Var id) (do @ -- cgit v1.2.3