From 80f87bc1000c46f7065e42cd6b0abd8a44f57bb4 Mon Sep 17 00:00:00 2001 From: John Wiegley Date: Wed, 30 Jul 2008 15:57:03 -0400 Subject: Corrected a failing test. --- acprep | 3 ++- commodity.h | 2 ++ test/numerics/t_amount.cc | 4 ++-- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/acprep b/acprep index fe35297b..75226516 100755 --- a/acprep +++ b/acprep @@ -26,7 +26,8 @@ cat configure.tmpl | \ autoreconf --force --install -INCDIRS="-I/usr/local/include -I/opt/local/include" +INCDIRS="-isystem /usr/local/include" +INCDIRS="$INCDIRS -isystem /opt/local/include" INCDIRS="$INCDIRS -isystem /usr/local/include/boost-1_35" LIBDIRS="-L/usr/local/lib -L/opt/local/lib" diff --git a/commodity.h b/commodity.h index 6f837942..94aa6b08 100644 --- a/commodity.h +++ b/commodity.h @@ -53,6 +53,8 @@ class commodity_t public: class base_t : public noncopyable, public supports_flags<> { + base_t(); + public: typedef std::map history_map; typedef std::pair history_pair; diff --git a/test/numerics/t_amount.cc b/test/numerics/t_amount.cc index 3fb6b0ee..69d97af3 100644 --- a/test/numerics/t_amount.cc +++ b/test/numerics/t_amount.cc @@ -1379,8 +1379,8 @@ void AmountTestCase::testCommodityForZero() { amount_t x1(internalAmount("$0.000000000000000000001")); - assertFalse(x1); - assertTrue(x1.is_zero()); + assertTrue(x1); // an internal amount never betrays its precision + assertFalse(x1.is_zero()); assertFalse(x1.is_realzero()); assertValid(x1); -- cgit v1.2.3