Skip to main content
Article thumbnail
Location of Repository

Revision: 2 General Attributes for C++

By Jens Maurer and Michael Wong


The idea is to be able to annotate some entities in C++ with additional information. Currently, there is no means to do that short of inventing a new keyword and augmenting the grammar accordingly, thereby reserving yet another name of the user's namespace. This proposal will survey existing industry practice for extending the C++ syntax, and presents a general means for such annotations, including its integration into the C++ grammar. Specific attributes are not introduced in this proposal. It does not obviate the ability to add or overload keywords where appropriate, but it does reduce such need and add an ability to extend the language. This proposal will allow many C++0x proposals to move forward. A draft form of t his proposal was presented in Oxford and received acceptance in EWG to proceed to wording stage. This proposal integrates suggestions and comments from the Oxford presentation, and email conversations post-Oxford. It addresses many of the controversial aspects from the Oxford presentation and includes comprehensive Standard wordings. Specifically, it adds: July 18, Revision 2: • HTML cleanup • allow empty attribute-lists • renamed "attribute-parameter-clause " to "attribute-argument-clause", "attributeparameter-list" to "attribute-argument-list", "attribute-parameter " to "attributeargument" • allow attribute on conversion-type-id's type-specifier-seq • Toronto: introduce attribute-specification (similar to 'extern "C " {}') • Toronto: integrate attributes into all keyword-based statements (except "break" and "continue"), plus "throw" • Toronto: allow attributes on using-directives • Toronto: add noreturn and final attributesMay 4, Revision 1: • Empty attribute lis

Topics: • Added Using
Year: 2013
OAI identifier: oai:CiteSeerX.psu:
Provided by: CiteSeerX
Download PDF:
Sorry, we are unable to provide the full text but you may find it at the following location(s):
  • (external link)
  • (external link)
  • Suggested articles

    To submit an update or takedown request for this paper, please submit an Update/Correction/Removal Request.