[cfe-dev] C++11 attributes attached to a statement

Michael Haidl haidl at pacxx.org
Sun Dec 14 01:11:06 PST 2014


Aaron is right. FallThrough is a better example attribute.

Michael

Aaron Ballman <aaron at aaronballman.com> schrieb:

>On Sat, Dec 13, 2014 at 9:00 AM, Michael Haidl <haidl at pacxx.org> wrote:
>> Hi!
>>
>> I the easiest way for you to add a C++11 attribute to a statement is to
>> follow the LoopHint attribute through the code.
>>
>> The attribute is handled in ./lib/Sema/SemaStmtAttr.cpp
>
>LoopHint isn't quite the one I would model after since that's a
>pragma. FallThrough, however, is a good statement attribute to model
>after. And the semantic handling for statement attributes is in
>SemaStmtAttr.cpp, as Michael points out.
>
>~Aaron




More information about the cfe-dev mailing list