refactor: use squared distance if possible
refactor: add some const-correctness to code
This commit is contained in:
parent
a49a4000c9
commit
4a35a87b25
24 changed files with 579 additions and 567 deletions
|
|
@ -27,7 +27,7 @@ public:
|
|||
|
||||
public:
|
||||
constexpr bool operator == (const DangerStorage &rhs) const {
|
||||
return rhs.data[2] == data[2] && rhs.data[1] == data[1] && rhs.data[0] == data[0];
|
||||
return cr::memcmp (rhs.data, data, sizeof (data));
|
||||
}
|
||||
|
||||
constexpr bool operator != (const DangerStorage &rhs) const {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue