operator + method

Dim operator +(
  1. Dim other
)

Adds another dimension with same unit to this dimension.

Implementation

Dim operator +(Dim other) {
  if (value == null || other.value == null || other.unit != unit) return this;
  return Dim(value! + other.value!, unit: unit, important: important);
}