Constructs an Expected with value or error based on the provided flag. This constructor is available only for cases when value and error has the same type, so we can still construct Expected with value or error.
Value to set as value or error
If true, Expected with value is created, Expected with error otherwise.
See Implementation
Constructs an Expected with value or error based on the provided flag. This constructor is available only for cases when value and error has the same type, so we can still construct Expected with value or error.