So I was reading this paper on elaborator reflection (https://eb.host.cs.st-andrews.ac.uk/drafts/elab-reflection.pdf) and decided I wanted to try this this tactic out (found in section 5.2):
mush : Elab ()
mush =
do attack
x <- gensym "x"
intro x
try intros
induction (Var x) `andThen` auto
solve
Supposedly this tactic could prove associativity of addition:
plusAssoc : (j, k, l : Nat) -> plus (plus j k) l = plus j (plus k l)
plusAssoc = %runElab mush
however when trying to typecheck mush I get the following error:
error: not a terminator, expected: "$", "&&", ")", "", ">", "+", "++", "-", "->", ".", "/", "/=", "::", ";", "<", "", "<", "<>", "<+>", "<<", "<=", "<|>", "=", "==", ">", ">=", ">>", ">>=", "\\", "`", "in", "||", "~=~", ambiguous use of a left-associative operator, ambiguous use of a non-associative operator, ambiguous use of a right-associative operator, end of input, matching application expression, where block x <- gensym "x" ^
I do not understand what is wrong, is the mush-tactic not correct or is there something I need to add to my file?