This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

g++-4.3 alignas(const-expr) fails; workaround?


With g++-4.3-20070323, alignas(2) fails compile with
message indicating it needs a type instead of
constant expression.  Is there any workaround.
For example, could I:

 typedef unsigned char work_around[const-expr];
 unsigned char alignas(work_around) actual_var[const-expr]

?
TIA.

-Larry


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]