From 700b62ccf29e12b68029883b5c1e69f151c4e512 Mon Sep 17 00:00:00 2001 From: Thomas Koenig Date: Sat, 13 Jan 2018 13:23:31 +0000 Subject: [PATCH] re PR fortran/83803 (Using -fc-prototypes on modules with empty dummy arg lists does not close paren.) 2018-01-13 Thomas Koenig PR fortran/83803 * dump-parse-tree.c (write_proc): Always emit closing parenthesis for functions. From-SVN: r256606 --- gcc/fortran/ChangeLog | 7 +++++++ gcc/fortran/dump-parse-tree.c | 5 +++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/gcc/fortran/ChangeLog b/gcc/fortran/ChangeLog index f4289343cc1..8f32e07babf 100644 --- a/gcc/fortran/ChangeLog +++ b/gcc/fortran/ChangeLog @@ -1,3 +1,10 @@ +2018-01-13 Thomas Koenig + + + PR fortran/83803 + * dump-parse-tree.c (write_proc): Always emit closing parenthesis + for functions. + 2018-01-10 Steven G. Kargl PR fortran/82367 diff --git a/gcc/fortran/dump-parse-tree.c b/gcc/fortran/dump-parse-tree.c index c2c9b63c880..5ead416e523 100644 --- a/gcc/fortran/dump-parse-tree.c +++ b/gcc/fortran/dump-parse-tree.c @@ -3194,9 +3194,10 @@ write_proc (gfc_symbol *sym) if (rok == T_WARN) fputs(" /* WARNING: non-interoperable KIND */ ", dumpfile); - fputs (f->next ? ", " : ")", dumpfile); + if (f->next) + fputs(", ", dumpfile); } - fputs (";\n", dumpfile); + fputs (");\n", dumpfile); } -- 2.30.2