Added a conversion to bool to check if a functor it's been initialized.

git-svn-id: svn://svn.code.sf.net/p/loki-lib/code/trunk@84 7ec92016-0320-0410-acc4-a06ded1c099a
This commit is contained in:
derfel 2002-12-31 00:04:21 +00:00
parent aeb33168e8
commit 90a16ecbd4
3 changed files with 15 additions and 0 deletions

View file

@ -762,6 +762,11 @@ namespace Loki
: spImpl_(new MemFunHandler<Functor, PtrObj, MemFn>(p, memFn))
{}
operator bool()
{
return spImpl_.get() ? true : false;
}
Functor& operator=(const Functor& rhs)
{
Functor copy(rhs);

View file

@ -899,6 +899,11 @@ namespace Loki
: spImpl_(new MemFunHandler<Functor, PtrObj, MemFn>(p, memFn))
{}
operator bool()
{
return spImpl_.get() ? true : false;
}
Functor& operator=(const Functor& rhs)
{
Functor copy(rhs);

View file

@ -762,6 +762,11 @@ namespace Loki
: spImpl_(new MemFunHandler<Functor, PtrObj, MemFn>(p, memFn))
{}
operator bool()
{
return spImpl_.get() ? true : false;
}
Functor& operator=(const Functor& rhs)
{
Functor copy(rhs);