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] |
I'm out of good suggestions ;) You can do the same-qualifier matching and simply have a mismatched array element vs. array-ref type.
We could also argue that whoever calls fold_indirect_ref_1 with TYPE that doesn't even have TYPE_MAIN_VARIANT (TREE_TYPE (TREE_TYPE (op0 (!))) == TYPE_MAIN_VARIANT (type) is broken.
Thus we could argue that even ignoring qualifiers is ok - but I'd be worried about folding *((volatile int *)&a[0] + 1) to a[1] with lost volatile qualification.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |