Skip to Content.
Sympa Menu

coq-club - [Coq-Club] A simple script does not work

coq-club AT inria.fr

Subject: The Coq mailing list

List archive

[Coq-Club] A simple script does not work


chronological Thread 
  • From: Victor Porton <porton AT narod.ru>
  • To: Coq <coq-club AT inria.fr>
  • Subject: [Coq-Club] A simple script does not work
  • Date: Mon, 14 Nov 2011 21:06:58 +0400
  • Envelope-from: porton AT yandex.ru

I am now learning how to create an object of a derived class having an object 
of a base class.

As the first act I decided to play with plain dependent records (not yet with 
type classes).

But that simple script does not work in some mysterious (for me) reason. 
Please explain why it does not verify.

[[[[
Record A := {
  num: nat
}.

Record B := {
  base : A;
  e: num base > 2
}.

Definition A_Sample: A := {| num := 3 |}.

Definition B_Sample: B := {| base := A_Sample |}.
Proof. Admitted.
]]]]

-- 
Victor Porton - http://portonvictor.org



Archive powered by MhonArc 2.6.16.

Top of Page