From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10040 invoked by alias); 10 Dec 2012 16:29:14 -0000 Received: (qmail 9970 invoked by uid 48); 10 Dec 2012 16:28:57 -0000 From: "dblaikie at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug debug/55641] New: debug info for the type of a reference declared with a typedef has spurious 'const' Date: Mon, 10 Dec 2012 16:29:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: debug X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: dblaikie at gmail dot com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: Message-ID: X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 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: 2012-12/txt/msg01005.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55641 Bug #: 55641 Summary: debug info for the type of a reference declared with a typedef has spurious 'const' Classification: Unclassified Product: gcc Version: unknown Status: UNCONFIRMED Severity: normal Priority: P3 Component: debug AssignedTo: unassigned@gcc.gnu.org ReportedBy: dblaikie@gmail.com Example code: typedef int &foo; int x; foo f(x); under gdb run "whatis f" and the answer is "const foo" when it should be plain "foo" (if you skip the typedef the answer is correctly "int&" not "int& const" or any similarly strange mismatch) Found in the GDB 7.5 test suite ( gdb.python/lib-types.exp ) - this is positively tested for, but so far as I can imagine that's by accident, not intent.