code: public static PyExpr genPyNotNullCheck(PyExpr pyExpr) {
      ImmutableList<PyExpr> exprs = ImmutableList.of(pyExpr, new PyExpr("None", Integer.MAX_VALUE));
      // Note: is/is not is Python's identity comparison. It's used for None checks for performance.
      String conditionalExpr = genExprWithNewToken(Operator.NOT_EQUAL, exprs, "is not");
      return new PyExpr(conditionalExpr, PyExprUtils.pyPrecedenceForOperator(Operator.NOT_EQUAL));
    }
docs: Generates a Python not null (None) check expression for the given {@link PyExpr}.