diff --git a/singleton.hpp b/singleton.hpp index a8b0361d..099651b2 100644 --- a/singleton.hpp +++ b/singleton.hpp @@ -27,6 +27,13 @@ namespace cruft { static SelfT *instance; public: + static bool + valid (void) noexcept + { + return instance; + } + + /// instantiates the one blessed value of this type. /// /// `instantiate` must be called once and once only before any calls