[Issue 3581] "private" attribute breaks "override"
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Mon Feb 28 14:25:08 PST 2011
http://d.puremagic.com/issues/show_bug.cgi?id=3581
Don <clugdbug at yahoo.com.au> changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords|wrong-code |
CC| |clugdbug at yahoo.com.au
--- Comment #2 from Don <clugdbug at yahoo.com.au> 2011-02-28 14:22:18 PST ---
Applies to 'static override' as well.
One possible patch is func.c, FuncDeclaration::semantic(), line 400:
// if static function, do not put in vtbl[]
if (!isVirtual())
{
//printf("\tnot virtual\n");
+ if (isOverride())
+ error("cannot use override with non-virtual functions");
goto Ldone;
}
But this should really be caught in the parser, I think.
Anyway, it's accepts-invalid rather than wrong-code.
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
More information about the Digitalmars-d-bugs
mailing list