Support doctest in our docstrings.

The doctest module pulls examples out of our docstrings and runs them as tests.
I've changed the formatting of our docstrings to support this. Unfortunately,
the doctest module tries to be smart, so winds up being dumb.