1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 17:47:44 +00:00

Kernel: Add some comparison operators to PhysicalAddress

This commit is contained in:
Conrad Pankoff 2019-06-11 21:12:17 +10:00 committed by Andreas Kling
parent 8df44b476d
commit 1a77dfed23

View file

@ -21,6 +21,11 @@ public:
dword page_base() const { return m_address & 0xfffff000; }
bool operator==(const PhysicalAddress& other) const { return m_address == other.m_address; }
bool operator!=(const PhysicalAddress& other) const { return m_address != other.m_address; }
bool operator>(const PhysicalAddress& other) const { return m_address > other.m_address; }
bool operator>=(const PhysicalAddress& other) const { return m_address >= other.m_address; }
bool operator<(const PhysicalAddress& other) const { return m_address < other.m_address; }
bool operator<=(const PhysicalAddress& other) const { return m_address <= other.m_address; }
private:
dword m_address { 0 };