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 13e1a1c351920e86f27c3f2ea4b4faf9bcd3f6f6..5cb637306de760b7c65317280d604a4fcdf6757f 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 25adb2c7f15ceee9389230f7d7f04ba848cd3b3c..73ee6dcd1f4115df0c555348264d4cd280edaac0 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