fix: make Term.mkAuxName async-compatible (#7468)

This commit is contained in:
Sebastian Ullrich 2025-03-13 13:24:24 +01:00 committed by GitHub
parent 137f559520
commit a014ae1001
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1891,7 +1891,7 @@ def addAutoBoundImplicits' (xs : Array Expr) (type : Expr) (k : Array Expr → E
forallBoundedTelescope (← mkForallFVars xs type) xs.size fun xs type => k xs type
def mkAuxName (suffix : Name) : TermElabM Name := do
match (← read).declName? with
match (← read).declName? <|> (← getEnv).asyncPrefix? with
| none => Lean.mkAuxName (mkPrivateName (← getEnv) `aux) 1
| some declName => Lean.mkAuxName (declName ++ suffix) 1