220 14117 <CANPtknxEuDw=n4NoJiYKDH74kBbh=O_dvLgkGHJ-iS6b_eT+Cg@mail.gmail.com> article
Path: news.gmane.org!not-for-mail
From: Peter Koch Larsen <peter.koch.larsen@gmail.com>
Newsgroups: gmane.comp.lang.c++.isocpp.proposals
Subject: Re: #pragma once
Date: Wed, 22 Oct 2014 12:39:15 +0200
Lines: 29
Approved: news@gmane.org
Message-ID: <CANPtknxEuDw=n4NoJiYKDH74kBbh=O_dvLgkGHJ-iS6b_eT+Cg@mail.gmail.com>
References: <3d0ab5b0-73d9-434a-9ae4-cd47d8275590@isocpp.org>
	<202c5550-8669-4b45-aa39-9a8d26c37015@isocpp.org>
	<93885a74-f1c7-4c85-9309-7bd878f08670@isocpp.org>
	<11313423.lvzWu67DM3@tjmaciei-mobl4>
Reply-To: std-proposals@isocpp.org
NNTP-Posting-Host: plane.gmane.org
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8
X-Trace: ger.gmane.org 1413974371 20142 80.91.229.3 (22 Oct 2014 10:39:31 GMT)
X-Complaints-To: usenet@ger.gmane.org
NNTP-Posting-Date: Wed, 22 Oct 2014 10:39:31 +0000 (UTC)
To: std-proposals@isocpp.org
Original-X-From: std-proposals+bncBDRIBXXKZQERBVEST2RAKGQEJDVL3PI@isocpp.org Wed Oct 22 12:39:20 2014
Return-path: <std-proposals+bncBDRIBXXKZQERBVEST2RAKGQEJDVL3PI@isocpp.org>
Envelope-to: gclcip-std-proposals@m.gmane.org
Original-Received: from mail-lb0-f199.google.com ([209.85.217.199])
	by plane.gmane.org with esmtp (Exim 4.69)
	(envelope-from <std-proposals+bncBDRIBXXKZQERBVEST2RAKGQEJDVL3PI@isocpp.org>)
	id 1XgtK2-0005yU-AI
	for gclcip-std-proposals@m.gmane.org; Wed, 22 Oct 2014 12:39:18 +0200
Original-Received: by mail-lb0-f199.google.com with SMTP id w7sf1831699lbi.10
        for <gclcip-std-proposals@m.gmane.org>; Wed, 22 Oct 2014 03:39:18 -0700 (PDT)
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=1e100.net; s=20130820;
        h=x-gm-message-state:mime-version:in-reply-to:references:date
         :message-id:subject:from:to:x-original-sender
         :x-original-authentication-results:reply-to:precedence:mailing-list
         :list-id:list-post:list-help:list-archive:list-subscribe
         :list-unsubscribe:content-type;
        bh=kP8joELbTBeLwA6QMuRunQy/vCaGYER9Yo6bzlMBnis=;
        b=iQxX0dPMJnlfg6aMc+DDgZMNxzgod9NkgXeqnfBreEZ4CCdm3g+ujdM570k/J75j2C
         mBSTCjsf8667sJY1MJJ6DghZhVYyUxAkwGcjU0usAht65aNFmnlhM0lYpacipTvPWNQe
         HedRM3gVzp42yf/jE/3UbGhHUerdK2gSIuiCgsC/U7tB9Jzs9YT8UqX2hr9P2bITS12z
         4V6WFIt09ZoQxbEtAEs9blvM+BzmXvslXw8FanI4QuA4a+lW+PUstDBhcYv6T1CbghDw
         HP2KMpyED0/kWzko89zxXtO4epBdvnSnPoi3/fsNDrgCLMG1EjyW8QIkR6cQoPxI8P7G
         bugg==
X-Gm-Message-State: ALoCoQmmYYKmeojLr2aLh232eDWJLUeiYWWkM+yq3zISaDaEpknrO8o2uEgbKMftKsAnBd1ne3hX
X-Received: by 10.180.75.83 with SMTP id a19mr4712671wiw.2.1413974358024;
        Wed, 22 Oct 2014 03:39:18 -0700 (PDT)
X-BeenThere: std-proposals@isocpp.org
Original-Received: by 10.152.10.2 with SMTP id e2ls158610lab.88.gmail; Wed, 22 Oct 2014
 03:39:15 -0700 (PDT)
X-Received: by 10.112.198.73 with SMTP id ja9mr40246385lbc.19.1413974355824;
        Wed, 22 Oct 2014 03:39:15 -0700 (PDT)
Original-Received: from mail-la0-x229.google.com (mail-la0-x229.google.com. [2a00:1450:4010:c03::229])
        by mx.google.com with ESMTPS id k1si22747989lam.96.2014.10.22.03.39.15
        for <std-proposals@isocpp.org>
        (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128);
        Wed, 22 Oct 2014 03:39:15 -0700 (PDT)
Received-SPF: pass (google.com: domain of peter.koch.larsen@gmail.com designates 2a00:1450:4010:c03::229 as permitted sender) client-ip=2a00:1450:4010:c03::229;
Original-Received: by mail-la0-f41.google.com with SMTP id pn19so2676601lab.0
        for <std-proposals@isocpp.org>; Wed, 22 Oct 2014 03:39:15 -0700 (PDT)
X-Received: by 10.112.125.106 with SMTP id mp10mr41513409lbb.50.1413974355358;
 Wed, 22 Oct 2014 03:39:15 -0700 (PDT)
Original-Received: by 10.152.162.104 with HTTP; Wed, 22 Oct 2014 03:39:15 -0700 (PDT)
In-Reply-To: <11313423.lvzWu67DM3@tjmaciei-mobl4>
X-Original-Sender: peter.koch.larsen@gmail.com
X-Original-Authentication-Results: mx.google.com;       spf=pass (google.com:
 domain of peter.koch.larsen@gmail.com designates 2a00:1450:4010:c03::229 as
 permitted sender) smtp.mail=peter.koch.larsen@gmail.com;       dkim=pass
 header.i=@gmail.com;       dmarc=pass (p=NONE dis=NONE) header.from=gmail.com
Precedence: list
Mailing-list: list std-proposals@isocpp.org; contact std-proposals+owners@isocpp.org
List-ID: <std-proposals.isocpp.org>
X-Google-Group-Id: 399137483710
List-Post: <http://groups.google.com/a/isocpp.org/group/std-proposals/post>, <mailto:std-proposals@isocpp.org>
List-Help: <http://support.google.com/a/isocpp.org/bin/topic.py?topic=25838>, <mailto:std-proposals+help@isocpp.org>
List-Archive: <http://groups.google.com/a/isocpp.org/group/std-proposals/>
List-Subscribe: <http://groups.google.com/a/isocpp.org/group/std-proposals/subscribe>,
 <mailto:std-proposals+subscribe@isocpp.org>
List-Unsubscribe: <mailto:googlegroups-manage+399137483710+unsubscribe@googlegroups.com>,
 <http://groups.google.com/a/isocpp.org/group/std-proposals/subscribe>
Xref: news.gmane.org gmane.comp.lang.c++.isocpp.proposals:14117
Archived-At: <http://permalink.gmane.org/gmane.comp.lang.c++.isocpp.proposals/14117>

On 10/22/14, Thiago Macieira <thiago@macieira.org> wrote:
> On Tuesday 21 October 2014 19:01:36 Myriachan wrote:
>> Sure, but that's years off if ever, and there are billions of lines of
>> code
>> in projects using #pragma once now.
> So why do we need to change anything? If that code is already working, it's
> working. If it's not working, then it won't magically begin working tomorrow
> -- at best, it would become valid from next year on and projects wishing
> compatibility would then begin using it in 2016 or 2017.
> They may as well simply use include guards if they need compatibility.

I agree with Thiago. Even if both my compilers support the once pragma
I stick to include guards. They work if you provide a meaningful name
(I include my initials and the date of construction so something like
.... _PKL_2014_10_22). I believe it would save me sixty seconds to
write #pragma instead.
If include guards make your compilation slow, you should complain to
your vendor.

/Peter

-- 

--- 
You received this message because you are subscribed to the Google Groups "ISO C++ Standard - Future Proposals" group.
To unsubscribe from this group and stop receiving emails from it, send an email to std-proposals+unsubscribe@isocpp.org.
To post to this group, send email to std-proposals@isocpp.org.
Visit this group at http://groups.google.com/a/isocpp.org/group/std-proposals/.

.
