[SPARK-2730][SQL] When retrieving a value from a Map, GetItem evaluates key twice

JIRA: https://issues.apache.org/jira/browse/SPARK-2730