NonLocalReturns
extends ObjectLibrary implementation of nonlocal return.
Usage:
import scala.util.control.NonLocalReturns._
returning { ... throwReturn(x) ... }
Supertypes
ObjectMembers
def
returning
[T] ( op: implicit ReturnThrowable[T] => T ) : TEnable nonlocal returns in op
.
Enable nonlocal returns in op
.
def
throwReturn
[T] ( result: T ) ( implicit returner: ReturnThrowable[T] ) : NothingPerforms a nonlocal return by throwing an exception.
Performs a nonlocal return by throwing an exception.