This commit is contained in:
+1
-1
@@ -167,7 +167,7 @@ public readonly struct Result<T> : IEquatable<Result<T>>
|
|||||||
public static implicit operator Result<T>(Error error) => new(error);
|
public static implicit operator Result<T>(Error error) => new(error);
|
||||||
[Pure, MethodImpl(MethodImplOptions.AggressiveInlining)]
|
[Pure, MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||||
public static implicit operator Result<T>(Exception exception) => new(
|
public static implicit operator Result<T>(Exception exception) => new(
|
||||||
new ExceptionalError(exception ?? throw new ArgumentNullException(nameof(exception))));
|
Error.New(exception ?? throw new ArgumentNullException(nameof(exception))));
|
||||||
[Pure, MethodImpl(MethodImplOptions.AggressiveInlining)]
|
[Pure, MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||||
public static implicit operator Result<T>(T value) => new(value);
|
public static implicit operator Result<T>(T value) => new(value);
|
||||||
[Pure] public bool IsSuccess => State == ResultState.Success;
|
[Pure] public bool IsSuccess => State == ResultState.Success;
|
||||||
|
|||||||
Reference in New Issue
Block a user