digitalmars.D.bugs - [Issue 1909] New: final classes' methods that don't override anything shouldn't be virtual
- d-bugmail puremagic.com (28/28) Mar 11 2008 http://d.puremagic.com/issues/show_bug.cgi?id=1909
- d-bugmail puremagic.com (11/11) Sep 18 2009 http://d.puremagic.com/issues/show_bug.cgi?id=1909
- d-bugmail puremagic.com (15/15) Sep 18 2009 http://d.puremagic.com/issues/show_bug.cgi?id=1909
http://d.puremagic.com/issues/show_bug.cgi?id=1909 Summary: final classes' methods that don't override anything shouldn't be virtual Product: D Version: 1.024 Platform: PC OS/Version: Windows Status: NEW Keywords: wrong-code Severity: minor Priority: P3 Component: DMD AssignedTo: bugzilla digitalmars.com ReportedBy: thecybershadow gmail.com test case: final class C { void m() { } } void main() { (new C).m; } Examining the generated code shows that m is a virtual function, and called using the class's Vtable. Needless to say, this is an unneeded slowdown. --
Mar 11 2008
http://d.puremagic.com/issues/show_bug.cgi?id=1909 Stewart Gordon <smjg iname.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |smjg iname.com This should also apply to methods that are declared final, whether in a final class or not. What happens here at the moment? -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Sep 18 2009
http://d.puremagic.com/issues/show_bug.cgi?id=1909 Matti Niemenmaa <matti.niemenmaa+dbugzilla iki.fi> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED CC| |matti.niemenmaa+dbugzilla i | |ki.fi Resolution| |DUPLICATE 2009-09-18 06:12:59 PDT --- in 1.037. *** This issue has been marked as a duplicate of issue 2326 *** -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Sep 18 2009