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/29396] segfault with character pointer association



------- Comment #4 from fxcoudert at gcc dot gnu dot org  2007-03-16 15:15 -------
Joost filed PR31220, which is a duplicate of this one, but contains an
interesting testcase (compile & run) to check and add to the testsuite when
we're done with this bug:

CHARACTER(LEN=4), POINTER :: b
CHARACTER(LEN=10) :: r
b=>F1(1,r)
b="1111"
b=>F1(2,r)
b="2222"
b=>F1(3,r)
b="3333"
IF (r.NE."12222-----") CALL ABORT()
CONTAINS
FUNCTION F1(I,r) result(b)
INTEGER :: I
CHARACTER(LEN=10), TARGET, SAVE :: a="----------"
CHARACTER(LEN=10) :: r
CHARACTER(LEN=4), POINTER :: b
r=a
b=>a(I:I+3)
END FUNCTION
END


-- 

fxcoudert at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
      Known to fail|                            |4.2.0 4.3.0
   Last reconfirmed|2007-01-28 22:15:31         |2007-03-16 15:15:54
               date|                            |


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


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