$ cat a4.f90 
  character(len=min(-4,5)) :: s
  print *, len(s)
  end
$ ./bin/gfortran -static a4.f90 
a4.f90:1.31:

  character(len=min(-4,5)) :: s
                              1
Error: 's' at (1) must have constant character length in this context

I tried with a few intrinsics, like MIN, MODULO, ... None of them work.


-- 
           Summary: Initialization expr as constant character length
                    rejected
           Product: gcc
           Version: 4.3.0
            Status: UNCONFIRMED
          Keywords: rejects-valid
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: fxcoudert at gcc dot gnu dot org


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

Reply via email to