Have an option to remove all memory blocks in the stack that are related to a document