From 57c4e39dcb8eb6013e22cfe82597111c5c6a55af Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Mon, 26 Feb 2018 09:53:46 +0200 Subject: Regularize directory target/scope-specific variable assignment syntax --- old-tests/variable/override/buildfile | 2 +- old-tests/variable/override/p/buildfile | 2 +- old-tests/variable/qualified/buildfile | 27 ------------------------ old-tests/variable/qualified/test.out | 12 ----------- old-tests/variable/qualified/test.sh | 3 --- old-tests/variable/type-pattern-append/buildfile | 4 ++-- old-tests/variable/type/buildfile | 4 ++-- 7 files changed, 6 insertions(+), 48 deletions(-) delete mode 100644 old-tests/variable/qualified/buildfile delete mode 100644 old-tests/variable/qualified/test.out delete mode 100755 old-tests/variable/qualified/test.sh (limited to 'old-tests/variable') diff --git a/old-tests/variable/override/buildfile b/old-tests/variable/override/buildfile index c090e81..2889f69 100644 --- a/old-tests/variable/override/buildfile +++ b/old-tests/variable/override/buildfile @@ -20,7 +20,7 @@ elif ($a == pr) print ". :" $v -d/: +d/ { if ($d_a == as) { diff --git a/old-tests/variable/override/p/buildfile b/old-tests/variable/override/p/buildfile index 527b9ae..5b84925 100644 --- a/old-tests/variable/override/p/buildfile +++ b/old-tests/variable/override/p/buildfile @@ -13,7 +13,7 @@ elif ($p_a == pr) print "p :" $v -d/: +d/ { if ($p_d_a == as) { diff --git a/old-tests/variable/qualified/buildfile b/old-tests/variable/qualified/buildfile deleted file mode 100644 index 870b808..0000000 --- a/old-tests/variable/qualified/buildfile +++ /dev/null @@ -1,27 +0,0 @@ -#v = (foo:) # error: variable name expected before ':' -#v = (:bar) # error: scope/target expected after ':' - -print (foo:bar) -print (foo :bar) -print (foo: bar) -print (foo : bar) -print (foo/: bar) -print (foo/file{fox}: bar) - -bar=bar -sub/: -{ - bar=Bar - fsdir{./}: bar=BAR - file{x}: bar=BBAARR -} - -print $(./:bar) -print $(sub/:bar) -print $(fsdir{sub/}:bar) -print $(sub/file{x}:bar) - -print $(sub/file{y}:bar) -print $(sup/:bar) - -./: diff --git a/old-tests/variable/qualified/test.out b/old-tests/variable/qualified/test.out deleted file mode 100644 index 5bf062e..0000000 --- a/old-tests/variable/qualified/test.out +++ /dev/null @@ -1,12 +0,0 @@ -foo:bar -foo:bar -foo:bar -foo:bar -foo/:bar -foo/file{fox}:bar -bar -Bar -BAR -BBAARR -Bar -bar diff --git a/old-tests/variable/qualified/test.sh b/old-tests/variable/qualified/test.sh deleted file mode 100755 index c745b76..0000000 --- a/old-tests/variable/qualified/test.sh +++ /dev/null @@ -1,3 +0,0 @@ -#!/bin/sh - -b -q | diff --strip-trailing-cr -u test.out - diff --git a/old-tests/variable/type-pattern-append/buildfile b/old-tests/variable/type-pattern-append/buildfile index a91b340..348f70f 100644 --- a/old-tests/variable/type-pattern-append/buildfile +++ b/old-tests/variable/type-pattern-append/buildfile @@ -41,7 +41,7 @@ x = $(dir{./}:x5) print $(dir{./}:x5) x6 = [string] a -sub/: +sub/ { dir{*}: x6 += b dir{*}: x6 += [null] @@ -50,7 +50,7 @@ sub/: x7 = [string] b dir{*}: x7 =+ a -sub/: +sub/ { dir{*}: x7 += c print $(dir{./}:x7) diff --git a/old-tests/variable/type/buildfile b/old-tests/variable/type/buildfile index a22cddd..ef56f19 100644 --- a/old-tests/variable/type/buildfile +++ b/old-tests/variable/type/buildfile @@ -54,14 +54,14 @@ v4b =+ [uint64] 01 print $v4b # 2 v5a = 01 -sub/: +sub/ { v5a += [uint64] 01 print $v5a # 2 } v5b = 01 -sub/: +sub/ { v5b =+ [uint64] 01 print $v5b # 2 -- cgit v1.1