add const_panic macro to make it easier to fall back to non-formatting panic in const#132542
Conversation
This comment has been minimized.
This comment has been minimized.
|
I am mildly amused about how similar this is to the patch I had but never finished up. Even down to both of us calling the const string "boring" in the example 😆 rust/library/core/src/panic.rs Line 196 in 6a9bdd0 |
I copied that example from you ;) |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
|
That's weird, I did run doc tests locally...
|
|
@bors r+ |
There was a problem hiding this comment.
Hm, maybe I shouldn't put them in this file, since this is generally for macros that are stable / intended to be stabilized?
There was a problem hiding this comment.
Did you have it in core::panic before? I guess that could make sense, considering most of the macros in core::panic are doc(hidden) and meant for internal use.
|
☀️ Test successful - checks-actions |
|
Finished benchmarking commit (e3a918e): comparison URL. Overall result: ❌✅ regressions and improvements - please read the text belowOur benchmarks found a performance regression caused by this PR. Next Steps:
@rustbot label: +perf-regression Instruction countThis is the most reliable metric that we have; it was used to determine the overall result at the top of this comment. However, even this metric can sometimes exhibit noise.
Max RSS (memory usage)Results (primary 3.9%, secondary 3.2%)This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
CyclesResults (primary 0.1%)This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
Binary sizeResults (primary 0.3%, secondary -0.0%)This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
Bootstrap: 780.556s -> 780.261s (-0.04%) |
|
@RalfJung looks like most of the regressions are taking longer in LLVM related queries (e.g., |
|
Looking at just the first two benchmarks, this seems to have immediately gone back to the old state in the next PR. |
|
I looked at the first things it lists when clicking the "instruction count" link. But apparently I just can't read the graph. ;) So, this PR does change the |
|
I'll do some experiments in #132662. |


Suggested by @tgross35
r? @tgross35