FluentResults icon indicating copy to clipboard operation
FluentResults copied to clipboard

The Result.Ok method has only 2 overloads

Open PUDGE133 opened this issue 5 months ago • 4 comments

Because of this I get compilation error CS0029

Image Image

PUDGE133 avatar Jul 23 '25 08:07 PUDGE133

It turns out that this is how it is done. Still, I think that additional overloads are needed. Image

PUDGE133 avatar Jul 23 '25 21:07 PUDGE133

Also, all this leads to the fact that I have to process successful options in a method not directly intended for this. Image

PUDGE133 avatar Jul 24 '25 09:07 PUDGE133

Author, do you ever come here?

PUDGE133 avatar Aug 10 '25 03:08 PUDGE133

@PUDGE133 I personally think that, readability-wise, specifying the output is really helpful. The plain Result method is void, so it doesn't clearly show what to expect. Using Result<T> makes it obvious that this method will return a value, which improves clarity and communicates the intention better

mozhganEtaati avatar Sep 12 '25 10:09 mozhganEtaati