Implemented Option.attempt.