F# - what does match...with | :? X as x mean?
This the Type Test Pattern.
PictureBrush
is a type. shape.Fill
matches :? PictureBrush
when the Fill
property is assignable to that type.
Also note that the as
allows for binding of a variable to be of that type. So pb
will be of type PictureBrush
, but will have the exact same value as what shape.Fill
resolved to.