Re: Option for viewing all values of an array?
Re: Option for viewing all values of an array?
- Subject: Re: Option for viewing all values of an array?
- From: Roland King <email@hidden>
- Date: Tue, 26 Jan 2010 08:29:57 +0800
p my_array@100
.. or something very like that. If gdb doesn't know what type of array
you have you sometimes need to cast the my_array
p ((double*)my_array)@100
That's all typed in mail and I normally end up trying a few combos until
I get it right.
Jens Alfke wrote:
On Jan 25, 2010, at 3:48 PM, Jonathon Kuo wrote:
Cool. How about for a C array, like float my_array[1000]?
Hm. You can type "po my_array[0]" (assuming the items are Obj-C
objects; otherwise use the "p" command) and then repeat for each index.
There might be a way to automate that using clever GDB syntax, but I
don't know how.
—Jens _______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden