This revision was automatically updated to reflect the committed changes.
Closed by commit rCTE334828: [clangd] UI for completion items that would
trigger include insertion. (authored by ioeric, committed by ).
Changed prior to commit:
https://reviews.llvm.org/D48163?vs=151498&id=151499#toc
Re
ioeric updated this revision to Diff 151498.
ioeric added a comment.
- clang-format again...
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D48163
Files:
clangd/CodeComplete.cpp
clangd/CodeComplete.h
clangd/Headers.cpp
clangd/Headers.h
test/clangd/completion-snippets.t
ioeric added inline comments.
Comment at: clangd/CodeComplete.h:63
- // Populated internally by clangd, do not set.
+ /// Populated internally by clangd, do not set.
/// If `Index` is set, it is used to augment the code completion
sammccall wrote:
> if you
ioeric updated this revision to Diff 151497.
ioeric added a comment.
- fix typo and clang-format
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D48163
Files:
clangd/CodeComplete.cpp
clangd/CodeComplete.h
clangd/Headers.cpp
clangd/Headers.h
test/clangd/completion-snippe
ioeric updated this revision to Diff 151496.
ioeric marked 6 inline comments as done.
ioeric added a comment.
- addressed review comments.
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D48163
Files:
clangd/CodeComplete.cpp
clangd/CodeComplete.h
clangd/Headers.cpp
clangd
sammccall added inline comments.
Comment at: clangd/CodeComplete.cpp:313
+I.label =
+(InsertingInclude ? Opts.IncludeInsertionIndicator : " ") + I.label;
I.scoreInfo = Scores;
sammccall wrote:
> string(IncludeInsertionIndicator.size(), ' ')?
oops
sammccall accepted this revision.
sammccall added inline comments.
This revision is now accepted and ready to land.
Comment at: clangd/CodeComplete.cpp:301
+ } else if (!IncludePath->empty()) {
+if (auto Edit = Includes.insert(*IncludePath)) {
+
ioeric added a comment.
Thanks for the review!
Comment at: clangd/CodeComplete.cpp:187
+ // Whether or not this candidate is in a completion where index is allowed.
+ // This can affect how items are built (e.g. indent label to align with
visual
+ // indicator in index resu
ioeric updated this revision to Diff 151492.
ioeric marked 6 inline comments as done.
ioeric added a comment.
- Addressed review comments.
- Merged with orgin/master
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D48163
Files:
clangd/CodeComplete.cpp
clangd/CodeComplete.h
sammccall added a comment.
Oops, forgot to link to the bundling patch: https://reviews.llvm.org/D47957
We should expect some conflicts one way or the other.
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D48163
___
cfe-commits mailin
sammccall added inline comments.
Comment at: clangd/CodeComplete.cpp:187
+ // Whether or not this candidate is in a completion where index is allowed.
+ // This can affect how items are built (e.g. indent label to align with
visual
+ // indicator in index results).
--
ioeric added inline comments.
Comment at: clangd/CodeComplete.cpp:278
+if (AllowIndexCompletion)
+ I.label = (InsertingInclude ? "+" : " ") + I.label;
I.scoreInfo = Scores;
sammccall wrote:
> I think we should avoid tokens that occur commonly in C++
ioeric updated this revision to Diff 151357.
ioeric added a comment.
- s/+/•/ and make the icon an code completion option to avoid hardcodes in
multiple places.
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D48163
Files:
clangd/CodeComplete.cpp
clangd/CodeComplete.h
clan
sammccall added a comment.
Ooh, bikeshed first!
Comment at: clangd/CodeComplete.cpp:278
+if (AllowIndexCompletion)
+ I.label = (InsertingInclude ? "+" : " ") + I.label;
I.scoreInfo = Scores;
I think we should avoid tokens that occur commonly in C+
ioeric created this revision.
ioeric added reviewers: sammccall, ilya-biryukov, hokein.
Herald added subscribers: cfe-commits, jkorous, MaskRay.
For completion items that would trigger include insertions (i.e. index symbols
that are not #included yet), add a visual indicator "+" before the complet
15 matches
Mail list logo