#lang ivy1.7
type t
var p(X:t) : bool
var q : bool
var y : t
after init {
p(X) := true
}
action a(x:t) = {
q := *;
if * {
p(x) := false
else {
q := true
invariant p(X)
export a