Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- type MyUnion =
- | First of int
- | Second of double
- type MyRecord = {
- A: int
- B: double
- C: MyUnion
- }
- let test (a: MyRecord) (b: int) =
- let c: double = 1.0
- ()
- let test a = async {
- return a;
- }
- let test a = foobar {
- return a;
- }
- // Mass, grams.
- [<Measure>] type g
- // Mass, kilograms.
- [<Measure>] type kg
- [<DllImport("kernel32", SetLastError=true)>]
- let func : HttpFunc = handler (Some >> Task.FromResult)
- type Base1() =
- abstract member F : unit -> unit
- default u.F() =
- printfn "F Base1"
- type Derived1() =
- inherit Base1()
- override u.F() =
- printfn "F Derived1"
- let d1 : Derived1 = Derived1()
- let base1 = d1 :> Base1
- let derived1 = base1 :?> Derived1
- type PersonName =
- | FirstOnly of string
- | LastOnly of string
- | FirstLast of string * string
- type Shape =
- | Rectangle of height : float * width : float
- | Circle of radius : float
- type MyInterface =
- abstract member Add: int -> int -> int
- abstract member Pi : float
- exception Error1 of string
- exception Error2 of string * int
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement