PetScan::scan: fix check for scop being proper part of statement
commit914e275e9dff443f01d6128ea317b56ea7217478
authorSven Verdoolaege <skimo@kotnet.org>
Tue, 18 Jun 2013 07:11:23 +0000 (18 09:11 +0200)
committerSven Verdoolaege <skimo@kotnet.org>
Wed, 19 Jun 2013 15:27:53 +0000 (19 17:27 +0200)
treeccf66cecb1f304c933563117aebf782060cfb390
parentf8eb1050c06faa90202878d1d10ccdcc7d106026
PetScan::scan: fix check for scop being proper part of statement

In particular, then end of the scop points beyond the scop,
while the end of the statement that it is compared with points
to the start of the token that represents the end of the statement.
This has only become a problem since e00885c (derive offset information
from location of scop and endscop pragmas, Tue Feb 5 17:37:13 2013 +0100).
Before that commit, the end of the scop would point to the line
containing the endscop pragma, while after that commit, it would
point to the next line.

Reported-by: Athanasios Konstantinidis <ak807@doc.ic.ac.uk>
Signed-off-by: Sven Verdoolaege <skimo@kotnet.org>
scan.cc
tests/loop_body2.c [new file with mode: 0644]
tests/loop_body2.scop [new file with mode: 0644]