Fortran Coder

标题: Subscript #1 of the array PRM has value 13 which is greater than the upper bo... [打印本页]

作者: liguanpeng    时间: 2014-10-8 20:37
标题: Subscript #1 of the array PRM has value 13 which is greater than the upper bo...
用别人的cvf下代码在ivf建了个project 编译出现compilation aborted (code 1) 什么意思?

另外我定义了PRM(16)  为什么我用PRM(13) PRM(14) PRM(15)时出现
error #5560 : Subscript #1 of the array PRM has value 13 which is greater than the upper bound of 12






2.jpg (169.87 KB, 下载次数: 357)

2

2

作者: 楚香饭    时间: 2014-10-8 21:25
compilation aborted (code 1) 没有意义,重点在于:

Subscript #1 of the array PRM has value 13 which is greater than the upper bound of 12

这是告诉你数组越界,你的 PRM 定义为 12 个元素,但你引用了第 13 个。

数组越界是常规错误。你可以参考 http://error.w.fcode.cn


作者: liguanpeng    时间: 2014-10-8 21:47
楚香饭 发表于 2014-10-8 21:25
compilation aborted (code 1) 没有意义,重点在于:

Subscript #1 of the array PRM has value 13 which ...

谢谢!确实是数组溢出
源程序定义了2次PRM
第二次定义的个数不够




欢迎光临 Fortran Coder (http://bbs.fcode.cn/) Powered by Discuz! X3.2