Remove unused code for handling stack allocation