Skip to content

Commit

Permalink
Ryan's feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
nbauernfeind committed Feb 8, 2024
1 parent 33053c1 commit 847aa4b
Showing 1 changed file with 3 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,6 @@
import io.deephaven.base.Pair;
import io.deephaven.base.verify.Assert;
import io.deephaven.configuration.Configuration;
import io.deephaven.engine.context.QueryScope;
import io.deephaven.engine.context.QueryScopeParam;
import io.deephaven.engine.table.impl.MatchPair;
import io.deephaven.engine.table.impl.ShiftedColumnsFactory;
Expand Down Expand Up @@ -337,7 +336,7 @@ public QueryLanguageParser(
// make sure the parser has no problem reparsing its own output and makes no changes to it.
final QueryLanguageParser validationQueryLanguageParser = new QueryLanguageParser(
printedSource, packageImports, classImports, staticImports, variables,
variableTypeArguments, possibleParams, false, false, pyCallableWrapperImplName);
variableTypeArguments, possibleParams, unboxArguments, false, pyCallableWrapperImplName);

final String reparsedSource = validationQueryLanguageParser.result.source;
Assert.equals(
Expand Down Expand Up @@ -2537,7 +2536,7 @@ private Optional<CastExpr> makeCastExpressionForPyCallable(Class<?> retType, Met
private Optional<Class<?>> pyCallableReturnType(@NotNull MethodCallExpr n) {
final PyCallableDetails pyCallableDetails = n.getData(QueryLanguageParserDataKeys.PY_CALLABLE_DETAILS);
final String pyMethodName = pyCallableDetails.pythonMethodName;
final QueryScopeParam<?> queryScopeParam = possibleParams.getOrDefault(pyMethodName, null);
final QueryScopeParam<?> queryScopeParam = possibleParams.get(pyMethodName);
if (queryScopeParam == null) {
return Optional.empty();
}
Expand Down Expand Up @@ -2633,7 +2632,7 @@ private void tryVectorizePythonCallable(@NotNull MethodCallExpr n,
// Note: "paramValueRaw" needs to be the *actual PyCallableWrapper* corresponding to the method.
// TODO: Support vectorization of instance methods of constant objects
// ^^ i.e., create a constant for `new PyCallableWrapperImpl(pyScopeObj.getAttribute("pyMethodName"))`
final QueryScopeParam<?> queryScopeParam = possibleParams.getOrDefault(pyMethodName, null);
final QueryScopeParam<?> queryScopeParam = possibleParams.get(pyMethodName);
if (queryScopeParam == null) {
throw new IllegalStateException("Resolved Python function name " + pyMethodName + " not found");
}
Expand Down

0 comments on commit 847aa4b

Please sign in to comment.