Skip to Content.
Sympa Menu

coq-club - [Coq-Club] Multiple [where] notations on a single record field

coq-club AT inria.fr

Subject: The Coq mailing list

List archive

[Coq-Club] Multiple [where] notations on a single record field


Chronological Thread 
  • From: Jason Gross <jasongross9 AT gmail.com>
  • To: coq-club AT inria.fr
  • Subject: [Coq-Club] Multiple [where] notations on a single record field
  • Date: Sun, 29 Jul 2012 19:50:56 -0400

Hi,
Is it possible to define multiple notations using the same record field with [where]?  That is, can I do something like

  Local Reserved Notation "A ⊗ B" (at level 40, left associativity).
  Local Reserved Notation "A ⊗m B" (at level 40, left associativity).

  Let src (C : SpecializedCategory morC) s d (_ : Morphism C s d) := s.
  Let dst (C : SpecializedCategory morC) s d (_ : Morphism C s d) := d.
  Record MonoidalCategory := {
    UnderlyingCategory :> SpecializedCategory morC;
    TensorProduct : SpecializedFunctor (UnderlyingCategory * UnderlyingCategory) UnderlyingCategory where "A ⊗ B" := (TensorProduct (A, B));
    TensorProduct' := TensorProduct
      where "A ⊗m B" := (TensorProduct.(MorphismOf) (s := (src A, src B)) (d := (dst A, dst B)) (A, B));
  }.

but without defining [TensorProduct']?

Thanks.

-Jason



Archive powered by MHonArc 2.6.18.

Top of Page