Changeset 16770:84f81aa993a4
- Timestamp:
- 01/18/10 05:43:48 (3 years ago)
- Branch:
- default
- File:
-
- 1 edited
-
sage/modules/vector_double_dense.pyx (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
sage/modules/vector_double_dense.pyx
r16698 r16770 169 169 sage: vector(RDF, 4, range(4)) 170 170 (0.0, 1.0, 2.0, 3.0) 171 172 sage: V = RDF^2 173 sage: V._element_class(V, 5) 174 Traceback (most recent call last): 175 ... 176 TypeError: entries must be a list or 0 177 sage: V._element_class(V, 0) 178 (0.0, 0.0) 171 179 """ 172 180 cdef Py_ssize_t i,j … … 195 203 raise TypeError("cannot coerce entry to type %s"%self._python_dtype) 196 204 if z != 0: 205 raise TypeError("entries must be a list or 0") 206 else: 207 # Set all entries to z=0. 197 208 for i from 0<=i<self._degree: 198 209 self.set_unsafe(i,z)
Note: See TracChangeset
for help on using the changeset viewer.
