[Lldb-commits] [PATCH] Use GUIDs to make pipe names unique on Windows.

Zachary Turner zturner at google.com
Mon Feb 9 16:54:14 PST 2015

In http://reviews.llvm.org/D7509#120920, @amccarth wrote:

> Corrected pointer dereference.  The reinterpret_cast is necessary because RPC_CSTR is a pointer to unsigned char and llvm::StringRef doesn't have a constructor for that.  If I ditch the RPC_CSTR and just declare unique_string as a pointer to char, then I'd have to cast it in the call to UuidToString, which is uglier.

If RPC_CSTR is a pointer to unsigned char*, then it sounds like it's probably unicode.  In that case the += operator on SmallString<> won't work correctly.  We need to use llvm::convertUTF16ToUTF8String() in that case.



More information about the lldb-commits mailing list