Add documentation, make the warnings consistent