use struct * functions to simplify structs