Commit 3ac4f0e6 by Jason Merrill

(fold, COMPONENT_REF): Don't die if the CONSTRUCTOR

        doesn't initialize the field we want.

From-SVN: r8223
parent c399861d
...@@ -3424,7 +3424,11 @@ fold (expr) ...@@ -3424,7 +3424,11 @@ fold (expr)
case COMPONENT_REF: case COMPONENT_REF:
if (TREE_CODE (arg0) == CONSTRUCTOR) if (TREE_CODE (arg0) == CONSTRUCTOR)
t = TREE_VALUE (purpose_member (arg1, CONSTRUCTOR_ELTS (arg0))); {
tree m = purpose_member (arg1, CONSTRUCTOR_ELTS (arg0));
if (m)
t = TREE_VALUE (m);
}
return t; return t;
case RANGE_EXPR: case RANGE_EXPR:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment