summaryrefslogtreecommitdiff
path: root/src/textual.cc
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2009-03-03 16:02:34 -0400
committerJohn Wiegley <johnw@newartisans.com>2009-03-03 16:02:34 -0400
commit098e3b0043c275cfe195be1c592baf5716ab73e5 (patch)
tree149d0f9d8c29db059cedd010beb9df237e69f343 /src/textual.cc
parent4af1bfdde3118b6abc19ca87ef99d42bec58197b (diff)
downloadfork-ledger-098e3b0043c275cfe195be1c592baf5716ab73e5.tar.gz
fork-ledger-098e3b0043c275cfe195be1c592baf5716ab73e5.tar.bz2
fork-ledger-098e3b0043c275cfe195be1c592baf5716ab73e5.zip
Fixed parsing of '(1, 2, (3, 4))'
Diffstat (limited to 'src/textual.cc')
-rw-r--r--src/textual.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/textual.cc b/src/textual.cc
index e3460202..4d90fad4 100644
--- a/src/textual.cc
+++ b/src/textual.cc
@@ -902,6 +902,7 @@ post_t * instance_t::parse_post(char * line,
else
parse_amount_expr(session_scope, stream, post->amount, post.get(),
static_cast<uint_least8_t>(expr_t::PARSE_NO_REDUCE) |
+ static_cast<uint_least8_t>(expr_t::PARSE_SINGLE) |
static_cast<uint_least8_t>(expr_t::PARSE_NO_ASSIGN));
if (! post->amount.is_null() && honor_strict && strict &&
@@ -949,6 +950,7 @@ post_t * instance_t::parse_post(char * line,
else
parse_amount_expr(session_scope, cstream, *post->cost, post.get(),
static_cast<uint_least8_t>(expr_t::PARSE_NO_MIGRATE) |
+ static_cast<uint_least8_t>(expr_t::PARSE_SINGLE) |
static_cast<uint_least8_t>(expr_t::PARSE_NO_ASSIGN));
if (post->cost->sign() < 0)
@@ -994,6 +996,7 @@ post_t * instance_t::parse_post(char * line,
post->assigned_amount->parse(stream, amount_t::PARSE_NO_MIGRATE);
else
parse_amount_expr(session_scope, stream, *post->assigned_amount, post.get(),
+ static_cast<uint_least8_t>(expr_t::PARSE_SINGLE) |
static_cast<uint_least8_t>(expr_t::PARSE_NO_MIGRATE));
if (post->assigned_amount->is_null())