diff options
| author | Mads Marquart <mads@marquart.dk> | 2024-09-29 22:14:55 +0200 | 
|---|---|---|
| committer | Mads Marquart <mads@marquart.dk> | 2024-11-01 17:07:19 +0100 | 
| commit | 1ef1af1c607fe268b5622041ff586ca603b8ec8d (patch) | |
| tree | 7feb7e4172e76ae899c5989e2d372b9daabdffaa /compiler/rustc_codegen_ssa/src/errors.rs | |
| parent | e75a7ddad37feea205df1e4b568a5316b31da641 (diff) | |
| download | rust-1ef1af1c607fe268b5622041ff586ca603b8ec8d.tar.gz rust-1ef1af1c607fe268b5622041ff586ca603b8ec8d.zip | |
Emit diagnostics for incorrect deployment targets
Diffstat (limited to 'compiler/rustc_codegen_ssa/src/errors.rs')
| -rw-r--r-- | compiler/rustc_codegen_ssa/src/errors.rs | 9 | 
1 files changed, 9 insertions, 0 deletions
| diff --git a/compiler/rustc_codegen_ssa/src/errors.rs b/compiler/rustc_codegen_ssa/src/errors.rs index d67cf0e3a6d..cf8d1cfa0d1 100644 --- a/compiler/rustc_codegen_ssa/src/errors.rs +++ b/compiler/rustc_codegen_ssa/src/errors.rs @@ -2,6 +2,7 @@ use std::borrow::Cow; use std::io::Error; +use std::num::ParseIntError; use std::path::{Path, PathBuf}; use std::process::ExitStatus; @@ -540,6 +541,14 @@ pub(crate) struct UnsupportedArch<'a> { } #[derive(Diagnostic)] +pub(crate) enum AppleDeploymentTarget { + #[diag(codegen_ssa_apple_deployment_target_invalid)] + Invalid { env_var: &'static str, error: ParseIntError }, + #[diag(codegen_ssa_apple_deployment_target_too_low)] + TooLow { env_var: &'static str, version: String, os_min: String }, +} + +#[derive(Diagnostic)] pub(crate) enum AppleSdkRootError<'a> { #[diag(codegen_ssa_apple_sdk_error_sdk_path)] SdkPath { sdk_name: &'a str, error: Error }, | 
