Thread overview
[Issue 18057] [ICE] Segmentation fault (stack overflow) in Expression::ctfeInterpret()
Dec 10, 2017
Iain Buclaw
Dec 11, 2017
Ketmar Dark
Dec 12, 2017
anonymous4
Dec 12, 2017
Iain Buclaw
December 10, 2017
https://issues.dlang.org/show_bug.cgi?id=18057

Iain Buclaw <ibuclaw@gdcproject.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |ibuclaw@gdcproject.org

--
December 11, 2017
https://issues.dlang.org/show_bug.cgi?id=18057

Ketmar Dark <ketmar@ketmar.no-ip.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |ketmar@ketmar.no-ip.org

--
December 12, 2017
https://issues.dlang.org/show_bug.cgi?id=18057

--- Comment #1 from anonymous4 <dfj1esp02@sneakemail.com> ---
What should happen? CTFE should detect and guard against stack overflow?

--
December 12, 2017
https://issues.dlang.org/show_bug.cgi?id=18057

--- Comment #2 from Iain Buclaw <ibuclaw@gdcproject.org> ---
In this instance, it should detect and guard against stack overflow, because the value of the initializer is indeed recursive.

Consider the following, that would cause a stack overflow at runtime:
---
struct RBNode
{
    RBNode *copy;
    this(int num)
    {
        this.copy = new RBNode(num++);
    }
}
---

--
January 14, 2018
https://issues.dlang.org/show_bug.cgi?id=18057

--- Comment #3 from github-bugzilla@puremagic.com ---
Commits pushed to master at https://github.com/dlang/dmd

https://github.com/dlang/dmd/commit/265e42a2bf63a89f27878fada44e9eb7892e319b
fix Issue 18057 - [ICE] Segmentation fault (stack overflow) in
Expression::ctfeInterpret()

https://github.com/dlang/dmd/commit/74285e41e670bf7e2ae7d83bc9b1617e12f93a65 Merge pull request #7701 from ibuclaw/fix18507

fix Issue 18057 - [ICE] Segmentation fault (stack overflow) in
Expression::ctfeInterpret()
merged-on-behalf-of: Sebastian Wilzbach <sebi.wilzbach@gmail.com>

--
January 14, 2018
https://issues.dlang.org/show_bug.cgi?id=18057

github-bugzilla@puremagic.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED

--
January 23, 2019
https://issues.dlang.org/show_bug.cgi?id=18057

--- Comment #4 from github-bugzilla@puremagic.com ---
Commits pushed to master at https://github.com/dlang/dmd

https://github.com/dlang/dmd/commit/8d6d1ea638e92f85b2af9fb83c2c019e38a0afe3 testsuite: Add another test for issue 18057

https://github.com/dlang/dmd/commit/de0782f642913cabb72bc91cf4d81209f035c6e2 Merge pull request #9285 from ibuclaw/fail18057b

testsuite: Add another test for issue 18057
merged-on-behalf-of: Nicholas Wilson <thewilsonator@users.noreply.github.com>

--