summaryrefslogtreecommitdiff
path: root/src/token.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/token.cc')
-rw-r--r--src/token.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/token.cc b/src/token.cc
index 6c28e7d6..964c65de 100644
--- a/src/token.cc
+++ b/src/token.cc
@@ -133,6 +133,7 @@ void expr_t::token_t::next(std::istream& in, const uint_least8_t pflags)
switch (c) {
case '&':
in.get(c);
+ c = in.peek();
if (c == '&') {
in.get(c);
kind = KW_AND;
@@ -143,6 +144,7 @@ void expr_t::token_t::next(std::istream& in, const uint_least8_t pflags)
break;
case '|':
in.get(c);
+ c = in.peek();
if (c == '|') {
in.get(c);
kind = KW_OR;