public void changeScaleDestructive(short scale) {
    if (scale == this.scale) {
      return;
    }

    checkScaleRange(scale);
    short scaleDown = (short) (this.scale - scale);
    if (scaleDown > 0) {
      this.unscaledValue.scaleDownTenDestructive(scaleDown);
      if (this.unscaledValue.isZero()) {
        this.signum = 0;
      }
    } else if (scaleDown < 0) {
      this.unscaledValue.scaleUpTenDestructive((short) -scaleDown);
    }
    this.scale = scale;

    this.unscaledValue.throwIfExceedsTenToThirtyEight();
  }
Changes the scaling of this {@code Decimal128}, preserving the represented
value. This method is destructive.
<p>
This method is NOT just a setter for #scale. It also adjusts the unscaled
value to preserve the represented value.
</p>
<p>
When the given scaling is larger than the current scaling, this method
shrinks the unscaled value accordingly. It will NOT throw any error even if
underflow happens.
</p>
<p>
When the given scaling is smaller than the current scaling, this method
expands the unscaled value accordingly. It does throw an error if overflow
happens.
</p>
<p>
Unchecked exceptions: ArithmeticException a negative value is specified or
overflow.
</p>

@param scale
         new scale. must be 0 or positive.
common/src/java/org/apache/hadoop/hive/common/type/Decimal128.java