comparison liboctave/MSparse.h @ 7620:36594d5bbe13

Move diag function into the octave_value class
author David Bateman <dbateman@free.fr>
date Fri, 21 Mar 2008 00:08:24 +0100
parents 7bfaa9611558
children eb63fbe60fab
comparison
equal deleted inserted replaced
7619:56012914972a 7620:36594d5bbe13
110 110
111 MSparse<T> ipermute (const Array<octave_idx_type>& vec) const 111 MSparse<T> ipermute (const Array<octave_idx_type>& vec) const
112 { return Sparse<T>::ipermute (vec); } 112 { return Sparse<T>::ipermute (vec); }
113 113
114 114
115 template <class U, class F> 115 MSparse<T> diag (octave_idx_type k = 0) const
116 {
117 return Sparse<T>::diag (k);
118 }
119
120 template <class U, class F>
116 MSparse<U> map (F fcn) const 121 MSparse<U> map (F fcn) const
117 { 122 {
118 return Sparse<T>::template map<U> (fcn); 123 return Sparse<T>::template map<U> (fcn);
119 } 124 }
120 125