Mercurial > hg > octave-avbm
changeset 9222:7bd406e12e4d
instantiate Array<void *> in liboctave
* * *
fix non-robust macro in Array.cc
author | Jaroslav Hajek <highegg@gmail.com> |
---|---|
date | Wed, 20 May 2009 14:08:13 +0200 |
parents | 659657942ba6 |
children | 902a4597dce8 |
files | liboctave/Array-voidp.cc liboctave/Array.cc liboctave/ChangeLog liboctave/Makefile.in |
diffstat | 4 files changed, 58 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
new file mode 100644 --- /dev/null +++ b/liboctave/Array-voidp.cc @@ -0,0 +1,50 @@ +/* + +Copyright (C) 1996, 1997, 2000, 2003, 2005, 2007, 2008, 2009 John W. Eaton + +This file is part of Octave. + +Octave is free software; you can redistribute it and/or modify it +under the terms of the GNU General Public License as published by the +Free Software Foundation; either version 3 of the License, or (at your +option) any later version. + +Octave is distributed in the hope that it will be useful, but WITHOUT +ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +for more details. + +You should have received a copy of the GNU General Public License +along with Octave; see the file COPYING. If not, see +<http://www.gnu.org/licenses/>. + +*/ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <string> + +// Instantiate Arrays of void *. + +#include "Array.h" +#include "Array.cc" + +NO_INSTANTIATE_ARRAY_SORT (void *); + +INSTANTIATE_ARRAY (void *, OCTAVE_API); + +#include "Array2.h" + +template class OCTAVE_API Array2<void *>; + +#include "Array3.h" + +template class OCTAVE_API Array3<void *>; + +/* +;;; Local Variables: *** +;;; mode: C++ *** +;;; End: *** +*/
--- a/liboctave/Array.cc +++ b/liboctave/Array.cc @@ -2574,7 +2574,7 @@ { return UNSORTED; } \ \ template <> octave_idx_type \ -Array<T>::lookup (const T&, sortmode) const \ +Array<T>::lookup (T const &, sortmode) const \ { return 0; } \ template <> Array<octave_idx_type> \ Array<T>::lookup (const Array<T>&, sortmode, bool, bool) const \
--- a/liboctave/ChangeLog +++ b/liboctave/ChangeLog @@ -1,3 +1,9 @@ +2009-05-20 Jaroslav Hajek <highegg@gmail.com> + + * Array-voidp.cc: New source. + * Array.cc (NO_INSTANTIATE_ARRAY_SORT): const T& -> T const & + * Makefile.in: Include it. + 2009-05-15 Jaroslav Hajek <highegg@gmail.com> * Array.cc (Array<T>::instantiation_guard): New function
--- a/liboctave/Makefile.in +++ b/liboctave/Makefile.in @@ -109,7 +109,7 @@ sparse-base-chol.cc sparse-dmsolve.cc TI_SRC := Array-C.cc Array-b.cc Array-ch.cc Array-i.cc Array-d.cc \ - Array-f.cc Array-fC.cc Array-s.cc Array-str.cc \ + Array-f.cc Array-fC.cc Array-s.cc Array-str.cc Array-voidp.cc \ Array-idx-vec.cc MArray-C.cc MArray-ch.cc MArray-i.cc MArray-d.cc \ MArray-f.cc MArray-fC.cc MArray-s.cc MSparse-C.cc MSparse-d.cc \ Sparse-C.cc Sparse-b.cc Sparse-d.cc oct-inttypes.cc