Issue #26: Detect empty array constructors, require at least on operand.

This commit is contained in:
John Kessenich
2015-07-21 14:35:39 -06:00
parent 222457054e
commit efb8461722
3 changed files with 12 additions and 2 deletions

View File

@@ -22,7 +22,9 @@ ERROR: 0:79: '' : array size required
ERROR: 0:84: 'return' : type does not match, or is not convertible to, the function's return type
ERROR: 0:93: 'length' : array must be declared with a size before using this method
ERROR: 0:101: '[' : array index out of range '5'
ERROR: 23 compilation errors. No code generated.
ERROR: 0:104: 'constructor' : array constructor must have at least one argument
ERROR: 0:104: '=' : cannot convert from 'const float' to 'global implicitly-sized array of int'
ERROR: 25 compilation errors. No code generated.
Shader version: 130
@@ -264,6 +266,7 @@ ERROR: node is still EOpNull!
0:? 'guns' (global implicitly-sized array of 3-component vector of float)
0:? 'f' (global float)
0:? 'gUnusedUnsized' (global implicitly-sized array of float)
0:? 'i' (global implicitly-sized array of int)
Linked fragment stage:
@@ -508,4 +511,5 @@ ERROR: node is still EOpNull!
0:? 'guns' (global 8-element array of 3-component vector of float)
0:? 'f' (global float)
0:? 'gUnusedUnsized' (global 1-element array of float)
0:? 'i' (global 1-element array of int)