free c:channel.

fun h(bitstring):bitstring.

const a,b:bitstring.

event A(bitstring).

const ok,ko:bitstring.

lemma x:bitstring,y:bitstring; event(A(x)) ==> x=a.

let P1 =
  in(c,x:bitstring);
  if x = a
  then
    event A(a);
    out(c,ok)
  else
    out(c,ko).

let P2 =
  in(c,x:bitstring);
  if x = b
  then
    event A(a);
    out(c,ok)
  else
    out(c,ko).

equivalence P1 P2

(* EXPECTPV
RESULT event(A(x_2)) ==> x_2 = a is true.
RESULT Observational equivalence cannot be proved.
0.044s (user 0.036s + system 0.008s), max rss 9036K
END *)
