Boost logo

Boost :

From: Douglas Gregor (gregod_at_[hidden])
Date: 2001-08-28 14:17:27


On Tuesday 28 August 2001 01:52, you wrote:
[snip]
> >
> > This gives us a character array large enough to hold a T, and at the
> > alignment of T that is equivalent to the alignment of alignment_type.
> >
> > I can upload the code to do this if anyone is interested. The rest of the
> > variant type is unfinished, but this part seems to work well enough :)
>
> This sounds exactly what I need.
> Please upload the file or send it directly to me in an email attachment.
> Thanks!
>
> Fernando Cacciola
> Sierra s.r.l.
> fcacciola_at_[hidden]
> www.gosierra.com

It is in the files section at:
http://groups.yahoo.com/group/boost/files/stack_aligned_variant.hpp

You will likely be most interested in the "type_with_alignment" metafunction.

\begin{disclaimer_shield}
I have not carefully considered whether or not this code is legal C++. I
believe it to be legal, but I won't say it is until I've had a good few hours
of pouring over the standard to think about it more.
\end{disclaimer shield}

        Doug


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