diff options
Diffstat (limited to 'dinput')
-rw-r--r-- | dinput/dinput.hpp | 14 |
1 files changed, 2 insertions, 12 deletions
diff --git a/dinput/dinput.hpp b/dinput/dinput.hpp index 4bb3b458..9dbc576c 100644 --- a/dinput/dinput.hpp +++ b/dinput/dinput.hpp @@ -36,16 +36,6 @@ public: di_t& operator=(const di_t&) = default; diptr operator->() const { return handle; } - operator bool() { return handle != nullptr; } - - // for debugging bad usages. must use a dependent name. - template<typename t = void> - explicit operator void*() const - { - static_assert(sizeof(t) == -1); - static_assert(sizeof(t) == 0); - - return nullptr; - } + operator bool() const { return handle != nullptr; } + operator diptr() const { return handle; } }; - |