[SPARK-4593] [SQL] return null when divider is 0 of Double type

SELECT max(1/0) FROM src
would return a very large number, which is obviously not right.
For hive-0.12, hive would return `Infinity` for 1/0, while for hive-0.13.1, it is `NULL` for 1/0.
I think it is better to keep our behavior with newer Hive version.
This PR ensures that when the divider is 0, the result of expression should be NULL, same with hive-0.13.1
I'm wondering we should check equality between the evaluated right value and zero here because evaluating `right.eval(input)` happens twice, here and in `f2` or `i2`.
Should be at around `_.div(_,  _)` or `_.quot(_, _)`?