https://gcc.gnu.org/bugzilla/show_bug.cgi?id=128891
--- Comment #2 from GCC Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Gaius Mulley <[email protected]>: https://gcc.gnu.org/g:c3129ba5e3ec6662168ccb87a7fe60bc72b5a410 commit r17-6763-gc3129ba5e3ec6662168ccb87a7fe60bc72b5a410 Author: Gaius Mulley <[email protected]> Date: Fri Nov 27 14:02:04 2026 +0000 PR modula2/128891: ICE when attempting a conversion from REAL32 to REAL64 This patch fixes an ICE which occurs when a program attempts to convert a REAL32 to a REAL64. The fix treats the sized SYSTEM REAL types the same as the base REAL, LONGREAL, SHORTREAL types. It introduces a new procedure function IsRealGCC (a target supported GCC real type) which is used instead of IsRealType (strict ISO Modula-2 real types only). gcc/m2/ChangeLog: PR modula2/128891 * gm2-compiler/M2Base.def (IsRealGCC): New procedure function. * gm2-compiler/M2Base.mod (IsRealGCC): Implement new procedure function. * gm2-compiler/M2ALU.mod (PushTypeOfTree): Replace IsRealType with IsRealGCC. * gm2-compiler/M2GCCDeclare.mod (TryDeclareConst): Ditto. (DeclareConst): Ditto. * gm2-compiler/M2GenGCC.mod (IsCoerceableParameter): Ditto. (CheckConvertCoerceParameter): Ditto. (BinaryOperandRealFamily): Ditto. (FoldUnary): Ditto. (PopKindTree): Ditto. (FoldConvert): Ditto. * gm2-compiler/M2Quads.mod (BuildTruncFunction): Ditto. * gm2-compiler/M2Range.mod (GetMinMax): Ditto. (DoCodeAssignmentExprType): Ditto. * gm2-compiler/PCSymBuild.mod (TypeToMeta): Ditto. gcc/testsuite/ChangeLog: PR modula2/128891 * gm2/extensions/pass/real32conv.mod: New test. Signed-off-by: Gaius Mulley <[email protected]>
