PetScan::scan: detect and report unbalanced pairs of scop/endscop pragmas