Cosmetic changes.

* use `nullptr` instead of `0` when it makes sense
* follow the same scheme when declaring variables
Re-indent file.