Nashorn supports calling FunctionalInterface interface objects to be treated like functions. This fails for java.util.Comparator objects: jjs> f = java.util.Comparator.reverseOrder() java.util.Collections$ReverseComparator@6283d8b8 jjs> f.compare(343, 55) -1 jjs> f(343, 55) <shell>:1 TypeError: java.util.Collections$ReverseComparator@6283d8b8 has no suc h function "equals"
|