On Tue, Jul 25, 2017 at 3:30 PM, Eric Botcazou <ebotca...@adacore.com> wrote: >> Eric, any comments? > > No objection for the build2_stat hunk, I think it's in keeping with the Ada > semantics. But the tree_could_trap_p hunk is certainly an abomination... > >> We could also avoid tree_could_trap_p by special-casing only >> *_DIV_EXPR and *_MOD_EXPR >> with integer zero 2nd operand explicitely in build2 given there's no >> "constant" value for this. That is, >> for FP 1./0. is NaN (a "constant" value) even if the operation might trap. > > Yes, that would be faster & simpler and avoids the abomination.
Ok, then let's go with that slightly uglier but less abominal variant ;) Thanks, Richard. > -- > Eric Botcazou