Skip to content

Commit a4740a1

Browse files
authored
Rollup merge of rust-lang#108433 - compiler-errors:missing-provider-nit, r=Nilstrieb
Wrap missing provider message correctly Fixes rust-lang#108429 ``` error: internal compiler error: compiler/rustc_middle/src/ty/query.rs:441:1: `tcx.trigger_delay_span_bug(DefId(0:3 ~ test[78c5]::main))` is not supported for local crate; hint: Queries can be either made to the local crate, or the external crate. This error means you tried to use it for one that's not supported. If that's not the case, trigger_delay_span_bug was likely never assigned to a provider function. thread 'rustc' panicked at 'Box<dyn Any>', /home/ec2-user/rust3/compiler/rustc_errors/src/lib.rs:1651:9 stack backtrace: 0: 0x7f51870926d7 - std::backtrace_rs::backtrace::libunwind::trace::hb0876bb39e7adf0d at /home/ec2-user/rust3/library/std/src/../../backtrace/src/backtrace/libunwind.rs:93:5 1: 0x7f51870926d7 - std::backtrace_rs::backtrace::trace_unsynchronized::h1bcab1313827007b at /home/ec2-user/rust3/library/std/src/../../backtrace/src/backtrace/mod.rs:66:5 2: 0x7f5187077e07 - std::sys_common::backtrace::_print_fmt::h262d2a62279fa102 at /home/ec2-user/rust3/library/std/src/sys_common/backtrace.rs:65:5 ```
2 parents 47c7d53 + a861b19 commit a4740a1

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

compiler/rustc_middle/src/ty/query.rs

+3-2
Original file line numberDiff line numberDiff line change
@@ -328,8 +328,9 @@ macro_rules! define_callbacks {
328328

329329
Providers {
330330
$($name: |_, key| bug!(
331-
"`tcx.{}({:?})` is not supported for {} crate;\n
332-
hint: Queries can be either made to the local crate, or the external crate. This error means you tried to use it for one that's not supported.\n
331+
"`tcx.{}({:?})` is not supported for {} crate;\n\
332+
hint: Queries can be either made to the local crate, or the external crate. \
333+
This error means you tried to use it for one that's not supported.\n\
333334
If that's not the case, {} was likely never assigned to a provider function.\n",
334335
stringify!($name),
335336
key,

0 commit comments

Comments
 (0)