re PR fortran/46020 (Improve error string for BIND(C) diagnostic for len>1 character...
authorThomas Koenig <tkoenig@gcc.gnu.org>
Thu, 1 Nov 2018 11:55:43 +0000 (11:55 +0000)
committerThomas Koenig <tkoenig@gcc.gnu.org>
Thu, 1 Nov 2018 11:55:43 +0000 (11:55 +0000)
2018-11-01  Thomas Koenig  <tkoenig@gcc.gnu.org>

    PR fortran/46020
    * gfortran.dg/bind_c_usage_7.f90: Adjust error message.
    * gfortran.dg/bind_c_usage_32.f90: New test.

From-SVN: r265716

gcc/testsuite/ChangeLog
gcc/testsuite/gfortran.dg/bind_c_usage_7.f03

index 13e1a1c..5cb6373 100644 (file)
@@ -1,3 +1,9 @@
+2018-11-01  Thomas Koenig  <tkoenig@gcc.gnu.org>
+
+       PR fortran/46020
+       * gfortran.dg/bind_c_usage_7.f90: Adjust error message.
+       * gfortran.dg/bind_c_usage_32.f90: New test.
+
 2018-11-01  Nathan Sidwell  <nathan@acm.org>
 
        * g++.dg/abi/anon5.C: New.
index 25adb2c..73ee6dc 100644 (file)
@@ -7,7 +7,7 @@ contains
     integer(c_int) :: bar(5)
   end function bar
 
-  function my_string_func() bind(c) ! { dg-error "cannot be a character string" }
+  function my_string_func() bind(c) ! { dg-error "must have length 1" }
     character(kind=c_char, len=10) :: my_string_func
     my_string_func = 'my_string' // C_NULL_CHAR
   end function my_string_func