Seq With Escaping Exceptions
let getTheThings (): int seq =
try
Seq.map (fun _ -> failwith "bad stuff") [42]
with
| _ ->
Seq.singleton 99
printfn "%A" (getTheThings () |> Seq.head)INFO
let getTheThings (): int seq =
try
Seq.map (fun _ -> failwith "bad stuff") [42]
with
| _ ->
Seq.singleton 99
printfn "%A" (getTheThings () |> Seq.head)