mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-12-13 14:10:42 +00:00
- replaced deprecated throw() with noexcept in TObjPtr
This commit is contained in:
parent
b1de11dce8
commit
8bdd4befbf
1 changed files with 8 additions and 8 deletions
|
@ -175,7 +175,7 @@ public:
|
||||||
TObjPtr() = default;
|
TObjPtr() = default;
|
||||||
TObjPtr(const TObjPtr<T> &q) = default;
|
TObjPtr(const TObjPtr<T> &q) = default;
|
||||||
|
|
||||||
TObjPtr(T q) throw()
|
TObjPtr(T q) noexcept
|
||||||
: pp(q)
|
: pp(q)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
@ -207,35 +207,35 @@ public:
|
||||||
return *this;
|
return *this;
|
||||||
}
|
}
|
||||||
|
|
||||||
T Get() throw()
|
T Get() noexcept
|
||||||
{
|
{
|
||||||
return GC::ReadBarrier(pp);
|
return GC::ReadBarrier(pp);
|
||||||
}
|
}
|
||||||
|
|
||||||
T ForceGet() throw() //for situations where the read barrier needs to be skipped.
|
T ForceGet() noexcept //for situations where the read barrier needs to be skipped.
|
||||||
{
|
{
|
||||||
return pp;
|
return pp;
|
||||||
}
|
}
|
||||||
|
|
||||||
operator T() throw()
|
operator T() noexcept
|
||||||
{
|
{
|
||||||
return GC::ReadBarrier(pp);
|
return GC::ReadBarrier(pp);
|
||||||
}
|
}
|
||||||
T &operator*()
|
T &operator*() noexcept
|
||||||
{
|
{
|
||||||
T q = GC::ReadBarrier(pp);
|
T q = GC::ReadBarrier(pp);
|
||||||
assert(q != NULL);
|
assert(q != NULL);
|
||||||
return *q;
|
return *q;
|
||||||
}
|
}
|
||||||
T operator->() throw()
|
T operator->() noexcept
|
||||||
{
|
{
|
||||||
return GC::ReadBarrier(pp);
|
return GC::ReadBarrier(pp);
|
||||||
}
|
}
|
||||||
bool operator!=(T u) throw()
|
bool operator!=(T u) noexcept
|
||||||
{
|
{
|
||||||
return GC::ReadBarrier(o) != u;
|
return GC::ReadBarrier(o) != u;
|
||||||
}
|
}
|
||||||
bool operator==(T u) throw()
|
bool operator==(T u) noexcept
|
||||||
{
|
{
|
||||||
return GC::ReadBarrier(o) == u;
|
return GC::ReadBarrier(o) == u;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue