aboutsummaryrefslogtreecommitdiff
path: root/old-tests
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2018-02-26 09:53:46 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2018-05-03 15:23:09 +0200
commit57c4e39dcb8eb6013e22cfe82597111c5c6a55af (patch)
treeeaf81473dbda167a187f01a632d39ba2f4908c71 /old-tests
parent4b9de5c80934772dbc5503e65e265da452ca356a (diff)
Regularize directory target/scope-specific variable assignment syntax
Diffstat (limited to 'old-tests')
-rw-r--r--old-tests/amalgam/libtest/build/export.build2
-rw-r--r--old-tests/attribute/buildfile4
-rw-r--r--old-tests/cli/lib/libtest/build/export.build2
-rw-r--r--old-tests/cli/lib/libtest/test/buildfile2
-rw-r--r--old-tests/install/lib/libtest/build/export.build2
-rw-r--r--old-tests/install/lib/libtest/build/root.build2
-rw-r--r--old-tests/postponed/buildfile2
-rw-r--r--old-tests/scope/amalgamation/l1/build/bootstrap.build2
-rw-r--r--old-tests/scope/amalgamation/l1/buildfile8
-rw-r--r--old-tests/semantics/include/includer5
-rw-r--r--old-tests/semantics/source/sourcer4
-rwxr-xr-xold-tests/test.sh1
-rw-r--r--old-tests/variable/override/buildfile2
-rw-r--r--old-tests/variable/override/p/buildfile2
-rw-r--r--old-tests/variable/qualified/buildfile27
-rw-r--r--old-tests/variable/qualified/test.out12
-rwxr-xr-xold-tests/variable/qualified/test.sh3
-rw-r--r--old-tests/variable/type-pattern-append/buildfile4
-rw-r--r--old-tests/variable/type/buildfile4
19 files changed, 24 insertions, 66 deletions
diff --git a/old-tests/amalgam/libtest/build/export.build b/old-tests/amalgam/libtest/build/export.build
index b95e409..c1c6a8b 100644
--- a/old-tests/amalgam/libtest/build/export.build
+++ b/old-tests/amalgam/libtest/build/export.build
@@ -1,4 +1,4 @@
-$out_root/:
+$out_root/
{
include buildfile
}
diff --git a/old-tests/attribute/buildfile b/old-tests/attribute/buildfile
index 6675894..7338641 100644
--- a/old-tests/attribute/buildfile
+++ b/old-tests/attribute/buildfile
@@ -6,10 +6,10 @@
#[foo=dir/file{bar}] # error: invalid attribute key
#[foo] print hello # error: attributes before print
-#[foo]./: # error: attributes before directory scope
+#[foo]./ # error: attributes before directory scope
#{
#}
-#[foo]./: # error: attributes before target/scope
+#[foo]./: # error: attributes before target scope
#./: [foo] buildfile # error: attributes before prerequisites
#import [foo] libz # error: attributes without variable
diff --git a/old-tests/cli/lib/libtest/build/export.build b/old-tests/cli/lib/libtest/build/export.build
index e8b12b3..f5e50c7 100644
--- a/old-tests/cli/lib/libtest/build/export.build
+++ b/old-tests/cli/lib/libtest/build/export.build
@@ -1,4 +1,4 @@
-$out_root/:
+$out_root/
{
include test/
}
diff --git a/old-tests/cli/lib/libtest/test/buildfile b/old-tests/cli/lib/libtest/test/buildfile
index a7667e6..4cf5ebe 100644
--- a/old-tests/cli/lib/libtest/test/buildfile
+++ b/old-tests/cli/lib/libtest/test/buildfile
@@ -6,7 +6,7 @@ cli.cxx{base}: cli{base}
cli.options += -I $src_root --include-with-brackets
-extra/:
+extra/
{
cxx{test} hxx{test}: cli{test}
cli.options += --include-prefix test/extra --guard-prefix TEST_EXTRA \
diff --git a/old-tests/install/lib/libtest/build/export.build b/old-tests/install/lib/libtest/build/export.build
index e8b12b3..f5e50c7 100644
--- a/old-tests/install/lib/libtest/build/export.build
+++ b/old-tests/install/lib/libtest/build/export.build
@@ -1,4 +1,4 @@
-$out_root/:
+$out_root/
{
include test/
}
diff --git a/old-tests/install/lib/libtest/build/root.build b/old-tests/install/lib/libtest/build/root.build
index 20536a2..9cf16a1 100644
--- a/old-tests/install/lib/libtest/build/root.build
+++ b/old-tests/install/lib/libtest/build/root.build
@@ -4,7 +4,7 @@ hxx{*}: extension = hxx
ixx{*}: extension = ixx
cxx{*}: extension = cxx
-tests/:
+tests/
{
exe{*}: test = true
install = false
diff --git a/old-tests/postponed/buildfile b/old-tests/postponed/buildfile
index 53873aa..437d85f 100644
--- a/old-tests/postponed/buildfile
+++ b/old-tests/postponed/buildfile
@@ -2,4 +2,4 @@ using cxx
exe{driver}: cxx{driver} fsdir{$out_root/out}
-./: exe{driver}
+./: exe{driver}
diff --git a/old-tests/scope/amalgamation/l1/build/bootstrap.build b/old-tests/scope/amalgamation/l1/build/bootstrap.build
index 6bde838..81499d4 100644
--- a/old-tests/scope/amalgamation/l1/build/bootstrap.build
+++ b/old-tests/scope/amalgamation/l1/build/bootstrap.build
@@ -8,7 +8,7 @@ using config
# If they are the same, then this scope will simply
# be "upgraded".
#
-$src_root/../:
+$src_root/../
{
print 0: $project
print 0: $src_base
diff --git a/old-tests/scope/amalgamation/l1/buildfile b/old-tests/scope/amalgamation/l1/buildfile
index 55d8c64..c6d3506 100644
--- a/old-tests/scope/amalgamation/l1/buildfile
+++ b/old-tests/scope/amalgamation/l1/buildfile
@@ -1,6 +1,6 @@
# Out of amalgamation.
#
-../../:
+../../
{
print -1: $project
print -1: $src_base
@@ -9,7 +9,7 @@
# In amalgamation.
#
-../s/:
+../s/
{
print 0: $project
print 0: $src_base
@@ -18,7 +18,7 @@
# In project.
#
-s/:
+s/
{
print 1: $project
print 1: $src_base
@@ -27,7 +27,7 @@ s/:
# In sub-project.
#
-l2/s/:
+l2/s/
{
print 2: $project
print 2: $src_base
diff --git a/old-tests/semantics/include/includer b/old-tests/semantics/include/includer
index 70527a5..700076e 100644
--- a/old-tests/semantics/include/includer
+++ b/old-tests/semantics/include/includer
@@ -2,9 +2,10 @@ include
include includee1
include includee1 ../include/includee2 # includee1 is skipped
include nested/includee3
-nested/:
+nested/
{
include includee5
include ../includee2 # skipped
}
-:
+
+./:
diff --git a/old-tests/semantics/source/sourcer b/old-tests/semantics/source/sourcer
index eb1310e..030e9bc 100644
--- a/old-tests/semantics/source/sourcer
+++ b/old-tests/semantics/source/sourcer
@@ -1,9 +1,9 @@
source
source sourcee1
source sourcee1 ../source/sourcee2
-nested/:
+nested/
{
source sourcee3
source ../sourcee1
}
-:
+./:
diff --git a/old-tests/test.sh b/old-tests/test.sh
index f02291a..96a7ed3 100755
--- a/old-tests/test.sh
+++ b/old-tests/test.sh
@@ -24,6 +24,5 @@ test "variable/expansion"
test "variable/null"
test "variable/override"
test "variable/prepend"
-test "variable/qualified"
test "variable/type"
test "variable/type-pattern-append"
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