Closed Artem-Romanenia closed 2 years ago
@ardalis I'd be happy to hear your feedback on whether any of this makes any sense
Sorry I've been busy - thanks for pinging me. This looks great based on your comments above.
...and the build failure is nothing to do with your code...
Looks great, thanks! Merged!
Attempt to address following issues:
80
77
65
41
Brief overview:
Result : Result<Result>
(looks a little tricky but this way no Unit class is needed, inspired by FluentResults)Result
class has a set of static factory methods for creatingResult
instances almost equivalent to such inResult<T>
.Result
also has static generic factory methods for creatingResult<T>
success-instancesResult<T>
has an implicit cast fromResult
Result<T>
creation in consumer code:Request<T>
that will not cause any casting.Also, there seem to be no braking changes, at least I didn't have to change any existing tests.
If this PR has any potential, but you want me to refactor something, please let me know.