This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [C++ Patch/RFC] PR 43906


Hi,

On 08/05/2014 02:32 PM, Jason Merrill wrote:
On 08/05/2014 08:10 AM, Paolo Carlini wrote:
.. a clarification. As I tried to briefly explain yesterday, this kind
of change means that:

extern void z();
void il() { if (z != (void*)0) z(); }

doesn't trigger anymore the pedwarn at beginning of
composite_pointer_type about the comparison itself, for the simple
reason that we don't call it anymore.
So let's keep calling it when the RHS is also a pointer?
Indeed ;) Then I'm finishing testing the below.

Note: I also rearranged the conditionals, splitting out the TYPE_PTRDATAMEM_P case, which was causing confusion in some cases: we were feeding a TYPE_PTRDATAMEM_P and a TYPE_PTR_P to composite_pointer_type, thus obtaining immediately verbose diagnostic, instead of the expected clean one talking about invalid operands to operator!=.

Thanks,
Paolo.

/////////////////////


Attachment: patch_43906_4
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]