This is the mail archive of the gdb@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: fortran multidimensional arrays and pointers


Here is a very simple example
-----------------------------------------
      program bug
      integer , pointer,dimension(:) :: some_ints
      allocate (some_ints(1:10))
      some_ints(1) = 1
      some_ints(2) = 2
      write(*,*) some_ints(1)
      write(*,*) some_ints(2)
      end program bug
------------------------------------------
The program prints out '1','2'
but in gdb
#gdb bug
>b 6
>run
>print some_ints(1)
0
>print some_ints(2)
-1
>quit

On Mon, Feb 7, 2011 at 8:22 AM, Tom Tromey <tromey@redhat.com> wrote:
>>>>>> "Mathew" == Mathew Yeates <mat.yeates@gmail.com> writes:
>
> Mathew> Are fortran pointers supported?
>
> I don't know, but could you file a report in bugzilla with your example
> and what you expected to happen?
>
> Tom
>


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]