Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

[comp.lang.fortran] Re: GDB appears to be lying to me?

139 views
Skip to first unread message

August West

unread,
Jan 10, 2013, 10:11:37 PM1/10/13
to
Subject: Re: GDB appears to be lying to me?
From: Louis Krupp <lkr...@nospam.pssw.com.invalid>
Newsgroups: comp.lang.fortran

On Sun, 18 Nov 2012 20:20:53 -0800 (PST), elzbieta...@gmail.com
wrote:

>I have subroutine that sets values its arguments.
>
>rtn = read_aero_input( data%A_nodes, data%Ax_rows, data%Ay_rows, CO%Az_rows, &
> data%Arx_rows, data%Ary_rows, data%Arz_rows, &
> cn, cy, ca, cn_overhang, cy_overhang )
>
>
>after this call I added this line:
>
>test = data%Ax_rows(101)
>
>If I try (in GDB):
>
>(gdb) p test
>$1 = 100
>
>If I try:
>
>p data%Ax_rows(101)
>warning: Range for type <error type> has invalid bounds 140737488335672..0
>warning: Range for type <error type> has invalid bounds 140737488335672..0
>$2 = 0
>
>It appears GDB is lying?
>
>Has anyone else seen this problem? Does anyone have solution?
>
>I use
>GNU gdb (GDB) Fedora (7.4.50.20120120-52.fc17)
>GNU Fortran (GCC) 4.7.2 20120921 (Red Hat 4.7.2-2)

How is "data" declared? What are the bounds for Ax_rows? Does your
program run OK if you enable bounds checking?

Louis

PS

People, please, please use question marks after questions and periods
after declarative sentences. For example,

"I think gdb is evidence that Leon Trotsky is still alive." is a
declarative sentence and should end with a period. A shorter, more
dramatic sentence like "Leon Trotsky lives!" could end with an
exclamation point.

"Do you think Leon Trotsky is still alive and working on gdb?" is a
question and ends with a question mark.

In another example, if you don't think my posts make sense, you would
say "I think you're full of $%^&." If wanted to appear more polite,
you would say "Is it possible that you're full of $%^&?"

You would not say:

You're full of $%^&?

It's bad grammar.

Thank you.

--
Moderators accept or reject articles based solely on the criteria posted
in the Frequently Asked Questions. Article content is the responsibility
of the submitter. Submit articles to ahbo...@mit.edu. To write to the
moderators, send mail to ahbo...@mit.edu.
0 new messages