From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id GjmtOsg4dGLChQQAWB0awg (envelope-from ) for ; Thu, 05 May 2022 16:51:20 -0400 Received: by simark.ca (Postfix, from userid 112) id E22141E058; Thu, 5 May 2022 16:51:20 -0400 (EDT) Authentication-Results: simark.ca; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.a=rsa-sha256 header.s=default header.b=KJmeYFEe; dkim-atps=neutral X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-4.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,NICE_REPLY_A,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 Received: from sourceware.org (server2.sourceware.org [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id 7C8C21E01D for ; Thu, 5 May 2022 16:51:20 -0400 (EDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 23C503857347 for ; Thu, 5 May 2022 20:51:20 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 23C503857347 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1651783880; bh=4J6Pfzb/u4hNeR5u1NBP7SGRzk9GOTeqfLPpWqD4iY0=; h=Date:Subject:To:References:In-Reply-To:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=KJmeYFEek78qPMzvfxn7lQobG5eRfhdgcfb4LaVrWXfvYh1qIj/0WgOYmSkY4kgPx a1FGmeAzix7m/yhbcpywsuupoaNMeYnB8nNkR60NcdZ3QO+9Bo7nAoyo88ZgGzI3Hp TqWab2LTk55Idez2iZ/pfByNhBbI1H/IhUOlr37A= Received: from us-smtp-delivery-74.mimecast.com (us-smtp-delivery-74.mimecast.com [170.10.129.74]) by sourceware.org (Postfix) with ESMTPS id B26653858D3C for ; Thu, 5 May 2022 20:51:01 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org B26653858D3C Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-361-LV_Ct1RTPayhrLWNfyHVmw-1; Thu, 05 May 2022 16:51:00 -0400 X-MC-Unique: LV_Ct1RTPayhrLWNfyHVmw-1 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.rdu2.redhat.com [10.11.54.7]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 0971A803D46; Thu, 5 May 2022 20:51:00 +0000 (UTC) Received: from [10.2.17.61] (unknown [10.2.17.61]) by smtp.corp.redhat.com (Postfix) with ESMTPS id BC750151F5DE; Thu, 5 May 2022 20:50:59 +0000 (UTC) Message-ID: <4ff65295-097a-1257-c2ec-8c2574d16714@redhat.com> Date: Thu, 5 May 2022 13:50:59 -0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.8.0 Subject: Re: [PATCH 3/3] Fix "b f(std::string)" when current language is C To: Pedro Alves , gdb-patches@sourceware.org References: <20220505185020.3648774-1-pedro@palves.net> <20220505185020.3648774-4-pedro@palves.net> In-Reply-To: <20220505185020.3648774-4-pedro@palves.net> X-Scanned-By: MIMEDefang 2.85 on 10.11.54.7 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Language: en-US Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Keith Seitz via Gdb-patches Reply-To: Keith Seitz Errors-To: gdb-patches-bounces+public-inbox=simark.ca@sourceware.org Sender: "Gdb-patches" On 5/5/22 11:50, Pedro Alves wrote: > Fix this by making cp-support.c:inspect_type print the expanded > typedef type using the language of the symbol whose type we're > expanding the typedefs for -- in the example in question, the > "std::string" typedef symbol, which is a C++ symbol. > > Use type_print_raw_options as it seems to me that in this scenario we > always want raw types, to match the real symbol names. > > Adjust the gdb.cp/break-std-string.exp testcase to try setting a > breakpoint at "f(std::string)" in both C and C++. If I may be so bold, this LGTM. Keith