diff options
Diffstat (limited to '')
-rw-r--r-- | new-luxc/source/luxc/lang/analysis/function.lux | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/new-luxc/source/luxc/lang/analysis/function.lux b/new-luxc/source/luxc/lang/analysis/function.lux index 627fb7c0a..5a6df4d3e 100644 --- a/new-luxc/source/luxc/lang/analysis/function.lux +++ b/new-luxc/source/luxc/lang/analysis/function.lux @@ -102,10 +102,14 @@ (&;with-stacked-errors (function [_] (Cannot-Apply-Function (format " Function: " (%type funcT) "\n" - "Arguments: " (|> args (list/map %code) (text;join-with " "))))) + "Arguments:" (|> args + list;enumerate + (list/map (function [[idx argC]] + (format "\n " (%n idx) " " (%code argC)))) + (text;join-with ""))))) (do meta;Monad<Meta> - [expected meta;expected-type + [expectedT meta;expected-type [applyT argsA] (&inference;apply-function analyse funcT args) _ (&;with-type-env - (tc;check expected applyT))] + (tc;check expectedT applyT))] (wrap (la;apply argsA funcA))))) |