Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@

import com.google.common.collect.BoundType;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableMap;
import com.google.common.collect.Lists;
import com.google.common.collect.Maps;
import com.google.common.collect.Range;
Expand Down Expand Up @@ -311,17 +310,17 @@ public Map<Expression, MinMaxValue> visitDiscreteValue(DiscreteValue value, Void

@Override
public Map<Expression, MinMaxValue> visitNotDiscreteValue(NotDiscreteValue value, Void context) {
return ImmutableMap.of();
return Maps.newHashMap();
}

@Override
public Map<Expression, MinMaxValue> visitIsNullValue(IsNullValue value, Void context) {
return ImmutableMap.of();
return Maps.newHashMap();
}

@Override
public Map<Expression, MinMaxValue> visitIsNotNullValue(IsNotNullValue value, Void context) {
return ImmutableMap.of();
return Maps.newHashMap();
}

@Override
Expand Down Expand Up @@ -412,6 +411,6 @@ public Map<Expression, MinMaxValue> visitCompoundValue(CompoundValue valueDesc,

@Override
public Map<Expression, MinMaxValue> visitUnknownValue(UnknownValue valueDesc, Void context) {
return ImmutableMap.of();
return Maps.newHashMap();
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -328,6 +328,7 @@ void testAddMinMax() {
)
));

assertRewriteAfterTypeCoercion("5 * 100 >= 10 and 5 * 100 <= 5", "5 * 100 >= 10 and 5 * 100 <= 5");
assertRewriteAfterTypeCoercion("TA >= 10", "TA >= 10");
assertRewriteAfterTypeCoercion("TA between 10 and 20", "TA >= 10 and TA <= 20");
assertRewriteAfterTypeCoercion("TA between 10 and 20 or TA >= 30",
Expand Down
Loading