Hi,
On 05/30/2014 04:13 PM, Jason Merrill wrote:
On 05/29/2014 03:17 PM, Paolo Carlini wrote:
I put together the below which already passes testing.
Thanks!
You are welcome. Let's finish this, then ;)
+ bool do_inject = this_type && !dependent_type_p (this_type);
!dependent_type_p should be !dependent_scope_p, or perhaps even
CLASS_TYPE_P. It should be OK to inject a this pointer of a dependent
class, and we might need it to get the right semantics.
I suspected that. I'll experiment with the latter, or in case the former.
You also need to propagate the flag in a bunch of other places:
everywhere we call build_method_type_directly ought to cover it.
Agreed, I spotted a few places. What about build_function_type? I think
it's the same issue, right? Because in that case we don't have any
problem with the injection of this but we want to propagate the flag in
order to eventually have tsubst_function_type substituting in the right
order.
Paolo.