cleanup cloning code; not complete yet