Re: Program terminated with SIGSEGV when trying to print an array element

Daniel Jacobowitz
2005-06-08T13:07:44Z

On Wed, Jun 08, 2005 at 02:52:20PM +0800, Wu Zhou wrote:
> Sure. But now I am having difficulty in one problem: given an struct value
> with the type being TYPE_CODE_PTR, how to get the value of the array (or
> string or whatever) it refer to? We need to know this to go on with the
> following evaluation. I had thought that function "value_from_pointer"
> will do this, but it turn out to be false. Anyone could help on this?

Usually, value_ind. Do you have a pointer to a TYPE_CODE_ARRAY, or has
the array decayed into a pointer (like in C)?

--
Daniel Jacobowitz
CodeSourcery, LLC