Move Go code to golang