---
title: "Raiyan Hossain (@zireael9797) | Hashnode"
description: "Raiyan Hossain (@zireael9797) writes on Hashnode. Read their latest articles and follow their work."
url: "https://hashnode.com/@zireael9797"
---

@zireael9797

# Raiyan Hossain

@zireael9797 · Joined August 2025

## Comments

[impl Iterator for Lexer<'\_> { type Item = (Token, Span); fn next(&mut self) -> Option<Self::Item> { - self.next\_token(); + self.emit\_next\_tokens(); + self.token\_queue.pop\_front() } } One question here emit\_next\_tokens(); can push one or more tokens to the queue. pop\_front(); only consumes one. Does this not mean the queue will race ahead of the iteration? I tried setting type Item = (Token, Span, u32 /Current Queue Size/) with a longer bit of code with a lot of indentation and it did race ahead. It's possible I missed something else elsewhere.](https://hashnode.com/posts/build-a-compiler-from-scratch-part-11-a-hello-world-of-sorts/685b368a2c1dbdb423ba0c92/comment/688ee4dc3598c01e878a1013)

Comment · Article · Aug 3, 2025 · [Build a Compiler from Scratch, Part 1.1: A Hello World of sorts](https://hashnode.com/posts/build-a-compiler-from-scratch-part-11-a-hello-world-of-sorts/685b368a2c1dbdb423ba0c92)
