Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rollup of 8 pull requests #79138

Merged
merged 25 commits into from
Nov 17, 2020
Merged
Changes from 1 commit
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
efe703a
[self-profiling] Include the estimated size of each cgu in the profile
wesleywiser Nov 3, 2020
279bf29
Get rid of `Class::None`
jyn514 Nov 15, 2020
74d5466
update rustfmt to v1.4.27
calebcartwright Nov 17, 2020
b3f9795
Get rid of clean::TyMethod
jyn514 Nov 17, 2020
2a991e1
Get rid of clean::Method
jyn514 Nov 17, 2020
5903163
Remove duplicate `Trait::auto` field
jyn514 Nov 17, 2020
a1cdf72
Fix exhaustiveness in case a byte string literal is used at slice type
oli-obk Nov 15, 2020
5f2a627
extend macro braces test
lcnr Nov 17, 2020
96a6a5f
Add color in rustdoc --test output
GuillaumeGomez Jul 13, 2020
54e8216
Update error code detection in compile_fail doctests
GuillaumeGomez Jul 14, 2020
57bab5e
Add check to get windows console type to decide to use colors or not
GuillaumeGomez Jul 16, 2020
704001b
Update lock file
GuillaumeGomez Jul 16, 2020
32d64ed
Simplfy color availability check
GuillaumeGomez Nov 11, 2020
fd4a33c
Update doctest tests
GuillaumeGomez Nov 11, 2020
95ee1fc
Correctly detect color support
GuillaumeGomez Nov 12, 2020
63785c8
Add comment explaining why we can't split on `error[{}]: ` because of…
GuillaumeGomez Nov 13, 2020
ec10824
Remove unused import
GuillaumeGomez Nov 15, 2020
81f9feb
Rollup merge of #74293 - GuillaumeGomez:rustdoc-test-compiler-output-…
m-ou-se Nov 17, 2020
fa45fce
Rollup merge of #78702 - wesleywiser:self_profile_cgu_sizes, r=Mark-S…
m-ou-se Nov 17, 2020
dda4798
Rollup merge of #79069 - jyn514:class-none, r=GuillaumeGomez
m-ou-se Nov 17, 2020
b6f5241
Rollup merge of #79072 - oli-obk:byte_str_pat, r=estebank
m-ou-se Nov 17, 2020
53ddb73
Rollup merge of #79120 - calebcartwright:update-rustfmt, r=Mark-Simul…
m-ou-se Nov 17, 2020
3d63f25
Rollup merge of #79125 - jyn514:fewer-types, r=GuillaumeGomez
m-ou-se Nov 17, 2020
ca38bd4
Rollup merge of #79126 - jyn514:auto, r=GuillaumeGomez
m-ou-se Nov 17, 2020
f698505
Rollup merge of #79130 - lcnr:extend-tes, r=varkor
m-ou-se Nov 17, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions src/librustdoc/doctest.rs
Original file line number Diff line number Diff line change
@@ -428,11 +428,13 @@ crate fn make_test(
// Any errors in parsing should also appear when the doctest is compiled for real, so just
// send all the errors that librustc_ast emits directly into a `Sink` instead of stderr.
let sm = Lrc::new(SourceMap::new(FilePathMapping::empty()));
supports_color =
EmitterWriter::stderr(ColorConfig::Auto, None, false, false, Some(80), false)
.supports_color();

let emitter =
EmitterWriter::new(box io::sink(), None, false, false, false, None, false);

supports_color = emitter.supports_color();

// FIXME(misdreavus): pass `-Z treat-err-as-bug` to the doctest parser
let handler = Handler::with_emitter(false, None, box emitter);
let sess = ParseSess::with_span_handler(handler, sm);