[Lldb-commits] [PATCH] D64536: Adding inline comments to code view type records

NILANJANA BASU via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Thu Jul 11 11:39:15 PDT 2019


nilanjana_basu marked 2 inline comments as done.
nilanjana_basu added inline comments.


================
Comment at: llvm/include/llvm/DebugInfo/CodeView/CodeViewRecordIO.h:63
 
-  Error mapInteger(TypeIndex &TypeInd);
+  Error mapInteger(TypeIndex &TypeInd, const char* Comment = nullptr);
 
----------------
rnk wrote:
> Is it possible to change these all to accept `const Twine &Comment = ""`? I think string literals are meant to be implicitly convertible to Twine.
> 
> Generally in LLVM StringRef is preferred over const char *. We have some documentation for this here:
> https://llvm.org/docs/ProgrammersManual.html#passing-strings-the-stringref-and-twine-classes
> 
> I think for this API where the string length is unlikely to be used at all, Twine makes sense, but across LLVM C strings are generally avoided if possible.
Got it. Have made the changes & updated the patch.


Repository:
  rLLDB LLDB

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

https://reviews.llvm.org/D64536





More information about the lldb-commits mailing list