[Issue 3863] Various errors and ICEs for struct constructors with ellipses

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sun Feb 28 03:29:19 PST 2010


http://d.puremagic.com/issues/show_bug.cgi?id=3863



--- Comment #1 from Sönke Ludwig <ludwig at informatik.uni-luebeck.de> 2010-02-28 03:29:17 PST ---
(In reply to comment #0)
> The following code snipped lists a number of ways to define a struct constant
> which fail compilation in one way or another. This happens only 
... if ellipses are used for the constructor arguments. However, the "more
fields than initializers" case remains even without them:

---
struct Vec{
    //static immutable constant = Vec(1, 2); // error more initializers than
fields
    //static immutable Vec constant = Vec(1, 2); // compiles
    //enum constant = Vec(1, 2); // error more initializers than fields
    //enum Vec constant = Vec(1, 2); // compiles

    this(float a, float b) {}
}
---

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


More information about the Digitalmars-d-bugs mailing list