summaryrefslogtreecommitdiff
path: root/chromium/third_party/blink/renderer/core/layout/ng/geometry/ng_bfc_offset.h
diff options
context:
space:
mode:
Diffstat (limited to 'chromium/third_party/blink/renderer/core/layout/ng/geometry/ng_bfc_offset.h')
-rw-r--r--chromium/third_party/blink/renderer/core/layout/ng/geometry/ng_bfc_offset.h10
1 files changed, 7 insertions, 3 deletions
diff --git a/chromium/third_party/blink/renderer/core/layout/ng/geometry/ng_bfc_offset.h b/chromium/third_party/blink/renderer/core/layout/ng/geometry/ng_bfc_offset.h
index ded1830cab5..ee363f9357a 100644
--- a/chromium/third_party/blink/renderer/core/layout/ng/geometry/ng_bfc_offset.h
+++ b/chromium/third_party/blink/renderer/core/layout/ng/geometry/ng_bfc_offset.h
@@ -24,7 +24,7 @@ struct CORE_EXPORT NGBfcDelta {
// a block formatting context (BFC). BFCs are agnostic to text direction, and
// uses line_offset instead of inline_offset.
//
-// Care must be taken when converting this to a NGLogicalOffset to respect the
+// Care must be taken when converting this to a LogicalOffset to respect the
// text direction.
struct CORE_EXPORT NGBfcOffset {
NGBfcOffset() = default;
@@ -44,8 +44,12 @@ struct CORE_EXPORT NGBfcOffset {
block_offset + delta.block_offset_delta};
}
- bool operator==(const NGBfcOffset& other) const;
- bool operator!=(const NGBfcOffset& other) const;
+ bool operator==(const NGBfcOffset& other) const {
+ return std::tie(other.line_offset, other.block_offset) ==
+ std::tie(line_offset, block_offset);
+ }
+
+ bool operator!=(const NGBfcOffset& other) const { return !operator==(other); }
String ToString() const;
};