Zulip Chat Archive

Stream: lean4

Topic: Binding the syntax being matched in `elab_rules`?


Scott Morrison (Nov 01 2021 at 04:21):

I want to change a use of

elab tk:"librarySearch" : tactic => do

to

elab_rules : tactic | `(librarySearch) => do ...

(as there will now be a syntax declaration earlier).

However I do still need the tk : Syntax later in the tactic, and I'm not sure how to obtain it when using elab_rules. How can I do this?

Scott Morrison (Nov 01 2021 at 04:22):

Specifically I want to make the change here.

Mac (Nov 01 2021 at 07:21):

@Scott Morrison You can do get tk like so:

elab_rules : tactic | `(librarySearch%$tk) => do ...

Last updated: Dec 20 2023 at 11:08 UTC