[C++ Patch] PR 52174 aka DR 1423
Jason Merrill
jason@redhat.com
Tue Jun 3 15:02:00 GMT 2014
On 06/03/2014 10:30 AM, Paolo Carlini wrote:
> implementing the resolution seems rather straightforward, just check
> LOOKUP_ONLYCONVERTING in standard_conversion.
Yep. Though it would be better to return a bad_p conversion than none
at all.
> However, while playing
> with some additional tests outside bug & testsuite (similar to
> nullptr32.C), I noticed a latent issue: in case of base initializers we
> were setting anyway LOOKUP_ONLYCONVERTING in add_function_candidate
Right. In the case of
> + TDerived()
> + : TBase<T>(nullptr) { }
we have direct-initialization of TBase<T>, but the parameter of the
TBase constructor is copy-initialized, so nullptr32.C is ill-formed;
please drop this hunk of the patch.
Jason
More information about the Gcc-patches
mailing list