diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2022-03-19 23:09:24 -0700 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2022-03-19 23:09:24 -0700 |
commit | 86a3448b554e2c9963eed87a43b2db2a8156f842 (patch) | |
tree | 70662053a5a39e03e477ad85003626979c68139d /testcases | |
parent | b627e525556c4452cb05ce8744e3f21f2bda2eb2 (diff) | |
download | cppawk-86a3448b554e2c9963eed87a43b2db2a8156f842.tar.gz cppawk-86a3448b554e2c9963eed87a43b2db2a8156f842.tar.bz2 cppawk-86a3448b554e2c9963eed87a43b2db2a8156f842.zip |
Handle situations when cpp breaks a line into pieces.
There are situations in which GNU cpp breaks a single line of
input into multiple lines. These are indicated by linemarkers
that repeat the current line number, for instance:
# 3 "file"
this
# 3 "file"
is
# 3 "file"
all line three
line four
line five
We now remove these repeat linemarkers and collapse the
indicated lines back into one line, also eliminating the
leading whitespace that tries to preserve the column.
Diffstat (limited to 'testcases')
-rw-r--r-- | testcases | 9 |
1 files changed, 9 insertions, 0 deletions
@@ -161,3 +161,12 @@ abc'def BEGIN { print __cppawk_ver >= 20220318 }' : 1 +-- +30: +./cppawk ' +#include <limits.h> +BEGIN { + print INT_MIN, INT_MIN, INT_MIN +}' +: +-2147483648 -2147483648 -2147483648 |