Skip to Content.
Sympa Menu

ssreflect - issue with nested fixpoint and nosimpl

Subject: Ssreflect Users Discussion List

List archive

issue with nested fixpoint and nosimpl


Chronological Thread 
  • From: Vincent Siles <>
  • To:
  • Subject: issue with nested fixpoint and nosimpl
  • Date: Thu, 24 Feb 2011 17:05:25 +0100
  • Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:reply-to:date:x-google-sender-auth:message-id :subject:from:to:content-type; b=V0lD6KUwtWHJsmnNGd1YKM40S2Tzg0tHR2TIl9hWbSgRF/uT9EakFhmyRfDRj9W3QC 1gzSCON5XGXW0JQ3fOl8qOir2Biyrh7fF1VmuCPk4vM9V0zPcAopJcC05L8beSmvdMBv 95d9PnnQpmzwxFw83iiShhuoepc5V+u4bz2Io=

Hi everyone,
I have a function with a nested fixpoint which is unrolled everytime I
do a /= simplification,
and I'd like to prevent this unrolling. Here is a simplification of my code:

Inductive T :Set :=
| Base
| Pair of T & T
.

Inductive T' : Set :=
| Base'
| Node' of seq T'.

Fixpoint foo (x:T') : T :=
let fix bar (y:seq T' ) := nosimpl match y with
| [::] => [::]
| hd::tl => foo hd :: bar tl
end in
match x with
| Base' => Base
| Node' l => foldr (fun xx yy => Pair xx yy) Base (bar l)
end.

Goal (forall l, foo (Node' l) = Base -> False).
move => /=.
Abort.

This print:
foldr (fun xx : T => [eta Pair xx]) Base
((fix bar (y : seq T') : seq T :=
match y with
| Nil => [::]
| hd :: tl => foo hd :: bar tl
end) l) = Base -> False


His there a way to prevent such unrolling of nested fixpoint ?

Best regards,
Vincent

PS: I'm using Coq v8.3 with ssreflect from the v8.3 contrib repository



Archive powered by MHonArc 2.6.18.

Top of Page