operator + method

Offset operator +(
  1. Offset other
)

Implementation

Offset operator +(Offset other) {
  return Offset(dx + other.dx, dy + other.dy);
}