[Ada] Deep copy operands of membership operations for unnesting
authorEd Schonberg <schonberg@adacore.com>
Mon, 16 Jul 2018 14:12:13 +0000 (14:12 +0000)
committerPierre-Marie de Rodat <pmderodat@gcc.gnu.org>
Mon, 16 Jul 2018 14:12:13 +0000 (14:12 +0000)
commitafe9c53918d14a5ef8807ea4284512dd94e4c15d
tree68e9262e2bd4131165245008976986e2eb5dab70
parent4dd2ed1495378681b58c2e7ff5c1cc5511882a2d
[Ada] Deep copy operands of membership operations for unnesting

2018-07-16  Ed Schonberg  <schonberg@adacore.com>

gcc/ada/

* exp_ch4.adb (Expand_Set_Membership): Use New_Copy_Tree to perform a
deep copy of the left operand when building each conjuct of the
expanded membership operation, to avoid sharing nodes between them.
This sharing interferes with the unnesting machinery and is generally
undesirable.

From-SVN: r262727
gcc/ada/ChangeLog
gcc/ada/exp_ch4.adb