This is the mail archive of the
mailing list for the GCC project.
Re: Elementary question about complete_type vs tsubst_flags_t
- From: Paolo Carlini <paolo dot carlini at oracle dot com>
- To: Jason Merrill <jason at redhat dot com>, "gcc at gnu dot org" <gcc at gnu dot org>
- Date: Fri, 10 Jul 2015 15:52:49 +0200
- Subject: Re: Elementary question about complete_type vs tsubst_flags_t
- Authentication-results: sourceware.org; auth=none
- References: <559FABE5 dot 6010704 at oracle dot com> <559FCBC0 dot 6040109 at redhat dot com>
On 07/10/2015 03:42 PM, Jason Merrill wrote:
Good. Thus in practice the "immediate context" theory boils down to
those irrevocable instantiations, that wasn't completely clear to me,
On 07/10/2015 07:26 AM, Paolo Carlini wrote:
I have an old question about an issue which I noticed a while ago, and
for example clearly shows up in c++/62085: in a few places in pt.c we
call complete_type from functions getting a tsubst_flags_t. Clearly,
complete_type often calls instantiate_class_template_1, which, in turn,
often calls tsubst with an hard-coded tf_error. Thus possible errors
coming from an initial tf_none.
Yep. Those errors are outside the "immediate context" of the
substitution, so SFINAE doesn't apply to them. In C++ we don't back
out of a class instantiation.
Does that imply that c++/62085 should be closed? The compilers I have
here aren't all in agreement: EDG rejects the testcase like GCC but
recent clangs don't, likewise SolarisStudio.