module TestGhost
  use int.Int
  use list.List
  use ref.Ref

  type t = { f1 : int; ghost f2 : int }

  exception Found int

  let test1 (x: int) (y: t)
    ensures { result = y.f1 }
  =
    try raise (Found y.f2) with
      Found _ -> y.f1
    end
end
