https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115112

--- Comment #7 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-14 branch has been updated by Gaius Mulley
<ga...@gcc.gnu.org>:

https://gcc.gnu.org/g:3d961691e0878e1328f9cbbc1d1af5e573ee6786

commit r14-11306-g3d961691e0878e1328f9cbbc1d1af5e573ee6786
Author: Gaius Mulley <gaiusm...@gmail.com>
Date:   Thu Feb 13 18:17:17 2025 +0000

    [PATCH] PR modula2/115112 Incorrect line debugging information occurs
during INC builtin

    This patch fixes location bugs in BuildDecProcedure,
    BuildIncProcedure, BuildInclProcedure, BuildExclProcedure and
    BuildThrow.  All these procedure functions use the token position
    passed as a parameter (rather than from the quad stack).  It also
    fixes location bugs in CheckRangeIncDec to ensure that the token
    position is stored on the quad stack before calling subsidiary
    procedure functions.

    gcc/m2/ChangeLog:

            PR modula2/115112
            * gm2-compiler/M2Quads.mod (BuildPseudoProcedureCall): Pass
            tokno to each build procedure.
            (BuildThrowProcedure): New parameter functok.
            (BuildIncProcedure): New parameter proctok.
            Pass proctok on the quad stack during every push.
            (BuildDecProcedure): Ditto.
            (BuildInclProcedure): New parameter proctok.
            (BuildExclProcedure): New parameter proctok.

    gcc/testsuite/ChangeLog:

            PR modula2/115112
            * gm2/pim/run/pass/dectest.mod: New test.
            * gm2/pim/run/pass/inctest.mod: New test.

    (cherry picked from commit 4d0faaaaf917528d1c59bfad5401274c5be71b7b)

    Signed-off-by: Gaius Mulley <gaiusm...@gmail.com>

Reply via email to