Last active
December 10, 2015 04:48
-
-
Save awreece/4383713 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module DJV = struct | |
type t = { level: int; vertex: string } | |
let vertex v = v.vertex | |
let level v = v.level | |
end | |
let _ = print_string (DJV.vertex DJV.({ level=0; vertex="hello, world\n" })) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ ocaml temp.ml | |
File "temp.ml", line 8, characters 35-40: | |
Error: Unbound record field label level |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module DJV = struct | |
type t = { level: int; vertex: string } | |
let vertex v = v.vertex | |
let level v = v.level | |
end | |
let _ = print_string (DJV.vertex { level=0; vertex="hello, world\n" }) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment