Using Seq.cast
seems to constantly fail, even for something as simple as the following:
let xor c = Seq.cast c |> Seq.reduce (^^^)
xor [1;3] // Works, assuming because no cast is necessary
xor ['a';'b'] // Fails
xor [2u] // Fails
The latter two fail with Specified Cast is not valid. What am I missing?
I'm trying to use Seq.cast
to convert a bunch of stuff to uint16
, but for some reason it always fails (even if I annotate it with Seq.cast<uint32>
). What's up with this?