[Lldb-commits] [PATCH] D74217: Add target.xml support for qXfer request.

Pavel Labath via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Mon Feb 17 23:29:52 PST 2020


labath added inline comments.


================
Comment at: lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServerLLGS.cpp:2814
+    if (!encoding.empty())
+      response.Printf("encoding=\"%s\" ", encoding.str().c_str());
+
----------------
jarin wrote:
> labath wrote:
> > Similarly, `response << "encoding='" << encoding << "' "`, or `response.Format("encoding='{0}'", encoding)` would be shorter, and avoid string copying.
> Nit: Now it is a funny mixture of operator<<, Printfs and PutCString. Is there a reason not to use << for everything? (I guess PutHex8 can't be easily done with <<, but everything else can?)
Yeah, I'm all for using anything else than printf (operator<<, the Format function, etc.). I just didn't feel like raising this point at that time. :/


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D74217/new/

https://reviews.llvm.org/D74217





More information about the lldb-commits mailing list