Skip to content

Commit

Permalink
Removing private protection of Reader and Writer
Browse files Browse the repository at this point in the history
  • Loading branch information
Patrick Cunningham committed Apr 10, 2015
1 parent 0eb2baa commit edc5148
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/main/scala/com/redis/serialization/Format.scala
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import scala.language.implicitConversions


@implicitNotFound(msg = "Cannot find implicit Read or Format type class for ${A}")
private[redis] trait Reader[A] { self =>
trait Reader[A] { self =>
def fromByteString(in: ByteString): A

def map[B](f: A => B): Reader[B] =
Expand All @@ -16,7 +16,7 @@ private[redis] trait Reader[A] { self =>
}
}

private[redis] trait ReaderLowPriorityImplicits {
trait ReaderLowPriorityImplicits {
implicit object bypassingReader extends Reader[ByteString] {
def fromByteString(in: ByteString) = in
}
Expand All @@ -32,8 +32,8 @@ object Reader extends ReaderLowPriorityImplicits {


@implicitNotFound(msg = "Cannot find implicit Write or Format type class for ${A}")
private[redis] trait Writer[A] { self =>
private[redis] def toByteString(in: A): ByteString
trait Writer[A] { self =>
def toByteString(in: A): ByteString

def contramap[B](f: B => A): Writer[B] =
new Writer[B] {
Expand All @@ -42,7 +42,7 @@ private[redis] trait Writer[A] { self =>
}
}

private[redis] trait WriterLowPriorityImplicits {
trait WriterLowPriorityImplicits {
implicit object bypassingWriter extends Writer[ByteString] {
def toByteString(in: ByteString) = in
}
Expand Down

1 comment on commit edc5148

@debasishg
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am +1 based on comments by @guersam in debasishg#109 (comment) .. will merge if no one has any objection.

Please sign in to comment.