gcc/fortran/ChangeLog:
PR fortran/103778
* check.c (is_c_interoperable): A BOZ literal constant is not
interoperable.
gcc/testsuite/ChangeLog:
PR fortran/103778
* gfortran.dg/illegal_boz_arg_3.f90: New test.
return false;
}
+ if (expr->ts.type == BT_BOZ)
+ {
+ *msg = "BOZ literal constant";
+ return false;
+ }
+
if (expr->ts.type == BT_CLASS)
{
*msg = "Expression is polymorphic";
--- /dev/null
+! { dg-do compile }
+! PR fortran/103778
+
+program p
+ use iso_c_binding, only : c_sizeof
+ integer, parameter :: a = c_sizeof(z'1') ! { dg-error "cannot appear" }
+end