Skip to content

ConformanceDescriptor

Azoy edited this page Mar 17, 2021 · 2 revisions

ConformanceDescriptor

A structure that helps describe a particular conformance in Swift. Information includes what type is being conformed to what protocol, some flags like if the conformance is retroactive, has conditional requirements, etc.

public struct ConformanceDescriptor: LayoutWrapper

ABI Stability: Stable since the following

| macOS | iOS/tvOS | watchOS | Linux | Windows |
|-------|----------|---------|-------|---------|
| 10.14 | 12.2     | 5.2     | NA    | NA      |

Inheritance

LayoutWrapper

Properties

flags

The specific flags that describe this conformance descriptor.

var flags: Flags

`protocol`

The protocol that this type conforms to.

var `protocol`: ProtocolDescriptor

contextDescriptor

The context descriptor of the type being conformed.

var contextDescriptor: TypeContextDescriptor?

objcClass

canImport(ObjectiveC)
var objcClass: ObjCClassWrapperMetadata?

witnessTablePattern

The witness table pattern is a base witness table that this conformance can base actual witness tables off of. In the case that this conformance does not have a generic witness table (flags.hasGenericWitnessTable), this witness table pattern is actually the real witness table.

var witnessTablePattern: WitnessTable
Types
Protocols
Global Variables
Global Functions
Clone this wiki locally