On 03/01/2017 09:40 AM, Jakub Jelinek wrote:
Unfortunately my patch apparently broke the case where such ctor in virtual class has no arguments (void_type_node is used in that case instead of a TREE_LIST, it is a little bit weird (I'd have expected perhaps void_list_node instead), but it is what it does).
Seems funky (but not your problem), which of the testcase(s) does it correspond to?
So this patch in addition to not walking anything for arguments == void_type_node just walks the arguments and calls mark_exp_read on all PARM_DECLs in there (I think that is all we care about, we can't have there VAR_DECLs or RESULT_DECLs).
I suppose someone could pass in a global VAR_DECL, but if the ctor's the only use of that decl, it's rather stupid.
Do you actually need to iterate over the arg list -- can't you just pass ARGUMENTS straight into cp_walk_tree?
Ok with or without that change. nathan -- Nathan Sidwell