Thread overview
[Issue 8673] New: enum z = [0][(()=>$-1)()]; crashes the compiler
Sep 17, 2012
timon.gehr@gmx.ch
Sep 24, 2012
Walter Bright
September 17, 2012
http://d.puremagic.com/issues/show_bug.cgi?id=8673

           Summary: enum z = [0][(()=>$-1)()]; crashes the compiler
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Keywords: CTFE
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody@puremagic.com
        ReportedBy: timon.gehr@gmx.ch


--- Comment #0 from timon.gehr@gmx.ch 2012-09-16 18:37:37 PDT ---
DMD 2.060
enum z = [0][(()=>$-1)()];

dmd: interpret.c:153: void CtfeStack::saveGlobalConstant(VarDeclaration*,
Expression*): Assertion `v->init && (v->isConst() || v->isImmutable()) &&
!v->isCTFE()' failed.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
September 24, 2012
http://d.puremagic.com/issues/show_bug.cgi?id=8673



--- Comment #1 from github-bugzilla@puremagic.com 2012-09-23 20:57:14 PDT ---
Commits pushed to master at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/ddcde35249c6c780422e11aa4ac965523f58aaea
Fix issue 8673 enum z = [0][(()=>$-1)()]; crashes the compiler

variables with CTFE storage class shouldn't be treated as globals. (__dollar is a funny hack, it's neither global nor local).

https://github.com/D-Programming-Language/dmd/commit/8f47d6113c8538131397ea2f68547ba2d859efb2 Merge pull request #1127 from donc/ice8673ctfe_dollar

Fix issue 8673 enum z = [0][(()=>$-1)()]; crashes the compiler

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
September 24, 2012
http://d.puremagic.com/issues/show_bug.cgi?id=8673


Walter Bright <bugzilla@digitalmars.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |bugzilla@digitalmars.com
         Resolution|                            |FIXED


-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------