Reorganizes code into a... CLEANer version.