def extract_template(template, name):
    """
    Extract a code-generated function from a string template.
    """
    namespace = {}
    exec(template, namespace)
    return namespace[name]

    Extract a code-generated function from a string template.
    
numba/experimental/jitclass/overloads.py