OSDN Git Service

2006-02-15 Toon Moene <toon@moene.indiv.nluug.nl>
authortoon <toon@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 15 Feb 2006 21:06:58 +0000 (21:06 +0000)
committertoon <toon@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 15 Feb 2006 21:06:58 +0000 (21:06 +0000)
PR fortran/26054
* fortran/options.c: Do not warn for Fortran 2003 features
by default.
* testsuite/gfortran.dg/enum_8.f90: Remove check for warning.
* testsuite/gfortran.dg/iomsg_1.f90: Ditto.
* testsuite/gfortran.dg/enum_1.f90: Ditto.
* testsuite/gfortran.dg/enum_9.f90: Ditto.
* testsuite/gfortran.dg/enum_2.f90: Ditto.
* testsuite/gfortran.dg/enum_10.f90: Ditto.
* testsuite/gfortran.dg/enum_3.f90: Ditto.
* testsuite/gfortran.dg/flush_1.f90: Ditto.
* testsuite/gfortran.dg/enum_4.f90: Ditto.
* testsuite/gfortran.dg/array_constructor_1.f90: Ditto.
* testsuite/gfortran.dg/enum_5.f90: Ditto.
* testsuite/gfortran.dg/enum_6.f90: Ditto.
* testsuite/gfortran.dg/enum_7.f90: Ditto.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@111117 138bc75d-0d04-0410-961f-82ee72b054a4

16 files changed:
gcc/fortran/ChangeLog
gcc/fortran/options.c
gcc/testsuite/ChangeLog
gcc/testsuite/gfortran.dg/array_constructor_1.f90
gcc/testsuite/gfortran.dg/enum_1.f90
gcc/testsuite/gfortran.dg/enum_10.f90
gcc/testsuite/gfortran.dg/enum_2.f90
gcc/testsuite/gfortran.dg/enum_3.f90
gcc/testsuite/gfortran.dg/enum_4.f90
gcc/testsuite/gfortran.dg/enum_5.f90
gcc/testsuite/gfortran.dg/enum_6.f90
gcc/testsuite/gfortran.dg/enum_7.f90
gcc/testsuite/gfortran.dg/enum_8.f90
gcc/testsuite/gfortran.dg/enum_9.f90
gcc/testsuite/gfortran.dg/flush_1.f90
gcc/testsuite/gfortran.dg/iomsg_1.f90

index 013e7ba..5a0b387 100644 (file)
@@ -1,3 +1,8 @@
+2006-02-15  Toon Moene  <toon@moene.indiv.nluug.nl>
+
+       PR fortran/26054
+       * options.c: Do not warn for Fortran 2003 features by default.
+
 2006-02-15  Tobias Schl\81üter  <tobias.schlueter@physik.uni-muenchen.de>
 
        * check.c: Update copyright years.
index bf1da85..6a9bec9 100644 (file)
@@ -90,7 +90,7 @@ gfc_init_options (unsigned int argc ATTRIBUTE_UNUSED,
     | GFC_STD_F2003 | GFC_STD_F95 | GFC_STD_F77 | GFC_STD_GNU
     | GFC_STD_LEGACY;
   gfc_option.warn_std = GFC_STD_F95_OBS | GFC_STD_F95_DEL
-    | GFC_STD_F2003 | GFC_STD_LEGACY;
+    | GFC_STD_LEGACY;
 
   gfc_option.warn_nonstd_intrinsics = 0;
 
index d22edd3..21fcc95 100644 (file)
@@ -1,3 +1,20 @@
+2006-02-15  Toon Moene  <toon@moene.indiv.nluug.nl>
+
+       PR fortran/26054
+       * gfortran.dg/enum_8.f90: Remove check for warning.
+       * gfortran.dg/iomsg_1.f90: Ditto.
+       * gfortran.dg/enum_1.f90: Ditto.
+       * gfortran.dg/enum_9.f90: Ditto.
+       * gfortran.dg/enum_2.f90: Ditto.
+       * gfortran.dg/enum_10.f90: Ditto.
+       * gfortran.dg/enum_3.f90: Ditto.
+       * gfortran.dg/flush_1.f90: Ditto.
+       * gfortran.dg/enum_4.f90: Ditto.
+       * gfortran.dg/array_constructor_1.f90: Ditto.
+       * gfortran.dg/enum_5.f90: Ditto.
+       * gfortran.dg/enum_6.f90: Ditto.
+       * gfortran.dg/enum_7.f90: Ditto.
+
 2006-02-15  Jakub Jelinek  <jakub@redhat.com>
 
        PR middle-end/26300
index 20452f3..0ba8ba0 100644 (file)
@@ -4,12 +4,12 @@ program bracket_array_constructor
     implicit none
     integer :: a(4), i
 
-    a = [ 1, 2, 3, 4 ]  ! { dg-warning "array constructor" }
+    a = [ 1, 2, 3, 4 ]
     do i = 1, size(a)
         if (a(i) /= i) call abort()
     end do
 
-    a = [ (/ 1, 2, 3, 4 /) ]  ! { dg-warning "array constructor" }
+    a = [ (/ 1, 2, 3, 4 /) ]
     do i = 1, size(a)
         if (a(i) /= i) call abort()
     end do
index 1af5ab8..0156cb5 100644 (file)
@@ -3,7 +3,7 @@
 
 program main
   implicit none
-  enum, bind (c)  ! { dg-warning "New in Fortran 2003" }
+  enum, bind (c)
     enumerator :: red, black
     enumerator blue
   end enum
index c3fbe53..dad29a1 100644 (file)
@@ -5,15 +5,15 @@
 ! corresponding C type.
 
 module enum_10
-enum, bind( c )   ! { dg-warning "New in Fortran 2003" }
+enum, bind( c )
    enumerator :: one1 = 1, two1, max1 = huge(1_1)
 end enum
 
-enum, bind( c )   ! { dg-warning "New in Fortran 2003" }
+enum, bind( c )
    enumerator :: one2 = 1, two2, max2 = huge(1_2)
 end enum
 
-enum, bind( c )   ! { dg-warning "New in Fortran 2003" }
+enum, bind( c )
    enumerator :: one4 = 1, two4, max4 = huge(1_4)
 end enum
 end module enum_10
index 1fd7247..6d8a4b2 100644 (file)
@@ -3,7 +3,7 @@
 
 program main
   implicit none
-  enum, bind (c)  ! { dg-warning "New in Fortran 2003" }
+  enum, bind (c)
     enumerator :: red, black
     integer :: x  ! { dg-error "Unexpected data declaration" }
     enumerator blue = 1  ! { dg-error "Syntax error in ENUMERATOR definition" }
index 3b01f93..277cabe 100644 (file)
@@ -3,7 +3,7 @@
 
 program main
   implicit none
-  enum, bind (c)  ! { dg-warning "New in Fortran 2003" } 
+  enum, bind (c)
     enumerator :: red, black = 2.2  ! { dg-error "initialized with integer expression" }
     enumerator :: blue = "x"  ! { dg-error "initialized with integer expression" }
   end enum  ! { dg-error "has no ENUMERATORS" }
index e3b13d7..99acda0 100644 (file)
@@ -3,12 +3,12 @@
 
 program main
   implicit none
-  enum, bind (c)  ! { dg-warning "New in Fortran 2003" } 
+  enum, bind (c)
     enumerator :: red, black = 2     
     enumerator :: blue = 1, red  ! { dg-error "already" }
   end enum
 
-  enum, bind (c)  ! { dg-warning "New in Fortran 2003" } 
+  enum, bind (c)
     enumerator :: r, b(10) = 2  ! { dg-error "cannot be array" }
     enumerator , save :: g = 1  ! { dg-error "cannot have attributes" }  
   end  ! { dg-error " END ENUM" } 
index 9ff2efa..604e50d 100644 (file)
@@ -5,7 +5,7 @@ program main
   implicit none
   integer :: i = 1
 
-  enum, bind (c)  ! { dg-warning "New in Fortran 2003" } 
+  enum, bind (c)
     enumerator :: red, black = i  ! { dg-error "is a variable" }
     enumerator :: blue = 1  
   end enum junk  ! { dg-error "Syntax error" }
index 0396862..a030727 100644 (file)
@@ -5,7 +5,7 @@ program main
   implicit none
   integer :: i = 1
 
-  enum, bind (c)  ! { dg-warning "New in Fortran 2003" } 
+  enum, bind (c)
     enumerator :: sun, mon = 2    
     i = 2  ! { dg-error "Unexpected" }  
     enumerator :: wed = 1    
index d85e61d..9971a51 100644 (file)
@@ -4,7 +4,7 @@
 program main
   implicit none
 
-  enum, bind (c)  ! { dg-warning "New in Fortran 2003" } 
+  enum, bind (c)
     enumerator :: sun, mon = 2    
     enum, bind (c)  ! { dg-error "Unexpected" }
       enumerator :: apple, mango
index 686b128..cd3c12a 100644 (file)
@@ -4,11 +4,11 @@
 
 program main
   implicit none
-  enum, bind (c)  ! { dg-warning "New in Fortran 2003" }
+  enum, bind (c)
     enumerator :: pp , qq = 4294967295, rr  ! { dg-error "not initialized with integer" }
   end enum  ! { dg-error "has no ENUMERATORS" }
 
-  enum, bind (c)  ! { dg-warning "New in Fortran 2003" }
+  enum, bind (c)
     enumerator :: p , q = 4294967299_8, r  ! { dg-error "Arithmetic overflow" }
   end enum  ! { dg-error "has no ENUMERATORS" }
 
index 81c441a..e735cf8 100644 (file)
@@ -4,7 +4,7 @@
 
 program main
   implicit none
-  enum, bind (c)  ! { dg-warning "New in Fortran 2003" }
+  enum, bind (c)
     enumerator :: red, black = 127
     enumerator blue
   end enum
index 51b7fa0..90875dc 100644 (file)
@@ -8,17 +8,17 @@ program flush_1
    open (unit=10, access='SEQUENTIAL', status='SCRATCH')
 
    write (10, *) 42
-   flush 10                   ! { dg-warning "Fortran 2003: FLUSH statement" }
+   flush 10
 
    write (10, *) 42
-   flush(10)                  ! { dg-warning "Fortran 2003: FLUSH statement" }
+   flush(10)
 
    write (10, *) 42
-   flush(unit=10, iostat=ios) ! { dg-warning "Fortran 2003: FLUSH statement" }
+   flush(unit=10, iostat=ios)
    if (ios /= 0) call abort
 
    write (10, *) 42
-   flush (unit=10, err=20)    ! { dg-warning "Fortran 2003: FLUSH statement" }
+   flush (unit=10, err=20)
    goto 30
 20 call abort
 30 continue
index 6a5819d..20c8e8b 100644 (file)
@@ -5,24 +5,24 @@ program iomsg_test
 
   ! Test that iomsg is left unchanged with no error
   ch = 'asdf'
-  open(10, status='scratch', iomsg=ch, iostat=i) ! { dg-warning "Fortran 2003: IOMSG tag" }
+  open(10, status='scratch', iomsg=ch, iostat=i)
   if (ch .ne. 'asdf') call abort
 
   ! Test iomsg with data transfer statement
-  read(10,'(I2)', iomsg=ch, end=100) k ! { dg-warning "Fortran 2003: IOMSG tag" }
+  read(10,'(I2)', iomsg=ch, end=100) k
   call abort
 100 continue
   if (ch .ne. 'End of file') call abort
 
   ! Test iomsg with open
-  open (-3, err=200, iomsg=ch) ! { dg-warning "Fortran 2003: IOMSG tag" }
+  open (-3, err=200, iomsg=ch)
 
   call abort
 200 continue
   if (ch .ne. 'Bad unit number in OPEN statement') call abort
 
   ! Test iomsg with close
-  close(23,status="no_idea", err=500, iomsg=ch) ! { dg-warning "Fortran 2003: IOMSG tag" }
+  close(23,status="no_idea", err=500, iomsg=ch)
 500 continue
   if (ch .ne. "Bad STATUS parameter in CLOSE statement") call abort
 end program iomsg_test