Various coding style cleanup

Merge #205 before this one.