ilya-biryukov added inline comments.
================ Comment at: clangd/Trace.cpp:138 return; - if (!Args) - Args = llvm::make_unique<json::obj>(); - T->event(Ctx, "E", - Args ? json::obj{{"args", std::move(*Args)}} : json::obj{}); + assert(Args && "Args can't be null at this point"); + T->end_event(Ctx, Name, std::move(*Args)); ---------------- sammccall wrote: > why not? Because `T` must outlive the `Span`, so we can't really have `if (!T)` evaluate to different things in constructor and destructor. Am I missing something? Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D40489 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits