Hide diagnostics emitted during --cfg parsing#64467
Merged
bors merged 1 commit intorust-lang:masterfrom Sep 16, 2019
Merged
Conversation
Contributor
|
r? @cramertj (rust_highfive has picked a reviewer for you, use r? to override) |
Member
Author
|
I'm not entirely sure if the NullEmitter approach is the right one but it seems reasonable. r? @estebank I guess |
Contributor
|
Could you add a test? R=me |
3121dad to
365d218
Compare
Member
Author
|
Added a test but I'll let PR CI check if it passes. |
Contributor
|
The job Click to expand the log.I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact |
The early error is more than sufficient for fixing the problem.
365d218 to
a678e31
Compare
Member
Author
|
@bors r=estebank |
Collaborator
|
📌 Commit a678e31 has been approved by |
Centril
added a commit
to Centril/rust
that referenced
this pull request
Sep 16, 2019
…r=estebank Hide diagnostics emitted during --cfg parsing The early error is more than sufficient for fixing the problem. Fixes rust-lang#31496.
bors
added a commit
that referenced
this pull request
Sep 16, 2019
Rollup of 10 pull requests Successful merges: - #63955 (Make sure interned constants are immutable) - #64028 (Stabilize `Vec::new` and `String::new` as `const fn`s) - #64119 (ci: ensure all tool maintainers are assignable on issues) - #64444 (fix building libstd without backtrace feature) - #64446 (Fix build script sanitizer check.) - #64451 (when Miri tests are not passing, do not add Miri component) - #64467 (Hide diagnostics emitted during --cfg parsing) - #64497 (Don't print the "total" `-Ztime-passes` output if `--prints=...` is also given) - #64499 (Use `Symbol` in two more functions.) - #64504 (use println!() instead of println!("")) Failed merges: r? @ghost
matthiaskrgr
pushed a commit
to matthiaskrgr/rust
that referenced
this pull request
Jan 1, 2022
Fixes rust-lang#73026 See also: rust-lang#64467, rust-lang#89468 The issue stems from a `FatalError` being silently raised in `panictry_buffer`. Normally this is not a problem, because `panictry_buffer` emits the causes of the error, but they are not themselves fatal, so they get filtered out by the silent emitter. To fix this, we use a parser entrypoint which doesn't use `panictry_buffer`, and we handle the error ourselves.
matthiaskrgr
added a commit
to matthiaskrgr/rust
that referenced
this pull request
Jan 1, 2022
Emit an error for `--cfg=)` Fixes rust-lang#73026 See also: rust-lang#64467, rust-lang#89468 The issue stems from a `FatalError` being silently raised in `panictry_buffer`. Normally this is not a problem, because `panictry_buffer` emits the causes of the error, but they are not themselves fatal, so they get filtered out by the silent emitter. To fix this, we use a parser entrypoint which doesn't use `panictry_buffer`, and we handle the error ourselves.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
The early error is more than sufficient for fixing the problem.
Fixes #31496.