summaryrefslogtreecommitdiff
path: root/src/balance.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/balance.h')
-rw-r--r--src/balance.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/balance.h b/src/balance.h
index 003e29f9..1bab4b6b 100644
--- a/src/balance.h
+++ b/src/balance.h
@@ -234,7 +234,26 @@ public:
balance_t& operator-=(const amount_t& amt);
balance_t& operator*=(const amount_t& amt);
+ balance_t& operator*=(const double val) {
+ return *this *= amount_t(val);
+ }
+ balance_t& operator*=(const unsigned long val) {
+ return *this *= amount_t(val);
+ }
+ balance_t& operator*=(const long val) {
+ return *this *= amount_t(val);
+ }
+
balance_t& operator/=(const amount_t& amt);
+ balance_t& operator/=(const double val) {
+ return *this /= amount_t(val);
+ }
+ balance_t& operator/=(const unsigned long val) {
+ return *this /= amount_t(val);
+ }
+ balance_t& operator/=(const long val) {
+ return *this /= amount_t(val);
+ }
/**
* Unary arithmetic operators. There are only a few unary methods