updated documentation and fixed compiler warnings