This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [Patch] PR c++/26256


2010/11/15 Fabien Chêne <fabien.chene@gmail.com>:
[...]

Index: gcc/cp/typeck.c
===================================================================
--- gcc/cp/typeck.c	(revision 166743)
+++ gcc/cp/typeck.c	(working copy)
@@ -2340,6 +2340,11 @@ build_class_member_access_expr (tree obj
 	result = build2 (COMPOUND_EXPR, TREE_TYPE (result),
 			 object, result);
     }
+  else if (TREE_CODE (member) == USING_DECL)
+       result = build_class_member_access_expr (object,
+						USING_DECL_DECLS (member),
+						access_path, preserve_reference,
+						complain);

I guess it would be safer to also check !DECL_DEPENDENT_P (member), I
will update the patch.

-- 
Fabien


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]