summaryrefslogtreecommitdiff
path: root/binary.cc
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2008-07-20 23:12:04 -0400
committerJohn Wiegley <johnw@newartisans.com>2008-07-20 23:12:04 -0400
commitd86a91d45b837d1d32e943107c856497897cc85c (patch)
tree3e9ca05a7126facb6b2ad7cd9447d4bc7c149d6c /binary.cc
parent689df610779d43bf740925a90ab3579b22d45da8 (diff)
downloadfork-ledger-d86a91d45b837d1d32e943107c856497897cc85c.tar.gz
fork-ledger-d86a91d45b837d1d32e943107c856497897cc85c.tar.bz2
fork-ledger-d86a91d45b837d1d32e943107c856497897cc85c.zip
The new XPath parser has been integrated, although I have removed the
XML-related bits -- I just wanted the better infrastructure that had been created during the rewrite. It doesn't work, but it compiles and links now. This means that all of the previous 3.0 code has been moved over, although there are still snippets of code in pending/old that need to be restored.
Diffstat (limited to 'binary.cc')
-rw-r--r--binary.cc12
1 files changed, 6 insertions, 6 deletions
diff --git a/binary.cc b/binary.cc
index 1c1487e9..f85ad47c 100644
--- a/binary.cc
+++ b/binary.cc
@@ -354,13 +354,13 @@ inline void read_transaction(const char *& data, transaction_t * xact)
}
else if (flag == 1) {
read_amount(data, xact->amount);
- read_string(data, xact->amount_expr.expr);
+ read_string(data, xact->amount_expr.expr_str);
}
else {
expr::ptr_op_t ptr = read_value_expr(data);
assert(ptr.get());
xact->amount_expr.reset(ptr);
- read_string(data, xact->amount_expr.expr);
+ read_string(data, xact->amount_expr.expr_str);
}
if (read_bool(data)) {
@@ -912,12 +912,12 @@ void write_transaction(std::ostream& out, transaction_t * xact,
else if (xact->amount_expr) {
write_number<unsigned char>(out, 2);
write_value_expr(out, xact->amount_expr.get());
- write_string(out, xact->amount_expr.expr);
+ write_string(out, xact->amount_expr.expr_str);
}
- else if (! xact->amount_expr.expr.empty()) {
+ else if (! xact->amount_expr.expr_str.empty()) {
write_number<unsigned char>(out, 1);
write_amount(out, xact->amount);
- write_string(out, xact->amount_expr.expr);
+ write_string(out, xact->amount_expr.expr_str);
}
else {
write_number<unsigned char>(out, 0);
@@ -928,7 +928,7 @@ void write_transaction(std::ostream& out, transaction_t * xact,
(! (ignore_calculated && xact->has_flags(TRANSACTION_CALCULATED)))) {
write_bool(out, true);
write_amount(out, *xact->cost);
- write_string(out, xact->cost_expr->expr);
+ write_string(out, xact->cost_expr->expr_str);
} else {
write_bool(out, false);
}