Shoud this compile?
[<return: Struct>]
let rec (|HasOne|_|) xs =
match xs with
| [] -> ValueNone
| h::_ when h = 1 -> ValueSome true
| _::tail ->
match tail with
| HasOne x -> ValueSome x
| _ -> ValueNone
// error FS0001: The type ''a option' does not match the type 'bool voption'