From: Eric Christopher Date: Wed, 2 Sep 2015 20:13:41 +0000 (+0000) Subject: Update comment for AdditionalMembers with a note to avoid using X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=06a1797e155e0f766b28c735d2df360ade71aea5;p=clang Update comment for AdditionalMembers with a note to avoid using additional data members in attributes as they'll leak and provide some guidance as to where they should be allocated if necessary. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@246701 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/clang/Basic/Attr.td b/include/clang/Basic/Attr.td index 8523ed92a7..58d82ae326 100644 --- a/include/clang/Basic/Attr.td +++ b/include/clang/Basic/Attr.td @@ -290,6 +290,8 @@ class Attr { // attribute to be applicable. If empty, no language options are required. list LangOpts = []; // Any additional text that should be included verbatim in the class. + // Note: Any additional data members will leak and should be constructed + // externally on the ASTContext. code AdditionalMembers = [{}]; // Any documentation that should be associated with the attribute. Since an // attribute may be documented under multiple categories, more than one