On Wed, 26 Sep 2018 at 12:04, Hans Dembinski
On 26. Sep 2018, at 10:41, degski
wrote: On Wed, 26 Sep 2018 at 11:17, Hans Dembinski via Boost < boost@lists.boost.org> wrote:
Ok, no calling of destructors.
You should, iff you use placement new to construct an object in uninitialized memory, that's what Steven started with saying.
Right, I got this now. When you have a union type with non-trivial bounded types you are also supposed to call the destructor manually when you switch types, and there it makes sense. My mistake was to believe that calling the destructor manually is like calling any other function. Now it is clear.
No no, something Steven said just before his other remark, "destructors are special functions". Always pay attention to what Steven says, in a very literal sense, except the "Ad Majorem Gloriam Dei", ignore that. degski -- *“If something cannot go on forever, it will stop" - Herbert Stein*