In reply to TC_2017:
The reduction methods are always evaluated in the context of each element type, or the type of the ‘with’ clause. Even though when in a constraint we say that the reduction operator gets unrolled, it still has to evaluate the same way as if it was not in a constraint. So none of the context outside the sum() method effects the expression inside.