def METHOD_NAME(self, pymodule, node):
    scope = pymodule.get_scope().get_inner_scope_for_line(node.lineno)
    expression = node
    if isinstance(expression, ast.Name) and isinstance(expression.ctx, ast.Store):
        start, end = patchedast.node_region(expression)
        text = pymodule.source_code[start:end]
        return evaluate.eval_str(scope, text)
    else:
        return evaluate.eval_node(scope, expression)