IRGen: LinkEntity::Kind::DifferentiabilityWitness is not a type kind

As the above comments imply, when isTypeKind() returns true, then
getType() should return a valid Type. This wasn't true with
DifferentiabilityWitness.
This commit is contained in:
Slava Pestov
2025-11-18 12:14:37 -05:00
parent 61e418c3e7
commit 6c1a2df419

View File

@@ -450,6 +450,10 @@ class LinkEntity {
// These are both type kinds and protocol-conformance kinds.
// TYPE KINDS: BEGIN {{
/// A SIL differentiability witness. The pointer is a
/// SILDifferentiabilityWitness*.
DifferentiabilityWitness,
/// A lazy protocol witness accessor function. The pointer is a
/// canonical TypeBase*, and the secondary pointer is a
/// ProtocolConformance*.
@@ -460,10 +464,6 @@ class LinkEntity {
/// ProtocolConformance*.
ProtocolWitnessTableLazyCacheVariable,
/// A SIL differentiability witness. The pointer is a
/// SILDifferentiabilityWitness*.
DifferentiabilityWitness,
// Everything following this is a type kind.
/// A value witness for a type.