diff options
author | Paolo Carlini <paolo.carlini@oracle.com> | 2012-09-05 10:14:37 +0000 |
---|---|---|
committer | Paolo Carlini <paolo@gcc.gnu.org> | 2012-09-05 10:14:37 +0000 |
commit | 22854930b945f09487ca7947326d741ff6328377 (patch) | |
tree | 2f95f089c2fa4d79dab5770ad9a8b5fa4956d54b /gcc/cp/tree.c | |
parent | b588ae3074e258f5c736034c212e7499a565746f (diff) | |
download | gcc-22854930b945f09487ca7947326d741ff6328377.zip gcc-22854930b945f09487ca7947326d741ff6328377.tar.gz gcc-22854930b945f09487ca7947326d741ff6328377.tar.bz2 |
re PR c++/54191 ([C++11] SFINAE does not handle conversion to inaccessible base)
/cp
2012-09-05 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/54191
* search.c (lookup_base): Add tsubst_flags_t parameter.
(adjust_result_of_qualified_name_lookup, check_final_overrider):
Adjust.
* name-lookup.c (do_class_using_decl): Adjust.
* typeck2.c (binfo_or_else, build_scoped_ref, build_m_component_ref):
Likewise.
* cvt.c (cp_convert_to_pointer, convert_to_pointer_force,
build_up_reference): Likewise.
* rtti.c (build_dynamic_cast_1): Likewise.
* tree.c (maybe_dummy_object): Likewise.
* call.c (build_conditional_expr_1, build_over_call): Likewise.
* cp-tree.h (UNIQUELY_DERIVED_FROM_P, PUBLICLY_UNIQUELY_DERIVED_P):
Remove.
(enum base_access_flags, ba_quiet): Remove.
(uniquely_derived_from_p, publicly_uniquely_derived_p): Declare.
* except.c (can_convert_eh): Adjust.
* decl.c (grokdeclarator): Likewise.
* typeck.c (comp_except_types, build_class_member_access_expr,
finish_class_member_access_expr, get_member_function_from_ptrfunc,
build_static_cast_1, get_delta_difference_1): Likewise.
* class.c (build_base_path, convert_to_base, build_vtbl_ref_1,
warn_about_ambiguous_bases): Likewise.
(uniquely_derived_from_p, publicly_uniquely_derived_p): Define.
/testsuite
2012-09-05 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/54191
* g++.dg/cpp0x/sfinae39.C: New.
From-SVN: r190969
Diffstat (limited to 'gcc/cp/tree.c')
-rw-r--r-- | gcc/cp/tree.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/cp/tree.c b/gcc/cp/tree.c index 7cc2457..ce1af73 100644 --- a/gcc/cp/tree.c +++ b/gcc/cp/tree.c @@ -2772,7 +2772,8 @@ maybe_dummy_object (tree type, tree* binfop) tree current = current_nonlambda_class_type (); if (current - && (binfo = lookup_base (current, type, ba_any, NULL))) + && (binfo = lookup_base (current, type, ba_any, NULL, + tf_warning_or_error))) context = current; else { |