File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -3047,9 +3047,12 @@ const TypeLowering &TypeConverter::getTypeLoweringForLoweredType(
3047
3047
AbstractionPattern origType, CanType loweredType,
3048
3048
TypeExpansionContext forExpansion,
3049
3049
IsTypeExpansionSensitive_t isTypeExpansionSensitive) {
3050
- assert (loweredType->isLegalSILType () && " type is not lowered!" );
3051
- (void )loweredType;
3052
-
3050
+
3051
+ // For very large types (e.g. tuples with many elements), this assertion is
3052
+ // very expensive to execute, because the `isLegalSILType` status is not cached.
3053
+ // Therefore the assert is commented out and only here for documentation purposes.
3054
+ // assert(loweredType->isLegalSILType() && "type is not lowered!");
3055
+
3053
3056
// Cache the lowered type record for a contextualized type independent of the
3054
3057
// abstraction pattern. Lowered type parameters can't be cached or looked up
3055
3058
// without context. (TODO: We could if they match the out-of-context
You can’t perform that action at this time.
0 commit comments