@@ -177,7 +177,9 @@ static bool alwaysNoncopyable(Type ty) {
177
177
return false ; // otherwise, the conservative assumption is it's copyable.
178
178
}
179
179
180
- static CanType preprocessType (GenericEnvironment *env, Type orig) {
180
+ // / Preprocesses a type before querying whether it conforms to an invertible.
181
+ static CanType preprocessTypeForInvertibleQuery (GenericEnvironment *env,
182
+ Type orig) {
181
183
Type type = orig;
182
184
183
185
// Always strip off SILMoveOnlyWrapper.
@@ -196,7 +198,7 @@ static CanType preprocessType(GenericEnvironment *env, Type orig) {
196
198
197
199
// / \returns true iff this type lacks conformance to Copyable.
198
200
bool TypeBase::isNoncopyable (GenericEnvironment *env) {
199
- auto canType = preprocessType (env, this );
201
+ auto canType = preprocessTypeForInvertibleQuery (env, this );
200
202
auto &ctx = canType->getASTContext ();
201
203
202
204
// for legacy-mode queries that are not dependent on conformances to Copyable
@@ -208,7 +210,7 @@ bool TypeBase::isNoncopyable(GenericEnvironment *env) {
208
210
}
209
211
210
212
bool TypeBase::isEscapable (GenericEnvironment *env) {
211
- auto canType = preprocessType (env, this );
213
+ auto canType = preprocessTypeForInvertibleQuery (env, this );
212
214
auto &ctx = canType->getASTContext ();
213
215
214
216
// for legacy-mode queries that are not dependent on conformances to Escapable
0 commit comments