This is an automated email from the ASF dual-hosted git repository. erans pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/commons-math.git
commit 286ff6ad392028007028ee5369b8978524428940 Author: Gilles Sadowski <gillese...@gmail.com> AuthorDate: Wed Jul 14 13:32:09 2021 +0200 Use method reference (suggested by "sonarcloud"). --- .../math4/legacy/optim/nonlinear/scalar/noderiv/SimplexOptimizer.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/commons-math-legacy/src/main/java/org/apache/commons/math4/legacy/optim/nonlinear/scalar/noderiv/SimplexOptimizer.java b/commons-math-legacy/src/main/java/org/apache/commons/math4/legacy/optim/nonlinear/scalar/noderiv/SimplexOptimizer.java index 81a04d6..60af50d 100644 --- a/commons-math-legacy/src/main/java/org/apache/commons/math4/legacy/optim/nonlinear/scalar/noderiv/SimplexOptimizer.java +++ b/commons-math-legacy/src/main/java/org/apache/commons/math4/legacy/optim/nonlinear/scalar/noderiv/SimplexOptimizer.java @@ -108,7 +108,7 @@ public class SimplexOptimizer extends MultivariateOptimizer { // Indirect call to "computeObjectiveValue" in order to update the // evaluations counter. - final MultivariateFunction evalFunc = p -> computeObjectiveValue(p); + final MultivariateFunction evalFunc = this::computeObjectiveValue; final boolean isMinim = getGoalType() == GoalType.MINIMIZE; final Comparator<PointValuePair> comparator = (o1, o2) -> {