@@ -61,8 +61,6 @@ public struct Type: TypeProperties, CustomStringConvertible, NoReflectionChildre
6161
6262 public var builtinVectorElementType : Type { Type ( bridged: bridged. getBuiltinVectorElementType ( ) ) }
6363
64- public var builtinFixedArrayElementType : Type { Type ( bridged: bridged. getBuiltinFixedArrayElementType ( ) ) }
65-
6664 public func subst( with substitutionMap: SubstitutionMap ) -> Type {
6765 return Type ( bridged: bridged. subst ( substitutionMap. bridged) )
6866 }
@@ -83,8 +81,6 @@ public struct CanonicalType: TypeProperties, CustomStringConvertible, NoReflecti
8381
8482 public var builtinVectorElementType : CanonicalType { rawType. builtinVectorElementType. canonical }
8583
86- public var builtinFixedArrayElementType : CanonicalType { rawType. builtinFixedArrayElementType. canonical }
87-
8884 public func subst( with substitutionMap: SubstitutionMap ) -> CanonicalType {
8985 return rawType. subst ( with: substitutionMap) . canonical
9086 }
@@ -195,6 +191,23 @@ extension TypeProperties {
195191 rawType. bridged. getRepresentationOfMetatype ( ) . representation
196192 }
197193
194+ public var builtinFixedArrayElementType : CanonicalType {
195+ CanonicalType ( bridged: rawType. bridged. getBuiltinFixedArrayElementType ( ) )
196+ }
197+ public var builtinFixedArraySizeType : CanonicalType {
198+ CanonicalType ( bridged: rawType. bridged. getBuiltinFixedArraySizeType ( ) )
199+ }
200+
201+ /// Returns the value of an integer value type (see `isInteger`).
202+ /// Returns nil if the value is not representable in an `Int`.
203+ public var valueOfInteger : Int ? {
204+ let optionalInt = rawType. bridged. getValueOfIntegerType ( )
205+ if optionalInt. hasValue {
206+ return optionalInt. value
207+ }
208+ return nil
209+ }
210+
198211 /// Assumes this is a nominal type. Returns a substitution map that sends each
199212 /// generic parameter of the declaration's generic signature to the corresponding
200213 /// generic argument of this nominal type.
0 commit comments