| Thread overview | |||||
|---|---|---|---|---|---|
|
May 25, 2007 final? | ||||
|---|---|---|---|---|
| ||||
Hi In the documentation about classses http://www.digitalmars.com/d/class.html I read : Final classes cannot be subclassed: final class A { } class B : A { } // error, class A is final But when I try to compile it, theres no error. Seems quite unusual to me. Is this a bug? Jan | ||||
May 25, 2007 Re: final? | ||||
|---|---|---|---|---|
| ||||
Posted in reply to Jan Hanselaer | Jan Hanselaer wrote: > Hi > > In the documentation about classses http://www.digitalmars.com/d/class.html > > I read : > Final classes cannot be subclassed: > final class A { } > class B : A { } // error, class A is final > > > But when I try to compile it, theres no error. Seems quite unusual to me. Is this a bug? > Are you using a recent version of DMD? It was a bug ( http://d.puremagic.com/issues/show_bug.cgi?id=558 ) until DMD 1.011, and I can confirm that it works in 1.014. -- Remove ".doesnotlike.spam" from the mail address. | |||
May 25, 2007 Re: final? | ||||
|---|---|---|---|---|
| ||||
Posted in reply to Deewiant | "Deewiant" <deewiant.doesnotlike.spam@gmail.com> schreef in bericht news:f36o9m$rt1$1@digitalmars.com... > Jan Hanselaer wrote: >> Hi >> >> In the documentation about classses http://www.digitalmars.com/d/class.html >> >> I read : >> Final classes cannot be subclassed: >> final class A { } >> class B : A { } // error, class A is final >> >> >> But when I try to compile it, theres no error. Seems quite unusual to me. Is this a bug? >> > > Are you using a recent version of DMD? It was a bug ( > http://d.puremagic.com/issues/show_bug.cgi?id=558 ) until DMD 1.011, and I > can > confirm that it works in 1.014. > > -- > Remove ".doesnotlike.spam" from the mail address. I was using version 1.010 ... Downloade 1.014 an you're right ... it's solved there. Thanks! | |||
Copyright © 1999-2021 by the D Language Foundation
Permalink
Reply