PR c++/50365
* parser.c (cp_parser_late_return_type_opt): Check quals parameter
for clearing current_class_ptr, too.
From-SVN: r178883
+2011-09-15 Jason Merrill <jason@redhat.com>
+
+ PR c++/50365
+ * parser.c (cp_parser_late_return_type_opt): Check quals parameter
+ for clearing current_class_ptr, too.
+
2011-09-14 Diego Novillo <dnovillo@google.com>
* name-lookup.c (lookup_arg_dependent): Use conditional
type = cp_parser_trailing_type_id (parser);
- if (current_class_type)
+ if (quals >= 0)
current_class_ptr = current_class_ref = NULL_TREE;
return type;
2011-09-15 Jason Merrill <jason@redhat.com>
+ PR c++/50365
+ * g++.dg/cpp0x/trailing7.C: New.
+
PR c++/50361
* g++.dg/cpp0x/nullptr23.C: New.
--- /dev/null
+// PR c++/50365
+// { dg-options -std=c++0x }
+
+struct A { int i; };
+
+struct B {
+ B();
+ A* f();
+};
+
+B::B()
+{
+ int(f()->i);
+}