On Monday, 11 January 2016 at 10:27:59 UTC, Brian Schott wrote:
I have an idea to simplify the grammar:

Attribute:
          Pragma
        | ProtectionAttribute
        | FloorWaxOrDessertTopping
        ;

StorageClass:
          "enum"
        | FloorWaxOrDessertTopping
        ;

FloorWaxOrDessertTopping:
          "abstract"
        | AlignAttribute
        | "auto"
        | "const"
        | DeprecatedAttribute
        | "enum"
        | "extern"
        | "final"
        | "__gshared"
        | "immutable"
        | "inout"
        | LinkageAttribute
        | "nothrow"
        | "override"
        | Property
        | "pure"
        | "ref"
        | "scope"
        | "shared"
        | "static"
        | "synchronized"
        ;

I'm only half joking.

Grammar is a bit over me but are you talking about this:

http://dpaste.dzfl.pl/bfc71e865596

---
enum A{A0,A1}
enum B = 1;
enum {C,D}

void main()
{
    static assert(is(A==enum));
    static assert(!is(B==enum));
    static assert(!is(C==enum));
}
---

by any chance ?

Reply via email to