mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
Merge remote-tracking branch 'origin/master' into master-next
This commit is contained in:
@@ -244,6 +244,9 @@ private:
|
||||
/// Normal protocol conformances referenced by this module.
|
||||
std::vector<Serialized<NormalProtocolConformance *>> NormalConformances;
|
||||
|
||||
/// SILLayouts referenced by this module.
|
||||
std::vector<Serialized<SILLayout *>> SILLayouts;
|
||||
|
||||
/// Types referenced by this module.
|
||||
std::vector<Serialized<Type>> Types;
|
||||
|
||||
@@ -304,6 +307,9 @@ private:
|
||||
std::unique_ptr<GroupNameTable> GroupNamesMap;
|
||||
std::unique_ptr<SerializedDeclCommentTable> DeclCommentTable;
|
||||
|
||||
/// Saved type substitution maps for lazily-created generic environments.
|
||||
std::vector<std::unique_ptr<TypeSubstitutionMap>> GenericEnvironmentMaps;
|
||||
|
||||
struct ModuleBits {
|
||||
/// The decl ID of the main class in this module file, if it has one.
|
||||
unsigned EntryPointDeclID : 31;
|
||||
@@ -419,7 +425,7 @@ private:
|
||||
/// Recursively reads a pattern from \c DeclTypeCursor.
|
||||
///
|
||||
/// If the record at the cursor is not a pattern, returns null.
|
||||
Pattern *maybeReadPattern();
|
||||
Pattern *maybeReadPattern(DeclContext *owningDC);
|
||||
|
||||
ParameterList *readParameterList();
|
||||
|
||||
@@ -437,7 +443,22 @@ private:
|
||||
void readGenericRequirements(SmallVectorImpl<Requirement> &requirements,
|
||||
llvm::BitstreamCursor &Cursor);
|
||||
|
||||
/// Reads a GenericEnvironment from \c DeclTypeCursor.
|
||||
/// Allocate a lazy generic environment map for use with lazily deserialized
|
||||
/// generic environments.
|
||||
uint64_t allocateLazyGenericEnvironmentMap(TypeSubstitutionMap &&map);
|
||||
|
||||
/// Set up a lazy generic environment for the given type or extension.
|
||||
void readLazyGenericEnvironment(
|
||||
llvm::PointerUnion<GenericTypeDecl *, ExtensionDecl *> typeOrExt);
|
||||
|
||||
/// Read the generic signature and type substitution map for a
|
||||
/// generic environment from \c Cursor.
|
||||
std::pair<GenericSignature *, TypeSubstitutionMap>
|
||||
readGenericEnvironmentPieces(llvm::BitstreamCursor &Cursor,
|
||||
Optional<ArrayRef<Requirement>> optRequirements
|
||||
= None);
|
||||
|
||||
/// Reads a GenericEnvironment from \c Cursor.
|
||||
///
|
||||
/// The optional requirements are used to construct the signature without
|
||||
/// attempting to deserialize any requirements, such as when reading SIL.
|
||||
@@ -648,6 +669,9 @@ public:
|
||||
virtual void finishNormalConformance(NormalProtocolConformance *conformance,
|
||||
uint64_t contextData) override;
|
||||
|
||||
GenericEnvironment *loadGenericEnvironment(const Decl *decl,
|
||||
uint64_t contextData) override;
|
||||
|
||||
Optional<StringRef> getGroupNameById(unsigned Id) const;
|
||||
Optional<StringRef> getSourceFileNameById(unsigned Id) const;
|
||||
Optional<StringRef> getGroupNameForDecl(const Decl *D) const;
|
||||
@@ -710,6 +734,9 @@ public:
|
||||
ProtocolConformanceRef readConformance(llvm::BitstreamCursor &Cursor,
|
||||
GenericEnvironment *genericEnv =
|
||||
nullptr);
|
||||
|
||||
/// Read a SILLayout from the given cursor.
|
||||
SILLayout *readSILLayout(llvm::BitstreamCursor &Cursor);
|
||||
|
||||
/// Read the given normal conformance from the current module file.
|
||||
NormalProtocolConformance *
|
||||
|
||||
Reference in New Issue
Block a user