aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-cfg.c
diff options
context:
space:
mode:
authorEric Botcazou <ebotcazou@adacore.com>2007-02-19 19:26:16 +0000
committerEric Botcazou <ebotcazou@gcc.gnu.org>2007-02-19 19:26:16 +0000
commit459ffad3fd0486d686a14f45f59167b1e08c240a (patch)
tree0bf1a7136b564b33aa579f826b8ad7fbae144356 /gcc/tree-cfg.c
parentdf10ee2a5a023ec7f9edf5961bec74b4aa475780 (diff)
downloadgcc-459ffad3fd0486d686a14f45f59167b1e08c240a.zip
gcc-459ffad3fd0486d686a14f45f59167b1e08c240a.tar.gz
gcc-459ffad3fd0486d686a14f45f59167b1e08c240a.tar.bz2
tree-cfg.c (dump_function_to_file): Be prepared for functions without DECL_STRUCT_FUNCTION initialized.
* tree-cfg.c (dump_function_to_file): Be prepared for functions without DECL_STRUCT_FUNCTION initialized. From-SVN: r122135
Diffstat (limited to 'gcc/tree-cfg.c')
-rw-r--r--gcc/tree-cfg.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/gcc/tree-cfg.c b/gcc/tree-cfg.c
index a99f3c7..593dc0d 100644
--- a/gcc/tree-cfg.c
+++ b/gcc/tree-cfg.c
@@ -4998,6 +4998,7 @@ void
dump_function_to_file (tree fn, FILE *file, int flags)
{
tree arg, vars, var;
+ struct function *dsf;
bool ignore_topmost_bind = false, any_var = false;
basic_block bb;
tree chain;
@@ -5015,8 +5016,10 @@ dump_function_to_file (tree fn, FILE *file, int flags)
}
fprintf (file, ")\n");
- if (flags & TDF_DETAILS)
- dump_eh_tree (file, DECL_STRUCT_FUNCTION (fn));
+ dsf = DECL_STRUCT_FUNCTION (fn);
+ if (dsf && (flags & TDF_DETAILS))
+ dump_eh_tree (file, dsf);
+
if (flags & TDF_RAW)
{
dump_node (fn, TDF_SLIM | flags, file);