[clang-tools-extra] r323518 - [clangd] Fix GCC build break 'declaration changes meaning'

Sam McCall via cfe-commits cfe-commits at lists.llvm.org
Fri Jan 26 03:23:33 PST 2018


Author: sammccall
Date: Fri Jan 26 03:23:33 2018
New Revision: 323518

URL: http://llvm.org/viewvc/llvm-project?rev=323518&view=rev
Log:
[clangd] Fix GCC build break 'declaration changes meaning'

Modified:
    clang-tools-extra/trunk/clangd/JSONRPCDispatcher.cpp

Modified: clang-tools-extra/trunk/clangd/JSONRPCDispatcher.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/clangd/JSONRPCDispatcher.cpp?rev=323518&r1=323517&r2=323518&view=diff
==============================================================================
--- clang-tools-extra/trunk/clangd/JSONRPCDispatcher.cpp (original)
+++ clang-tools-extra/trunk/clangd/JSONRPCDispatcher.cpp Fri Jan 26 03:23:33 2018
@@ -29,26 +29,26 @@ class RequestSpan {
   RequestSpan(json::obj *Args) : Args(Args) {}
   std::mutex Mu;
   json::obj *Args;
-  static Key<std::unique_ptr<RequestSpan>> Key;
+  static Key<std::unique_ptr<RequestSpan>> RSKey;
 
 public:
   // Return a context that's aware of the enclosing request, identified by Span.
   static Context stash(const trace::Span &Span) {
-    return Span.Ctx.derive(RequestSpan::Key, std::unique_ptr<RequestSpan>(
+    return Span.Ctx.derive(RSKey, std::unique_ptr<RequestSpan>(
                                                  new RequestSpan(Span.Args)));
   }
 
   // If there's an enclosing request and the tracer is interested, calls \p F
   // with a json::obj where request info can be added.
   template <typename Func> static void attach(const Context &Ctx, Func &&F) {
-    auto *RequestArgs = Ctx.get(RequestSpan::Key);
+    auto *RequestArgs = Ctx.get(RSKey);
     if (!RequestArgs || !*RequestArgs || !(*RequestArgs)->Args)
       return;
     std::lock_guard<std::mutex> Lock((*RequestArgs)->Mu);
     F(*(*RequestArgs)->Args);
   }
 };
-Key<std::unique_ptr<RequestSpan>> RequestSpan::Key;
+Key<std::unique_ptr<RequestSpan>> RequestSpan::RSKey;
 } // namespace
 
 void JSONOutput::writeMessage(const json::Expr &Message) {




More information about the cfe-commits mailing list