Initial v0.4 refactorings.