Boost logo

Boost :

From: brianjparker_at_[hidden]
Date: 2001-10-28 07:59:42


--- In boost_at_y..., Beman Dawes <bdawes_at_a...> wrote:
> At 10:25 PM 10/25/01 -0400, Douglas Gregor wrote:
> >On Thursday 25 October 2001 05:36, you wrote:
> >> > The best solution, I think, given that the problem cannot be
> >> > completely solved in current ISO C++, would be a language
change that
> >> > added a standardised alignment_of() and #pragma align that
worked on
> >> > members of structures and in templated code.
> >>
> >> I haven't tought about the core issues involved.
> >
> >This is actually a relatively common extension. GCC, Microsoft,
and
> >EDG-based
> >compilers support alignof or __alignof__ (same semantics as
sizeof).
>
> It is one of the language extensions on the C++ committee's
Evolution
> Working Group list for possible standardization in the next
revision of the
> standard.

That's good news, but alignof will be quite useless without a
corresponding #pragma align.

In any case, having a boost library solution would still be useful,
both as an interim measure and to gauge the need for the language
extension.

(actually, something like the Microsoft declspec(align(N)) syntax
would probably be better than the #pragma I suggested above.)

,Brian Parker.

 


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk