diff options
author | John Wiegley <johnw@newartisans.com> | 2009-06-21 18:37:39 +0100 |
---|---|---|
committer | John Wiegley <johnw@newartisans.com> | 2009-06-21 18:37:39 +0100 |
commit | f83a1c887304795871d2ed1a9b78675898cdab9b (patch) | |
tree | f4bfecd4291d42bf6cd825735d7d42a429cb7938 /src | |
parent | fe6055bf165aed4869d4a17daf2bb1a74f60c773 (diff) | |
download | fork-ledger-f83a1c887304795871d2ed1a9b78675898cdab9b.tar.gz fork-ledger-f83a1c887304795871d2ed1a9b78675898cdab9b.tar.bz2 fork-ledger-f83a1c887304795871d2ed1a9b78675898cdab9b.zip |
Restored --unround, added baseline test
Diffstat (limited to 'src')
-rw-r--r-- | src/amount.cc | 3 | ||||
-rw-r--r-- | src/report.h | 6 |
2 files changed, 7 insertions, 2 deletions
diff --git a/src/amount.cc b/src/amount.cc index 9dea532c..66934947 100644 --- a/src/amount.cc +++ b/src/amount.cc @@ -488,7 +488,10 @@ void amount_t::in_place_unround() return; _dup(); + + DEBUG("amount.unround", "Unrounding " << *this); set_keep_precision(true); + DEBUG("amount.unround", "Unrounded = " << *this); } void amount_t::in_place_reduce() diff --git a/src/report.h b/src/report.h index da1a7c5a..45d4f11a 100644 --- a/src/report.h +++ b/src/report.h @@ -778,8 +778,10 @@ public: }); OPTION_(report_t, unround, DO() { - parent->HANDLER(amount_).set_expr(string("--uncleared"), - "unrounded(amount)"); + parent->HANDLER(display_amount_) + .set_expr(string("--unround"), "unrounded(amount_expr)"); + parent->HANDLER(display_total_) + .set_expr(string("--unround"), "unrounded(total_expr)"); }); OPTION_(report_t, weekly, DO() { // -W |