We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a37146c commit 79cbb2eCopy full SHA for 79cbb2e
include/swift/SIL/SILType.h
@@ -537,6 +537,13 @@ class SILType {
537
return SILType(castTo<TupleType>().getElementType(index), getCategory());
538
}
539
540
+ /// Given that this is a pack type, return the lowered type of the
541
+ /// given pack element. The result will have the same value
542
+ /// category as the base type.
543
+ SILType getPackElementType(unsigned index) const {
544
+ return SILType(castTo<SILPackType>()->getElementType(index), getCategory());
545
+ }
546
+
547
/// Given that this is a pack expansion type, return the lowered type
548
/// of the pattern type. The result will have the same value category
549
/// as the base type.
0 commit comments