Skip to content

Instantly share code, notes, and snippets.

@od0x0
Created July 6, 2010 23:40
Show Gist options
  • Save od0x0/466094 to your computer and use it in GitHub Desktop.
Save od0x0/466094 to your computer and use it in GitHub Desktop.
alloca: extern func(SizeT)->Pointer
Vec2: class{
x, y: Float
init: func(=x,=y){}
print: func{"(%f, %f)\n" format(x, y) println()}
}
object:=alloca(Vec2 instanceSize) as Vec2
object class=Vec2
object init(1,1)
object print()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment