Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-7550

Locals and Expressions should also display symbolic names for pointers

XMLWordPrintable

    • Icon: Suggestion Suggestion
    • Resolution: Done
    • Icon: P3: Somewhat important P3: Somewhat important
    • Qt Creator 4.14.0
    • Qt Creator 2.6.0-rc
    • Debugger
    • None
    • 20eba776da41da180217b7737706d21603827a3f

      Whenever Qt Creator displays a pointer (and possibly a reference) in the Locals and Expressions, it displays only the pointer's value. For example, right now I am seeing:

       * this    @0x7fffffffca90
        * d      @0x7ffff796c220
      

      But if you ask the debugger (gdb at least), it can provide a more meaningful name:

      (gdb) p/a this
      $1 = 0x7fffffffca90
      (gdb) p/a d
      $2 = 0x7ffff796c220 <_ZL18emptyNotNullShared>
      

      That extra name can be extremely useful in debugging.

      This feature could be left disabled by default if the cost is high of obtaining such information for all pointers and references. It should be on by default for all function pointers, though (member and non-member ones).

      Another trick is for Creator to know which pointers are pointing to memory regions of loaded libraries (see gdb command info shared) and enable symbolic names only for those.

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            hjk hjk
            thiago Thiago Macieira
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes