On 11/23/2013 08:36 PM, Jason Merrill wrote:
On 11/06/2013 05:56 AM, Paolo Carlini wrote:
in this bug, filed by Zack, we loop forever after error in
constant_value_1. Straightforward thing to do, detect and break out.

This doesn't handle mutual infinite recursion, such as the modified testcase below. I think the right answer is to make sure that if we hit an instantiation depth error during instantiation of the initializer of a variable, we set DECL_INITIAL to error_mark_node. Perhaps just checking errorcount is good enough.
You are totally right. I discovered a couple of days later that I was just papering over the real issue, the error messages were still suboptimal with my patch, that was a bad sign. Thanks for your suggestion, anyway, I'll see if I can make progress with it.

Paolo.

Reply via email to