Fix PEP violations

* hash/codegen.py: cleanup code according to PEP8