[
https://issues.apache.org/jira/browse/FLINK-4609?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15480437#comment-15480437
]
ASF GitHub Bot commented on FLINK-4609:
---------------------------------------
Github user zentol commented on a diff in the pull request:
https://github.com/apache/flink/pull/2490#discussion_r78283727
--- Diff:
flink-java/src/main/java/org/apache/flink/api/java/operators/CrossOperator.java
---
@@ -133,10 +133,6 @@ public DefaultCross(DataSet<I1> input1, DataSet<I2>
input2, CrossHint hint, Stri
new TupleTypeInfo<Tuple2<I1,
I2>>(input1.getType(), input2.getType()),
hint, defaultName);
- if (input1 == null || input2 == null) {
- throw new NullPointerException();
- }
-
--- End diff --
yes, but if you used the preconditions check you could supply a useful
error message, for example stating which input was actually null.
> Remove redundant check for null in CrossOperator
> ------------------------------------------------
>
> Key: FLINK-4609
> URL: https://issues.apache.org/jira/browse/FLINK-4609
> Project: Flink
> Issue Type: Bug
> Components: Java API
> Affects Versions: 1.1.2
> Reporter: Alexander Pivovarov
> Priority: Trivial
>
> CrossOperator checks input1 and input2 for null after they were dereferenced
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)