return an astroid.List node as string
554509
def visit_list(self, node):
        """"""
        return "[%s]" % ", ".join(child.accept(self) for child in node.elts)
884912
def visit_listcomp(self, node):
        """"""
        return "[%s %s]" % (
            node.elt.accept(self),
            " ".join(n.accept(self) for n in node.generators),
        )
1024763
def list_nodes():
    
    token = session.get('token')
    node = nago.core.get_node(token)
    if not node.get('access') == 'master':
        return jsonify(status='error', error="You need master access to view this page")

    nodes = nago.core.get_nodes().values()
    return render_template('nodes.html', **locals())
527815
def list(cls, name, parent=None, interleave=None):
        """"""
        node = cls.leaf_list(name, parent, interleave=interleave)
        node.keys = []
        node.keymap = {}
        return node
14083
def visit_list(self, node, parent):
        """"""
        context = self._get_context(node)
        newnode = nodes.List(
            ctx=context, lineno=node.lineno, col_offset=node.col_offset, parent=parent
        )
        newnode.postinit([self.visit(child, newnode) for child in node.elts])
        return newnode
864397
def to_json(self):
        ''' 
        '''

        skip_list = []
        for u, v, connection_type in self.skip_connections:
            skip_list.append({"from": u, "to": v, "type": connection_type})
        return {"node_list": self.layers, "skip_list": skip_list}
1312266
def visit_name(self, node, parent):
        """"""
        context = self._get_context(node)
        # True and False can be assigned to something in py2x, so we have to
        # check first the context.
        if context == astroid.Del:
            newnode = nodes.DelName(node.id, node.lineno, node.col_offset, parent)
        elif context == astroid.Store:
            newnode = nodes.AssignName(node.id, node.lineno, node.col_offset, parent)
        elif node.id in CONST_NAME_TRANSFORMS:
            newnode = nodes.Const(
                CONST_NAME_TRANSFORMS[node.id],
                getattr(node, "lineno", None),
                getattr(node, "col_offset", None),
                parent,
            )
            return newnode
        else:
            newnode = nodes.Name(node.id, node.lineno, node.col_offset, parent)
        # XXX REMOVE me :
        if context in (astroid.Del, astroid.Store):  # 'Aug' ??
            self._save_assignment(newnode)
        return newnode
684819
private List<Node> asList(NodeList n) {
		return n.getLength() == 0 ? Collections.<Node> emptyList() : new NodeListWrapper(n);
	}
1074967
def construct_getatt(node):
    

    if isinstance(node.value, six.text_type):
        return node.value.split(".", 1)
    elif isinstance(node.value, list):
        return [s.value for s in node.value]
    else:
        raise ValueError("Unexpected node type: {}".format(type(node.value)))
1093433
def extract_script_nodes(list)
      list.select { |item| item.is_a?(::Sass::Script::Tree::Node) }
    end
83145
def visit_tuple(self, node):
        """"""
        if len(node.elts) == 1:
            return "(%s, )" % node.elts[0].accept(self)
        return "(%s)" % ", ".join(child.accept(self) for child in node.elts)
1005590
def list_nodes(**kwargs):
    '''
    
    '''
    ret = {}

    nodes = list_nodes_full()
    for node in nodes:
        ret[node] = {}
        for prop in 'id', 'image', 'size', 'state', 'private_ips', 'public_ips':
            ret[node][prop] = nodes[node][prop]

    return ret
330461
def visit_str(self, node, parent):
        """"""
        return nodes.Const(
            node.s,
            getattr(node, "lineno", None),
            getattr(node, "col_offset", None),
            parent,
        )
997113
def path_to_list(pathstr):
    """"""
    return [elem for elem in pathstr.split(os.path.pathsep) if elem]
318259
def to_string(self):
        """"""


        # RMF: special case defaults for node, edge and graph properties.
        #
        node = quote_if_necessary(self.obj_dict['name'])

        node_attr = list()

        for attr in sorted(self.obj_dict['attributes']):
            value = self.obj_dict['attributes'][attr]
            if value == '':
                value = '""'
            if value is not None:
                node_attr.append(
                    '%s=%s' % (attr, quote_if_necessary(value) ) )
            else:
                node_attr.append( attr )


        # No point in having nodes setting any defaults if the don't set
        # any attributes...
        #
        if node in ('graph', 'node', 'edge') and len(node_attr) == 0:
            return ''

        node_attr = ', '.join(node_attr)

        if node_attr:
            node += ' [' + node_attr + ']'

        return node + ';'
1354143
def listNode(node):
    
    if node.list_data['type'] == u'bullet':
        o = nodes.bullet_list(bullet=node.list_data['bullet_char'])
    else:
        o = nodes.enumerated_list(suffix=node.list_data['delimiter'], enumtype='arabic', start=node.list_data['start'])
    for n in MarkDown(node):
        o += n
    return o
1174772
def lookup(node, name):
    
    if isinstance(
        node, (astroid.List, astroid.Tuple, astroid.Const, astroid.Dict, astroid.Set)
    ):
        return _builtin_lookup(node, name)
    if isinstance(node, astroid.Instance):
        return _lookup_in_mro(node, name)
    if isinstance(node, astroid.ClassDef):
        return _class_lookup(node, name)

    raise exceptions.AttributeInferenceError(attribute=name, target=node)