Add helper functions for performing monkey patching on existing code.