Various docs/code improvements/fixes.

* Tidy up Sphinx.
* Add mini-language examples to all Field classes.
* Remove UNDEFINED noise, since we hate None anyway.
* Tidy up the special case hack to avoid needlessly rebuilding
  dicts/lists.
* Avoid 3 list builds in def operations.
* Remove long_to_short() from get(), was wrong.
* Precalculate most of _dbcollection().