Mercurial > ~dholland > hg > tradcpp > index.cgi
changeset 70:ca5e4e0237f5
merge
author | David A. Holland |
---|---|
date | Sun, 31 Mar 2013 11:22:22 -0400 |
parents | 8eee66a25533 (current diff) f8507e5ed84c (diff) |
children | dc63e70e425d |
files | tests/Makefile |
diffstat | 5 files changed, 10 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/directive.c Sun Mar 31 08:06:40 2013 +0200 +++ b/directive.c Sun Mar 31 11:22:22 2013 -0400 @@ -571,12 +571,11 @@ p->column += acomm; } - /* check if we have a directive line */ - skip = strspn(line + acomm, ws); - if (acomm == 0 && line[skip] == '#') { + /* check if we have a directive line (# exactly in column 0) */ + if (acomm == 0 && line[0] == '#') { char ch; - skip = skip + 1 + strspn(line + skip + 1, ws); + skip = 1 + strspn(line + 1, ws); assert(skip <= text); p->column += skip; assert(line[len] == '\0');
--- a/tests/Makefile Sun Mar 31 08:06:40 2013 +0200 +++ b/tests/Makefile Sun Mar 31 11:22:22 2013 -0400 @@ -3,7 +3,7 @@ TESTS=\ t01 t02 t03 t04 t05 t06 t07 t08 t09 t10 t11 t12 t13 t14 t15 t16 \ - t17 t18 t19 + t17 t18 t19 t20 t21 all: run-tests .WAIT show-diffs
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tests/t20.c Sun Mar 31 11:22:22 2013 -0400 @@ -0,0 +1,1 @@ +#undef foo /* blah */