This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/80477] [OOP] Polymorphic function result generates memory leak
- From: "janus at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Wed, 26 Apr 2017 10:59:15 +0000
- Subject: [Bug fortran/80477] [OOP] Polymorphic function result generates memory leak
- Auto-submitted: auto-generated
- References: <bug-80477-4@http.gcc.gnu.org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80477
--- Comment #14 from janus at gcc dot gnu.org ---
(In reply to paul.richard.thomas@gmail.com from comment #11)
> I'll take a look tonight. I believe, without the source in front of me, that
>
> s/gfc_add_expr_to_block (&post, gfc_call_free
> (tmp));/gfc_add_expr_to_block (&se->post, gfc_call_free (tmp));
Thanks for the suggestion, Paul. I just tried it, but unfortunately it makes
exactly zero difference, probably because gfc_conv_procedure_call has at the
very end:
gfc_add_block_to_block (&se->post, &post);