Unverified Commit 7f0074a6 authored by Valentin Clement's avatar Valentin Clement
Browse files

[flang] Avoid double finalization when intrinsic assignment is done in the runtime

genRecordAssignment is emitting code to call Assign in the runtime for some cases.
In these cases, the finalization is done by the runtime so we do not need to do it in
a separate cal to avoid multiple finalization..
Also refactor the code in Bridge so the actual finalization of allocatable
is done before any reallocation. We might need to push this into ReallocIfNeeded.
It is not clear if the allocatable lhs needs to be finalized in any cases or only if it is
reallocated.

Reviewed By: jeanPerier

Differential Revision: https://reviews.llvm.org/D143186
parent 6e1ebb91
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment