let foo : obj = failwith "" match foo with | :? SomeType as blah -> // use blah : SomeType
match thing { case a: String => // use a as string case a @ MyCaseClass(b: String, c, d) => // use a as the instance of MyCaseClass or use b as a string }