diff options
author | Arnold D. Robbins <arnold@skeeve.com> | 2020-01-05 21:18:36 +0200 |
---|---|---|
committer | Arnold D. Robbins <arnold@skeeve.com> | 2020-01-05 21:18:36 +0200 |
commit | c7eeb57210cc7104df233a243295c36ffe6a2117 (patch) | |
tree | 40ad578b849d4a0d18d6669b367ef8f47e939e1b /testdir | |
parent | a1aad88728f6a8bf70c9bf9fd07b062aa6540040 (diff) | |
download | one-true-awk-c7eeb57210cc7104df233a243295c36ffe6a2117.tar.gz |
Fix merging of concatenated string constants.
Diffstat (limited to 'testdir')
-rwxr-xr-x | testdir/T.concat | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/testdir/T.concat b/testdir/T.concat new file mode 100755 index 0000000..c6bd016 --- /dev/null +++ b/testdir/T.concat @@ -0,0 +1,29 @@ +echo T.concat: test constant string concatentation + +awk=${awk-../a.out} + +$awk ' +BEGIN { + $0 = "aaa" + print "abcdef" " " $0 +} +BEGIN { print "hello" "world"; print helloworld } +BEGIN { + print " " "hello" + print "hello" " " + print "hello" " " "world" + print "hello" (" " "world") +} +' > foo1 + +cat << \EOF > foo2 +abcdef aaa +helloworld + + hello +hello +hello world +hello world +EOF + +diff foo1 foo2 || echo 'BAD: T.concat (1)' |