This is an automated email from the ASF dual-hosted git repository.

ggregory pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-collections.git

commit ed01dd2d0e98c1c9c0614b53c3a4e97e3efc3535
Author: Gary Gregory <garydgreg...@gmail.com>
AuthorDate: Thu Jul 11 11:11:51 2024 -0400

    Migrate toward java.util.function
    
    - Package-private changes only
    - Maintains binary and source compatibility
---
 .../java/org/apache/commons/collections4/functors/FunctorUtils.java  | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git 
a/src/main/java/org/apache/commons/collections4/functors/FunctorUtils.java 
b/src/main/java/org/apache/commons/collections4/functors/FunctorUtils.java
index 93f4f7b2c..8a9f57700 100644
--- a/src/main/java/org/apache/commons/collections4/functors/FunctorUtils.java
+++ b/src/main/java/org/apache/commons/collections4/functors/FunctorUtils.java
@@ -22,7 +22,6 @@ import java.util.function.Consumer;
 import java.util.function.Function;
 
 import org.apache.commons.collections4.Predicate;
-import org.apache.commons.collections4.Transformer;
 
 /**
  * Internal utilities for functors.
@@ -60,8 +59,8 @@ final class FunctorUtils {
      * @return the coerced transformer.
      */
     @SuppressWarnings("unchecked")
-    static <I, O> Transformer<I, O> coerce(final Transformer<? super I, ? 
extends O> transformer) {
-        return (Transformer<I, O>) transformer;
+    static <R extends Function<I, O>, P extends Function<? super I, ? extends 
O>, I, O> R coerce(final P transformer) {
+        return (R) transformer;
     }
 
     /**

Reply via email to