Sample library
Bug fixes for VM and code generator