Rather than just skipping requirements with satisfied Obj-C siblings during
`resolveValueWitnesses()`, proactively record a default witness for these
requirements. This prevents lazy value witness resolution from giving the
skipped requirements a default witness after the conformance is already marked
complete, which causes an assertion to fail.
Resolves rdar://119435253
Serialization now enumerates the value witnesses of conformances with a
resolver in order to facilitate lazy type checking
(https://github.com/apple/swift/pull/68262). This change in behavior introduced
an assertion failure when compiling modules from swiftinterface when the
interface contains a conformance to an `@objc` protocol that has a requirement
that is imported with an `async` variant. The `forEachValueWitness()`
invocation during serialization was causing the missing witness for an objc
async protocol requirement to be resolved after conformance check was already
marked "complete". This witness had not been previously resolved because
`ConformanceChecker::resolveValueWitnesses()` had special logic to skip objc
protocol requirements with witnessed siblings, whereas `forEachValueWitness()`
did not.
There are multiple potential solutions to this problem, but the one that seemed
least disruptive to me was to stop skipping resolution of these sibling
witnesses during `ConformanceChecker::resolveValueWitnesses()`. When I looked
into why they were being skipped, I discovered that this seemed to be a
concession to bugs in the logic for pruning missing witnesses. When I adjusted
the pruning logic it no longer became necessary to skip witnesses in
`ConformanceChecker::resolveValueWitnesses()` in order to avoid incorrect
diagnostics.
Resolves rdar://119435253