-
Notifications
You must be signed in to change notification settings - Fork 79
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
9 changed files
with
42 additions
and
0 deletions.
There are no files selected for viewing
3 changes: 3 additions & 0 deletions
3
core/shared/src/main/scala-2/org/atnos/eff/AugmentCompanion.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
package org.atnos.eff | ||
|
||
abstract class AugmentCompanion { self: Augment.type => } |
3 changes: 3 additions & 0 deletions
3
core/shared/src/main/scala-2/org/atnos/eff/TranslateCompanion.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
package org.atnos.eff | ||
|
||
abstract class TranslateCompanion { self: Translate.type => } |
3 changes: 3 additions & 0 deletions
3
core/shared/src/main/scala-2/org/atnos/eff/WriteCompanion.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
package org.atnos.eff | ||
|
||
abstract class WriteCompanion { self: Write.type => } |
9 changes: 9 additions & 0 deletions
9
core/shared/src/main/scala-3/org/atnos/eff/AugmentCompanion.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
package org.atnos.eff | ||
|
||
abstract class AugmentCompanion { self: Augment.type => | ||
final def lift[T[_], O[_]](f: [X] => T[X] => O[Unit]): Augment[T, O] = | ||
new Augment[T, O] { | ||
override def apply[Y](tx: T[Y]): O[Unit] = | ||
f[Y](tx) | ||
} | ||
} |
9 changes: 9 additions & 0 deletions
9
core/shared/src/main/scala-3/org/atnos/eff/TranslateCompanion.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
package org.atnos.eff | ||
|
||
abstract class TranslateCompanion { self: Translate.type => | ||
final def lift[T[_], U](f: [X] => T[X] => Eff[U, X]): Translate[T, U] = | ||
new Translate[T, U] { | ||
override def apply[Y](kv: T[Y]): Eff[U, Y] = | ||
f[Y](kv) | ||
} | ||
} |
9 changes: 9 additions & 0 deletions
9
core/shared/src/main/scala-3/org/atnos/eff/WriteCompanion.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
package org.atnos.eff | ||
|
||
abstract class WriteCompanion { self: Write.type => | ||
final def lift[T[_], O](f: [X] => T[X] => O): Write[T, O] = | ||
new Write[T, O] { | ||
override def apply[Y](tx: T[Y]): O = | ||
f[Y](tx) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,3 +3,5 @@ package org.atnos.eff | |
trait Write[T[_], O] { | ||
def apply[X](tx: T[X]): O | ||
} | ||
|
||
object Write extends WriteCompanion |