diff options
| author | Maxime Coste <mawww@kakoune.org> | 2023-05-21 12:40:27 +1000 |
|---|---|---|
| committer | Maxime Coste <mawww@kakoune.org> | 2023-05-21 12:40:27 +1000 |
| commit | 19b4149d47019424bf304c5dfe13e132492e97fb (patch) | |
| tree | 9700263052ebf1ac6b3a2de400bd7d9ff3562380 /src/coord.hh | |
| parent | 1a5a31cfbf4eef263b59a6481b4d1cf64ad9620e (diff) | |
Fix warnings with gcc-13
Diffstat (limited to 'src/coord.hh')
| -rw-r--r-- | src/coord.hh | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/coord.hh b/src/coord.hh index 30f8e1c0..8420dcee 100644 --- a/src/coord.hh +++ b/src/coord.hh @@ -42,16 +42,16 @@ struct LineAndColumn } [[gnu::always_inline]] - constexpr auto operator<=> (EffectiveType other) const + constexpr friend auto operator<=>(const EffectiveType& lhs, const EffectiveType& rhs) { - return (line != other.line) ? line <=> other.line - : column <=> other.column; + return (lhs.line != rhs.line) ? lhs.line <=> rhs.line + : lhs.column <=> rhs.column; } [[gnu::always_inline]] - constexpr bool operator== (EffectiveType other) const + constexpr friend bool operator==(const EffectiveType& lhs, const EffectiveType& rhs) { - return line == other.line and column == other.column; + return lhs.line == rhs.line and lhs.column == rhs.column; } friend constexpr size_t hash_value(const EffectiveType& val) |
