@@ -24,7 +24,6 @@ import scala.annotation.tailrec
2424import scala .collection .mutable
2525import scala .concurrent .{BlockContext , CanAwait }
2626import scala .concurrent .duration .{Duration , FiniteDuration }
27- import scala .util .control .NonFatal
2827
2928import java .lang .Long .MIN_VALUE
3029import java .util .concurrent .{ArrayBlockingQueue , ThreadLocalRandom }
@@ -376,7 +375,7 @@ private[effect] final class WorkerThread[P <: AnyRef](
376375 pool.notifyParked(rnd)
377376 try fiber.run()
378377 catch {
379- case t if NonFatal (t) => pool.reportFailure(t)
378+ case t if UnsafeNonFatal (t) => pool.reportFailure(t)
380379 case t : Throwable => IOFiber .onFatalFailure(t)
381380 }
382381
@@ -393,7 +392,7 @@ private[effect] final class WorkerThread[P <: AnyRef](
393392 // The dequeued element is a single fiber. Execute it immediately.
394393 try fiber.run()
395394 catch {
396- case t if NonFatal (t) => pool.reportFailure(t)
395+ case t if UnsafeNonFatal (t) => pool.reportFailure(t)
397396 case t : Throwable => IOFiber .onFatalFailure(t)
398397 }
399398
@@ -443,7 +442,7 @@ private[effect] final class WorkerThread[P <: AnyRef](
443442 // Run the stolen fiber.
444443 try fiber.run()
445444 catch {
446- case t if NonFatal (t) => pool.reportFailure(t)
445+ case t if UnsafeNonFatal (t) => pool.reportFailure(t)
447446 case t : Throwable => IOFiber .onFatalFailure(t)
448447 }
449448 }
@@ -495,7 +494,7 @@ private[effect] final class WorkerThread[P <: AnyRef](
495494 pool.notifyParked(rnd)
496495 try fiber.run()
497496 catch {
498- case t if NonFatal (t) => pool.reportFailure(t)
497+ case t if UnsafeNonFatal (t) => pool.reportFailure(t)
499498 case t : Throwable => IOFiber .onFatalFailure(t)
500499 }
501500
@@ -515,7 +514,7 @@ private[effect] final class WorkerThread[P <: AnyRef](
515514 // The dequeued element is a single fiber. Execute it immediately.
516515 try fiber.run()
517516 catch {
518- case t if NonFatal (t) => pool.reportFailure(t)
517+ case t if UnsafeNonFatal (t) => pool.reportFailure(t)
519518 case t : Throwable => IOFiber .onFatalFailure(t)
520519 }
521520
@@ -545,7 +544,7 @@ private[effect] final class WorkerThread[P <: AnyRef](
545544 // Run the stolen fiber.
546545 try fiber.run()
547546 catch {
548- case t if NonFatal (t) => pool.reportFailure(t)
547+ case t if UnsafeNonFatal (t) => pool.reportFailure(t)
549548 case t : Throwable => IOFiber .onFatalFailure(t)
550549 }
551550 }
@@ -813,7 +812,7 @@ private[effect] final class WorkerThread[P <: AnyRef](
813812
814813 try fiber.run()
815814 catch {
816- case t if NonFatal (t) => pool.reportFailure(t)
815+ case t if UnsafeNonFatal (t) => pool.reportFailure(t)
817816 case t : Throwable => IOFiber .onFatalFailure(t)
818817 }
819818 } else if (element.isInstanceOf [Runnable ]) {
@@ -827,7 +826,7 @@ private[effect] final class WorkerThread[P <: AnyRef](
827826 // The dequeued element is a single fiber. Execute it immediately.
828827 try fiber.run()
829828 catch {
830- case t if NonFatal (t) => pool.reportFailure(t)
829+ case t if UnsafeNonFatal (t) => pool.reportFailure(t)
831830 case t : Throwable => IOFiber .onFatalFailure(t)
832831 }
833832 }
@@ -862,7 +861,7 @@ private[effect] final class WorkerThread[P <: AnyRef](
862861 // Run the fiber.
863862 try fiber.run()
864863 catch {
865- case t if NonFatal (t) => pool.reportFailure(t)
864+ case t if UnsafeNonFatal (t) => pool.reportFailure(t)
866865 case t : Throwable => IOFiber .onFatalFailure(t)
867866 }
868867 } else {
0 commit comments