#18149: Can add vertex to immutable graph once
----------------------------+----------------------------
Reporter: vbraun | Owner:
Type: defect | Status: new
Priority: major | Milestone: sage-6.6
Component: graph theory | Keywords:
Merged in: | Authors:
Reviewers: | Report Upstream: N/A
Work issues: | Branch:
Commit: | Dependencies:
Stopgaps: |
----------------------------+----------------------------
{{{
sage: g = Graph({0:[1,2,3], 2:[4]}, immutable=True)
sage: g.add_vertex()
5
sage: g.add_vertex()
---------------------------------------------------------------------------
NotImplementedError Traceback (most recent call
last)
<ipython-input-8-ec8a05af84d7> in <module>()
----> 1 g.add_vertex()
/home/vbraun/Code/sage.git/local/lib/python2.7/site-
packages/sage/graphs/generic_graph.pyc in add_vertex(self, name)
8476
8477 """
-> 8478 return self._backend.add_vertex(name)
8479
8480 def add_vertices(self, vertices):
/home/vbraun/Code/sage.git/src/sage/graphs/base/c_graph.pyx in
sage.graphs.base.c_graph.CGraphBackend.add_vertex
(build/cythonized/sage/graphs/base/c_graph.c:13807)()
1533 retval = name
1534
-> 1535 check_vertex(name,
1536 self.vertex_ints,
1537 self.vertex_labels,
/home/vbraun/Code/sage.git/src/sage/graphs/base/c_graph.pyx in
sage.graphs.base.c_graph.check_vertex
(build/cythonized/sage/graphs/base/c_graph.c:11994)()
1199 u_int = bitset_first_in_complement(G.active_vertices)
1200 if u_int == -1:
-> 1201 G.realloc(2*G.active_vertices.size)
1202 if reverse:
1203 G_rev.realloc(2*G_rev.active_vertices.size)
/home/vbraun/Code/sage.git/src/sage/graphs/base/c_graph.pyx in
sage.graphs.base.c_graph.CGraph.realloc
(build/cythonized/sage/graphs/base/c_graph.c:9528)()
721 30
722 """
--> 723 raise NotImplementedError()
724
725 ###################################
NotImplementedError:
}}}
--
Ticket URL: <http://trac.sagemath.org/ticket/18149>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.