diff options
author | John Wiegley <johnw@newartisans.com> | 2009-10-25 04:35:19 -0400 |
---|---|---|
committer | John Wiegley <johnw@newartisans.com> | 2009-10-25 05:01:39 -0400 |
commit | 588f2ef2f51d7bdf209820bfb244034863601939 (patch) | |
tree | 7a473de7c117bf71bb802398823826ca4dfbfdca /src/format.h | |
parent | dc66840dd745863c06ad6513f9f66d589bcc29d8 (diff) | |
download | fork-ledger-588f2ef2f51d7bdf209820bfb244034863601939.tar.gz fork-ledger-588f2ef2f51d7bdf209820bfb244034863601939.tar.bz2 fork-ledger-588f2ef2f51d7bdf209820bfb244034863601939.zip |
Fixed many compiler warnings from g++ 4.4
Diffstat (limited to 'src/format.h')
-rw-r--r-- | src/format.h | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/src/format.h b/src/format.h index 03ed28c7..bc513f71 100644 --- a/src/format.h +++ b/src/format.h @@ -65,10 +65,7 @@ class format_t : public noncopyable { #define ELEMENT_ALIGN_LEFT 0x01 - enum kind_t { - STRING, - EXPR, - }; + enum kind_t { STRING, EXPR }; kind_t type; std::size_t min_width; @@ -89,7 +86,7 @@ class format_t : public noncopyable friend inline void mark_red(std::ostream& out, const element_t * elem) { out.setf(std::ios::left); out.width(0); - out << "\e[31m"; + out << "\033[31m"; if (elem->has_flags(ELEMENT_ALIGN_LEFT)) out << std::left; @@ -145,8 +142,9 @@ public: elem->dump(out); } - static string truncate(const unistring& str, std::size_t width, - const int account_abbrev_length = -1); + static string truncate(const unistring& str, + const std::size_t width, + const std::size_t account_abbrev_length = 0); }; #define FMT_PREFIX "fmt_" |