[boost-users] lexical-cast throws exceptions
Please take a look at the simple piece of code. When it is compiled on MSVC 2008 (no sp) , Win Sp2 then we receive access violation on program exit Can you tell me the reason of such strange behaviour? (boost 1.38.0) #include "stdafx.h" #include <iostream> #include <boost/lexical_cast.hpp> //#include <boost/thread.hpp> using namespace std; class ctest { public: ~ctest () { boost::lexical_cast<string>(1); } }; ctest a; int main(int argc, char* argv[]) { boost::lexical_cast<string>(1); return 0; }
AMDG Roman Shmelev wrote:
Please take a look at the simple piece of code. When it is compiled on MSVC 2008 (no sp) , Win Sp2 then we receive access violation on program exit Can you tell me the reason of such strange behaviour? (boost 1.38.0)
#include "stdafx.h"
#include <iostream> #include <boost/lexical_cast.hpp> //#include <boost/thread.hpp>
using namespace std;
class ctest { public: ~ctest () { boost::lexical_cast<string>(1); } };
ctest a;
int main(int argc, char* argv[]) { boost::lexical_cast<string>(1); return 0; }
It looks like the standard library's facet(s) have been destroyed before a. In Christ, Steven Watanabe
participants (2)
-
Roman Shmelev
-
Steven Watanabe