Small doc changes
Move struct into header, simpler smartlist frees
Start writing tests, update makefile