groovy

Switch is not working

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: 1.0-JSR-5
  • Fix Version/s: 1.0-JSR-6
  • Component/s: bytecode
  • Labels:
    None
  • Environment:
    Windows XP/SP2 + jdk1.5.0_06
  • Number of attachments :
    0

Description

The following script never ends

def a = true
while(a) {
while(false) {} //1
a = false
break //2
}

remove either 1 or 2 and it runs %-)

Activity

Hide
blackdrag blackdrag added a comment -

I forgot to remove the nested scope, so the scopes got mixed up. Iadded some tests inside the CompileStack to prevent this from happening again

Show
blackdrag blackdrag added a comment - I forgot to remove the nested scope, so the scopes got mixed up. Iadded some tests inside the CompileStack to prevent this from happening again

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: