https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108612
Gaius Mulley <gaius at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |gaius at gcc dot gnu.org --- Comment #3 from Gaius Mulley <gaius at gcc dot gnu.org> --- Created attachment 54380 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=54380&action=edit Proposed fix PR108612 - m2/gm2-libs-iso/ClientSocket.mod:229:1: error: control reaches end of non-void function [-Werror=return-type] PR108551 - gcc/m2/gm2-libs-pim/Termbase.mod:128:1: error: control reaches end of non-void function [-Werror=return-type] The immediate fixes would be to ensure that the offending procedure functions return a value. However the front end does not correctly declared the throw function to be noreturn. Also HALT, Halt, Raise procedures in the libraries need the <* noreturn *> attribute to be applied. Finally when these changes have been made the bootstrap tools mc and pge need rebuilding. The patch also changes the build flags for m2 libraries to -Wreturn-type -fcase. (It it worth checking whether -fcase needs a 2nd implementation should -fno-exceptions be used - and call Halt).