Skip to content

Commit 5d7a9d1

Browse files
author
Mark Perry
committed
Added first class cons_
1 parent 5df56fc commit 5d7a9d1

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

core/src/main/java/fj/data/List.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1383,6 +1383,10 @@ public List<A> f(final List<A> tail) {
13831383
};
13841384
}
13851385

1386+
public static <A> F2<A, List<A>, List<A>> cons_() {
1387+
return (a, listA) -> cons(a, listA);
1388+
}
1389+
13861390
/**
13871391
* Returns a function that prepends a value to the given list.
13881392
*

0 commit comments

Comments
 (0)