-
-
Notifications
You must be signed in to change notification settings - Fork 14.8k
Regression: E0152 duplicate lang item 'sized' when using -Z build-std with Apple iOS targets #145629
Copy link
Copy link
Closed as duplicate of#145594
Closed as duplicate of#145594
Copy link
Labels
-Zfixed-x18Unstable option: -Zfixed-x18Unstable option: -Zfixed-x18E-needs-bisectionCall for participation: This issue needs bisection: https://github.com/rust-lang/cargo-bisect-rustcCall for participation: This issue needs bisection: https://github.com/rust-lang/cargo-bisect-rustcO-appleOperating system: Apple / Darwin (macOS, iOS, tvOS, visionOS, watchOS)Operating system: Apple / Darwin (macOS, iOS, tvOS, visionOS, watchOS)O-iosOperating system: iOSOperating system: iOSS-needs-reproStatus: This issue has no reproduction and needs a reproduction to make progress.Status: This issue has no reproduction and needs a reproduction to make progress.regression-from-stable-to-nightlyPerformance or correctness regression from stable to nightly.Performance or correctness regression from stable to nightly.
Metadata
Metadata
Assignees
Labels
-Zfixed-x18Unstable option: -Zfixed-x18Unstable option: -Zfixed-x18E-needs-bisectionCall for participation: This issue needs bisection: https://github.com/rust-lang/cargo-bisect-rustcCall for participation: This issue needs bisection: https://github.com/rust-lang/cargo-bisect-rustcO-appleOperating system: Apple / Darwin (macOS, iOS, tvOS, visionOS, watchOS)Operating system: Apple / Darwin (macOS, iOS, tvOS, visionOS, watchOS)O-iosOperating system: iOSOperating system: iOSS-needs-reproStatus: This issue has no reproduction and needs a reproduction to make progress.Status: This issue has no reproduction and needs a reproduction to make progress.regression-from-stable-to-nightlyPerformance or correctness regression from stable to nightly.Performance or correctness regression from stable to nightly.
Type
Fields
Give feedbackNo fields configured for issues without a type.
Code
I tried this code:
I expected to see this happen: The project should compile successfully for Apple iOS targets when using
-Z build-std.Instead, this happened: Compilation fails with duplicate lang item error during
std_detectcrate compilation:Version it worked on
It most recently worked on: nightly-2025-08-15 (rustc 1.91.0-nightly (898aff7 2025-08-14))
Version with regression
rustc --version --verbose:Additional Information
aarch64-apple-ios,aarch64-apple-ios-sim,x86_64-apple-ios-Z build-stdflag combinationsThe error suggests that there are conflicting definitions of the
sizedlang item between the locally builtcorecrate (via-Z build-std) and the pre-compiledcorecrate from the toolchain.@rustbot modify labels: +regression-from-stable-to-nightly -regression-untriaged