http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56859
Bug #: 56859 Summary: alignas() fails in template Classification: Unclassified Product: gcc Version: 4.8.1 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ AssignedTo: unassig...@gcc.gnu.org ReportedBy: w...@leicester.ac.uk The alignas attribute fails when used with a template-dependent integer constant, as in template<typename T> struct alignas(2*sizeof(T)) foo { /* ... */ }; when gcc complains that "error: requested alignment is not an integer constant" (no problem with clang++ 3.2). In a non-templated context, this construct compiles fine.