type Node =
val X: int
new (x: int) = { X = x }
type Leaf =
inherit Node
val Y: string
new (x: int, y: string) =
{ inherit Node(x); Y = y }
[<EntryPoint>]
let main _args =
let node = Leaf(3, "4")
let x = node.X // <-- Error: This should be 3, but is undefined.
let y = node.Y
System.Console.WriteLine($"x: {x}, y: {y}")
0