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/24917] New: Handling of hexadecimal constants in gfortran


Compilation of the following program TEST.f fails:

PROGRAM HEX_TEST
INTEGER(4) MASK
MASK = 'c0'X
END

~ $ gfortran -c TEST.f
 In file TEST.f:5



      MASK = 'c0'X
     1
Error: Unclassifiable statement at (1)

whereas the following code compiles correctly:

PROGRAM HEX_TEST
INTEGER(4) MASK
MASK = X'c0'
END

As stated in http://gcc.gnu.org/ml/fortran/2005-11/msg00382.html, the first
version of the code is an extension which was supported in g77, therefore it
should also be supported in gfortran.

The compiler I used to test this is:

~ $ gfortran -v
Using built-in specs.
Target: i686-pc-linux-gnu
Configured with: ../gcc-4.0.2/configure
--prefix=/home/iev/apps/gcc-4.0.2 --enable-languages=c,c++,f95
--enable-shared --enable-threads=posix --disable-checking
--with-system-zlib --enable-__cxa_atexit --disable-libgcj --disable-nls
Thread model: posix
gcc version 4.0.2


-- 
           Summary: Handling of hexadecimal constants in gfortran
           Product: gcc
           Version: 4.0.2
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: iev at hpclab dot ceid dot upatras dot gr
 GCC build triplet: i686-pc-linux-gnu
  GCC host triplet: i686-pc-linux-gnu
GCC target triplet: i686-pc-linux-gnu


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


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