public static boolean chooseVarargsMode(MethodCandidateInfo currentMethod,
                                          JavaResolveResult resolveResult) {
    return resolveResult instanceof MethodCandidateInfo && ((MethodCandidateInfo)resolveResult).isVarargs() ||
           currentMethod != null && currentMethod.isVarargs();
  }
public static boolean chooseVarargsMode(MethodCandidateInfo currentMethod,
                                          JavaResolveResult resolveResult)