This is an archive of the discontinued LLVM Phabricator instance.

[clangd] If an undocumented definition exists, don't accept documentation from other forward decls.
ClosedPublic

Authored by sammccall on Oct 4 2019, 8:26 AM.

Details

Summary

This fixes cases like:

foo.h
  class Undocumented{}
bar.h
  // break an include cycle. we should refactor this!
  class Undocumented;

Where the comment doesn't describe the class.

Note that a forward decl that is *visible to the definition* will still have
its doc comment used, by SymbolCollector: Merge isn't involved here.

Diff Detail

Repository
rL LLVM

Event Timeline

sammccall created this revision.Oct 4 2019, 8:26 AM
Herald added a project: Restricted Project. · View Herald TranscriptOct 4 2019, 8:26 AM
This revision is now accepted and ready to land.Oct 7 2019, 2:54 AM
This revision was automatically updated to reflect the committed changes.
Herald added a project: Restricted Project. · View Herald TranscriptOct 7 2019, 10:09 PM