[Issue 9040] Assertion `precedence[e->op] != PREC_zero' failed instantiating anonymous class at compile time

d-bugmail at puremagic.com d-bugmail at puremagic.com
Thu Nov 21 22:42:22 PST 2013


https://d.puremagic.com/issues/show_bug.cgi?id=9040


Kenji Hara <k.hara.pg at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |RESOLVED
         Resolution|                            |WORKSFORME


--- Comment #7 from Kenji Hara <k.hara.pg at gmail.com> 2013-11-21 22:42:18 PST ---
(In reply to comment #6)
> (In reply to comment #5)
> I do not longer observe the compiler failure. In v2.063.2, I am hitting Issue
> 11126 instead when running:
> -----
> class BaseClass {}
> 
> void main()
> {
>     static BaseClass staticAnonInstance = new class BaseClass {};
> }
> -----

>From 2.064, the code prints following error.

test.d(5): Error: variable test.main.staticAnonInstance is mutable. Only const
or immutable class thread local variable are allowed, not test.BaseClass

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


More information about the Digitalmars-d-bugs mailing list