Skip to content

Commit 64515a4

Browse files
borsMuscraft
authored andcommitted
Auto merge of rust-lang#149002 - matthiaskrgr:rollup-tbjck7g, r=matthiaskrgr
Rollup of 7 pull requests Successful merges: - rust-lang#148703 (Use `overflow_checks` intrinsic so `IterRangeFrom` yields MAX before panicking in debug) - rust-lang#148881 (use `cfg_select!` to pick assembly in codegen test) - rust-lang#148911 (Make flags from `*FLAGS*` (such as `RUSTFLAGS`) env. vars. have precedence over flags set by bootstrap) - rust-lang#148914 (fix incorrect import in `std_detect` on `aarch64-unknown-openbsd`) - rust-lang#148971 (Document Error::{new,other} as to be avoided in pre_exec) - rust-lang#148983 (Use rustc target metadata for build-manifest target lists) - rust-lang#148995 (add must_use to extract_if methods) r? `@ghost` `@rustbot` modify labels: rollup
2 parents 43b97a2 + 046e090 commit 64515a4

File tree

34 files changed

+432
-267
lines changed

34 files changed

+432
-267
lines changed

compiler/rustc_target/src/spec/targets/aarch64_pc_windows_gnullvm.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ pub(crate) fn target() -> Target {
1717
metadata: TargetMetadata {
1818
description: Some("ARM64 MinGW (Windows 10+), LLVM ABI".into()),
1919
tier: Some(2),
20-
host_tools: Some(false),
20+
host_tools: Some(true),
2121
std: Some(true),
2222
},
2323
pointer_width: 64,

compiler/rustc_target/src/spec/targets/i586_unknown_linux_gnu.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,11 @@ pub(crate) fn target() -> Target {
55
base.rustc_abi = None; // overwrite the SSE2 ABI set by the base target
66
base.cpu = "pentium".into();
77
base.llvm_target = "i586-unknown-linux-gnu".into();
8+
base.metadata = crate::spec::TargetMetadata {
9+
description: Some("32-bit Linux (kernel 3.2, glibc 2.17+)".into()),
10+
tier: Some(2),
11+
host_tools: Some(false),
12+
std: Some(true),
13+
};
814
base
915
}

compiler/rustc_target/src/spec/targets/sparcv9_sun_solaris.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ pub(crate) fn target() -> Target {
1818
metadata: TargetMetadata {
1919
description: Some("SPARC Solaris 11.4".into()),
2020
tier: Some(2),
21-
host_tools: Some(false),
21+
host_tools: Some(true),
2222
std: Some(true),
2323
},
2424
pointer_width: 64,

compiler/rustc_target/src/spec/targets/wasm32_wasip2.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ pub(crate) fn target() -> Target {
6363
llvm_target: "wasm32-wasip2".into(),
6464
metadata: TargetMetadata {
6565
description: Some("WebAssembly".into()),
66-
tier: Some(3),
66+
tier: Some(2),
6767
host_tools: Some(false),
6868
std: Some(true),
6969
},

compiler/rustc_target/src/spec/targets/wasm32_wasip3.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,12 @@ pub(crate) fn target() -> Target {
1515
// and this may grow over time as more features are supported.
1616
let mut target = super::wasm32_wasip2::target();
1717
target.llvm_target = "wasm32-wasip3".into();
18+
target.metadata = crate::spec::TargetMetadata {
19+
description: Some("WebAssembly".into()),
20+
tier: Some(3),
21+
host_tools: Some(false),
22+
std: Some(true),
23+
};
1824
target.options.env = Env::P3;
1925
target
2026
}

compiler/rustc_target/src/spec/targets/x86_64_pc_solaris.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ pub(crate) fn target() -> Target {
2020
metadata: TargetMetadata {
2121
description: Some("64-bit Solaris 11.4".into()),
2222
tier: Some(2),
23-
host_tools: Some(false),
23+
host_tools: Some(true),
2424
std: Some(true),
2525
},
2626
pointer_width: 64,

compiler/rustc_target/src/spec/targets/x86_64_pc_windows_gnullvm.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ pub(crate) fn target() -> Target {
1414
metadata: TargetMetadata {
1515
description: Some("64-bit x86 MinGW (Windows 10+), LLVM ABI".into()),
1616
tier: Some(2),
17-
host_tools: Some(false),
17+
host_tools: Some(true),
1818
std: Some(true),
1919
},
2020
pointer_width: 64,

library/alloc/src/collections/btree/map.rs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1434,7 +1434,8 @@ impl<K, V, A: Allocator + Clone> BTreeMap<K, V, A> {
14341434
///
14351435
/// If the returned `ExtractIf` is not exhausted, e.g. because it is dropped without iterating
14361436
/// or the iteration short-circuits, then the remaining elements will be retained.
1437-
/// Use [`retain`] with a negated predicate if you do not need the returned iterator.
1437+
/// Use `extract_if().for_each(drop)` if you do not need the returned iterator,
1438+
/// or [`retain`] with a negated predicate if you also do not need to restrict the range.
14381439
///
14391440
/// [`retain`]: BTreeMap::retain
14401441
///
@@ -1945,7 +1946,8 @@ impl<K, V> Default for Values<'_, K, V> {
19451946

19461947
/// An iterator produced by calling `extract_if` on BTreeMap.
19471948
#[stable(feature = "btree_extract_if", since = "1.91.0")]
1948-
#[must_use = "iterators are lazy and do nothing unless consumed"]
1949+
#[must_use = "iterators are lazy and do nothing unless consumed; \
1950+
use `retain` or `extract_if().for_each(drop)` to remove and discard elements"]
19491951
pub struct ExtractIf<
19501952
'a,
19511953
K,

library/alloc/src/collections/btree/set.rs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1189,7 +1189,8 @@ impl<T, A: Allocator + Clone> BTreeSet<T, A> {
11891189
///
11901190
/// If the returned `ExtractIf` is not exhausted, e.g. because it is dropped without iterating
11911191
/// or the iteration short-circuits, then the remaining elements will be retained.
1192-
/// Use [`retain`] with a negated predicate if you do not need the returned iterator.
1192+
/// Use `extract_if().for_each(drop)` if you do not need the returned iterator,
1193+
/// or [`retain`] with a negated predicate if you also do not need to restrict the range.
11931194
///
11941195
/// [`retain`]: BTreeSet::retain
11951196
/// # Examples
@@ -1547,7 +1548,8 @@ impl<'a, T, A: Allocator + Clone> IntoIterator for &'a BTreeSet<T, A> {
15471548

15481549
/// An iterator produced by calling `extract_if` on BTreeSet.
15491550
#[stable(feature = "btree_extract_if", since = "1.91.0")]
1550-
#[must_use = "iterators are lazy and do nothing unless consumed"]
1551+
#[must_use = "iterators are lazy and do nothing unless consumed; \
1552+
use `retain` or `extract_if().for_each(drop)` to remove and discard elements"]
15511553
pub struct ExtractIf<
15521554
'a,
15531555
T,

library/alloc/src/collections/linked_list.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1943,7 +1943,8 @@ impl<'a, T, A: Allocator> CursorMut<'a, T, A> {
19431943

19441944
/// An iterator produced by calling `extract_if` on LinkedList.
19451945
#[stable(feature = "extract_if", since = "1.87.0")]
1946-
#[must_use = "iterators are lazy and do nothing unless consumed"]
1946+
#[must_use = "iterators are lazy and do nothing unless consumed; \
1947+
use `extract_if().for_each(drop)` to remove and discard elements"]
19471948
pub struct ExtractIf<
19481949
'a,
19491950
T: 'a,

0 commit comments

Comments
 (0)