File:  [parser3project] / parser3 / tests / 377.html
Revision 1.1: download - view: text, annotated - select for diffs - revision graph
Tue Jan 17 20:25:22 2017 UTC (9 years, 4 months ago) by moko
Branches: MAIN
CVS tags: release_3_5_1, release_3_5_0, release_3_4_6, release_3_4_5, HEAD
test for different combinations of breaks in body and delimiter (related to bug #1077)

@main[]
1. continue in body does not influence delimiter code and vice versa
    ^for[i](1;10){body$i %^if($i>4){^continue[]}%}{, [$i] =^if($i>8){^continue[]}=}
2. break can be called from delimiter
    ^for[i](1;8){body$i}{, [$i] =^if($i>4){^break[]}=}
3. break in body still allows next delimiter execution
    ^for[i](1;8){body$i =^if($i>4){^break[]}=}{, [$i] }
4. continue in delimiter called after and thus has precedence over break in body
    ^for[i](1;8){body$i =^if($i>4){^break[]}=}{, [$i] %^continue[]%}
5. ^^break[] can be passed to break from the called method inner cicle
    ^test5{ =^break[]= }

@test5[code]
^while(1){ %$code% }

E-mail: