[prev in list] [next in list] [prev in thread] [next in thread] 

List:       cfe-dev
Subject:    Re: [cfe-dev] [PROPOSAL] Reintroduce guards for Intel intrinsic headers
From:       David Blaikie <dblaikie () gmail ! com>
Date:       2015-07-30 18:30:09
Message-ID: CAENS6Et_8fuZg=-o_XCYoHP0RaZrQhd=bGmcP6uj3YQXL3zXZA () mail ! gmail ! com
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


On Thu, Jul 30, 2015 at 11:04 AM, Reid Kleckner <rnk@google.com> wrote:

> On Thu, Jul 30, 2015 at 10:33 AM, Eric Christopher <echristo@gmail.com>
> wrote:
>>
>> What kind of file is this? Keep in mind that things in the global
>> namespace prefixed with an underscore is a reserved name for implementers
>> as well. That would make this code not standards compliant as well.
>>
>
> The actual C++ rules are that any name with double underscores is
> reserved, and names beginning with an underscore followed by a capital
> letter. So, the Intel intrinsics are *not* in the implementer's namespace,
> but that was probably a mistake.
>

There's a second clause in 17.6.4.3.2\1:

"Each name that begins with an underscore is reserved to the implementation
for use as a name in the global namespace" (the other names you mentioned
are reserved for any use - so they can be used for macros, etc too - these
one's cannot)


>
> I'm sympathetic to users who are probably implementing a compatibility
> layer here and don't want to write their own intrinsic wrappers, but I
> think the right tradeoff is probably to fix the code.
>
> _______________________________________________
> cfe-dev mailing list
> cfe-dev@cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev
>
>

[Attachment #5 (text/html)]

<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Jul 30, 2015 \
at 11:04 AM, Reid Kleckner <span dir="ltr">&lt;<a href="mailto:rnk@google.com" \
target="_blank">rnk@google.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" \
style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div \
class="gmail_extra"><div class="gmail_quote"><span class="">On Thu, Jul 30, 2015 at 10:33 AM, \
Eric Christopher <span dir="ltr">&lt;<a href="mailto:echristo@gmail.com" \
target="_blank">echristo@gmail.com</a>&gt;</span> wrote:<blockquote class="gmail_quote" \
style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div \
class="gmail_quote"><div>What kind of file is this? Keep in mind that things in the global \
namespace prefixed with an underscore is a reserved name for implementers as well. That would \
make this code not standards compliant as \
well.</div></div></div></blockquote><div><br></div></span><div>The actual C++ rules are that \
any name with double underscores is reserved, and names beginning with an underscore followed \
by a capital letter. So, the Intel intrinsics are *not* in the implementer&#39;s namespace, but \
that was probably a mistake.</div></div></div></div></blockquote><div><br>There&#39;s a second \
clause in 17.6.4.3.2\1:<br><br>&quot;Each name that begins with an underscore is reserved to \
the implementation for use as a name in the global namespace&quot; (the other names you \
mentioned are reserved for any use - so they can be used for macros, etc too - these one&#39;s \
cannot)<br>  </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px \
#ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div \
class="gmail_quote"><div><br></div><div>I&#39;m sympathetic to users who are probably \
implementing a compatibility layer here and don&#39;t want to write their own intrinsic \
wrappers, but I think the right tradeoff is probably to fix the code.</div></div></div></div> \
<br>_______________________________________________<br> cfe-dev mailing list<br>
<a href="mailto:cfe-dev@cs.uiuc.edu">cfe-dev@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev" rel="noreferrer" \
target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev</a><br> \
<br></blockquote></div><br></div></div>



_______________________________________________
cfe-dev mailing list
cfe-dev@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic