diff options
Diffstat (limited to 'gcc/fortran')
-rw-r--r-- | gcc/fortran/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/fortran/dump-parse-tree.c | 21 |
2 files changed, 26 insertions, 0 deletions
diff --git a/gcc/fortran/ChangeLog b/gcc/fortran/ChangeLog index 409992e..a122e70 100644 --- a/gcc/fortran/ChangeLog +++ b/gcc/fortran/ChangeLog @@ -1,3 +1,8 @@ +2004-05-22 Pau Brook <paul@codesourcery.com> + + * dump-parse-tree.c (gfc_show_equiv): New function. + (gfc_show_namespace): Use it. + 2004-05-22 Victor Leikehman <lei@haifasphere.co.il> PR fortran/13249 diff --git a/gcc/fortran/dump-parse-tree.c b/gcc/fortran/dump-parse-tree.c index 5f1db22..64e4a81 100644 --- a/gcc/fortran/dump-parse-tree.c +++ b/gcc/fortran/dump-parse-tree.c @@ -1384,6 +1384,23 @@ gfc_show_code_node (int level, gfc_code * c) } +/* Show and equivalence chain. */ + +static void +gfc_show_equiv (gfc_equiv *eq) +{ + show_indent (); + gfc_status ("Equivalence: "); + while (eq) + { + gfc_show_expr (eq->expr); + eq = eq->eq; + if (eq) + gfc_status (", "); + } +} + + /* Show a freakin' whole namespace. */ void @@ -1392,6 +1409,7 @@ gfc_show_namespace (gfc_namespace * ns) gfc_interface *intr; gfc_namespace *save; gfc_intrinsic_op op; + gfc_equiv *eq; int i; save = gfc_current_ns; @@ -1450,6 +1468,9 @@ gfc_show_namespace (gfc_namespace * ns) gfc_traverse_user_op (ns, show_uop); } } + + for (eq = ns->equiv; eq; eq = eq->next) + gfc_show_equiv (eq); gfc_status_char ('\n'); gfc_status_char ('\n'); |