From 7e2ecb3cd84eae18e838624feeb2e5cf46b9cc57 Mon Sep 17 00:00:00 2001 From: est31 Date: Fri, 3 Mar 2023 00:18:38 +0100 Subject: Simplify message paths This makes it easier to open the messages file while developing on features. The commit was the result of automatted changes: for p in compiler/rustc_*; do mv $p/locales/en-US.ftl $p/messages.ftl; rmdir $p/locales; done for p in compiler/rustc_*; do sed -i "s#\.\./locales/en-US.ftl#../messages.ftl#" $p/src/lib.rs; done --- compiler/rustc_driver_impl/locales/en-US.ftl | 19 ------------------- compiler/rustc_driver_impl/messages.ftl | 19 +++++++++++++++++++ compiler/rustc_driver_impl/src/lib.rs | 2 +- 3 files changed, 20 insertions(+), 20 deletions(-) delete mode 100644 compiler/rustc_driver_impl/locales/en-US.ftl create mode 100644 compiler/rustc_driver_impl/messages.ftl (limited to 'compiler/rustc_driver_impl') diff --git a/compiler/rustc_driver_impl/locales/en-US.ftl b/compiler/rustc_driver_impl/locales/en-US.ftl deleted file mode 100644 index f19b1ff6426..00000000000 --- a/compiler/rustc_driver_impl/locales/en-US.ftl +++ /dev/null @@ -1,19 +0,0 @@ -driver_impl_rlink_unable_to_read = failed to read rlink file: `{$err}` - -driver_impl_rlink_wrong_file_type = The input does not look like a .rlink file - -driver_impl_rlink_empty_version_number = The input does not contain version number - -driver_impl_rlink_encoding_version_mismatch = .rlink file was produced with encoding version `{$version_array}`, but the current version is `{$rlink_version}` - -driver_impl_rlink_rustc_version_mismatch = .rlink file was produced by rustc version `{$rustc_version}`, but the current version is `{$current_version}` - -driver_impl_rlink_no_a_file = rlink must be a file - -driver_impl_unpretty_dump_fail = pretty-print failed to write `{$path}` due to error `{$err}` - -driver_impl_ice = the compiler unexpectedly panicked. this is a bug. -driver_impl_ice_bug_report = we would appreciate a bug report: {$bug_report_url} -driver_impl_ice_version = rustc {$version} running on {$triple} -driver_impl_ice_flags = compiler flags: {$flags} -driver_impl_ice_exclude_cargo_defaults = some of the compiler flags provided by cargo are hidden diff --git a/compiler/rustc_driver_impl/messages.ftl b/compiler/rustc_driver_impl/messages.ftl new file mode 100644 index 00000000000..f19b1ff6426 --- /dev/null +++ b/compiler/rustc_driver_impl/messages.ftl @@ -0,0 +1,19 @@ +driver_impl_rlink_unable_to_read = failed to read rlink file: `{$err}` + +driver_impl_rlink_wrong_file_type = The input does not look like a .rlink file + +driver_impl_rlink_empty_version_number = The input does not contain version number + +driver_impl_rlink_encoding_version_mismatch = .rlink file was produced with encoding version `{$version_array}`, but the current version is `{$rlink_version}` + +driver_impl_rlink_rustc_version_mismatch = .rlink file was produced by rustc version `{$rustc_version}`, but the current version is `{$current_version}` + +driver_impl_rlink_no_a_file = rlink must be a file + +driver_impl_unpretty_dump_fail = pretty-print failed to write `{$path}` due to error `{$err}` + +driver_impl_ice = the compiler unexpectedly panicked. this is a bug. +driver_impl_ice_bug_report = we would appreciate a bug report: {$bug_report_url} +driver_impl_ice_version = rustc {$version} running on {$triple} +driver_impl_ice_flags = compiler flags: {$flags} +driver_impl_ice_exclude_cargo_defaults = some of the compiler flags provided by cargo are hidden diff --git a/compiler/rustc_driver_impl/src/lib.rs b/compiler/rustc_driver_impl/src/lib.rs index e321a9847ba..555917c8b5e 100644 --- a/compiler/rustc_driver_impl/src/lib.rs +++ b/compiler/rustc_driver_impl/src/lib.rs @@ -64,7 +64,7 @@ use crate::session_diagnostics::{ RLinkWrongFileType, RlinkNotAFile, RlinkUnableToRead, }; -fluent_messages! { "../locales/en-US.ftl" } +fluent_messages! { "../messages.ftl" } pub static DEFAULT_LOCALE_RESOURCES: &[&str] = &[ // tidy-alphabetical-start -- cgit 1.4.1-3-g733a5