From -6448426605913967829
X-Google-Thread: f78e5,661f9f6c1b45f277
X-Google-NewGroupId: yes
X-Google-Attributes: gid7894ca11fe,domainid0,public,usenet
X-Google-Language: ENGLISH,ASCII-7-bit
Path: g2news1.google.com!news1.google.com!news2.google.com!npeer01.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!Xl.tags.giganews.com!border1.nntp.dca.giganews.com!nntp.giganews.com!local2.nntp.dca.giganews.com!news.giganews.com.POSTED!not-for-mail
NNTP-Posting-Date: Tue, 27 Apr 2010 17:30:02 -0500
Return-Path: <cppmods@ruralroute.cs.rpi.edu>
To: (Usenet)
From: Olaf Krzikalla <krzikalla@gmx.de>
Newsgroups: comp.std.c++
Subject: Re: Two thoughts about attributes in the FCD
Organization: albasani.net
Sender: cppmods@cs.rpi.edu
Approved: austern@google.com
Message-ID: <hr68k7$752$1@news.albasani.net>
References: <hq1aa6$nad$1@news.albasani.net>
Content-Type: text/plain; charset=ISO-8859-15; format=flowed
X-Original-Date: Tue, 27 Apr 2010 10:52:25 +0200
X-Submission-Address: std-c++@netlab.cs.rpi.edu<std-c%2B%2B@netlab.cs.rpi.edu>
Date: Tue, 27 Apr 2010 17:29:25 CST
Lines: 42
X-Usenet-Provider: http://www.giganews.com
X-Trace: sv3-sm4bLIJfy/xsdxwmxP4vvnn33CXs5W4zAaExi5otZ+n/ZVjUdmHf9iSFUOSGQL8s8iC8vyBBgRI5Xgy!kTJX6RWn2xVOP6kSA8v+TELM1Ed+Ls/dVxOIyEtSAKLuXklg9FizPrWf
X-Complaints-To: abuse@giganews.com
X-DMCA-Notifications: http://www.giganews.com/info/dmca.html
X-Abuse-and-DMCA-Info: Please be sure to forward a copy of ALL headers
X-Abuse-and-DMCA-Info: Otherwise we will be unable to process your complaint properly
X-Postfilter: 1.3.40
Xref: g2news1.google.com comp.std.c++:2471

Hi again,

and sorry for responding to my own posting. Nevertheless I hope someone else
is reading.

Olaf Krzikalla schrieb:

> 2. =A77.6.1.5 states, that attibute tokens not being specified behave
> implementation-defined. Shouldn't we restrict this in a way, that attibutes
> unknown to an particular implementation shall be ignored. Like: an
> implementation is not allowed to refuse compilation only because a
> syntactically correct attribute-token is unknown.
> Maybe someone can rephrase this to standard speak.
>
During a discussion about adding attributes to clang I noticed that section
7.6.1.5 as written IMHO opens a can of worms. If everybody is allowed to add
arbitrary attributes then we can't extend the set of predefined attributes
in the future without the danger of breaking standard-conform code. Thus I
would propose that the use of attributes in the global and std
attribute-namespace cause undefined behavior unless they are defined in the
standard. This keeps the freedom to standardize more attributes in the
future. For attributes in other namespaces the behavior is still
implementation defined. But as I wrote in my previous post, we should add
the sentence:

"Any attribute (not in the global and std attribute-namespace) that is not
recognized by the implementation is ignored."

(this was just taken from section 16.6 (pragmas)).


Best regards
Olaf Krzikalla

-- 
[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use
mailto:std-c++@netlab.cs.rpi.edu<std-c%2B%2B@netlab.cs.rpi.edu>
]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://www.comeaucomputing.com/csc/faq.html                      ]



