Skip to content

Abort statement not working  #15

@MohamedGhardallou

Description

@MohamedGhardallou

Hello ,
with the last compiler version i have this behavior :

activity inc()(x: int32)

  repeat
    x = x + 1
    await true
  end

end

@[EntryPoint]
activity Ctrl()(x: int32 , y: int32)
  y = 0
  x = 0
  await true

  when x > 5 abort
      cobegin 
        run inc()(x)
      with
        run inc()(y)
      end
  end
end

the output sequence of this program is :
x 0 y 0
x 1 y 1
x 2 y 2
x 3 y 3
x 4 y 4
x 5 y 5
x 6 y 6
x 6 y 6
x 6 y 6
x 6 y 6
...

if you replace the condition x > 5 by y > 5 the program should have that same output sequence
but we have this output instead:

x 0 y 0
x 1 y 1
x 1 y 1
x 1 y 1
x 1 y 1
x 1 y 1
x 1 y 1
x 1 y 1
x 1 y 1
x 1 y 1
...

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions