diff options
author | John Wiegley <johnw@newartisans.com> | 2007-04-15 02:55:16 +0000 |
---|---|---|
committer | John Wiegley <johnw@newartisans.com> | 2008-04-13 03:35:32 -0400 |
commit | a087e6ea97494d97580c97705c665cac317a0dc3 (patch) | |
tree | d771c7f88f5b6255cb46b2d69aeec9395b3f982d /datetime.h | |
parent | 691c29a696d2347faebd5663da9d1dc751f275eb (diff) | |
download | fork-ledger-a087e6ea97494d97580c97705c665cac317a0dc3.tar.gz fork-ledger-a087e6ea97494d97580c97705c665cac317a0dc3.tar.bz2 fork-ledger-a087e6ea97494d97580c97705c665cac317a0dc3.zip |
Cleared out all warnings; started work on getting Python up again.
Diffstat (limited to 'datetime.h')
-rw-r--r-- | datetime.h | 9 |
1 files changed, 4 insertions, 5 deletions
@@ -8,7 +8,7 @@ class date_error : public error { public: - date_error(const std::string& reason) throw() : error(reason) {} + date_error(const std::string& _reason) throw() : error(_reason) {} virtual ~date_error() throw() {} }; @@ -71,12 +71,11 @@ class date_t virtual date_t& operator+=(const long days) { // jww (2006-03-26): This is not accurate enough when DST is in effect! - assert(0); when += days * 86400; return *this; } virtual date_t& operator-=(const long days) { - assert(0); + // jww (2006-03-26): This is not accurate enough when DST is in effect! when -= days * 86400; return *this; } @@ -167,7 +166,7 @@ inline std::istream& operator>>(std::istream& in, date_t& moment) { class datetime_error : public error { public: - datetime_error(const std::string& reason) throw() : error(reason) {} + datetime_error(const std::string& _reason) throw() : error(_reason) {} virtual ~datetime_error() throw() {} }; @@ -176,7 +175,7 @@ class datetime_t : public date_t public: static datetime_t now; - datetime_t() : date_t() {} + datetime_t() : date_t(now.when) {} datetime_t(const datetime_t& _when) : date_t(_when.when) {} datetime_t(const date_t& _when) : date_t(_when) {} |