We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4de44e3 commit 5182efcCopy full SHA for 5182efc
tests/run/i7788.scala
@@ -8,7 +8,7 @@ given showEither[A,B]: (sA: Show[A]) => Show[B] => Show[Either[A,B]] =
8
_.fold(a => s"Left(${summon[Show[A]].show(a)})", b => s"Right(${summon[Show[B]].show(b)})")
9
given [A,B]: (sA: Show[A]) => (sB: Show[B]) => Show[(A,B)] = (a,b) => s"(${sA.show(a)}), ${sB.show(b)})"
10
11
-@main def ShowDemo =
+@main def Test =
12
println(summon[Show[(Int, String)]].show(0 -> "hello"))
13
println(summon[Show[Either[Int, String]]].show(Left(-1)))
14
println(summon[Show[Either[Int, String]]].show(Right("success message")))
0 commit comments