https://gcc.gnu.org/g:1f07dea91c37d45874cd91c2333696e784ae2d44
commit r15-4484-g1f07dea91c37d45874cd91c2333696e784ae2d44 Author: Thomas Koenig <tkoe...@gcc.gnu.org> Date: Fri Oct 18 17:58:56 2024 +0200 Handle GFC_STD_UNSIGNED like a standard in error messages. gcc/fortran/ChangeLog: * error.cc (notify_std_msg): Handle GFC_STD_UNSIGNED. gcc/testsuite/ChangeLog: * gfortran.dg/unsigned_37.f90: New test. Diff: --- gcc/fortran/error.cc | 2 ++ gcc/testsuite/gfortran.dg/unsigned_37.f90 | 4 ++++ 2 files changed, 6 insertions(+) diff --git a/gcc/fortran/error.cc b/gcc/fortran/error.cc index d184ffd878ad..afe2e49e4994 100644 --- a/gcc/fortran/error.cc +++ b/gcc/fortran/error.cc @@ -362,6 +362,8 @@ notify_std_msg(int std) return _("Obsolescent feature:"); else if (std & GFC_STD_F95_DEL) return _("Deleted feature:"); + else if (std & GFC_STD_UNSIGNED) + return _("Unsigned:"); else gcc_unreachable (); } diff --git a/gcc/testsuite/gfortran.dg/unsigned_37.f90 b/gcc/testsuite/gfortran.dg/unsigned_37.f90 new file mode 100644 index 000000000000..b11f214336aa --- /dev/null +++ b/gcc/testsuite/gfortran.dg/unsigned_37.f90 @@ -0,0 +1,4 @@ +! { dg-do compile } +program main + use iso_fortran_env, only : uint32 ! { dg-error "not in the selected standard" } +end program main