master
tinysnail 3 years ago
parent 54b2897aba
commit 213c653206

@ -65,12 +65,8 @@ SysYCompiler test.sy -emit-ir -o test.ll
选做部分验收方式为线下验收,你需要在线下检查时提供对应代码通过助教给出的选做部分测试样例,并且讲解你的代码
选做部分说明如下:
- H班:
- 多维数组
- 网安班:
- 多维数组
- 将一维数组指针作为参数
- 逻辑运算(\&\&, \|\|, \!), 重点考察短路计算
### 4.1 多维数组
@ -84,10 +80,6 @@ SysYCompiler test.sy -emit-ir -o test.ll
`int a[5][2] = {1,{2,3},{4},{5,6,7}}`
`int a[5][2] = {{1,0},{2,3},{4,0},{5,6},{7,0}}`
### 4.2 数组指针参数 & 逻辑运算
目前给出的SysY IR接口支持数组指针参数和逻辑运算的短路计算因此你不需要修改接口
注意`pointer`和`array`的区别以及文法中`&&`和`||`的优先级
## 5 备注

Loading…
Cancel
Save