fold

inline fun fold(onSuccess: (S) -> Unit, onFailure: (F) -> Unit)