Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR is built on the following PRs: (EDIT: now all of them merged)
Span
s to detect "system crate"s, for error deferral (zombie) purposes. #952bimap
dependency with a more efficient pair of maps, and arena-allocate slices. #951Sadly, this is not ready. The big issue here is that Rust 2021 makespanic!("...")
go through the sameformat_args!("...")
machinery as everything else (i.e. its special-casing was removed - this means that e.g.panic!("foo: {}")
no long bypasses format string checks, and actually errors).While we should have the ability to ignore such things, there's enough going on that our panic entry-point special-casing (plus thefn
param weakening, maybe?) doesn't actually bypass the "zombie" systems enough.My best guess so far is that, unlike a string literal constant,format_args!
actually needs local variables, and the "zombie" system's concept of "dead code" might not include them.So far my efforts have focused on improving the granularity of the "zombie" system (hence the other PRs), to better debug such failure modes (when I started, it kept pointing atptr::metadata
, which is pretty useless).EDIT: the new Rust 2021
panic!
(which always usesformat_args!
) is now supported (by removing simple invocations offormat_args!
feeding directly into a panic entry-point)