The previous bool() operator for ChSharedPtr and ChSmartPtr were potentially dangerous because the compiler could implicitly cast bool to integer etc. To avoid this potential risk of misunderstanding, now I implemented it by using the 'safe bool idiom', as used in boost shared pointers, so the bool implicit cast can be used only for  tests like   if (mysharedptr) ... Note that this is also possible with more typing..   if (!mysharedptr.IsNull()) Note also that, when we'll migrate to C++11 / C++0x , there will be no need of this odd 'safe bool idiom', because we could use the 'explicit' in   explicit operator bool() ..
The previous bool() operator for ChSharedPtr and ChSmartPtr were potentially dangerous because the compiler could implicitly cast bool to integer etc.
To avoid this potential risk of misunderstanding, now I implemented it by using the 'safe bool idiom', as used in boost shared pointers, so the bool implicit cast can be used only for  tests like
  if (mysharedptr) ...
Note that this is also possible with more typing..
  if (!mysharedptr.IsNull())
Note also that, when we'll migrate to C++11 / C++0x , there will be no need of this odd 'safe bool idiom', because we could use the 'explicit' in
  explicit operator bool() ..

Bryan-Peterson/chrono,PedroTrujilloV/chrono,Bryan-Peterson/chrono,tjolsen/chrono,armanpazouki/chrono,jcmadsen/chrono,Bryan-Peterson/chrono,rserban/chrono,armanpazouki/chrono,Milad-Rakhsha/chrono,projectchrono/chrono,projectchrono/chrono,jcmadsen/chrono,jcmadsen/chrono,Milad-Rakhsha/chrono,rserban/chrono,Milad-Rakhsha/chrono,amelmquist/chrono,Milad-Rakhsha/chrono,scpeters/chrono,PedroTrujilloV/chrono,tjolsen/chrono,PedroTrujilloV/chrono,tjolsen/chrono,dariomangoni/chrono,armanpazouki/chrono,dariomangoni/chrono,amelmquist/chrono,projectchrono/chrono,PedroTrujilloV/chrono,andrewseidl/chrono,Bryan-Peterson/chrono,scpeters/chrono,armanpazouki/chrono,amelmquist/chrono,dariomangoni/chrono,scpeters/chrono,Milad-Rakhsha/chrono,projectchrono/chrono,armanpazouki/chrono,rserban/chrono,tjolsen/chrono,tjolsen/chrono,armanpazouki/chrono,andrewseidl/chrono,dariomangoni/chrono,Milad-Rakhsha/chrono,PedroTrujilloV/chrono,amelmquist/chrono,jcmadsen/chrono,hsu/chrono,hsu/chrono,projectchrono/chrono,rserban/chrono,andrewseidl/chrono,amelmquist/chrono,projectchrono/chrono,scpeters/chrono,amelmquist/chrono,Bryan-Peterson/chrono,jcmadsen/chrono,scpeters/chrono,hsu/chrono,rserban/chrono,dariomangoni/chrono,jcmadsen/chrono,rserban/chrono,hsu/chrono,hsu/chrono,rserban/chrono,andrewseidl/chrono,jcmadsen/chrono,dariomangoni/chrono,andrewseidl/chrono