]> git.ipfire.org Git - thirdparty/gcc.git/commit
d: Fix infinite loop regression in CTFE
authorIain Buclaw <ibuclaw@gdcproject.org>
Thu, 17 Apr 2025 06:21:40 +0000 (08:21 +0200)
committerIain Buclaw <ibuclaw@gdcproject.org>
Thu, 17 Apr 2025 06:59:36 +0000 (08:59 +0200)
commit0eae20c899e327aec0e48b9ff2d856aba44b2639
treec7fb1df49b405f208ce25d91fc95209de0e3905c
parenta4f81e168e02b0b1f8894070c6552b85672d4ee5
d: Fix infinite loop regression in CTFE

An infinite loop was introduced by a previous refactoring in the
semantic pass for DeclarationExp nodes. Ensure the loop properly
terminates and add tests cases.

gcc/d/ChangeLog:

* dmd/MERGE: Merge upstream dmd 956e73d64e.

gcc/testsuite/ChangeLog:

* gdc.test/fail_compilation/test21247.d: New test.
* gdc.test/fail_compilation/test21247b.d: New test.

Reviewed-on: https://github.com/dlang/dmd/pull/21248
gcc/d/dmd/MERGE
gcc/d/dmd/expressionsem.d
gcc/testsuite/gdc.test/fail_compilation/test21247.d [new file with mode: 0644]
gcc/testsuite/gdc.test/fail_compilation/test21247b.d [new file with mode: 0644]