Home | History | Annotate | Download | only in fst

Lines Matching defs:front_

115   TrivialQueue() : QueueBase<S>(TRIVIAL_QUEUE), front_(kNoStateId) {}
116 StateId Head() const { return front_; }
117 void Enqueue(StateId s) { front_ = s; }
118 void Dequeue() { front_ = kNoStateId; }
120 bool Empty() const { return front_ == kNoStateId; }
121 void Clear() { front_ = kNoStateId; }
135 StateId front_;
321 : QueueBase<S>(TOP_ORDER_QUEUE), front_(0), back_(kNoStateId),
336 : QueueBase<S>(TOP_ORDER_QUEUE), front_(0), back_(kNoStateId),
339 StateId Head() const { return state_[front_]; }
342 if (front_ > back_) front_ = back_ = order_[s];
344 else if (order_[s] < front_) front_ = order_[s];
349 state_[front_] = kNoStateId;
350 while ((front_ <= back_) && (state_[front_] == kNoStateId)) ++front_;
355 bool Empty() const { return front_ > back_; }
358 for (StateId i = front_; i <= back_; ++i) state_[i] = kNoStateId;
360 front_ = 0;
364 StateId front_;
389 : QueueBase<S>(STATE_ORDER_QUEUE), front_(0), back_(kNoStateId) {}
391 StateId Head() const { return front_; }
394 if (front_ > back_) front_ = back_ = s;
396 else if (s < front_) front_ = s;
402 enqueued_[front_] = false;
403 while ((front_ <= back_) && (enqueued_[front_] == false)) ++front_;
408 bool Empty() const { return front_ > back_; }
411 for (StateId i = front_; i <= back_; ++i) enqueued_[i] = false;
412 front_ = 0;
417 StateId front_;
447 : QueueBase<S>(SCC_QUEUE), queue_(queue), scc_(scc), front_(0),
451 while ((front_ <= back_) &&
452 (((*queue_)[front_] && (*queue_)[front_]->Empty())
453 || (((*queue_)[front_] == 0) &&
454 ((front_ > trivial_queue_.size())
455 || (trivial_queue_[front_] == kNoStateId)))))
456 ++front_;
457 if ((*queue_)[front_])
458 return (*queue_)[front_]->Head();
460 return trivial_queue_[front_];
464 if (front_ > back_) front_ = back_ = scc_[s];
466 else if (scc_[s] < front_) front_ = scc_[s];
477 if ((*queue_)[front_])
478 (*queue_)[front_]->Dequeue();
479 else if (front_ < trivial_queue_.size())
480 trivial_queue_[front_] = kNoStateId;
489 if (front_ < back_) // Queue scc # back_ not empty unless back_==front_
491 else if (front_ > back_)
493 else if ((*queue_)[front_])
494 return (*queue_)[front_]->Empty();
496 return (front_ > trivial_queue_.size())
497 || (trivial_queue_[front_] == kNoStateId);
501 for (StateId i = front_; i <= back_; ++i)
506 front_ = 0;
513 mutable StateId front_;