[PATCH] D92788: [clangd] NFC: Use SmallVector where possible

2020-12-17 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. Should be fixed in 894c4761c67ac850e156a26aa427035a811d7aed , LMK if this workaround doesn't work Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D92788/n

[PATCH] D92788: [clangd] NFC: Use SmallVector where possible

2020-12-16 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added inline comments. Comment at: clang-tools-extra/clangd/Headers.h:139 // Maps a file's index to that of the files it includes. - llvm::DenseMap> IncludeChildren; + llvm::DenseMap> IncludeChildren; }; sammccall wrote: > kbobyrev wrote: > > arpha

[PATCH] D92788: [clangd] NFC: Use SmallVector where possible

2020-12-16 Thread Sam McCall via Phabricator via cfe-commits
sammccall added inline comments. Comment at: clang-tools-extra/clangd/Headers.h:139 // Maps a file's index to that of the files it includes. - llvm::DenseMap> IncludeChildren; + llvm::DenseMap> IncludeChildren; }; kbobyrev wrote: > arphaman wrote: > > It lo

[PATCH] D92788: [clangd] NFC: Use SmallVector where possible

2020-12-16 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev added inline comments. Comment at: clang-tools-extra/clangd/Headers.h:139 // Maps a file's index to that of the files it includes. - llvm::DenseMap> IncludeChildren; + llvm::DenseMap> IncludeChildren; }; arphaman wrote: > It looks like the change o

[PATCH] D92788: [clangd] NFC: Use SmallVector where possible

2020-12-16 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added inline comments. Comment at: clang-tools-extra/clangd/Headers.h:139 // Maps a file's index to that of the files it includes. - llvm::DenseMap> IncludeChildren; + llvm::DenseMap> IncludeChildren; }; It looks like the change on this line is fai

[PATCH] D92788: [clangd] NFC: Use SmallVector where possible

2020-12-10 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev added inline comments. Comment at: clang-tools-extra/clangd/unittests/TestTU.cpp:190 const NamedDecl &findDecl(ParsedAST &AST, llvm::StringRef QName) { - llvm::SmallVector Components; + llvm::SmallVector Components; QName.split(Components, "::"); k

[PATCH] D92788: [clangd] NFC: Use SmallVector where possible

2020-12-10 Thread Kirill Bobyrev via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGee02e20c0817: [clangd] NFC: Use SmallVector where possible (authored by kbobyrev). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTI

[PATCH] D92788: [clangd] NFC: Use SmallVector where possible

2020-12-10 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev added inline comments. Comment at: clang-tools-extra/clangd/unittests/TestTU.cpp:190 const NamedDecl &findDecl(ParsedAST &AST, llvm::StringRef QName) { - llvm::SmallVector Components; + llvm::SmallVector Components; QName.split(Components, "::"); k

[PATCH] D92788: [clangd] NFC: Use SmallVector where possible

2020-12-09 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev added inline comments. Comment at: clang-tools-extra/clangd/unittests/TestTU.cpp:190 const NamedDecl &findDecl(ParsedAST &AST, llvm::StringRef QName) { - llvm::SmallVector Components; + llvm::SmallVector Components; QName.split(Components, "::"); n

[PATCH] D92788: [clangd] NFC: Use SmallVector where possible

2020-12-09 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 310650. kbobyrev marked an inline comment as done. kbobyrev added a comment. Revert the case flagged by @njames93. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D92788/new/ https://reviews.llvm.org/D92788 File

[PATCH] D92788: [clangd] NFC: Use SmallVector where possible

2020-12-09 Thread Sam McCall via Phabricator via cfe-commits
sammccall added inline comments. Comment at: clang-tools-extra/clangd/SemanticHighlighting.cpp:608 for (const auto &Line : Tokens) { -llvm::SmallVector LineByteTokens; +llvm::SmallVector LineByteTokens; llvm::raw_svector_ostream OS(LineByteTokens); ---

[PATCH] D92788: [clangd] NFC: Use SmallVector where possible

2020-12-09 Thread Nathan James via Phabricator via cfe-commits
njames93 added inline comments. Comment at: clang-tools-extra/clangd/ConfigProvider.cpp:100 llvm::StringRef Parent = path::parent_path(P.Path); - llvm::SmallVector Ancestors; for (auto I = path::begin(Parent, path::Style::posix), This should be

[PATCH] D92788: [clangd] NFC: Use SmallVector where possible

2020-12-08 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 310232. kbobyrev marked 4 inline comments as done. kbobyrev added a comment. Resolve review comments. @sammccall, thanks for clarifying the cases you thought should be remaining as they are! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D92788: [clangd] NFC: Use SmallVector where possible

2020-12-08 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. Thanks for cleaning up! In D92788#2438207 , @njames93 wrote: > Not sure I'm a huge fan of this, Some of these cases the size is specified > because that's the upper limit we typically expect the SmallVector to use. The idea be

[PATCH] D92788: [clangd] NFC: Use SmallVector where possible

2020-12-07 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. Not sure I'm a huge fan of this, Some of these cases the size is specified because that's the upper limit we typically expect the SmallVector to use. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D92788/new/ https://review

[PATCH] D92788: [clangd] NFC: Use SmallVector where possible

2020-12-07 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev added a comment. I've excluded the cases where the size does not seem arbitrary (e.g. `1`/ code relying on `sizeof(Something) == Value`, e.g. dex payloads and CodeCompletion bundles). The rest looks fairly innocent but I don't know all the code around changed lines. Repository: rG

[PATCH] D92788: [clangd] NFC: Use SmallVector where possible

2020-12-07 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev created this revision. kbobyrev added a reviewer: sammccall. Herald added subscribers: usaxena95, kadircet, arphaman, javed.absar. kbobyrev requested review of this revision. Herald added subscribers: cfe-commits, MaskRay, ilya-biryukov. Herald added a project: clang. SmallVector with def