[modules] Allow parsing a duplicate Obj-C interface if a previous one comes...
[modules] Allow parsing a duplicate Obj-C interface if a previous one comes from a hidden [sub]module. Instead of emitting a redefinition error, check that definitions are equivalent and allow such scenario. A few non-obvious implementation details: * to avoid multiple definitions in the redeclaration chain we just drop the new definition after checking for equivalence; * for checking definition equivalence use ODR hash instead of ASTStructuralEquivalence because it avoids excessive recursive deserialization. Though after detecting a mismatch we do deserialize multiple entities to provide a better error message. rdar://82908223 Differential Revision: https://reviews.llvm.org/D124286
Loading
Please sign in to comment