Mostly documentation fixes, some edge cases tested