Finished implementation of stack reset/rebind
Adding commited file and some cleanup