From 10bd72e858a8ffaacafa296dbbc429dc73b0111c Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Fri, 18 Jan 2019 14:22:17 -0800 Subject: Added `tree` back as a parameter to compile actions, which helps with better error reporting, e.g. for (fail) (no arguments). Overall better error reporting now. Also added shorthand ("Action" tree with ...) for (SyntaxTree {.type = "Action", .1 = ...}). --- lib/compatibility/6.14.nom | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/compatibility/6.14.nom') diff --git a/lib/compatibility/6.14.nom b/lib/compatibility/6.14.nom index 0e742d0..b11474b 100644 --- a/lib/compatibility/6.14.nom +++ b/lib/compatibility/6.14.nom @@ -28,11 +28,11 @@ upgrade action (assume $assumption or barf $err) to "6.14" as upgrade action (barf $msg) to "6.14" as (fail $msg) upgrade action (\(1's meaning)).stub to "6.14" via - $tree -> (SyntaxTree {.source = $tree.source, .type = "Var", $tree.1}) + $tree -> ("Var" tree from $tree.source with $tree.1) upgrade action (log base $b of $n) to "6.14" as (log $n base $b) upgrade action "use" to "6.14" via for $tree: $path = $tree.2.1 $path = ($path, with "%.nom$" -> "") $path = ($path, with "^lib/" -> "") - return \(use (SyntaxTree {.source = $tree.2.source, .type = "Text"} $path)) + return \(use ("Text" tree from $tree.2.source with $path)) -- cgit v1.2.3