Thanks for the report.
This is fixed with "teoz" engine.
@startuml
!pragma teoz true
Int -> Int: Foo
activate Int
ref over Int
Bar
end ref
deactivate Int
@enduml
Is it possible for you to switch to this engine ? Someday, it will become the default one.