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
Make early lints translatable #124417
base: master
Are you sure you want to change the base?
Make early lints translatable #124417
Conversation
Some changes occurred in check-cfg diagnostics cc @Urgau
cc @davidtwco, @compiler-errors, @TaKO8Ki Some changes occurred in tests/ui/check-cfg cc @Urgau |
This comment has been minimized.
This comment has been minimized.
☔ The latest upstream changes (presumably #124424) made this pull request unmergeable. Please resolve the merge conflicts. |
Translation of the lint message happens when the actual diagnostic is created, not when the lint is buffered. Generating the message from BuiltinLintDiag ensures that all required data to construct the message is preserved in the LintBuffer, eventually allowing the messages to be moved to fluent. Remove the `msg` field from BufferedEarlyLint, it is either generated from the data in the BuiltinLintDiag or stored inside BuiltinLintDiag::Normal.
This ensures all diagnostic messages are created at diagnostic emission time, making them translatable.
362f064
to
4edd58f
Compare
The job Click to see the possible cause of the failure (guessed by this bot)
|
☔ The latest upstream changes (presumably #124558) made this pull request unmergeable. Please resolve the merge conflicts. |
r? @davidtwco I'm going on vacation for two weeks |
Requires projectfluent/fluent-rs#353.
r? diagnostics