- if (TREE_CODE (exp) == ARRAY_REF)
- {
- tree domain = TYPE_DOMAIN (TREE_TYPE (TREE_OPERAND (exp, 0)));
-
- if (domain != 0
- && ((TREE_CODE (TYPE_MIN_VALUE (domain)) != INTEGER_CST
- && contains_this_placeholder_p (TYPE_MIN_VALUE (domain),
- pl))
- || (TREE_CODE (TYPE_MAX_VALUE (domain)) != INTEGER_CST
- && contains_this_placeholder_p (TYPE_MAX_VALUE (domain),
- pl))
- || contains_this_placeholder_p (TREE_OPERAND (exp, 1), pl)))
- return 1;
- }
- else if (TREE_CODE (exp) == BIT_FIELD_REF
- && (contains_this_placeholder_p (TREE_OPERAND (exp, 1), pl)
- || contains_this_placeholder_p (TREE_OPERAND (exp, 2), pl)))
- return 1;
-
- return contains_this_placeholder_p (TREE_OPERAND (exp, 0), pl);
+ /* Don't look at any PLACEHOLDER_EXPRs that might be in index or bit
+ position computations since they will be converted into a
+ WITH_RECORD_EXPR involving the reference, which will assume
+ here will be valid. */
+ return contains_placeholder_p (TREE_OPERAND (exp, 0));