fix(doctest): treat fatal parse errors as incomplete attributes#99142
Conversation
|
(rust-highfive has picked a reviewer for you, use r? to override) |
|
I'm a bit lost about this change: you added the support for sending compilation errors somewhere else that |
|
Rustdoc already has the infrastructure in place to recognize unterminated crate attributes. rust/src/librustdoc/doctest.rs Line 826 in 6c44357 The only reason it didn’t work is that unclosed quotes are a Fatal error in rustc, which is implemented by panicking. That means I need to catch the panic (which |
|
Thanks for the explanations! @bors r+ rollup |
…ne-crate-attributes, r=GuillaumeGomez fix(doctest): treat fatal parse errors as incomplete attributes Fixes rust-lang#99089
…ne-crate-attributes, r=GuillaumeGomez fix(doctest): treat fatal parse errors as incomplete attributes Fixes rust-lang#99089
…ne-crate-attributes, r=GuillaumeGomez fix(doctest): treat fatal parse errors as incomplete attributes Fixes rust-lang#99089
…askrgr Rollup of 8 pull requests Successful merges: - rust-lang#97210 (Support `-A`, `-W`, `-D` and `-F` when running `./x.py clippy`) - rust-lang#99055 (Fix rustdoc help options) - rust-lang#99075 (Fix duplicated type annotation suggestion) - rust-lang#99124 (Fix sized check ICE in asm check) - rust-lang#99142 (fix(doctest): treat fatal parse errors as incomplete attributes) - rust-lang#99145 (Don't rerun the build script for the compiler each time on non-windows platforms) - rust-lang#99146 (Do not error during method probe on `Sized` predicates for types that aren't the method receiver) - rust-lang#99161 (compiletest: trim edition before passing as flag) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
Fixes #99089