Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit4c91720

Browse files
committed
Lens.Simple#both logically allows differently focused lenses
1 parentc87b7dd commit4c91720

File tree

1 file changed

+3
-2
lines changed
  • src/main/java/com/jnape/palatable/lambda/lens

1 file changed

+3
-2
lines changed

‎src/main/java/com/jnape/palatable/lambda/lens/Lens.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -374,10 +374,11 @@ static <S, A> Simple<S, A> adapt(Lens<S, S, A, A> lens) {
374374
* @param f the first lens
375375
* @param g the second lens
376376
* @param <S> both lens larger values
377-
* @param <A> both lens smaller values
377+
* @param <A> lens f smaller values
378+
* @param <B> lens g smaller values
378379
* @return the dual-focus simple lens
379380
*/
380-
static <S,A>Lens.Simple<S,Tuple2<A,A>>both(Lens<S,S,A,A>f,Lens<S,S,A,A>g) {
381+
static <S,A,B>Lens.Simple<S,Tuple2<A,B>>both(Lens<S,S,A,A>f,Lens<S,S,B,B>g) {
381382
returnadapt(Lens.both(f,g));
382383
}
383384

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp