bugfix: @end statement in between code