[Ada] Avoid redundant checks for empty lists
authorPiotr Trojanek <trojanek@adacore.com>
Thu, 6 Jan 2022 18:14:33 +0000 (19:14 +0100)
committerPierre-Marie de Rodat <derodat@adacore.com>
Tue, 11 Jan 2022 13:24:49 +0000 (13:24 +0000)
commit9d4a5ddc7b124f201d7c6746e07b0ad98be5f702
tree7ae84ed64958d7871182982f53b714dd64498503
parentc441162d56974eb557f2ed3cab25c6107411ac62
[Ada] Avoid redundant checks for empty lists

gcc/ada/

* exp_ch4.adb (Expand_N_Expression_With_Actions): Avoid
redundant check.
* exp_ch5.adb (Expand_N_If_Statement): Likewise.
* exp_ch7.adb (Process_Declarations): Likewise.
* sem_elab.adb (Freeze_Node_Location): Likewise.
* exp_util.adb (Insert_Actions): Likewise.
(Is_OK_PF_Pragma): Likewise.
(Requires_Cleanup_Actions): Remove early exit; ordinary
processing path will similarly do nothing.
gcc/ada/exp_ch4.adb
gcc/ada/exp_ch5.adb
gcc/ada/exp_ch7.adb
gcc/ada/exp_util.adb
gcc/ada/sem_elab.adb