http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58084
--- Comment #8 from Richard Biener <rguenth at gcc dot gnu.org> --- If a type is refered to by two functions it is by definition not local. But as it references a local entity it is local. Note that you seem to have put the type local for RESULT_DECL but still have the global type used for the function type that hangs off the function decl. That type also refers to the PARM_DECLs which are local, too , now AFAIK. So, you cannot really make PARM_DECLs or RESULT_DECL local.