On 10/07/2015 08:42 PM, Jason Merrill wrote:
While looking at another issue I noticed that in g++.dg/init/vbase1.C
the Diamond(int) constructor was unnecessarily storing a CONSTRUCTOR
into a stack temporary and then copying it into the SubB base subobject
rather than directly storing the CONSTRUCTOR. It was doing this because
the base subobject is smaller than a complete object of SubB, but we
already know how to store a CONSTRUCTOR into a space smaller than it
would normally take without needing to introduce an extra temporary.
This patch fixes that.
Tested x86_64-pc-linux-gnu. OK for trunk?
OK.
jeff