remove null check during access

This commit is contained in:
Zac Hansen 2018-03-29 20:50:36 -07:00
parent d846fe50a3
commit 7757e7ec9f

View File

@ -88,7 +88,12 @@ public:
constexpr T get() const
{
Ensures(ptr_ != nullptr);
/*
not_null constructors and assignment operators always verify ptr_ is
not set to null. As long as references to ptr_ are not exposed publicly
it is not additionally necessary to check the value against nullptr here.
*/
// Ensures(ptr_ != nullptr);
return ptr_;
}