Skip to content

Hard code DEFAULT_LOCALE_RESOURCES in rustc_interface#152137

Open
bjorn3 wants to merge 1 commit intorust-lang:mainfrom
bjorn3:driver_fixed_locale_resources
Open

Hard code DEFAULT_LOCALE_RESOURCES in rustc_interface#152137
bjorn3 wants to merge 1 commit intorust-lang:mainfrom
bjorn3:driver_fixed_locale_resources

Conversation

@bjorn3
Copy link
Member

@bjorn3 bjorn3 commented Feb 4, 2026

locale_resources will no longer be used at all soon, so no need for custom drivers to have the ability to define their own locale_resources. Also hard code report_ice to not use any locale resources. It only emits diagnostics that have already been ported to inline fluent messages.

Part of #151366, cc @JonathanBrouwer

@rustbot
Copy link
Collaborator

rustbot commented Feb 4, 2026

The rustc-dev-guide subtree was changed. If this PR only touches the dev guide consider submitting a PR directly to rust-lang/rustc-dev-guide otherwise thank you for updating the dev guide with your changes.

cc @BoxyUwU, @jieyouxu, @Kobzol, @tshepang

@rustbot rustbot added the A-rustc-dev-guide Area: rustc-dev-guide label Feb 4, 2026
@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. labels Feb 4, 2026
@rustbot
Copy link
Collaborator

rustbot commented Feb 4, 2026

r? @jdonszelmann

rustbot has assigned @jdonszelmann.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@rust-log-analyzer

This comment has been minimized.

locale_resources will no longer be used at all soon, so no need for
custom drivers to have the ability to define their own locale_resources.
Also hard code report_ice to not use any locale resources. It only emits
diagnostics that have already been ported to inline fluent messages.
@bjorn3 bjorn3 force-pushed the driver_fixed_locale_resources branch from 8f3dce7 to dbf46f0 Compare February 4, 2026 19:54

// Create a Parser.
let psess = ParseSess::new(rustc_driver::DEFAULT_LOCALE_RESOURCES.to_vec());
let psess = ParseSess::new(vec![]);
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this is fine as we cancel all errors below rather than emit them.

@rust-log-analyzer
Copy link
Collaborator

The job pr-check-2 failed! Check out the build log: (web) (plain enhanced) (plain)

Click to see the possible cause of the failure (guessed by this bot)
REPOSITORY                                   TAG       IMAGE ID       CREATED      SIZE
ghcr.io/dependabot/dependabot-updater-core   latest    bcec0b4e062b   9 days ago   783MB
=> Removing docker images...
Deleted Images:
untagged: ghcr.io/dependabot/dependabot-updater-core:latest
untagged: ghcr.io/dependabot/dependabot-updater-core@sha256:b662be51f7b8ef7e2c8464428f14e49cb79c36aa9afb7ecb9221dfe0f507050c
deleted: sha256:bcec0b4e062b5ffe11cc1c2729558c0cd96621c0271ab5e97ff3a56e0c25045a
deleted: sha256:64e147d5e54d9be8b8aa322e511cda02296eda4b8b8d063c6a314833aca50e29
deleted: sha256:5cba409bb463f4e7fa1a19f695450170422582c1bc7c0e934d893b4e5f558bc6
deleted: sha256:cddc6ebd344b0111eaab170ead1dfda24acdfe865ed8a12599a34d338fa8e28b
deleted: sha256:2412c3f334d79134573cd45e657fb6cc0abd75bef3881458b0d498d936545c8d

@JonathanBrouwer
Copy link
Contributor

I'd like to wait a few days with merging this until the spam of diagnostics convert PRs has calmed down, as this will conflict with all of them

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-rustc-dev-guide Area: rustc-dev-guide S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants