From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29463 invoked by alias); 18 Sep 2012 19:16:40 -0000 Received: (qmail 29436 invoked by uid 22791); 18 Sep 2012 19:16:36 -0000 X-SWARE-Spam-Status: No, hits=-6.8 required=5.0 tests=AWL,BAYES_00,KHOP_RCVD_UNTRUST,RCVD_IN_DNSWL_HI,RCVD_IN_HOSTKARMA_W,RP_MATCHES_RCVD,SPF_HELO_PASS X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 18 Sep 2012 19:16:05 +0000 Received: from int-mx01.intmail.prod.int.phx2.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id q8IJG4kh025195 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Tue, 18 Sep 2012 15:16:04 -0400 Received: from barimba (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by int-mx01.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id q8IJG2vU015563 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NO); Tue, 18 Sep 2012 15:16:03 -0400 From: Tom Tromey To: Joel Brobecker Cc: gdb-patches@sourceware.org Subject: Re: [RFA] wrong language used when re-setting breakpoint References: <1347928803-15526-1-git-send-email-brobecker@adacore.com> <87k3vrxu2o.fsf@fleche.redhat.com> <20120918150542.GD3276@adacore.com> <878vc7xlxu.fsf@fleche.redhat.com> <20120918181839.GF3276@adacore.com> <87sjafw5ky.fsf@fleche.redhat.com> <20120918185535.GG3276@adacore.com> Date: Tue, 18 Sep 2012 19:16:00 -0000 In-Reply-To: <20120918185535.GG3276@adacore.com> (Joel Brobecker's message of "Tue, 18 Sep 2012 11:55:35 -0700") Message-ID: <87obl3w39p.fsf@fleche.redhat.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2012-09/txt/msg00374.txt.bz2 >>>>> "Joel" == Joel Brobecker writes: Joel> In the meantime, I have found the source of the language switch, and Joel> I know why you're not seeing it. There is a function called Joel> ada-lang.c:add_symbols_from_enclosing_procs which is empty in the Joel> official tree, but starts with the following code in our tree: Joel> frame = deprecated_safe_get_selected_frame (); Ah, I see. Joel> Perhaps we (AdaCore) should also do something to avoid the Joel> language-switch side-effect, but I am hesitant to do anything, Joel> because I'm thinking I might affect something else later on. I don't really know the Ada code well enough to comment. The current code you have sounds tricky, maybe too tricky. I wouldn't mind pushing linespec to be more fully parameterized. However, this is maybe non-trivial if it calls out into other parts of gdb. I do see that linespec itself takes care to restore current_language in a similar scenario; see get_search_block. But I wonder whether this can have the effect of accidentally dropping a language switch. Tom