Fix incorrect results from cumulative_sum and cumulative_prod with dtype=bool
#2018
+45
−11
cumulative_sum and cumulative_prod with dtype=bool
#2018