My GCC extension will never be merged with the GCC source I dont think
but will be distributed as a patch for GCC. So with that in mind do you
think there will be any functional issues for me to set the TREE_TYPE of
all THROW_EXPR nodes to have the type of the exception they are throwing
or void (as it is currently) if the type is not known (Like for rethrow)?


Currently the throw expr nodes are constructed with the line:
exp = build1 (THROW_EXPR, void_type_node, exp);

I was going to change that line to:
exp = build1 (THROW_EXPR, resulting_type, exp);

where resulting_type is the type of the exception being thrown (stripped
of CV qualifiers + references by calling prepare_eh_type to get the
correct type).

I have tried it and there don't seem to be any problems with the small
tests I have performed, but just thought i would see if others know of
any issues that may arise from doing this?

Thanks,
Brendon.

Reply via email to