Correct usage of alignas in std::ostringstream wrapper
This seems overcomplicated to me. Lazy-loading something doesn't require placement-new trickery and mucking around with alignments. Why not simply store a pointer to the stream which is only initialised when the user performs some kind of operation? This is the general way to do lazy-loading:

struct error_stream
{
private:
    std::unique_ptr&lt;std::ostringstream&gt; stream;

    // This should use make_unique, which you can find 
    // or write yourself without too much hassle.
    void construct()
    {
        stream = std::unique_ptr&lt;std::ostringstream&gt;(
            new std::ostringstream);
    }

public:

    template &lt;typename T&gt;
    std::ostream&amp; operator&lt;&lt;(T&amp;&amp; arg)
    {
        if(!stream) {
            construct();
        }
        (*stream) &lt;&lt; std::forward&lt;T&gt;(arg);
        return *stream;
    }

    bool empty() const
    {
        return stream ? false : true;
    }

    std::string str() 
    {
        if(empty()) {
             construct();
        }
        return stream-&gt;str();
    }
};


This seems to have the semantics you want (including being non-copyable due to using a std::unique_ptr) with much less hassle. You don't have to worry about placement new or any alignment requirements, which is going to make the code a -lot- harder to maintain.

Edit: If you really what to avoid the heap, I suppose you can use placement new. You allocate the memory for the stream when you create an error_stream, so I'm curious as to what problem you're trying to solve exactly. That being said, what you want to align is the storage for the ostringstream.

char memory_[sizeof(std::stringstream)];


Hence I'd use:

struct holder
{
....
private:
    alignas(std::ostringstream) char memory_[sizeof(std::stringstream)];
    ...
};