summaryrefslogtreecommitdiff
path: root/examples/c/bistromathic/bistromathic.test
diff options
context:
space:
mode:
authorAkim Demaille <akim.demaille@gmail.com>2022-01-15 10:28:16 +0100
committerAkim Demaille <akim.demaille@gmail.com>2022-06-15 07:55:13 +0200
commit6ee1494d6ec270a5832b0ce8e2e5f16cca16935d (patch)
treef9d38041ad4b84a92b9e3824d018c700547fcaa8 /examples/c/bistromathic/bistromathic.test
parenta475c4d5c1fff75b31dcedf0124c521e573a5fc7 (diff)
downloadbison-6ee1494d6ec270a5832b0ce8e2e5f16cca16935d.tar.gz
doc: explain why location's "column" are defined vaguely
Suuggested by Frank Heckenbach. <https://lists.gnu.org/r/bug-bison/2022-01/msg00000.html> * doc/bison.texi (Location Type): Explain why location's "column" are defined vaguely. Show tab handling in ltcalc and calc++. * examples/c/bistromathic/parse.y: Show tab handling. * examples/c++/calc++/calc++.test, * examples/c/bistromathic/bistromathic.test: Check tab handling.
Diffstat (limited to 'examples/c/bistromathic/bistromathic.test')
-rwxr-xr-xexamples/c/bistromathic/bistromathic.test23
1 files changed, 23 insertions, 0 deletions
diff --git a/examples/c/bistromathic/bistromathic.test b/examples/c/bistromathic/bistromathic.test
index b46f996a..4a8efe44 100755
--- a/examples/c/bistromathic/bistromathic.test
+++ b/examples/c/bistromathic/bistromathic.test
@@ -366,3 +366,26 @@ err: 1.15: syntax error: expected - or ( or number or function or variable befor
err: 1 | (1++2) + 3 + ''
err: | ^
'
+
+# Check handling of literal tabs. "Escape" them with a C-v, so that
+# they are not processed as completion requests.
+cat >input<<EOF
+ *1
+ *2
+  *3
+EOF
+# readline processes the tabs itself, and replaces then with spaces.
+run -n 0 '> *1
+> *2
+> *3
+> ''
+err: 1.9: syntax error: expected end of file or - or ( or exit or number or function etc., before *
+err: 1 | *1
+err: | ^
+err: 2.9: syntax error: expected end of file or - or ( or exit or number or function etc., before *
+err: 2 | *2
+err: | ^
+err: 3.9: syntax error: expected end of file or - or ( or exit or number or function etc., before *
+err: 3 | *3
+err: | ^
+'