public void set(final T value) {
    if (!Objects.equals(this.value, value)) {
      undoLog.add(new UndoEntry<>(this.value));
      this.value = value;
    }
  }
Set a new value in the scalar.

@param value new value
evm/src/main/java/org/hyperledger/besu/collections/undo/UndoScalar.java