Skip to content

Instantly share code, notes, and snippets.

@SteveGilham
Created April 26, 2015 13:50
Show Gist options
  • Select an option

  • Save SteveGilham/b332d670dcb7b5030f3c to your computer and use it in GitHub Desktop.

Select an option

Save SteveGilham/b332d670dcb7b5030f3c to your computer and use it in GitHub Desktop.
type Point = { mutable x: int; mutable y: int }
with member p.move q = p.x <- p.x + q.x;
p.y <- p.y + q.y
let makePoint x y = { x = x; y = y }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment