This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC 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]

[Bug fortran/34740] New: -fbounds-check with TRANSFER misses out of bounds in array assignment


For the following program, I expect an out-of-bounds error; NAG f95 shows at
run time:
   Rank 1 of array operand has extent 7 instead of 8

   character, pointer :: ptr(:)
   allocate(ptr(8))
   ptr = transfer('Sample'//achar(0),ptr)
end


-- 
           Summary: -fbounds-check with TRANSFER misses out of bounds in
                    array assignment
           Product: gcc
           Version: 4.3.0
            Status: UNCONFIRMED
          Keywords: diagnostic
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: burnus at gcc dot gnu dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34740


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