changed constructors to downgrade BALANCE and BALANCE_PAIR types when possible
This commit is contained in:
parent
fcaaa37201
commit
93d73f828c
1 changed files with 3 additions and 2 deletions
5
value.h
5
value.h
|
|
@ -46,8 +46,9 @@ class value_t
|
||||||
*((unsigned int *) data) = value;
|
*((unsigned int *) data) = value;
|
||||||
type = INTEGER;
|
type = INTEGER;
|
||||||
}
|
}
|
||||||
value_t(const amount_t& value) : type(INTEGER) {
|
value_t(const amount_t& value) {
|
||||||
*this = value;
|
new((amount_t *)data) amount_t(value);
|
||||||
|
type = AMOUNT;
|
||||||
}
|
}
|
||||||
value_t(const balance_t& value) : type(INTEGER) {
|
value_t(const balance_t& value) : type(INTEGER) {
|
||||||
*this = value;
|
*this = value;
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue