[cfe-commits] Virtual function recognition

Douglas Gregor dgregor at apple.com
Thu Nov 6 05:49:57 PST 2008

On Nov 5, 2008, at 6:04 PM, Sebastian Redl wrote:
> The attached patch enables semantic checking of virtual functions.  
> This means:
> 1) Virtual fields and virtual static functions are rejected.
> 2) Classes with virtual functions are not considered aggregates.
> 3) Classes with virtual functions are polymorphic, as are classes  
> derived from polymorphic classes.
> 4) dynamic_cast checking is complete.

Great, thanks! I only have one lame comment, and you're free to commit:

+DIAG(err_virtual_non_function, ERROR,
+     "virtual can only appear on non-static member functions")

Could you put single quotes around 'virtual'?

   - Doug

More information about the cfe-commits mailing list