mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
[Serialization] Wire up archetype generic environments eagerly.
Teach the serialized form of ArchetypeType about its owning generic environment, so we can wire up the generic environment of (primary) archetypes eagerly (at the point of deserialization) rather than when we form the generic environment. This ensures that there is no point at which we have a (non-opened-existential) archetype without a generic environment. ... except that the type reconstruction code creates such archetypes.
This commit is contained in:
@@ -529,17 +529,6 @@ private:
|
||||
serialization::DeclID willSet,
|
||||
serialization::DeclID didSet);
|
||||
|
||||
/// Return the generic signature or environment at the current position in
|
||||
/// the given cursor.
|
||||
///
|
||||
/// \param cursor The cursor to read from.
|
||||
/// \param wantEnvironment Whether we always want to receive a generic
|
||||
/// environment vs. being able to handle the generic signature.
|
||||
llvm::PointerUnion<GenericSignature *, GenericEnvironment *>
|
||||
readGenericSignatureOrEnvironment(
|
||||
llvm::BitstreamCursor &cursor,
|
||||
bool wantEnvironment);
|
||||
|
||||
public:
|
||||
/// Loads a module from the given memory buffer.
|
||||
///
|
||||
|
||||
Reference in New Issue
Block a user