From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27560 invoked by alias); 15 Sep 2008 16:55:30 -0000 Received: (qmail 27549 invoked by uid 22791); 15 Sep 2008 16:55:29 -0000 X-Spam-Check-By: sourceware.org Received: from ey-out-1920.google.com (HELO ey-out-1920.google.com) (74.125.78.148) by sourceware.org (qpsmtpd/0.31) with ESMTP; Mon, 15 Sep 2008 16:54:54 +0000 Received: by ey-out-1920.google.com with SMTP id 4so959148eyg.24 for ; Mon, 15 Sep 2008 09:54:51 -0700 (PDT) Received: by 10.210.25.19 with SMTP id 19mr7042480eby.20.1221497691075; Mon, 15 Sep 2008 09:54:51 -0700 (PDT) Received: by 10.210.76.7 with HTTP; Mon, 15 Sep 2008 09:54:51 -0700 (PDT) Message-ID: <366c6f340809150954p5e560b0dm590aaa976dfbc00e@mail.gmail.com> Date: Mon, 15 Sep 2008 16:55:00 -0000 From: "Peng Yu" To: gdb@sourceware.org Subject: no symbol in current context problem MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2008-09/txt/msg00088.txt.bz2 Hi, I have the following program. When I step in to test's constructor, I would be able to print the variable three. It says (gdb) n 7 T three = 3; (gdb) n 8 std::cout << three << std::endl; (gdb) p three No symbol "three" in current context. I know that this is a bug has been reported before. But I'm wondering if it is already fixed in the newest version of gdb. Thanks, Peng #include template class test { public: test(const T &a) : _a(a) { T three = 3; std::cout << three << std::endl; } private: T _a; }; int main() { test p(10); }