windows building support
removes unused code
separates tests
adds tuple write support
handles some tuple leaks