summary refs log tree commit diff
path: root/compiler/rustc_target/src
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2024-10-02 16:24:05 +0000
committerbors <bors@rust-lang.org>2024-10-02 16:24:05 +0000
commit5384697e9e73709301850a414e1cc40324e6460b (patch)
tree125ebc0214a035ac43fd09ee1a5edade5a3b1603 /compiler/rustc_target/src
parent44722bd9ba50426191f78d12138a2ae1a12affe7 (diff)
parentb38f7ad9b18ae2bc7e8073e7ec64453ac617f516 (diff)
downloadrust-5384697e9e73709301850a414e1cc40324e6460b.tar.gz
rust-5384697e9e73709301850a414e1cc40324e6460b.zip
Auto merge of #131158 - matthiaskrgr:rollup-3x2vado, r=matthiaskrgr
Rollup of 7 pull requests

Successful merges:

 - #130863 (Relax a debug assertion for dyn principal *equality* in codegen)
 - #131016 (Apple: Do not specify an SDK version in `rlib` object files)
 - #131140 (Handle `rustc_hir_analysis` cases of `potential_query_instability` lint)
 - #131141 (mpmc doctest: make sure main thread waits for child threads)
 - #131150 (only query `params_in_repr` if def kind is adt)
 - #131151 (Replace zero-width whitespace with a visible `\` in the PR template)
 - #131152 (Improve const traits diagnostics for new desugaring)

r? `@ghost`
`@rustbot` modify labels: rollup
Diffstat (limited to 'compiler/rustc_target/src')
-rw-r--r--compiler/rustc_target/src/spec/base/apple/mod.rs17
-rw-r--r--compiler/rustc_target/src/spec/mod.rs2
2 files changed, 1 insertions, 18 deletions
diff --git a/compiler/rustc_target/src/spec/base/apple/mod.rs b/compiler/rustc_target/src/spec/base/apple/mod.rs
index 81b5a936d35..73763cf034c 100644
--- a/compiler/rustc_target/src/spec/base/apple/mod.rs
+++ b/compiler/rustc_target/src/spec/base/apple/mod.rs
@@ -158,23 +158,6 @@ pub(crate) fn base(
     (opts, llvm_target(os, arch, abi), arch.target_arch())
 }
 
-pub fn sdk_version(platform: u32) -> Option<(u16, u8)> {
-    // NOTE: These values are from an arbitrary point in time but shouldn't make it into the final
-    // binary since the final link command will have the current SDK version passed to it.
-    match platform {
-        object::macho::PLATFORM_MACOS => Some((13, 1)),
-        object::macho::PLATFORM_IOS
-        | object::macho::PLATFORM_IOSSIMULATOR
-        | object::macho::PLATFORM_TVOS
-        | object::macho::PLATFORM_TVOSSIMULATOR
-        | object::macho::PLATFORM_MACCATALYST => Some((16, 2)),
-        object::macho::PLATFORM_WATCHOS | object::macho::PLATFORM_WATCHOSSIMULATOR => Some((9, 1)),
-        // FIXME: Upgrade to `object-rs` 0.33+ implementation with visionOS platform definition
-        11 | 12 => Some((1, 0)),
-        _ => None,
-    }
-}
-
 pub fn platform(target: &Target) -> Option<u32> {
     Some(match (&*target.os, &*target.abi) {
         ("macos", _) => object::macho::PLATFORM_MACOS,
diff --git a/compiler/rustc_target/src/spec/mod.rs b/compiler/rustc_target/src/spec/mod.rs
index d1fcfe4adef..c557091242e 100644
--- a/compiler/rustc_target/src/spec/mod.rs
+++ b/compiler/rustc_target/src/spec/mod.rs
@@ -61,7 +61,7 @@ pub mod crt_objects;
 mod base;
 pub use base::apple::{
     deployment_target_for_target as current_apple_deployment_target,
-    platform as current_apple_platform, sdk_version as current_apple_sdk_version,
+    platform as current_apple_platform,
 };
 pub use base::avr_gnu::ef_avr_arch;