Fix bug found with optimisation and -fhandle-exception while implementing

PIC support for GCC/arm.
This fix is untested on platforms other that the ARM and is only enabled
if GCC_27_ARM32_PIC_SUPPORT is defined.
This commit is contained in:
mark 1997-10-19 19:01:28 +00:00
parent 29500b20c0
commit df179fd1e4
1 changed files with 9 additions and 0 deletions

View File

@ -2469,7 +2469,16 @@ build_method_call (instance, name, parms, basetype_path, flags)
#if 1
/* Is it a synthesized method that needs to be synthesized? */
#ifdef GCC_27_ARM32_PIC_SUPPORT
/*
* This is a patch for a bug found when implementing arm32 PIC support
* that should be fixed in 2.8
* Fixes code generation problems with optimisation and -fhandle-exceptions
*/
if (DECL_ARTIFICIAL (function) && ! flag_no_inline && !flag_handle_exceptions
#else
if (DECL_ARTIFICIAL (function) && ! flag_no_inline
#endif
&& ! DECL_INITIAL (function)
/* Kludge: don't synthesize for default args. */
&& current_function_decl)