Skip to content

Commit 964a81e

Browse files
committed
Auto merge of rust-lang#86588 - JohnTitor:rollup-ibgjbkf, r=JohnTitor
Rollup of 8 pull requests Successful merges: - rust-lang#86137 (Error code cleanup and enforce checks) - rust-lang#86296 (Add documentation for various THIR structs) - rust-lang#86415 (Document associativity of iterator folds.) - rust-lang#86533 (Support lowercase error codes in `--explain`) - rust-lang#86536 (Edition 2021 enables disjoint capture) - rust-lang#86560 (Update cargo) - rust-lang#86561 (chore(rustdoc): Remove unused impl block) - rust-lang#86566 (Use `use_verbose` for `mir::Constant`) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
2 parents f1e691d + 64c9712 commit 964a81e

25 files changed

+319
-158
lines changed

Cargo.lock

+21-7
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@ dependencies = [
180180
"merge",
181181
"num_cpus",
182182
"once_cell",
183-
"opener",
183+
"opener 0.5.0",
184184
"pretty_assertions",
185185
"serde",
186186
"serde_json",
@@ -195,7 +195,9 @@ version = "0.2.13"
195195
source = "registry+https://github.com/rust-lang/crates.io-index"
196196
checksum = "31accafdb70df7871592c058eca3985b71104e15ac32f64706022c58867da931"
197197
dependencies = [
198+
"lazy_static",
198199
"memchr",
200+
"regex-automata",
199201
]
200202

201203
[[package]]
@@ -253,7 +255,7 @@ checksum = "81a18687293a1546b67c246452202bbbf143d239cb43494cc163da14979082da"
253255

254256
[[package]]
255257
name = "cargo"
256-
version = "0.55.0"
258+
version = "0.56.0"
257259
dependencies = [
258260
"anyhow",
259261
"atty",
@@ -288,11 +290,10 @@ dependencies = [
288290
"log",
289291
"memchr",
290292
"num_cpus",
291-
"opener",
293+
"opener 0.5.0",
292294
"openssl",
293295
"percent-encoding 2.1.0",
294296
"pretty_env_logger",
295-
"rand 0.8.3",
296297
"rustc-workspace-hack",
297298
"rustfix 0.6.0",
298299
"semver 1.0.3",
@@ -375,10 +376,12 @@ dependencies = [
375376
"flate2",
376377
"git2",
377378
"glob",
379+
"itertools 0.10.0",
378380
"lazy_static",
379381
"remove_dir_all",
380382
"serde_json",
381383
"tar",
384+
"termcolor",
382385
"toml",
383386
"url 2.2.2",
384387
]
@@ -575,7 +578,7 @@ dependencies = [
575578
"bytecount",
576579
"clap",
577580
"itertools 0.9.0",
578-
"opener",
581+
"opener 0.4.1",
579582
"regex",
580583
"shell-escape",
581584
"walkdir",
@@ -2418,6 +2421,16 @@ dependencies = [
24182421
"winapi 0.3.9",
24192422
]
24202423

2424+
[[package]]
2425+
name = "opener"
2426+
version = "0.5.0"
2427+
source = "registry+https://github.com/rust-lang/crates.io-index"
2428+
checksum = "4ea3ebcd72a54701f56345f16785a6d3ac2df7e986d273eb4395c0b01db17952"
2429+
dependencies = [
2430+
"bstr",
2431+
"winapi 0.3.9",
2432+
]
2433+
24212434
[[package]]
24222435
name = "openssl"
24232436
version = "0.10.33"
@@ -3558,6 +3571,7 @@ dependencies = [
35583571
name = "rustc-workspace-hack"
35593572
version = "1.0.0"
35603573
dependencies = [
3574+
"bstr",
35613575
"byteorder",
35623576
"crossbeam-utils 0.8.3",
35633577
"libc",
@@ -5158,9 +5172,9 @@ dependencies = [
51585172

51595173
[[package]]
51605174
name = "termcolor"
5161-
version = "1.1.0"
5175+
version = "1.1.2"
51625176
source = "registry+https://github.com/rust-lang/crates.io-index"
5163-
checksum = "bb6bfa289a4d7c5766392812c0a1f4c1ba45afa1ad47803c11e1f407d846d75f"
5177+
checksum = "2dfed899f0eb03f32ee8c6a0aabdb8a7949659e3466561fc0adf54e26d88c5f4"
51645178
dependencies = [
51655179
"winapi-util",
51665180
]

compiler/rustc_driver/src/lib.rs

+6-2
Original file line numberDiff line numberDiff line change
@@ -528,8 +528,12 @@ fn stderr_isatty() -> bool {
528528
}
529529

530530
fn handle_explain(registry: Registry, code: &str, output: ErrorOutputType) {
531-
let normalised =
532-
if code.starts_with('E') { code.to_string() } else { format!("E{0:0>4}", code) };
531+
let upper_cased_code = code.to_ascii_uppercase();
532+
let normalised = if upper_cased_code.starts_with('E') {
533+
upper_cased_code
534+
} else {
535+
format!("E{0:0>4}", code)
536+
};
533537
match registry.try_find_description(&normalised) {
534538
Ok(Some(description)) => {
535539
let mut is_in_code_block = false;

compiler/rustc_error_codes/src/error_codes.rs

+4-5
Original file line numberDiff line numberDiff line change
@@ -609,7 +609,7 @@ E0783: include_str!("./error_codes/E0783.md"),
609609
// E0540, // multiple rustc_deprecated attributes
610610
E0544, // multiple stability levels
611611
// E0548, // replaced with a generic attribute input check
612-
E0553, // multiple rustc_const_unstable attributes
612+
// E0553, // multiple rustc_const_unstable attributes
613613
// E0555, // replaced with a generic attribute input check
614614
// E0558, // replaced with a generic attribute input check
615615
// E0563, // cannot determine a type for this `impl Trait` removed in 6383de15
@@ -620,10 +620,9 @@ E0783: include_str!("./error_codes/E0783.md"),
620620
// E0612, // merged into E0609
621621
// E0613, // Removed (merged with E0609)
622622
E0625, // thread-local statics cannot be accessed at compile-time
623-
E0629, // missing 'feature' (rustc_const_unstable)
624-
// rustc_const_unstable attribute must be paired with stable/unstable
625-
// attribute
626-
E0630,
623+
// E0629, // missing 'feature' (rustc_const_unstable)
624+
// E0630, // rustc_const_unstable attribute must be paired with stable/unstable
625+
// attribute
627626
E0632, // cannot provide explicit generic arguments when `impl Trait` is
628627
// used in argument position
629628
E0640, // infer outlives requirements

0 commit comments

Comments
 (0)