I would recommend making GitCheckoutOpts a struct, and then pass by reference when a pointer is needed. Then you can just include the struct here (without copying the fields individually). Seems much more maintainable.