toOption method

Option<R> toOption()

Implementation

Option<R> toOption() => fold((_) => none(), some);