Skip to Content.
Sympa Menu

coq-club - Re: [Coq-Club] goal selectors; tactic expressions

coq-club AT inria.fr

Subject: The Coq mailing list

List archive

Re: [Coq-Club] goal selectors; tactic expressions


Chronological Thread 
  • From: Jason -Zhong Sheng- Hu <fdhzs2010 AT hotmail.com>
  • To: Jeremy Dawson <Jeremy.Dawson AT anu.edu.au>, "coq-club AT inria.fr" <coq-club AT inria.fr>
  • Subject: Re: [Coq-Club] goal selectors; tactic expressions
  • Date: Fri, 25 Jan 2019 13:46:40 +0000
  • Accept-language: en-CA, en-US
  • Authentication-results: mail2-smtp-roc.national.inria.fr; spf=None smtp.pra=fdhzs2010 AT hotmail.com; spf=Pass smtp.mailfrom=fdhzs2010 AT hotmail.com; spf=Pass smtp.helo=postmaster AT NAM01-BN3-obe.outbound.protection.outlook.com
  • Ironport-phdr: 9a23:R0yVZBTBi2oR2sdho62zBW6yDNpsv+yvbD5Q0YIujvd0So/mwa6zZRON2/xhgRfzUJnB7Loc0qyK6/CmATRIyK3CmUhKSIZLWR4BhJdetC0bK+nBN3fGKuX3ZTcxBsVIWQwt1Xi6NU9IBJS2PAWK8TW94jEIBxrwKxd+KPjrFY7OlcS30P2594HObwlSizexfbB/IA+qoQnNq8IbnZZsJqEtxxXTv3BGYf5WxWRmJVKSmxbz+MK994N9/ipTpvws6ddOXb31cKokQ7NYCi8mM30u683wqRbDVwqP6WACXWgQjxFFHhLK7BD+Xpf2ryv6qu9w0zSUMMHqUbw5Xymp4rx1QxH0ligIKz858HnWisNuiqJbvAmhrAF7z4LNfY2ZKOZycqbbcNgHR2ROQ9xRWjRBDI2icoUPE+QPM+VWr4b/u1QBogCzChOwCO/z0DJEmmP60K883u88EQ/GxgsgH9cWvXrQttr1L6ASUeaox6XRzjrDb/RW2THy6IPVbx4hoe+DXbR/ccbI1EIhFR7FhUiXpIzrIjyV1uUMs3OF4+Z8SO6jl3UqqwF2ojizw8cjkIjJhoYPxl/Y8iV5xZ84KNulQ0B4ed6pCJRduz2AO4ZyXM8uWX1ktDw6x7EaoZK7cjYFxZc7yxPabvGKcoyF7g7/WOuUPDt1hH1od666ihu26kev1OjxWdO03VpXsyVIlMTHuGoX2BzJ8MeHT+Nw/ke/1jaL0ADe8vlKLFwzm6bHNpIt26M9mIIdvEjaGS/5g1v5gLWRdkU55uin8OPnYqjgppCBLYN0khv+MqMymsOhHes4LgkOX2+d+eim073j4FH5QLFNjv0xkanVqozVJcMepqKhAg9V1Jgs6wqnAjqpzNgUh30KIExfdB6blYTkO03CLOj9DfilglSslDlrx+rBPr3kGpjNIGXMkLfgfLZm9UJQ1Bc/wcxE6pJUDbEBPPfzVVXwtNzcFBM2Lwu0w+P/BNVnyoweQX6PArOeMK7KrVCI4fsvL/CQa48RpTbyMOMo5+XujH88gV8SZ7Ol3ZoRaHCiH/RpOV+VYXT2goRJLWBfnAckQen7wHGLTiVUYT7mfa8m6zQqTq6vEpzEQKikhqHH0SumWJRLMCQOQFuLCDLjc5iOc/YKciObZMF72HRQXr+4DoQlyBuGtQngyrMhIPCCqQMCspe29tFu4Oub0CMy8jp7R/+d3meCCilUgytcSTM2zrsl+RUl4leEza1xgvgeHttWsaAaGjwmPILRmrQpQ+v5XRjMK5LQEA7/E4eWRAopR9d0+OcgJkN0GtGslBfGhnH4A7gJkrWKANo/9aeOhiGtdfY48G7P0ewat3djWtFGbDb0hqlj8gHSA8jClEDLz//3J5RZ5zbE8SK49UTLvExcV1IvA4PseChGI2Hw9pH+7E6ESKKyA7M6NAcH0dSFNqZBdtzuixNBWevnP9PdJWm2njXpCA==

It's strange that solve_eqs can succeed twice but repeat fails to execute it more than once. You can try in the first goal `repeat solve_eqs` only and see if it solves the goal.

How's solve_eqs defined though? There seems like some problem with it.

Sincerely Yours,

Jason Hu

From: coq-club-request AT inria.fr <coq-club-request AT inria.fr> on behalf of Jeremy Dawson <Jeremy.Dawson AT anu.edu.au>
Sent: January 25, 2019 8:37 AM
To: coq-club AT inria.fr
Subject: Re: [Coq-Club] goal selectors; tactic expressions
 
Hi Jason,

No, I used { on a subgoal, which subsequently gave two subgoals at the
point at the start of the output shown in my email below

Cheers,

Jeremy

On 01/26/2019 12:32 AM, Jason -Zhong Sheng- Hu wrote:
> Are you in an assert or something? all: won't catch a goal that is not
> visible in the current scope.
>
> Thanks,
> Jason Hu
>
> On Jan 25, 2019 08:19, Jeremy Dawson <Jeremy.Dawson AT anu.edu.au> wrote:
> Hi Gaëtan,
>
> all: repeat solve_eqs
> doesn't succeed, I don't know exactly what all : repeat solve_eqs does
> (previous emails addressed this question and the answer I was given)
> though in this case it's consistent with applying
> 1: repeat solve_eqs (which leaves one subgoal, so subgoal 2: is the
> original subgoal 2)
> then applying 2 : repeat solve_eqs.
> or maybe just
> 1: solve_eqs. then 2: solve_eqs. (ie without "repeat", I can't tell)
>
> It doesn't go back to try 1 : solve_eqs again.
>
> eg see the following, where the
> second application of the tactic
> all : repeat solve_eqs
> makes progress beyond the results of the first application of it.
>
> 2 focused subgoals
> (shelved: 5)
>
>     V : Set
>     Φ2, Ψ1, Ψ2, Γ1 : list (PropF V)
>     Q : PropF V
>     sel1, l, l1 : list (PropF V)
>     ============================
>     ((Γ1 ++ Q :: sel1) ++ l ++ Φ2, Ψ1 ++ l1 ++ Ψ2) =
>     (?Γ1 ++ ?Q :: ?Γ2 ++ ?Γ3, ?Δ)
>
> subgoal 2 is:
>    G ++ (?Γ1 ++ ?Γ2 ++ ?Q :: ?Γ3, ?Δ, d0) :: H6 =
>    G ++ ((Γ1 ++ sel1) ++ l ++ Q :: Φ2, Ψ1 ++ l1 ++ Ψ2, d0) :: H6
>
> gen_moveL < all : repeat solve_eqs.
> 1 subgoal
>
>     V : Set
>     Φ2, sel1, l : list (PropF V)
>     ============================
>     sel1 ++ l ++ Φ2 = (sel1 ++ l) ++ Φ2
>
> gen_moveL < all : repeat solve_eqs.
> This subproof is complete, but there are some unfocused goals.
> Try unfocusing with "}".
>
> Cheers,
>
> Jeremy
>
>
> On 01/25/2019 08:53 PM, Gaëtan Gilbert wrote:
>> Note that repeat runs the inner tactic focused on each goal separately
>> so "repeat (all: solve_eqs)" would (if the syntax allowed it) be the
>> same as "repeat (only 1: solve_eqs)" which is also the same as "repeat
>> solve_eqs", and "repeat (only 2: solve_eqs)" is the same as "repeat
>> fail" ie idtac.
>>
>> I feel like "all: repeat solve_eqs" should work given what you describe,
>> can you explain how it fails?
>>
>> Gaëtan Gilbert
>>
>> On 25/01/2019 06:54, Jeremy Dawson wrote:
>>>
>>> Hi Cyprian,
>>>
>>> What I wanted is what I would express as
>>> repeat (all : solve_eqs)
>>> but it seems as though that form is forbidden.
>>>
>>> The various things I tried as indicated in my earlier email were simply
>>> looking for alternatives that work.
>>>
>>> Detailed background to what I want: solve_eqs doesn't seem to enlarge
>>> the number of goals in the cases where I want to use it, and sometimes
>>> solves a goal, sometimes only after solve_eqs has instantiated an evar
>>> in another goal, sometimes only after being repeatedly called on the
>>> same goal (where each time it simplifies the goal)
>>>
>>> Cheers,
>>>
>>> Jeremy
>>>
>>>
>>> On 01/25/2019 10:00 AM, Cyprien Mangin wrote:
>>>> What you probably meant is something like "all : repeat solve_eqs"



Archive powered by MHonArc 2.6.18.

Top of Page