ioeric added inline comments.

================
Comment at: clangd/Cancellation.h:96
+/// checks using it to avoid extra lookups in the Context.
+class CancellationToken {
+public:
----------------
As chatted offline, I have questions about the motivation of the 
`CancellationToken` class. Intuitively, it seems to me that this can be merged 
into `TaskHandle`, and we can simply stash the `TaskHandle` instead of a token 
into the context. There would be fewer states to maintain, and the design would 
be a bit more straightforward. I might be missing context/concerns here, so I'd 
like to hear what you and Ilya think. @ilya-biryukov 


================
Comment at: clangd/ClangdLSPServer.cpp:75
+std::string NormalizeRequestID(const json::Value &ID) {
+  CancelParams CP;
+  fromJSON(json::Object{{"id", ID}}, CP);
----------------
Use `ID.getAsString()`?


Repository:
  rCTE Clang Tools Extra

https://reviews.llvm.org/D50502



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

Reply via email to