instead of a string use untyped, i.e. 
    
    
    template tpl(name:untyped, body:untyped):untyped =
        proc `name Free`()=
            body
    
    tpl(myname):
        echo "1"
        echo "2"
    
    mynameFree()
    
    
    Run

Reply via email to