You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[include-cleaner] Weaken signal for boosting preferred headers
Putting preferred header signal above completeness implied we would
uprank forward declarations above complete ones in certain cases.
This can be desired in cases where:
- Complete definition is private. But this case is already governed by
publicness signal.
- The library indeed intends to provide a forward declaring interface, like
iosfwd vs ostream.
In all other cases, upranking is undesired as it means we've picked up prefered
headerness signal by mistake from an unrelated declaration to the library.
This change regresses the behavior for libraries that intentionally provide a
forward declaring interface. But that wasn't something we intended to support
explicitly, it was working incidentally when the forward declaring header had a
similar name to the symbol. Moreover, include-cleaner deliberately discourages
forward-declarations, so not working in this case is also more aligned with rest
of the components.
Differential Revision: https://reviews.llvm.org/D159441
0 commit comments