http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47638
Summary: sanity check error message is wrong in expand_one_var
Product: gcc
Version: 4.6.0
Status: UNCONFIRMED
Severity: trivial
Priority: P3
Component: middle-end
AssignedTo: [email protected]
ReportedBy: [email protected]
in cfgexpand.c expand_one_var can give an error message like:
"error: size of variable ‘var’ is too large"
which is very wrong and misleading if DECL_SIZE(var) is actually =0
I modified the line like this:
error ("size of variable %q+D is too large, size: %i", var,
DECL_SIZE_UNIT(var));
and got:
error: size of variable ‘var’ is too large, size: 0
DECL_SIZE(var) = 0 can happen when the type layout is missing.
the fix is obvious, we need another error message for this case.