preparing for major code rewriting