This is an archive of the discontinued LLVM Phabricator instance.

[clangd] Treat class constructor as in the same scope as the class in ranking.
ClosedPublic

Authored by ioeric on Jul 4 2018, 5:37 AM.

Diff Detail

Event Timeline

ioeric created this revision.Jul 4 2018, 5:37 AM
sammccall accepted this revision.Jul 5 2018, 12:48 AM
sammccall added inline comments.
unittests/clangd/QualityTests.cpp
219

hmm, maybe neater to add an overload of findAnyDecl() that takes a filter function<bool(const NamedDecl&)>? (and implement the findAnyDecl in terms of it)

Call site should be slightly more readable, and you'll also get an assertion that there's exactly one match "for free".

This revision is now accepted and ready to land.Jul 5 2018, 12:48 AM
ioeric updated this revision to Diff 154182.Jul 5 2018, 1:14 AM
  • Refactored findAnyDecl.
This revision was automatically updated to reflect the committed changes.