From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5710 invoked by alias); 10 Apr 2017 23:19:08 -0000 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 Received: (qmail 5695 invoked by uid 89); 10 Apr 2017 23:19:06 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-3.6 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_NONE,RCVD_IN_SORBS_SPAM,SPF_PASS autolearn=no version=3.3.2 spammy=Hx-languages-length:735 X-HELO: gproxy7-pub.mail.unifiedlayer.com Received: from gproxy7-pub.mail.unifiedlayer.com (HELO gproxy7-pub.mail.unifiedlayer.com) (70.40.196.235) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with SMTP; Mon, 10 Apr 2017 23:19:05 +0000 Received: (qmail 9715 invoked by uid 0); 10 Apr 2017 23:19:05 -0000 Received: from unknown (HELO cmgw2) (10.0.90.83) by gproxy7.mail.unifiedlayer.com with SMTP; 10 Apr 2017 23:19:05 -0000 Received: from box522.bluehost.com ([74.220.219.122]) by cmgw2 with id 6nK21v0032f2jeq01nK5Ql; Mon, 10 Apr 2017 17:19:05 -0600 X-Authority-Analysis: v=2.2 cv=LIwWeNe9 c=1 sm=1 tr=0 a=GsOEXm/OWkKvwdLVJsfwcA==:117 a=GsOEXm/OWkKvwdLVJsfwcA==:17 a=AzvcPWV-tVgA:10 a=I9hMa9ZD25jm2v9RplIA:9 Received: from 75-166-65-226.hlrn.qwest.net ([75.166.65.226]:54360 helo=bapiya) by box522.bluehost.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.87) (envelope-from ) id 1cxiaL-0007Ub-Om; Mon, 10 Apr 2017 17:19:01 -0600 From: Tom Tromey To: Simon Marchi Cc: Tom Tromey , gdb-patches@sourceware.org Subject: Re: [RFA 01/14] Introduce event_location_up References: <20170408201208.2672-1-tom@tromey.com> <20170408201208.2672-2-tom@tromey.com> Date: Mon, 10 Apr 2017 23:19:00 -0000 In-Reply-To: (Simon Marchi's message of "Sun, 09 Apr 2017 21:33:44 -0400") Message-ID: <87pogjzw9o.fsf@tromey.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-BWhitelist: no X-Exim-ID: 1cxiaL-0007Ub-Om X-Source-Sender: 75-166-65-226.hlrn.qwest.net (bapiya) [75.166.65.226]:54360 X-Source-Auth: tom+tromey.com X-Email-Count: 2 X-Source-Cap: ZWx5bnJvYmk7ZWx5bnJvYmk7Ym94NTIyLmJsdWVob3N0LmNvbQ== X-SW-Source: 2017-04/txt/msg00250.txt.bz2 >> - b->location = new_explicit_location (&explicit_loc); >> + b->location = new_explicit_location (&explicit_loc).release (); Simon> Since the breakpoint structure is new'ed and delete'd, you can also Simon> change breakpoint's location field to be an event_location_up, instead Simon> of doing a (bunch of) release. I think you could do the same with the Simon> location field in linespec_result as well, since that structure is Simon> only allocated statically (and therefore its defaults ctor/dtor are Simon> called). Rather than change this patch, I've added new patches to do these things. Once I started changing linespec_result, I realized it should be converted more fully. Tom