On Mon, Oct 27, 2014 at 7:49 PM, David Blaikie <[email protected]> wrote: > > > On Mon, Oct 27, 2014 at 4:40 PM, Aaron Ballman <[email protected]> > wrote: >> >> On Mon, Oct 27, 2014 at 7:38 PM, Richard Smith <[email protected]> >> wrote: >> > On Mon, Oct 27, 2014 at 4:35 PM, Aaron Ballman <[email protected]> >> > wrote: >> >> >> >> On Mon, Oct 27, 2014 at 7:30 PM, Jordan Rose <[email protected]> >> >> wrote: >> >> > Nifty! But do you think this is cheap enough for a general compiler >> >> > warning? It certainly doesn't depend on the analyzer's path-sensitive >> >> > analysis, so it's mostly just how much we care about the cost of >> >> > isDerivedFrom. >> >> >> >> This should be relatively inexpensive, so it may make sense as a >> >> general compiler warning if others feel that's a better approach. >> > >> > >> > Yes, I think this is a good candidate for an (on-by-default) compiler >> > warning. >> >> Then I'll rework this, thanks! > > > While it's probably more use as its own warning, I wonder if the CFG should > be taught about this anyway (maybe not) & then it should appear as an > unreachable-code warning.
That's an interesting suggestion; I don't think it's a bad idea to teach the CFG about this at some point, but I do think it's slightly better as its own warning (esp since we already have similar warnings regarding duplicate handlers). ~Aaron _______________________________________________ cfe-commits mailing list [email protected] http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits
