hokein added inline comments.

================
Comment at: clangd/index/Merge.cpp:29
+     //    b) if it's in the dynamic slab, merge it and yield the result
+     //  3) now yield all the dynamic symbols we haven't processed.
+     bool More = false; // We'll be incomplete if either source was.
----------------
Maybe add another FIXME, saying filer out symbols in static index, but are 
removed in dynamic index?


================
Comment at: clangd/index/Merge.cpp:34
+         Dynamic->fuzzyFind(Ctx, Req, [&](const Symbol &S) { DynB.insert(S); 
});
+     SymbolSlab Dyn = std::move(DynB).build();
+
----------------
IIUC, `Dyn` is a local variable, which holds all the underlying data of 
`Symbol`, the `Symbol` returned in the callback of `fuzzyFind` would be invalid 
after the `fuzzyFind(..)` function call is finished.

Our previous assumption is that `Symbol` is valid as long as the `SymbolIndex` 
exists?


================
Comment at: clangd/index/Merge.cpp:75
+    if (S.Detail->Documentation == "")
+      S.Detail->Documentation = R.Detail->Documentation;
+  }
----------------
Don't we need ` CompletionDetail`?


Repository:
  rCTE Clang Tools Extra

https://reviews.llvm.org/D42049



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to