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/34342] New: BOZ extensions not diagnosed as such with -std=f95


real, parameter :: M2_PI = '40490FDB'X
end

uses several extensions, which are not diagnosed:
- X instead of Z
- Suffix instead of prefix
- BOZ to initialize a REAL
  (the later is allowed in F2003 using REAL(Z'...').)

BOZ bugs: PR 18026 and PR 29471.

Fortran 95:

   In a DATA statement (5.2.10), an unsigned binary, octal, or hexadecimal 
   literal constant shall correspond to an integer scalar variable.
   R407 boz-literal-constant is binary-constant
                             or octal-constant
                             or hex-constant
   Constraint: A boz-literal-constant may appear only in a DATA statement.

Fortran 2003:

   "A boz-literal-constant shall appear only as a data-stmt-constant
   in a DATA statement, as the actual argument associated with the
   dummy argument A of the numeric intrinsic functions DBLE, REAL or
   INT, or as the actual argument associated with the X or Y dummy
   argument of the intrinsic function CMPLX."

Came up in
http://groups.google.com/group/comp.lang.fortran/browse_thread/thread/2ad94287d7f8a6f0/


-- 
           Summary: BOZ extensions not diagnosed as such with -std=f95
           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=34342


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