fix: withPosition case at MacroArgUtil

fixes #1267 after update stage0
This commit is contained in:
Leonardo de Moura 2022-06-29 15:35:34 -07:00
parent 1b7fab4497
commit 95efa3dcd2

View file

@ -33,7 +33,9 @@ where
| `(stx| interpolatedStr(term)) => pure ⟨Syntax.mkAntiquotNode interpolatedStrKind id⟩
-- bind through withPosition
| `(stx| withPosition($stx)) =>
return (← mkSyntaxAndPat id? id stx)
let (stx, pat) ← mkSyntaxAndPat id? id stx
let stx ← `(stx| withPosition($stx))
return (stx, pat)
| _ => match id? with
-- if there is a binding, we assume the user knows what they are doing
| some id => mkAntiquotNode stx id