Java and other OO languages seem to get around it very nicely. In Java all methods are virtual by default. If you want a method to be non-virtual you mark it as final (yah, I know it's not quite the same). So, why can't .NET?
> there is no keyword for "non-virtual". C# and VB.NET are both new languages, so they can (and did) add as many new keywords as they want, like nonvirtual. Seems like it was a conscious choice to me... Just curious. ______________________________ - David Lanouette - [EMAIL PROTECTED] "Excellence, then, is not an act, but a habit" - Aristotle > -----Original Message----- > From: Discussion of advanced .NET topics. > [mailto:[EMAIL PROTECTED] On Behalf Of Dean Cleaver > Sent: Friday, July 07, 2006 7:40 PM > To: [email protected] > Subject: Re: [ADVANCED-DOTNET] Virtual methods in .NET - was > Implementing an Interface - C# vs. VB.NET > > Because in OO programming, there is no keyword for "non-virtual". > > It's an OO issue, not a .Net issue. > > Dino > > -----Original Message----- > From: Discussion of advanced .NET topics. > [mailto:[EMAIL PROTECTED] On Behalf Of > David Lanouette > Sent: Saturday, 8 July 2006 11:37 > To: [email protected] > Subject: [ADVANCED-DOTNET] Virtual methods in .NET - was > Implementing an Interface - C# vs. VB.NET > > Anybody know why methods aren't virtual by default in .NET? > It seems like a really bad default to have all methods non-virtual. > > > ______________________________ > - David Lanouette > - [EMAIL PROTECTED] > > "Excellence, then, is not an act, but a habit" - Aristotle > > =================================== > This list is hosted by DevelopMentor(r) http://www.develop.com > > View archives and manage your subscription(s) at > http://discuss.develop.com > > =================================== > This list is hosted by DevelopMentor. http://www.develop.com > > View archives and manage your subscription(s) at > http://discuss.develop.com > =================================== This list is hosted by DevelopMentorĀ® http://www.develop.com View archives and manage your subscription(s) at http://discuss.develop.com
