Improve formatting of function definitions and imports

This is just a short-term hack, later we plan to copy formatting from
the YCP source.