summaryrefslogtreecommitdiff
path: root/src/token.cc
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2009-02-07 04:27:14 -0400
committerJohn Wiegley <johnw@newartisans.com>2009-02-07 04:27:14 -0400
commit19694cf2a2986849048ab01fbbfda7f0b9ee102a (patch)
tree864e81a90aa7e7eefa4d99fc193b19d324975117 /src/token.cc
parent682544ef17cdf96cde684d5601c6145132624f22 (diff)
downloadfork-ledger-19694cf2a2986849048ab01fbbfda7f0b9ee102a.tar.gz
fork-ledger-19694cf2a2986849048ab01fbbfda7f0b9ee102a.tar.bz2
fork-ledger-19694cf2a2986849048ab01fbbfda7f0b9ee102a.zip
Use seekg, in place of multiple ungets.
Diffstat (limited to 'src/token.cc')
-rw-r--r--src/token.cc6
1 files changed, 0 insertions, 6 deletions
diff --git a/src/token.cc b/src/token.cc
index a2046924..f7133af3 100644
--- a/src/token.cc
+++ b/src/token.cc
@@ -406,13 +406,7 @@ void expr_t::token_t::next(std::istream& in, const uint_least8_t pflags)
void expr_t::token_t::rewind(std::istream& in)
{
-#if 0
in.seekg(- length, std::ios::cur);
-#else
- for (unsigned int i = 0; i < length; i++)
- in.unget();
-#endif
-
if (in.fail())
throw_(parse_error, "Failed to rewind input stream");
}