#!../../parrot tcl.pbc

source lib/test_more.tcl

plan 2

eval_is {
 for {set a 0} {$a < 20} {incr a} {
   if {$a > 10} { break }
 }
 set a
} 11 {break from for}

eval_is {
 set a 20
 while {$a} {
   incr a -1
   if {$a < 10} { break }
 }
 set a
} 9 {break from while}

#!../../parrot tcl.pbc

source lib/test_more.tcl

plan 3

eval_is {
 for {set a 0} {$a < 20} {incr a} {
   if {$a > 10} { break }
 }
 set a
} 11 {break from for}

eval_is {
 set a 20
 while {$a} {
   incr a -1
   if {$a < 10} { break }
 }
 set a
} 9 {break from while}

eval_is {
  proc test {} {break}
  test
} {invoked "break" outside of a loop} \
  {break outside of a loop}


Add a failing [break] test
[tcl]: Add a failing [break] test


git-svn-id: 6e74a02f85675cec270f5d931b0f6998666294a3@14371 d31e2699-5ff4-0310-a27c-f18f2fbe73fe
