PetScan::scan: detect and report unbalanced pairs of scop/endscop pragmas
commit3267493b88ca018b797ce0787f2d77890a543438
authorSven Verdoolaege <skimo@kotnet.org>
Mon, 31 Oct 2016 09:19:55 +0000 (31 10:19 +0100)
committerSven Verdoolaege <skimo@kotnet.org>
Mon, 7 Nov 2016 15:46:22 +0000 (7 16:46 +0100)
treea011132d57ec7b9e4772b507dea06a420e6db2ae
parent5bc06597d9e3cc0267252f8935776cb29d5d6b03
PetScan::scan: detect and report unbalanced pairs of scop/endscop pragmas

In particular, check that the scop pragma is not inside a child statement
that does not also contain the endscop pragma.
Without this check, such unbalanced pairs of scop/endscop pragmas
would get silently ignored.

Reported-by: Samuel Thibault <samuel.thibault@inria.fr>
Signed-off-by: Sven Verdoolaege <skimo@kotnet.org>
scan.cc
scan.h