cgraphunit.c (cgraph_finalize_unit): Set current_function_decl before calling tree_in...
authorJan Hubicka <jh@suse.cz>
Wed, 2 Jul 2003 06:14:50 +0000 (08:14 +0200)
committerJan Hubicka <hubicka@gcc.gnu.org>
Wed, 2 Jul 2003 06:14:50 +0000 (06:14 +0000)
* cgraphunit.c (cgraph_finalize_unit): Set current_function_decl
before calling tree_inlinable_function_p.

From-SVN: r68819

gcc/ChangeLog
gcc/cgraphunit.c

index 537735db5457124a11179ee0f6e142d721da917c..0b7a46145c4ca9941ed1a2641080b01ccc4c11f7 100644 (file)
@@ -1,3 +1,8 @@
+Wed Jul  2 08:12:36 CEST 2003  Jan Hubicka  <jh@suse.cz>
+
+       * cgraphunit.c (cgraph_finalize_unit): Set current_function_decl
+       before calling tree_inlinable_function_p.
+
 2003-07-02  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
 
        * fixinc/inclhack.def (irix_stdio_va_list): Apply to IRIX 6.5
index f9e2ff6c2f8268c7229fcf59bcf6303436143619..a904eb544eaf598d7ffc18cceee669a92e267dd0 100644 (file)
@@ -165,6 +165,7 @@ cgraph_finalize_compilation_unit ()
       if (lang_hooks.callgraph.lower_function)
        (*lang_hooks.callgraph.lower_function) (decl);
 
+      current_function_decl = node->decl;
       if (!node->needed && !DECL_COMDAT (node->decl))
        node->local.can_inline_once = tree_inlinable_function_p (decl, 1);
       else