He-Pin commented on code in PR #1026:
URL: https://github.com/apache/incubator-pekko/pull/1026#discussion_r1462737061


##########
stream/src/main/scala/org/apache/pekko/stream/impl/fusing/Ops.scala:
##########
@@ -348,10 +350,11 @@ private[stream] object Collect {
       override def onPush(): Unit = push(out, grab(in))
       import Collect.NotApplied
 
+      @nowarn("msg=Any")
       override def onUpstreamFailure(ex: Throwable): Unit = f.applyOrElse(ex, 
NotApplied) match {
-        case NotApplied   => super.onUpstreamFailure(ex)
-        case t: Throwable => super.onUpstreamFailure(t)
-        case _            => throw new IllegalStateException() // won't 
happen, compiler exhaustiveness check pleaser
+        case _: NotApplied.type => super.onUpstreamFailure(ex)
+        case t: Throwable       => super.onUpstreamFailure(t)
+        case _                  => throw new IllegalStateException() // won't 
happen, compiler exhaustiveness check pleaser

Review Comment:
   It's better which cover the error case. @mdedetrich 



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to