While True
  X
  Dim match1st as Integer = GetMatch1st()
  if match1st = -1 then
    Exit While
  Else
    Y
  End If
End While