Re: C PATCH to fix ICE with -Wsizeof-array-argument (PR c/82167)

2017-09-13 Thread Jeff Law
On 09/13/2017 05:00 AM, Marek Polacek wrote: > This fixes a segv, where -Wsizeof-array-argument crashed because > expr.original_type was null. It was null because for sizeof (*) > we go to c_parser_unary_expression's case CPP_AND: and case CPP_MULT:, > and that removes the original_type. But we

C PATCH to fix ICE with -Wsizeof-array-argument (PR c/82167)

2017-09-13 Thread Marek Polacek
This fixes a segv, where -Wsizeof-array-argument crashed because expr.original_type was null. It was null because for sizeof (*) we go to c_parser_unary_expression's case CPP_AND: and case CPP_MULT:, and that removes the original_type. But we don't need the original type, we can just use