mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
NCGenerics: rebuild stdlib from its interface
When a NoncopyableGenericsMismatch happens between the compiler and stdlib, allow the compiler to rebuild the stdlib from its interface instead of exiting with an error.
This commit is contained in:
@@ -426,8 +426,8 @@ static ValidationInfo validateControlBlock(
|
||||
}
|
||||
case control_block::HAS_NONCOPYABLE_GENERICS: {
|
||||
auto hasNoncopyableGenerics = scratch[0];
|
||||
if (requiresNoncopyableGenerics && !hasNoncopyableGenerics)
|
||||
result.status = Status::NotUsingNoncopyableGenerics;
|
||||
if (requiresNoncopyableGenerics != hasNoncopyableGenerics)
|
||||
result.status = Status::NoncopyableGenericsMismatch;
|
||||
break;
|
||||
}
|
||||
default:
|
||||
@@ -533,8 +533,8 @@ std::string serialization::StatusToString(Status S) {
|
||||
case Status::FormatTooNew: return "FormatTooNew";
|
||||
case Status::RevisionIncompatible: return "RevisionIncompatible";
|
||||
case Status::NotInOSSA: return "NotInOSSA";
|
||||
case Status::NotUsingNoncopyableGenerics:
|
||||
return "NotUsingNoncopyableGenerics";
|
||||
case Status::NoncopyableGenericsMismatch:
|
||||
return "NoncopyableGenericsMismatch";
|
||||
case Status::MissingDependency: return "MissingDependency";
|
||||
case Status::MissingUnderlyingModule: return "MissingUnderlyingModule";
|
||||
case Status::CircularDependency: return "CircularDependency";
|
||||
|
||||
Reference in New Issue
Block a user