http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53175
--- Comment #2 from Tobias Burnus <burnus at gcc dot gnu.org> 2012-05-02 17:15:33 UTC --- As I have not clearly mentioned it before, there exist the following workarounds: a) Make "dim" *not* PRIVATE. ("dim" can be marked as PROTECTED to avoid unwanted changes.) That might be easier for the real world code than concatenating files together. b) Put MODULE ENERGY_FUNCTION into the same file as all the callers of its functions. (For completeness.) b) Compile "MODULE ENERGY_FUNCTION" with -O0. c) Use GCC 4.7 and wait for the patch ;-)