mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
Add LangOptions::EnableTargetOSChecking, so that LLDB can ignore OS mismatches.
In particular, this is problematic when libraries are loaded dynamically, and may have newer deployment targets than the main executable. Swift SVN r26786
This commit is contained in:
@@ -1007,7 +1007,9 @@ Status ModuleFile::associateWithFileContext(FileUnit *file,
|
||||
if (!areCompatibleArchitectures(moduleTarget, ctx.LangOpts.Target) ||
|
||||
!areCompatibleOSs(moduleTarget, ctx.LangOpts.Target)) {
|
||||
return error(Status::TargetIncompatible);
|
||||
} else if (isTargetTooNew(moduleTarget, ctx.LangOpts.Target)) {
|
||||
}
|
||||
if (ctx.LangOpts.EnableTargetOSChecking &&
|
||||
isTargetTooNew(moduleTarget, ctx.LangOpts.Target)) {
|
||||
return error(Status::TargetTooNew);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user