Make rev lazy.
Add documentation.