Summary: Parser bug with const placed after ~this() in decl
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD

--- Comment #0 from Dmitry Olshansky <> 2012-07-04 
02:28:45 PDT ---
A small test shows parser inconsistency:

struct A{
    //const this(int dummy){} //fine
    this(int dummy) const {} //and this too
    ~this() const{} //NG
    //const ~this(){} //this work

void main(){}

m1.d(4): Error: semicolon expected following function declaration

Note that const in front of ~this works but not after unlike  any other member

Tested with latest git master for 2.060, must have been in previous versions as

Configure issuemail:
------- You are receiving this mail because: -------

Reply via email to