bug-ddd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug #25513] GDB "set print repeats" can confuse DDD


From: Peter Wainwright
Subject: [bug #25513] GDB "set print repeats" can confuse DDD
Date: Sat, 07 Feb 2009 12:53:57 +0000
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-GB; rv:1.9.0.5) Gecko/2008121622 Ubuntu/8.04 (hardy) Firefox/3.0.5

URL:
  <http://savannah.gnu.org/bugs/?25513>

                 Summary: GDB "set print repeats" can confuse DDD
                 Project: DDD
            Submitted by: pwainwright
            Submitted on: Sat 07 Feb 2009 12:53:56 GMT
                Category: Data display
                Severity: 3 - Normal
              Item Group: None
                  Status: None
                 Privacy: Public
             Assigned to: None
             Open/Closed: Open
         Discussion Lock: Any
                 Release: 3.3.12-rc2

    _______________________________________________________

Details:

Consider this example:

main()
{
  char *x[2] ={
    "top left                                           top right",
    "bottom left                                        bottom right"
  };
}

Set break on closing } and run.  Then graph display x, and graph display
x[0].

If "set print repeats" is 10, the the display of x will contain 6 elements:

"top left" | ' ' <43x> | "top right" | "bottom left" | ' ' <40x> | "bottom
right"

and the display of x[0] will just show "top left".

This occurs because the output of "print x" contains commas which are
interpreted by DDD as field separators:

(gdb) print x
$2 =   {0x400550 "top left", ' ' <repeats 43 times>, "top right",
  0x400590 "bottom left", ' ' <repeats 40 times>, "bottom right"}

I can work around this by setting "set print repeats" to a large value. 
Probably DDD should temporarily override the user-set value of this parameter
when capturing data for displays.





    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?25513>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/





reply via email to

[Prev in Thread] Current Thread [Next in Thread]