Skip to Content.
Sympa Menu

coq-club - Re: [Coq-Club] more naive questions about rewriting

coq-club AT inria.fr

Subject: The Coq mailing list

List archive

Re: [Coq-Club] more naive questions about rewriting


Chronological Thread 
  • From: Vadim Zaliva <vzaliva AT cmu.edu>
  • To: coq-club AT inria.fr
  • Subject: Re: [Coq-Club] more naive questions about rewriting
  • Date: Tue, 16 Aug 2016 16:26:07 -0700
  • Authentication-results: mail3-smtp-sop.national.inria.fr; spf=None smtp.pra=vadim.zaliva AT west.cmu.edu; spf=Pass smtp.mailfrom=vadim.zaliva AT west.cmu.edu; spf=None smtp.helo=postmaster AT mail-wm0-f45.google.com
  • Ironport-phdr: 9a23:wZcy2hNhmyifuxXzotAl6mtUPXoX/o7sNwtQ0KIMzox0KPjyrarrMEGX3/hxlliBBdydsKMdzbOG+Pm6ESxYuNDa4ShEKMQNHzY+yuwu1zQ6B8CEDUCpZNXLVAcdWPp4aVl+4nugOlJUEsutL3fbo3m18CJAUk6nbVk9GO35F8bogtit0KjqotuIMlwO3Wr2OOk6bE3v616A7o9O2coqA51y4yOBmmFPdeVSyDEgDnOotDG42P2N+oV++T9bofMr+p0Ie6z7e6MlUe4QV2x+YChmrPHs4BLEVE6E4mYWemQQiBtBRQbfvz/gWZKkjCL2t+816iCePNP/BeQqSz2m7rliYBTtlWEKOyNvozKfsdB5kK8O+EHpnBd42YOBOIw=


On Tue, Aug 16, 2016 at 3:20 PM, Jonathan Leivent <jonikelee AT gmail.com> wrote:
[setoid_rewrite <-compose_assoc at 2] works in Vadim's example.  The way that setoid_rewrite matches patterns is different from the way that rewrite matches patterns.  I think that setoid_rewrite's method is more intuitive.

That's very interesting. Thanks! I think it would good to mention this in the documentation. Confusingly it mentions that 'rewrite ... at ..." uses Setoid equality, but apparently that does not mean that it matches patterns in the same way as 'setoid_rewrite'.

My remaining problem is that I am working in environment where I am already using setoid equality and thus my 'default_relation' is re-defined ('equiv' not 'eq'), while `comp_assoc` is defined for 'eq'. So I need to find a way to use `setoid_rewrite` tactics but with 'eq' relation. You can specify one for 'setoid_replace' tactic ('using relation' argument), but unfortunately not for `setoid_rewrite`!

Vadim

--
CMU ECE PhD candidate
Mobile: +1(510)220-1060




Archive powered by MHonArc 2.6.18.

Top of Page