Skip to content

Commit

Permalink
Close #165 - Rename derived type classes - some of them have a naming…
Browse files Browse the repository at this point in the history
… conflict issue
  • Loading branch information
kevin-lee committed Dec 25, 2023
1 parent 7a3aceb commit 2ec7217
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import refined4s.{Coercible, RefinedCtor}
*/
trait instances {

inline given putNewtype[A, B](using coercible: Coercible[A, B], put: Put[B]): Put[A] =
inline given derivedPut[A, B](using coercible: Coercible[A, B], put: Put[B]): Put[A] =
put.contramap(coercible(_))

inline given derivedRefinedGet[A, B](using refinedCtor: RefinedCtor[B, A], getA: Get[A], showA: Show[A]): Get[B] =
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,5 @@ import refined4s.NewtypeBase
trait PureconfigNewtypeConfigReader[A: ConfigReader] {
self: NewtypeBase[A] =>

given derivedEncoder: ConfigReader[Type] = deriving[ConfigReader]
given derivedConfigReader: ConfigReader[Type] = deriving[ConfigReader]
}
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import refined4s.internal.typeTools.getTypeName
trait PureconfigRefinedConfigReader[A: ConfigReader] {
self: RefinedBase[A] =>

given derivedEncoder: ConfigReader[Type] = ConfigReader[A].emap { a =>
given derivedConfigReader: ConfigReader[Type] = ConfigReader[A].emap { a =>
from(a).left.map { err =>
val expectedType = getTypeName[Type]
UserValidationFailed(
Expand Down

0 comments on commit 2ec7217

Please sign in to comment.