Allow balances to be rounded and unrounded
This commit is contained in:
parent
3e543d187c
commit
640279c65d
1 changed files with 4 additions and 0 deletions
|
|
@ -1223,6 +1223,8 @@ value_t value_t::rounded() const
|
||||||
return *this;
|
return *this;
|
||||||
case AMOUNT:
|
case AMOUNT:
|
||||||
return as_amount().rounded();
|
return as_amount().rounded();
|
||||||
|
case BALANCE:
|
||||||
|
return as_balance().rounded();
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
@ -1238,6 +1240,8 @@ value_t value_t::unrounded() const
|
||||||
return *this;
|
return *this;
|
||||||
case AMOUNT:
|
case AMOUNT:
|
||||||
return as_amount().unrounded();
|
return as_amount().unrounded();
|
||||||
|
case BALANCE:
|
||||||
|
return as_balance().unrounded();
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue