def replace_variables(self, tokens, scope):
list = []<EOL>for t in tokens:<EOL><INDENT>if utility.is_variable(t):<EOL><INDENT>list.append(scope.swap(t))<EOL><DEDENT>elif str(type(t)) == "<STR_LIT>":<EOL><INDENT>list.append(scope.swap(t.name))<EOL><DEDENT>else:<EOL><INDENT>list.append(t)<EOL><DEDENT><DEDENT>return list<EOL>
Replace variables in tokenlist
        args:
            tokens (list): tokenlist
            scope (Scope): Current scope
        returns:
            list