added destructors to references, need more tests