Adds Dialyzer functionality.

This patch does not fix all dialyzer warnings. It uses specs generated by Typer with some hand editing to clean them up. The -spec annotations try to match the original edoc specs where possible. However, some of the edoc annotations were out of date. The specs are underspecified in some places to allow dialyzer to run.