<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Wed, Apr 23, 2014 at 1:45 AM, Jean-Daniel Dupas <span dir="ltr"><<a href="mailto:devlists@shadowlab.org" target="_blank">devlists@shadowlab.org</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word"><br><div><div>Le 22 avr. 2014 à 22:45, Nico Weber <<a href="mailto:thakis@chromium.org" target="_blank">thakis@chromium.org</a>> a écrit :</div>
<div class=""><br><blockquote type="cite"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Sat, Apr 19, 2014 at 4:05 PM, Alp Toker <span dir="ltr"><<a href="mailto:alp@nuanti.com" target="_blank">alp@nuanti.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Small update for the list..<br>
<br>
We discussed this at LLVM Europe 2014 and came to the conclusion that we might as well offer the feature behind an -f flag.<br>
<br>
This should satisfy user requests for C++11-style attributes in C11 without prejudicing any standards process. Thanks to the many detailed use-cases people sent in that have made me more comfortable picking this up again.<br>

</blockquote><div><br></div><div>Are these use-cases visible anywhere?</div><div> </div></div></div></div></blockquote><div><br></div></div>[[clang::fallthough]] ?</div></div></blockquote><div><br></div><div>We could support that in C by allowing GNU __attribute__s on statements, or by adding a __builtin_fallthrough() function or a __fallthrough keyword, or by recognizing /* Fall through. */ comments. (There's prior art for at least the latter two of these options.) Allowing C++ attributes in C is not the only way to provide this functionality; is it better than the alternatives?</div>
<div><br></div><div>It's not obvious to me that we want C++ attributes for the capability attributes: C++ attributes on function declarations appear *before* the parameter-declaration-clause, making them a worse choice for attributes that might name function parameters than GNU attributes. These attributes will be wrapped by a macro anyway, so an end user won't see the syntactic difference between the two approaches. And the C++ attributes in C extension, if we provide it, will be off by default. This seems like a hard sell. What's the upside?</div>
</div></div></div>