
9 Nov
2011
9 Nov
'11
9:01 p.m.
2011/11/9 Oliver Kowalke <oliver.kowalke@gmx.de>
My solution is: remove icontext, use non-templated context_base directly. So it looks like:
<snip>
OK - I got it and I'll take it into account. thx!
In the sample code I gave I forgot one important thing -- init order. Please apply trick like this: template< typename Fn, typename Allocator > class context_object : compressed_pair<Fn, Allocator>, public context_base {...}; By first private inheriting, the order is guaranteed and it's safe to pass allocator to context_base(...).