some pass by reference stuff