From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8800 invoked by alias); 9 Nov 2009 15:40:57 -0000 Received: (qmail 8721 invoked by uid 48); 9 Nov 2009 15:40:56 -0000 Date: Mon, 09 Nov 2009 15:40:00 -0000 From: "egor at sun dot com" To: gdb-prs@sourceware.org Message-ID: <20091109154055.10929.egor@sun.com> Reply-To: sourceware-bugzilla@sourceware.org Subject: [Bug c++/10929] New: Unable to set a function breakpoint in unnamed namespace X-Bugzilla-Reason: CC Mailing-List: contact gdb-prs-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-prs-owner@sourceware.org X-SW-Source: 2009-q4/txt/msg00221.txt.bz2 try this code: namespace { int foo() { int a = 5; } }; int main() { int a = foo(); return a; } in gdb 7.0: (gdb) b main Breakpoint 1 at 0x8050d48: file welcome.cc, line 8. (gdb) r Starting program: /home/eu155513/NetBeansProjects/Welcome_74/dist/Debug/GNU-Solaris-x86/welcome_74 [Thread debugging using libthread_db enabled] [New Thread 1 (LWP 1)] [Switching to Thread 1 (LWP 1)] Breakpoint 1, main () at welcome.cc:8 8 int a = foo(); (gdb) b foo Function "foo" not defined. Make breakpoint pending on future shared library load? (y or [n]) in gdb 6.6: (gdb) b main Breakpoint 1 at 0x8050d48: file welcome.cc, line 8. (gdb) r Starting program: /home/eu155513/NetBeansProjects/Welcome_74/dist/Debug/GNU-Solaris-x86/welcome_74 warning: Temporarily disabling breakpoints for unloaded shared library "/usr/lib/ld.so.1" Breakpoint 1, main () at welcome.cc:8 8 int a = foo(); (gdb) b foo Breakpoint 2 at 0x8050d22: file welcome.cc, line 3. (gdb) -- Summary: Unable to set a function breakpoint in unnamed namespace Product: gdb Version: 7.0 Status: UNCONFIRMED Severity: normal Priority: P2 Component: c++ AssignedTo: unassigned at sourceware dot org ReportedBy: egor at sun dot com CC: gdb-prs at sourceware dot org http://sourceware.org/bugzilla/show_bug.cgi?id=10929 ------- You are receiving this mail because: ------- You are on the CC list for the bug, or are watching someone who is.