Patches to the template system.