Plycc:使用PLY(Python Lex-Yacc)的C语言编译器-源码

上传者: 42106765 | 上传时间: 2021-07-12 15:27:50 | 文件大小: 79KB | 文件类型: ZIP
Plycc 项目简介 在这个项目中,我使用了基于Python的Lex-Yacc库 ,并且全项目使用Python编写 此编译器可以生成包含短路条件的if结构对应四元式,while结构对应四元式 项目总行数约700,其中词法分析100行,语法分析600行 项目使用 Github 进行管理,仓库位于,上面有对应的 commit 记录和代码行数统计 用Python构建项目的原因有如下几点: Python作为解释型语言,它要比C语言这种编译型语言,更加适合快速搭建原型(如我们的编译器) C这类编译型语言适合写一些性能要求较高的程序 Python隐藏了一些底层的编程细节,我们可以更专注于实现功能,而不是调试用C可能会产生的各种语法错误 文法 start_state -> INT ID OPBRAC CLOSEBRAC stmts stmts -> OPENFLR stmts CLOSEFLR

文件下载

资源详情

[{"title":"( 22 个子文件 79KB ) Plycc:使用PLY(Python Lex-Yacc)的C语言编译器-源码","children":[{"title":"Plycc-master","children":[{"title":".gitignore <span style='color:#111;'> 1.19KB </span>","children":null,"spread":false},{"title":"README.md <span style='color:#111;'> 6.73KB </span>","children":null,"spread":false},{"title":"test","children":[{"title":"test5 <span style='color:#111;'> 48B </span>","children":null,"spread":false},{"title":"test7 <span style='color:#111;'> 130B </span>","children":null,"spread":false},{"title":"test1 <span style='color:#111;'> 13B </span>","children":null,"spread":false},{"title":"test8 <span style='color:#111;'> 92B </span>","children":null,"spread":false},{"title":"test3 <span style='color:#111;'> 36B </span>","children":null,"spread":false},{"title":"test6 <span style='color:#111;'> 77B </span>","children":null,"spread":false},{"title":"test4 <span style='color:#111;'> 48B </span>","children":null,"spread":false},{"title":"test2 <span style='color:#111;'> 31B </span>","children":null,"spread":false}],"spread":true},{"title":"LICENSE <span style='color:#111;'> 34.30KB </span>","children":null,"spread":false},{"title":".gitattributes <span style='color:#111;'> 66B </span>","children":null,"spread":false},{"title":"pic","children":[{"title":"test5.png <span style='color:#111;'> 9.00KB </span>","children":null,"spread":false},{"title":"test7.png <span style='color:#111;'> 10.33KB </span>","children":null,"spread":false},{"title":"test3.png <span style='color:#111;'> 6.91KB </span>","children":null,"spread":false},{"title":"test4.png <span style='color:#111;'> 7.88KB </span>","children":null,"spread":false},{"title":"test.png <span style='color:#111;'> 17.21KB </span>","children":null,"spread":false},{"title":"test2.png <span style='color:#111;'> 4.27KB </span>","children":null,"spread":false},{"title":"test1.png <span style='color:#111;'> 2.87KB </span>","children":null,"spread":false}],"spread":true},{"title":"src","children":[{"title":"lexer.py <span style='color:#111;'> 1.75KB </span>","children":null,"spread":false},{"title":"main.py <span style='color:#111;'> 8.06KB </span>","children":null,"spread":false},{"title":"parser.py <span style='color:#111;'> 4.08KB </span>","children":null,"spread":false}],"spread":true}],"spread":true}],"spread":true}]

评论信息

免责申明

【只为小站】的资源来自网友分享,仅供学习研究,请务必在下载后24小时内给予删除,不得用于其他任何用途,否则后果自负。基于互联网的特殊性,【只为小站】 无法对用户传输的作品、信息、内容的权属或合法性、合规性、真实性、科学性、完整权、有效性等进行实质审查;无论 【只为小站】 经营者是否已进行审查,用户均应自行承担因其传输的作品、信息、内容而可能或已经产生的侵权或权属纠纷等法律责任。
本站所有资源不代表本站的观点或立场,基于网友分享,根据中国法律《信息网络传播权保护条例》第二十二条之规定,若资源存在侵权或相关问题请联系本站客服人员,zhiweidada#qq.com,请把#换成@,本站将给予最大的支持与配合,做到及时反馈和处理。关于更多版权及免责申明参见 版权及免责申明