summaryrefslogtreecommitdiff
path: root/decoder
diff options
context:
space:
mode:
authorChris Dyer <redpony@gmail.com>2014-03-27 00:11:01 -0400
committerChris Dyer <redpony@gmail.com>2014-03-27 00:11:01 -0400
commitca29417acd47dbbd2aa68cd31fcd3129e6482bf7 (patch)
tree2b900a3f15aba1277a9c8fc2b033690f8d99086d /decoder
parent34785db78a0ad12f0fe74d98924acc20a8cab79a (diff)
remove warnings
Diffstat (limited to 'decoder')
-rw-r--r--decoder/tree_fragment.h12
1 files changed, 4 insertions, 8 deletions
diff --git a/decoder/tree_fragment.h b/decoder/tree_fragment.h
index b1dbbae0..a38dbdfa 100644
--- a/decoder/tree_fragment.h
+++ b/decoder/tree_fragment.h
@@ -91,14 +91,10 @@ class BreadthFirstIterator : public std::iterator<std::forward_iterator_tag, uns
void Stage() {
if (q_.empty()) return;
const TFIState& s = q_.front();
- if (s.rhspos < 0) {
- sym = tf_->nodes[s.node].lhs;
- } else {
- sym = tf_->nodes[s.node].rhs[s.rhspos];
- if (IsInternalNT(sym)) {
- q_.push(TFIState(sym & ALL_MASK, 0));
- sym = tf_->nodes[sym & ALL_MASK].lhs;
- }
+ sym = tf_->nodes[s.node].rhs[s.rhspos];
+ if (IsInternalNT(sym)) {
+ q_.push(TFIState(sym & ALL_MASK, 0));
+ sym = tf_->nodes[sym & ALL_MASK].lhs;
}
}
const BreadthFirstIterator& operator++() {