let unopt = function
    | None   -> failwith "Cannot unopt None"
    | Some v -> v