www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 10250] New: Grammar does not allow invariants in struct declarations

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

           Summary: Grammar does not allow invariants in struct
                    declarations
           Product: D
           Version: unspecified
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: websites
        AssignedTo: nobody puremagic.com
        ReportedBy: brian-schott cox.net


--- Comment #0 from brian-schott cox.net 2013-06-03 00:42:03 PDT ---
The following code compiles:

struct TestStruct
{
    invariant() {}
}
void main(string[] args) {}

but the specification only mentions invariants being valid inside of class
bodies. Either DMD or the specification is wrong.

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