Mealy machines are a better model of lexical analyzers

Wuu Yang*

*此作品的通信作者

研究成果: Article同行評審

5 引文 斯高帕斯(Scopus)

摘要

Lexical analyzers partition input characters into tokens. When ambiguities arise during lexical analysis, the longest-match rule is generally adopted to resolve the ambiguities. The longest-match rule causes the look-ahead problem in traditional lexical analyzers, which are based on Moore machines. In Moore machines, output tokens are associated with states of the automata. By contrast, because Mealy machines associate output tokens with state transitions, the look-ahead behaviors can be encoded in their state transition tables. Therefore, we believe that lexical analyzers should be based on Mealy machines, rather than Moore machines, in order to solve the look-ahead problem. We propose techniques to construct Mealy machines from regular expressions and to perform sequential and data-parallel lexical analysis with these Mealy machines.

原文English
頁(從 - 到)27-38
頁數12
期刊Computer Languages
22
發行號1
DOIs
出版狀態Published - 4月 1996

指紋

深入研究「Mealy machines are a better model of lexical analyzers」主題。共同形成了獨特的指紋。

引用此