From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 92174 invoked by alias); 25 Nov 2018 16:54:45 -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 92155 invoked by uid 89); 25 Nov 2018 16:54:45 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-2.8 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_NONE,SPF_HELO_PASS autolearn=ham version=3.3.2 spammy=ranged, involve, ugly, Hx-languages-length:940 X-HELO: gateway31.websitewelcome.com Received: from gateway31.websitewelcome.com (HELO gateway31.websitewelcome.com) (192.185.143.43) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Sun, 25 Nov 2018 16:54:43 +0000 Received: from cm16.websitewelcome.com (cm16.websitewelcome.com [100.42.49.19]) by gateway31.websitewelcome.com (Postfix) with ESMTP id 44B2510F41F for ; Sun, 25 Nov 2018 10:54:42 -0600 (CST) Received: from box5379.bluehost.com ([162.241.216.53]) by cmsmtp with SMTP id QxgAg3FcKaSeyQxgAgGLyZ; Sun, 25 Nov 2018 10:54:42 -0600 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=tromey.com; s=default; h=Message-Id:Date:Subject:To:From:Sender:Reply-To:Cc:MIME-Version :Content-Type:Content-Transfer-Encoding:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: In-Reply-To:References:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=nRfS9lFaLd7fgWmadqBjj9CqzgN0VZEXvfVofwJ1jcM=; b=dpEEwpuyVIRGSJAup/XXBhCs32 9FaWBR4V3jzmJET20KbnJ4j6ujgdLifGJ+ApaOVRRNb2kmJpkgG73lK4umRCJjn/TwGI5Uqu9ZHU3 Cia37U5Mjqq2TLUmqofi/Qpor; Received: from 97-122-190-66.hlrn.qwest.net ([97.122.190.66]:51592 helo=bapiya.Home) by box5379.bluehost.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.91) (envelope-from ) id 1gQxgA-0013GF-22 for gdb-patches@sourceware.org; Sun, 25 Nov 2018 10:54:42 -0600 From: Tom Tromey To: gdb-patches@sourceware.org Subject: [PATCH 00/12] Remove some ALL_* iteration macros Date: Sun, 25 Nov 2018 16:54:00 -0000 Message-Id: <20181125165439.13773-1-tom@tromey.com> X-SW-Source: 2018-11/txt/msg00400.txt.bz2 This series removes various ALL_* iteration macros, in favor of C++ iterators, range adapters, and ranged for loops. I've been wanting this for a while, because it helps a little bit with various experiments of mine that involve changing objfile lifetime management; Pedro's thread iterator patch prompted me to finally do this. The main downside of removing these macros is that it involves some reindentation; and expanding some macros to two nested loops means a couple somewhat ugly reformattings. On the plus side, though, this tightens the scope of iteration variables, which is good. And, it removes some hairy code, particularly the ALL_OBJSECTIONS patch. There are still a few more such macros that could be converted. And, I think inf_threads_iterator could be converted to use next_iterator. I can do some of this if there's interest. Regression tested by the buildbot. Tom