scala.util.control
  package scala.util.control
 
Members list
Type members
Deprecated classlikes
            object NonLocalReturns
           
          Library implementation of nonlocal return.
Library implementation of nonlocal return.
Usage:
import scala.util.control.NonLocalReturns.*
returning { ... throwReturn(x) ... }
This API has been deprecated. Its functionality is better served by
- scala.util.boundaryin place of- returning
- scala.util.breakin place of- throwReturn
The new abstractions work with plain RuntimeExceptions and are more performant, since returns within the scope of the same method can be rewritten by the compiler to jumps.
Attributes
- Deprecated
- 
               [Since version 3.3]Use scala.util.boundary instead
- Source
- NonLocalReturns.scala
- Supertypes
- Self type
- 
               NonLocalReturns.type
In this article