Skip to content
Commit ed7a46a8 authored by Volodymyr Sapsai's avatar Volodymyr Sapsai
Browse files

[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
parent 6ba4afb4
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment