re PR fortran/13826 (Derived types in DATA statements not PARAMETERs)
authorTobias Schlüter <tobias.schlueter@physik.uni-muenchen.de>
Sat, 15 May 2004 18:10:06 +0000 (20:10 +0200)
committerTobias Schlüter <tobi@gcc.gnu.org>
Sat, 15 May 2004 18:10:06 +0000 (20:10 +0200)
testsuite:
PR fortran/13826
PR fortran/13940
* gfortran.fortran-torture/compile/data_1.f90: New test.
(add second test)

fortran:
* primary.c (match_boz_constant): Use gfc_notify_std() for
issuing a warning or an error.

From-SVN: r81892

gcc/fortran/ChangeLog
gcc/fortran/primary.c
gcc/testsuite/ChangeLog
gcc/testsuite/gfortran.fortran-torture/compile/data_1.f90

index 16ea4470998b03db8e1c78b7f15de721d45c82fc..549b82daeacbffe8d761ad54f4c61c28c6783817 100644 (file)
@@ -1,3 +1,8 @@
+2004-05-15  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
+
+       * primary.c (match_boz_constant): Use gfc_notify_std() for
+       issuing a warning or an error.
+
 2004-05-15  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
 
        PR fortran/13826
index d10a46244e9f37950c6e3c6ae816d063475a1002..0e7e7e796aa0d5f1226a0c6e271be71337493a36 100644 (file)
@@ -255,9 +255,12 @@ match_boz_constant (gfc_expr ** result)
       rname = "octal";
       break;
     case 'x':
-      if (pedantic)
-       gfc_warning_now ("Hexadecimal constant at %C uses non-standard "
-                        "syntax. Use \"Z\" instead.");
+      if (pedantic
+         && (gfc_notify_std (GFC_STD_GNU, "Extension: Hexadecimal "
+                            "constant at %C uses non-standard syntax.")
+             == FAILURE))
+       goto backup;
+
       /* Fall through.  */
     case 'z':
       radix = 16;
index d23aed287c8bf11087cbeda029647fa31ea4c086..c1a37d6da8f46f2d8646cd02a8f2d2f7cb94fbb2 100644 (file)
@@ -1,6 +1,7 @@
 2004-05-15  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
 
        PR fortran/13826
+       PR fortran/13940
        * gfortran.fortran-torture/compile/data_1.f90: New test.
 
 2004-05-15  Ulrich Weigand  <uweigand@de.ibm.com>
index fa8ab9fe1f7a0b31390c388249290568fca077f5..e3d65efc520d0b1b562d43e7a2f6f2c4da63ae96 100644 (file)
@@ -5,3 +5,7 @@ END TYPE
 TYPE(a) :: y
 DATA y /a(1.)/ ! used to give an error about non-PARAMETER
 END
+! this tests the fix for PR 13940
+SUBROUTINE a
+DATA i /x'f95f95f9'/
+END