public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/31243]  New: truncating strings longer than 2**32 characters
@ 2007-03-17 14:51 tkoenig at gcc dot gnu dot org
  2007-03-17 20:06 ` [Bug fortran/31243] " fxcoudert at gcc dot gnu dot org
                   ` (12 more replies)
  0 siblings, 13 replies; 14+ messages in thread
From: tkoenig at gcc dot gnu dot org @ 2007-03-17 14:51 UTC (permalink / raw)
  To: gcc-bugs

The string lengths are truncated to 32-bit
values here, which shouldn't happen.

$ cat substr.f90
program main
  character (len=2_8**32_8+4_8) :: ch
  ch = ' '
  print *,ch(1:2_8**32_8+3_8)
end program main
$ gfortran -fdump-tree-original substr.f90
$ cat substr.f90.003t.original
MAIN__ ()
{
  char ch[1:4];

  _gfortran_set_std (68, 127, 0);
  __builtin_memmove (&ch, " ", 1);
  __builtin_memset (&ch + 1B, 32, 3);

...


-- 
           Summary: truncating strings longer than 2**32 characters
           Product: gcc
           Version: 4.3.0
            Status: UNCONFIRMED
          Keywords: wrong-code
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: tkoenig at gcc dot gnu dot org


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


^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2009-05-16 17:01 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-03-17 14:51 [Bug fortran/31243] New: truncating strings longer than 2**32 characters tkoenig at gcc dot gnu dot org
2007-03-17 20:06 ` [Bug fortran/31243] " fxcoudert at gcc dot gnu dot org
2007-03-28 21:50 ` fxcoudert at gcc dot gnu dot org
2007-04-16 12:52 ` tobi at gcc dot gnu dot org
2007-05-28 16:13 ` fxcoudert at gcc dot gnu dot org
2007-12-25 23:32 ` tkoenig at gcc dot gnu dot org
2008-07-24 16:32 ` domob at gcc dot gnu dot org
2009-01-27  5:00 ` jvdelisle at gcc dot gnu dot org
2009-04-17 22:13 ` jb at gcc dot gnu dot org
2009-04-17 22:42 ` dominiq at lps dot ens dot fr
2009-04-18 22:07 ` jvdelisle at gcc dot gnu dot org
2009-05-16 16:15 ` fxcoudert at gcc dot gnu dot org
2009-05-16 16:53 ` fxcoudert at gcc dot gnu dot org
2009-05-16 17:01 ` [Bug fortran/31243] Detect " fxcoudert at gcc dot gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).