refactors macro runtimes

Following typedMacroBody, macroRuntime along with its friends has also
been moved out into a separate component.