* typeck.c (finish_class_member_access_expr): Avoid stripping
SCOPE_REF to dependent base.
From-SVN: r239136
+2016-08-04 Jason Merrill <jason@redhat.com>
+
+ PR c++/72796
+ * typeck.c (finish_class_member_access_expr): Avoid stripping
+ SCOPE_REF to dependent base.
+
2016-08-04 Thomas Schwinge <thomas@codesourcery.com>
* parser.c (cp_ensure_no_oacc_routine): Improve diagnostics.
{
dependent:
return build_min_nt_loc (UNKNOWN_LOCATION, COMPONENT_REF,
- orig_object, name, NULL_TREE);
+ orig_object, orig_name, NULL_TREE);
}
object = build_non_dependent_expr (object);
}
--- /dev/null
+// PR c++/72796
+// { dg-do compile { target c++11 } }
+
+struct a;
+template <int> struct b { typedef a c; };
+struct d {
+ void e(int);
+};
+struct a : d {
+ void e(int) = delete;
+};
+template <int f> struct g : b<f>::c {
+ g(int) { this->d::e(0); }
+};
+struct h : g<0> {
+ using i = g;
+ h() : i(0) {}
+};