From f788ca8980d123476d820104aa0e171df05bfc3d Mon Sep 17 00:00:00 2001 From: Dave Korn Date: Wed, 10 Jun 2009 12:34:10 +0000 Subject: [PATCH] trans-decl.c (create_main_function): Don't build main decl twice. 2009-06-10 Dave Korn * trans-decl.c (create_main_function): Don't build main decl twice. From-SVN: r148344 --- gcc/fortran/ChangeLog | 4 ++++ gcc/fortran/trans-decl.c | 1 - 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/gcc/fortran/ChangeLog b/gcc/fortran/ChangeLog index 5326973b39c..cb5312066a3 100644 --- a/gcc/fortran/ChangeLog +++ b/gcc/fortran/ChangeLog @@ -1,3 +1,7 @@ +2009-06-10 Dave Korn + + * trans-decl.c (create_main_function): Don't build main decl twice. + 2009-06-09 Tobias Burnus * trans-decl.c (gfc_generate_function_code): Use gfc_option.rtcheck diff --git a/gcc/fortran/trans-decl.c b/gcc/fortran/trans-decl.c index 33d459ade2a..a491c0b1f21 100644 --- a/gcc/fortran/trans-decl.c +++ b/gcc/fortran/trans-decl.c @@ -3876,7 +3876,6 @@ create_main_function (tree fndecl) NULL_TREE); main_identifier_node = get_identifier ("main"); ftn_main = build_decl (FUNCTION_DECL, main_identifier_node, tmp); - ftn_main = build_decl (FUNCTION_DECL, get_identifier ("main"), tmp); DECL_EXTERNAL (ftn_main) = 0; TREE_PUBLIC (ftn_main) = 1; TREE_STATIC (ftn_main) = 1;