Closed jhkuperus closed 8 years ago
I think we can achieve the desired behaviour by wrapping the option in a Try or Future.
:) Way to rein me in there trying to create something that's basically expressed as easily as this:
type EvaluationResult[A] = Try[Option[A]]
I'll have to think about the Future
you mention, it may actually open the door to allowing evaluations which are considered to be asynchronous.
Sometimes the wheel has already been invented! ^^
For proper error handling, we are going to need an extension over the
Option
type. Preferably, we'd have something like this:This will allow us to differentiate between the cases in which a value simply was not available and when an exception occurred preventing the proper completion of an evaluation.