mirror of https://github.com/apache/druid.git
Add explicit EOF and use assert instead of exception (#11041)
This commit is contained in:
parent
6789ed0a05
commit
43ea184b74
|
@ -15,6 +15,8 @@
|
||||||
|
|
||||||
grammar Expr;
|
grammar Expr;
|
||||||
|
|
||||||
|
start : expr EOF;
|
||||||
|
|
||||||
expr : NULL # null
|
expr : NULL # null
|
||||||
| ('-'|'!') expr # unaryOpExpr
|
| ('-'|'!') expr # unaryOpExpr
|
||||||
|<assoc=right> expr '^' expr # powOpExpr
|
|<assoc=right> expr '^' expr # powOpExpr
|
||||||
|
|
|
@ -36,7 +36,8 @@ public abstract class BottomUpTransform implements Function<Filtration, Filtrati
|
||||||
private DimFilter checkedProcess(final DimFilter filter)
|
private DimFilter checkedProcess(final DimFilter filter)
|
||||||
{
|
{
|
||||||
final DimFilter retVal = process(Preconditions.checkNotNull(filter, "filter"));
|
final DimFilter retVal = process(Preconditions.checkNotNull(filter, "filter"));
|
||||||
return Preconditions.checkNotNull(retVal, "process(filter) result in %s", getClass().getSimpleName());
|
assert retVal != null;
|
||||||
|
return retVal;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
Loading…
Reference in New Issue