[PATCH] D97362: [clang][parser] Allow attributes in explicit template instantiations

Aaron Ballman via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Feb 25 05:36:18 PST 2021


aaron.ballman added a reviewer: rsmith.
aaron.ballman added a comment.

I don't think that's dead code, but I do think it's unclear code that should be fixed.

The behavior for double square bracket attributes in C++ is correct in Clang and incorrect in GCC, according to: http://eel.is/c++draft/temp.explicit#3.sentence-3. Adding a comment to that effect would be reasonable so there's not confusion again in the future.

Based on empirical testing, I think the GNU-style attribute should continue to be accepted in that position as it has effect in GCC.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D97362/new/

https://reviews.llvm.org/D97362



More information about the cfe-commits mailing list