aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/gcc-interface/utils.cc
diff options
context:
space:
mode:
authorEric Botcazou <ebotcazou@adacore.com>2024-12-10 10:24:47 +0100
committerMarc Poulhiès <dkm@gcc.gnu.org>2025-01-07 13:33:35 +0100
commit980415be73a4c762302eeba0813e435116bccc70 (patch)
tree85d3f57c601dfca3b5d6f633182b5ca15173e34a /gcc/ada/gcc-interface/utils.cc
parenta80bb3525e6e3596e025399691dc7789268fffe2 (diff)
downloadgcc-980415be73a4c762302eeba0813e435116bccc70.zip
gcc-980415be73a4c762302eeba0813e435116bccc70.tar.gz
gcc-980415be73a4c762302eeba0813e435116bccc70.tar.bz2
ada: Do not create temporaries for initialization statements
Assignment statements marked with the No_Ctrl_Actions or No_Finalize_Actions flag are initialization statements and, therefore, no temporaries are needed to hold the value of the right-hand side for them. gcc/ada/ChangeLog: * gcc-interface/trans.cc (Call_to_gnu): Always use the return slot optimization if the parent node is an initialization statement. (gnat_to_gnu) <N_Assignment_Statement>: Build an INIT_EXPR instead of a MODIFY_EXPR if this is an initialization statement.
Diffstat (limited to 'gcc/ada/gcc-interface/utils.cc')
0 files changed, 0 insertions, 0 deletions