$include_dir="/home/hyper-archives/boost/include"; include("$include_dir/msg-header.inc") ?>
Subject: [boost] [boost::sprit::basic_hold_any] needs non template operator=
From: Alexey Tkachenko (iskaspb_at_[hidden])
Date: 2013-08-20 06:44:45
Hi,
I found that hold_any template operator= is not used during assignment to another hold_any (as intended by its developer). Instead compiler uses self generated version of operator= which doesn't forward to assign(const basic_hold_any&). This leads to memory corruption.
The fix is simple - you need to add explicit operator=(const basic_hold_any&).
My compiler is gcc 4.4.7 and I use option -std=c++0x
Version of boost is 1.53 but I don't see that something changed in 1.54 so it should have the same issue.
Best regards,
Alexey Tkachenko.