Commit 8ba33780 authored by Max Kellermann's avatar Max Kellermann

util/AllocatedString: add operator==(nullptr)

parent 22598482
...@@ -103,6 +103,14 @@ public: ...@@ -103,6 +103,14 @@ public:
return *this; return *this;
} }
constexpr bool operator==(std::nullptr_t other) const {
return value == other;
}
constexpr bool operator!=(std::nullptr_t other) const {
return value != other;
}
constexpr bool IsNull() const { constexpr bool IsNull() const {
return value == nullptr; return value == nullptr;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment