手动编写递归下降解析器的资源

发布于 2024-08-11 07:36:53 字数 49 浏览 1 评论 0原文

我正在寻找手工编写一个递归下降解析器,并且正在寻找有关如何构造它、算法等的良好资源。

I'm looking to write a recursive descent parser by hand and I'm looking for good resources on how to structure it, algorithms, etc.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

拥抱没勇气 2024-08-18 07:36:53

在“编译器模式”下有一个关于 codeproject 的很好的教程。最近,你甚至可以直接谷歌“编译器模式”。

http://www.codeproject.com/Articles/286121/Compiler-Patterns

本文涵盖了构建简单编译器的大部分方面(后端、BNF 以及用于实现各种 BNF 规则的模式),但并没有过多地阐述理论,甚至没有讨论为什么递归下降编译器能够将语言输入到代码中。

There is a good tutorial on codeproject under "Compiler Patterns". Lately, you can even just Google "compiler patterns".

http://www.codeproject.com/Articles/286121/Compiler-Patterns

The article covers most aspects of building a simple compiler (the back-end, the BNF, and the patterns used to implement the various BNF rules), but is not very heavy on theory, or even on why a recursive descent compiler works to convert language input into code.

画中仙 2024-08-18 07:36:53

我可以推荐 Charles N. Fischer 和 Richard J. LeBlanc 的《Crafting a Compiler》。

编辑。这是更新版本:http://www.amazon.com/Crafting-Compiler- Charles-N-Fischer/dp/0136067050/ref=sr_1_2?ie=UTF8&s=books&qid=1258514561&sr=8-2

I can suggest "Crafting a Compiler" by Charles N. Fischer and Richard J. LeBlanc.

Edit. This is an updated version: http://www.amazon.com/Crafting-Compiler-Charles-N-Fischer/dp/0136067050/ref=sr_1_2?ie=UTF8&s=books&qid=1258514561&sr=8-2

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文