[PATCH] D72589: Add GDB pretty printers for llvm::ilist, llvm::simple_ilist, and llvm::ilist_node.

Christian Sigg via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jan 28 13:34:12 PST 2020


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


================
Comment at: debuginfo-tests/llvm-prettyprinters/gdb/prettyprinters.gdb:48-58
+# CHECK-NOT: ilist_node_impl
+# CHECK: Value = 13
+# CHECK: Value = 14
+# CHECK: Value = 15
+p Ilist
+
+# CHECK-NOT: ilist_node_impl
----------------
dblaikie wrote:
> Could you check these with the surrounding syntax too to give a better sense of how the printing would look to the user? 
> 
> (I guess they'll print in {}, is there a type prefix like with the other pretty printers (eg: "llvm::ArrayRef of", etc)?
Done.

No, there is no prefix because the printer has no `to_string` method. That's intentional because gdb does not print the type for ordinary values either. There is `ptype` for that. CLion watches show the result of both `print` and `ptype`. I should probably go back and remove it from the PointerIntPair as well, and add individual printer classes while I'm at it.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D72589





More information about the llvm-commits mailing list