Skip to content

Commit 332c65f

Browse files
committed
Sema: Define {Abstract,Inferred}GenericSignatureRequest::isCached() inside the request type
1 parent 47ad3c9 commit 332c65f

File tree

2 files changed

+2
-10
lines changed

2 files changed

+2
-10
lines changed

include/swift/AST/TypeCheckRequests.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1414,7 +1414,7 @@ class AbstractGenericSignatureRequest :
14141414

14151415
public:
14161416
// Separate caching.
1417-
bool isCached() const;
1417+
bool isCached() const { return true; }
14181418

14191419
/// Abstract generic signature requests never have source-location info.
14201420
SourceLoc getNearestLoc() const {
@@ -1449,7 +1449,7 @@ class InferredGenericSignatureRequest :
14491449

14501450
public:
14511451
// Separate caching.
1452-
bool isCached() const;
1452+
bool isCached() const { return true; }
14531453

14541454
/// Inferred generic signature requests don't have source-location info.
14551455
SourceLoc getNearestLoc() const {

lib/AST/GenericSignatureBuilder.cpp

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8738,14 +8738,6 @@ void GenericSignatureBuilder::verifyGenericSignaturesInModule(
87388738
verifyGenericSignature(context, canGenericSig);
87398739
}
87408740
}
8741-
8742-
bool AbstractGenericSignatureRequest::isCached() const {
8743-
return true;
8744-
}
8745-
8746-
bool InferredGenericSignatureRequest::isCached() const {
8747-
return true;
8748-
}
87498741

87508742
/// Check whether the inputs to the \c AbstractGenericSignatureRequest are
87518743
/// all canonical.

0 commit comments

Comments
 (0)