From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 906 invoked by alias); 2 Oct 2006 16:47:24 -0000 Received: (qmail 868 invoked by uid 48); 2 Oct 2006 16:47:15 -0000 Date: Mon, 02 Oct 2006 16:47:00 -0000 Message-ID: <20061002164715.867.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug fortran/18026] boz initialization of REALs fails In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "kargl at gcc dot gnu dot org" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2006-10/txt/msg00149.txt.bz2 List-Id: ------- Comment #8 from kargl at gcc dot gnu dot org 2006-10-02 16:47 ------- Remove reject-valid keyword, again! Return this to enhancement. This is NOT a bug. g77 compatibility and the Fortran 95 standard have a conflict, and so IMNSHO the Fortran 95 standard wins. See comment #3. The Fortran 95 standard has quite explicit language concerning how a BOZ is handled in a DATA statement, and that is what gfortran implements. A BOZ is handled consistently so that the gfortran extension of allowing a BOZ in an assignment gives the same result as the DATA statement. troutmask:kargl[204] cat a.f90 PROGRAM GFCBUG19 DOUBLE PRECISION y, x DATA x / Z'7FF0000000000000' / ! Conforms to Fortran 95 standard y = Z'7FF0000000000000' ! gfortran extension print *, x, y END troutmask:kargl[205] gfc -o z a.f90 troutmask:kargl[206] ./z 9.218868437227405E+018 9.218868437227405E+018 If someone wants to create a patch to implement a -fbroken-boz-behavior option, then that's fine. OTOH, the user can use the bit manipulation functions and TRANSFER to create whatever bit pattern the user wants. Or, the user can use the -fno-range-check option and simply compute inf = 1./0. and nan = 0. / .0. -- kargl at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |kargl at gcc dot gnu dot org Severity|normal |enhancement Keywords|rejects-valid | http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18026