http://gcc.gnu.org/bugzilla/show_bug.cgi?id=2316
--- Comment #20 from Marc Glisse <marc.glisse at normalesup dot org> 2011-08-30 00:20:07 UTC --- Created attachment 25134 --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=25134 remember linkage of a function type This is an extremely basic patch, that probably misses many things (and we'd want to have conversions between extern"C" and regular functions not to break too much code), but it can be useful to play with (it got at least 4 examples right :-) although it ICEs (assert) on some other code...). Obviously it has to be built with --disable-bootstrap since the gcc source code is far from extern"C"-clean, but it can also be used to help clean it ;-) Oh, and it won't build libstdc++ either, first because of functions in gthread that take &pthread_cancel and then because of the __stoa helper in ext/string_conversions.h (I didn't try to go further). Function type trees apparently leave at least 2 trees unused in tree_type_non_common so I reused one (minval), but since I only want one bit, there are probably better ways to store it.