<div dir="ltr"><div>> One potential issue is the possible existence of compilers that claim to support C++14, but are not fully compliant.<br></div><div><br></div><div>At least from the compilers listed [here](<a href="https://en.cppreference.com/w/cpp/compiler_support#cpp14">https://en.cppreference.com/w/cpp/compiler_support#cpp14</a>), all of them support the [[deprecated]] attribute.</div><div><br></div>> The only downside I'm aware of is<br>>   <a href="https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96117" rel="noreferrer" target="_blank">https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96117</a><div><br></div><div>Thanks for pointing that out Stephen. I couldn't find any instance where LLVM_ATTRIBUTE_DEPRECATED is used in combination with another attribute and gcc's deficiency doesn't manifest itself on functions (<a href="https://godbolt.org/z/er9Pax">https://godbolt.org/z/er9Pax</a>), so hopefully this is only a theoretical problem.</div><div><br></div><div>If there are no objections, I will go ahead with D94219 and wait two weeks to see if any problems pop up before changing the call sites.</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Jan 8, 2021 at 11:12 PM Stephen Kelly via llvm-dev <<a href="mailto:llvm-dev@lists.llvm.org">llvm-dev@lists.llvm.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On 08/01/2021 11:05, Christian Sigg via llvm-dev wrote:<br>
> The LLVM_ATTRIBUTE_DEPRECATED macro marks e.g. function declarations as <br>
> deprecated.<br>
> <br>
> C++14 introduced the [[deprecated]] attribute, and I would like to <br>
> switch LLVM's code to that because it's portable, easier to read, and <br>
> can be applied to inline functions as well.<br>
> <br>
> <a href="https://reviews.llvm.org/D94219" rel="noreferrer" target="_blank">https://reviews.llvm.org/D94219</a> is the first step towards that by <br>
> changing the LLVM_ATTRIBUTE_DEPRECATED implementation from <br>
> __attribute__/__declspec to [[deprecated]]. In a follow-up change, I <br>
> will switch the call sites to use [[deprecated]] directly and finally <br>
> remove the macro.<br>
> <br>
> Are there any downsides that I'm missing or any objections?<br>
<br>
The only downside I'm aware of is<br>
<br>
  <a href="https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96117" rel="noreferrer" target="_blank">https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96117</a><br>
<br>
I don't think the llvm build uses export macros, but are there any <br>
places where different attribute types are used?<br>
<br>
Thanks,<br>
<br>
Stephen.<br>
<br>
_______________________________________________<br>
LLVM Developers mailing list<br>
<a href="mailto:llvm-dev@lists.llvm.org" target="_blank">llvm-dev@lists.llvm.org</a><br>
<a href="https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev" rel="noreferrer" target="_blank">https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev</a><br>
</blockquote></div>