mirror of
https://github.com/SerenityOS/serenity
synced 2026-05-05 22:52:10 +02:00
LibCore/DateTime: Add more binary operators
This commit is contained in:
@@ -42,6 +42,9 @@ public:
|
||||
static Optional<DateTime> parse(StringView format, StringView string);
|
||||
|
||||
bool operator<(DateTime const& other) const { return m_timestamp < other.m_timestamp; }
|
||||
bool operator>(DateTime const& other) const { return m_timestamp > other.m_timestamp; }
|
||||
bool operator<=(DateTime const& other) const { return m_timestamp <= other.m_timestamp; }
|
||||
bool operator>=(DateTime const& other) const { return m_timestamp >= other.m_timestamp; }
|
||||
bool operator==(DateTime const& other) const { return m_timestamp == other.m_timestamp; }
|
||||
|
||||
private:
|
||||
|
||||
Reference in New Issue
Block a user