Make sizeof on indeterminate arrays an error.

This commit is contained in:
David Anderson
2014-11-08 02:07:43 -08:00
parent 6d507ceb27
commit f08e53f5d2
4 changed files with 14 additions and 4 deletions
@@ -0,0 +1,8 @@
native print(const char[] str);
native printnum(num);
public main()
{
char[] egg = "!\n";
return sizeof(egg);
}
@@ -0,0 +1 @@
(7) : error 163: indeterminate array size in "sizeof" expression (symbol "egg")