[PATCH] D28889: Change where we handle arg-dependent diagnose_if attributes
George Burgess IV via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Jan 18 20:35:49 PST 2017
george.burgess.iv created this revision.
As it turns out, emitting diagnostics from places where you're not meant to emit them from is a very bad idea. :)
After some looking around, it seems that it's less insane to check for `diagnose_if` attributes in code that's already checking for e.g. nullness warnings. As a result, we get to rip out the `diagnose_if`-induced changes to overloading. Woohoo!
This also includes a slight change to how `diagnose_if` works: for "error" calls, we'll always assume that overload resolution chose the overload the user wanted. So, regardless of whetehr a `diagnose_if` attribute emits a diag or not, we'll continue building the AST/etc as usual.
This patch aims to fix PR31638, PR31639, and PR31640.
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 57244 bytes
Desc: not available
More information about the cfe-commits