toggle method

bool toggle()

Toggles the boolean value.

Returns true if the original value was false, and vice versa.

Implementation

bool toggle() {
  return !this;
}