-
Notifications
You must be signed in to change notification settings - Fork 433
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: do not propagate pretty printer errors through messages #3696
Conversation
Mathlib CI status (docs):
|
I guess this needs |
Looking through the Mathlib/Std failures, there are some direct replications of @semorrison Should I make PRs to the Mathlib/Std testing branches or is this something you can handle? |
Sorry, missed this earlier. Could you rebase onto |
@tydeu, would you be able to rebase this onto |
@kim-em I can certainly try! :-) |
Mathlib CI status (docs):
|
@kim-em The PR is now updated and rebased on the latest |
Mathlib fix looks straightforward, hopefully CI will agree. |
@kim-em LGTM! Should I throw it on the queue? |
This PR makes all message constructors handle pretty printer errors.
Prior to this change, pretty printer errors in messages were not uniformly handled. In core, some printers capture their errors (e.g.,
ppExprWithInfos
andppTerm
) and some do not (e.g.,ppGoal
andppSignature
) propagate them to whatever serializes the message (e.g., the frontend).To resolve this inconsistency and uniformly handle errors, the signature for
ofLazy
now usesBaseIO
. As such, all printers been adapted to capture any errors within them and print similar messages toppExprWithInfos
andppTerm
on such errors.