summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorCraig Earls <enderw88@gmail.com>2014-08-29 22:36:55 -0700
committerCraig Earls <enderw88@gmail.com>2014-08-29 22:36:55 -0700
commit5427c94272d909d0c162f2d0a3382a8c0e3fd90b (patch)
treea1e9d58e951f3248df922eb693ad1506fb038267 /src
parentdd3fd0e9deab8deb586745960f10f833eb783f1b (diff)
parentc1598b7de27c5ba5fafc8a5efb1db18fe54d3070 (diff)
downloadfork-ledger-5427c94272d909d0c162f2d0a3382a8c0e3fd90b.tar.gz
fork-ledger-5427c94272d909d0c162f2d0a3382a8c0e3fd90b.tar.bz2
fork-ledger-5427c94272d909d0c162f2d0a3382a8c0e3fd90b.zip
Merge branch 'master' into new-fontification-scheme
Diffstat (limited to 'src')
-rw-r--r--src/account.h4
-rw-r--r--src/item.h4
-rw-r--r--src/post.h4
-rw-r--r--src/ptree.cc5
-rw-r--r--src/times.h4
5 files changed, 21 insertions, 0 deletions
diff --git a/src/account.h b/src/account.h
index 4a4041b7..7411dfc2 100644
--- a/src/account.h
+++ b/src/account.h
@@ -261,7 +261,11 @@ public:
mutable optional<xdata_t> xdata_;
bool has_xdata() const {
+#if BOOST_VERSION >= 105600
return xdata_ != NULL;
+#else
+ return xdata_;
+#endif
}
void clear_xdata();
xdata_t& xdata() {
diff --git a/src/item.h b/src/item.h
index d194ac07..767a0715 100644
--- a/src/item.h
+++ b/src/item.h
@@ -191,7 +191,11 @@ public:
static bool use_aux_date;
virtual bool has_date() const {
+#if BOOST_VERSION >= 105600
return _date != NULL;
+#else
+ return _date;
+#endif
}
virtual date_t date() const {
diff --git a/src/post.h b/src/post.h
index c4fc3827..d04be266 100644
--- a/src/post.h
+++ b/src/post.h
@@ -205,7 +205,11 @@ public:
mutable optional<xdata_t> xdata_;
bool has_xdata() const {
+#if BOOST_VERSION >= 105600
return xdata_ != NULL;
+#else
+ return xdata_;
+#endif
}
void clear_xdata() {
xdata_ = none;
diff --git a/src/ptree.cc b/src/ptree.cc
index fa6a1db9..3fc9ace6 100644
--- a/src/ptree.cc
+++ b/src/ptree.cc
@@ -80,7 +80,12 @@ void format_ptree::flush()
switch (format) {
case FORMAT_XML:
+#if BOOST_VERSION >= 105600
auto indented = property_tree::xml_writer_make_settings<std::string> (' ', 2);
+#else
+ property_tree::xml_writer_settings<char> indented(' ', 2);
+#endif
+
property_tree::write_xml(out, pt, indented);
out << std::endl;
break;
diff --git a/src/times.h b/src/times.h
index d2f7bb19..00007580 100644
--- a/src/times.h
+++ b/src/times.h
@@ -568,7 +568,11 @@ public:
void stabilize(const optional<date_t>& date = none);
bool is_valid() const {
+#if BOOST_VERSION >= 105600
return start != NULL;
+#else
+ return start;
+#endif
}
/** Find the current or next period containing date. Returns false if