Fixes for dereference operator.
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
This commit is contained in:
parent
c08224ed26
commit
d3c9998afa
|
@ -29,14 +29,11 @@ namespace ArbUt {
|
||||||
AssertNotNull(_raw);
|
AssertNotNull(_raw);
|
||||||
return _raw;
|
return _raw;
|
||||||
}
|
}
|
||||||
inline T operator*() const {
|
|
||||||
if constexpr (std::is_abstract<T>()) {
|
inline typename std::enable_if<!std::is_abstract<T>::value, bool>::type operator*() const {
|
||||||
static_assert(!std::is_abstract<T>(), "You're not allowed to dereference an abstract class.");
|
|
||||||
} else {
|
|
||||||
AssertNotNull(_raw);
|
AssertNotNull(_raw);
|
||||||
return *_raw;
|
return *_raw;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
inline T* GetRaw() const noexcept { return _raw; }
|
inline T* GetRaw() const noexcept { return _raw; }
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue