[cfe-commits] C++0x Attributes Patch - INCOMPLETE

Sean Hunt rideau3 at gmail.com
Fri Sep 4 16:29:17 PDT 2009

Hey all,

After a near-disaster, I figured I should make sure any important work I
have unsaved is kept somewhere where It's not going to be lost to a
single hard drive crash. So I'm going to post my mostly-complete
attributes patch here - you guys can also review it this way (or, if
you're crazy enough, try it out).

Known bugs:
 - Attributes are not supported after the declarator-id in a declaration
 - Attributes anywhere in a declaration apply to the entire declaration
(e.g. int * [[noreturn]] foo (); is a noreturn function, even though it
should error out because [[noreturn]] is being applied to a pointer).
 - [[align(type)]] is not supported

 - Attributes are allowed in front of function definitions, like they
are on declarations. This is in contrast to the draft, but I believe the
committee will make this legal in the next draft
 - The [[final]] attribute has the behavior suggested by a core language
issue (no time to look it up, sorry), rather than the draft (it prevents
any class from deriving from it, rather than making all virtual
functions [[final]]).
 - No non-standard attributes are currently supported with C++0x syntax.
 - [[carries_dependency]] is ignored, and does not error out if applied
to the wrong type.
 - I probably broke several style rules.

Sean "coppro" Hunt
-------------- next part --------------
A non-text attachment was scrubbed...
Name: attributes.patch
Type: text/x-diff
Size: 75160 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20090904/061f36db/attachment.patch>

More information about the cfe-commits mailing list