From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 31906 invoked by alias); 18 Nov 2009 05:43:21 -0000 Received: (qmail 31802 invoked by uid 48); 18 Nov 2009 05:43:04 -0000 Date: Wed, 18 Nov 2009 05:43:00 -0000 Message-ID: <20091118054304.31801.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug c++/950] Template problem: decay of pointer-to-member-of-derived to p-o-m-o-base In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "jason at gcc dot gnu dot org" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2009-11/txt/msg01446.txt.bz2 ------- Comment #13 from jason at gcc dot gnu dot org 2009-11-18 05:43 ------- 5.3.1 [expr.unary.op] paragraph 3: ...If the member is a non-static member of class C of type T, the type of the result is “pointer to member of class C of type T.” [ Example: struct A { int i; }; struct B : A { }; // has type int A::* ... &B::i ... — end example ] So, the type of &D::a is the same as the type of &B::a, and this is not a bug. -- jason at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution| |INVALID http://gcc.gnu.org/bugzilla/show_bug.cgi?id=950