operator unary- method Null safety

double? operator unary-()

Negate operator. */

Implementation

double? operator -() {
  if (value != null) {
    return -value!;
  }
}