-
这是一份实验报告,目的是掌握YACC的使用方法,了解YACC处理二义性的方法。
用YACC等工具生成如下文法表示的表达式对应的计算器
exp...
这是一份实验报告,目的是掌握YACC的使用方法,了解YACC处理二义性的方法。
用YACC等工具生成如下文法表示的表达式对应的计算器
exp->exp + exp | exp - exp| exp * exp |exp / exp |exp ^ exp | - exp |(exp) |NUM
对于输入的表达式,能输出结果。比如:
3 +(4 *5)结果应为23
当出现错误时可以进行错误处理。
-This is a test report, the purpose is to master the use YACC to learn YACC handling of the ambiguity approach. Using tools such as YACC grammar that generates the following expression for the corresponding calculator exp-> exp+ exp | exp- exp | exp* exp | exp/exp | exp ^ exp |- exp | (exp) | NUM expression for the input type, can be output. For example: 3+ (4* 5) the result should be 23 when the error can be error-handling.
- 2022-05-23 10:34:44下载
- 积分:1
-
编译原理实验中的工具BISON,可以再windows或者DOS下使用
编译原理实验中的工具BISON,可以再windows或者DOS下使用-Compilation Principle Experiment tools BISON, can be used under windows or DOS
- 2023-08-09 12:55:03下载
- 积分:1
-
SLR parser
slr语法分析器-SLR parser
- 2022-02-24 15:46:01下载
- 积分:1
-
一个免费的汇编语言编译器的源代码
一个免费的汇编语言编译器的源代码-a free compilation of language compiler source code
- 2022-05-30 12:47:36下载
- 积分:1
-
一个简单的词法分析器,1代表字符,2代表关键字(命令字),4带表算符界符, 注:要把wangs.txt这个文件放在桌面上,然后在这个TXT里写上你要识别的语句。...
一个简单的词法分析器,1代表字符,2代表关键字(命令字),4带表算符界符, 注:要把wangs.txt这个文件放在桌面上,然后在这个TXT里写上你要识别的语句。然后保存后关毕,在运行WANG词法分析.EXE进行词法分析。 完成识别后,会在相应的词面前出现以上代号。暂不能对数字进行识别。因为在某种请况下数字也可表是为字符……稍有困难,但完成老师的针对程序段:area=b+c*d。那简直是小菜一碟。-a simple lexical analyzer, a representative character, the two representatives keyword (command word), with four tables operator sector website Note : The wangs.txt the document on the desktop, then the TXT Lane write you to identify words. Then preserved customs Albert, running WANG lexical analysis. EXE for lexical analysis. After completing the identification, in the appropriate words appear in front of the above code. Provisional figures for the right not to identify. Because of the status of requests under certain figures might be for the characters ... the slightest difficulty, but the completion of procedural teachers : area = b, c* d. It is simply to touch.
- 2022-07-26 00:51:29下载
- 积分:1
-
判断a^mba^n m,n=0的字符串
判断a^mba^n m,n=0的字符串- Judges a^mba^n m, the n=0 character string
- 2022-05-24 12:20:42下载
- 积分:1
-
目标代码生成,从四元式到汇编语言的翻译
目标代码生成,从四元式到汇编语言的翻译-object code generation, from four yuan to the compilation-language translation.
- 2022-08-12 11:59:41下载
- 积分:1
-
使用Java语言实现Small Basic语言解释器。包括两个主要的子系统:一个是表达式解释器,负责处理数字表达式;另一个是解释器,负责程序的实际执行。...
使用Java语言实现Small Basic语言解释器。包括两个主要的子系统:一个是表达式解释器,负责处理数字表达式;另一个是解释器,负责程序的实际执行。-use Java language Small Basic language interpreter. Including the two major subsystems : an expression interpreter is responsible for handling digital expression; Another interpreter, responsible for the actual implementation process.
- 2022-04-11 19:06:50下载
- 积分:1
-
一种小型的语言编译器
一个小型C语言编译器- A small C language compiler
- 2022-01-26 04:28:25下载
- 积分:1
-
-
- 2022-06-13 21:40:01下载
- 积分:1