(variable_size): Better error for div by 0 in size.

From-SVN: r3722
This commit is contained in:
Richard Stallman 1993-03-12 23:17:41 +00:00
parent c841050eed
commit 80f9c711d9
1 changed files with 5 additions and 1 deletions

View File

@ -81,7 +81,11 @@ variable_size (size)
if (global_bindings_p ())
{
error ("variable-size type declared outside of any function");
if (TREE_CONSTANT (size))
error ("type size can't be explicitly evaluated");
else
error ("variable-size type declared outside of any function");
return size_int (1);
}