This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/36625] bogus error on __attribute__((aligned(N))) in template code
- From: "sebor at roguewave dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 26 Jun 2008 20:46:59 -0000
- Subject: [Bug c++/36625] bogus error on __attribute__((aligned(N))) in template code
- References: <bug-36625-1186@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #3 from sebor at roguewave dot com 2008-06-26 20:46 -------
Oddly enough, doubling up on the parens around N works:
template <int N>
struct A { struct S { short f[3]; } __attribute__ ((aligned ((N)))); };
int main ()
{
A<123>::S s;
}
--
sebor at roguewave dot com changed:
What |Removed |Added
----------------------------------------------------------------------------
Summary|missing diagnostic on |bogus error on
|invalid |__attribute__((aligned(N)))
|__attribute__((aligned(N))) |in template code
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36625