所属分类:
编译器/解释器
开发工具:Visual C++
文件大小:6KB
下载次数:55
上传日期:2005-06-10 10:09:31
说明: C_minus语言的BNF语法定义 程序由声明的列表(或序列)组成,声明可以是函数或变量声明,顺序是任意的。至少必须有一个声明。接下来是语义限制(这些在C中不会出现)。所有的变量和函数在使用前必须声明(这避免了向后backpatching引用)。程序中最后的声明必须是一个函数声明,名字为main。注意,C-缺乏原型,因此声明和定义之间没有区别(像C一样)。
(C_minus BNF language syntax definition of procedures from the list of statement (or sequence), with a statement can be variable or function statement, the order is arbitrary. There must be at least one statement. Next is the semantic constraints (these will not arise C). All the variables and functions to be used in the statement (which avoids the use Backpatching backwards). Procedures must be the last statement is a function declaration, the name of the main. Attention C- lack of a prototype, and the definition of a statement is no difference between (the same as C).)