Mercurial > hg > octave-lyh
annotate src/ov-range.h @ 12233:2aafbdac2ca8 release-3-4-x
Explicitly disallow copying in some classes
author | Pascal Dupuis <Pascal.Dupuis@uclouvain.be> |
---|---|
date | Mon, 24 Jan 2011 14:57:07 -0500 |
parents | 12df7854fa7c |
children | 72c96de7a403 |
rev | line source |
---|---|
2376 | 1 /* |
2 | |
11523 | 3 Copyright (C) 1996-2011 John W. Eaton |
2376 | 4 |
5 This file is part of Octave. | |
6 | |
7 Octave is free software; you can redistribute it and/or modify it | |
8 under the terms of the GNU General Public License as published by the | |
7016 | 9 Free Software Foundation; either version 3 of the License, or (at your |
10 option) any later version. | |
2376 | 11 |
12 Octave is distributed in the hope that it will be useful, but WITHOUT | |
13 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | |
14 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License | |
15 for more details. | |
16 | |
17 You should have received a copy of the GNU General Public License | |
7016 | 18 along with Octave; see the file COPYING. If not, see |
19 <http://www.gnu.org/licenses/>. | |
2376 | 20 |
21 */ | |
22 | |
23 #if !defined (octave_range_h) | |
24 #define octave_range_h 1 | |
25 | |
26 #include <cstdlib> | |
27 | |
8950
d865363208d6
include <iosfwd> instead of <iostream> in header files
John W. Eaton <jwe@octave.org>
parents:
8920
diff
changeset
|
28 #include <iosfwd> |
2376 | 29 #include <string> |
30 | |
31 #include "Range.h" | |
32 | |
2889 | 33 #include "lo-mappers.h" |
2376 | 34 #include "lo-utils.h" |
35 #include "mx-base.h" | |
2477 | 36 #include "oct-alloc.h" |
2376 | 37 #include "str-vec.h" |
38 | |
39 #include "error.h" | |
5051 | 40 #include "oct-stream.h" |
2376 | 41 #include "ov-base.h" |
6127 | 42 #include "ov-re-mat.h" |
2376 | 43 #include "ov-typeinfo.h" |
44 | |
45 class octave_value_list; | |
46 | |
47 class tree_walker; | |
48 | |
49 // Range values. | |
50 | |
51 class | |
52 octave_range : public octave_base_value | |
53 { | |
54 public: | |
55 | |
56 octave_range (void) | |
11584
cda4aa780d58
Another round of initialising members in the constructor initialisation list
Pascal Dupuis <Pascal.Dupuis@uclouvain.be>
parents:
11570
diff
changeset
|
57 : octave_base_value (), range (), idx_cache () { } |
2376 | 58 |
59 octave_range (double base, double limit, double inc) | |
9350
16a5f9e1fdb3
cache idx_vector result in matrices once used for indexing
Jaroslav Hajek <highegg@gmail.com>
parents:
9146
diff
changeset
|
60 : octave_base_value (), range (base, limit, inc), idx_cache () |
2376 | 61 { |
10313 | 62 if (range.nelem () < 0) |
63 ::error ("invalid range"); | |
2376 | 64 } |
65 | |
66 octave_range (const Range& r) | |
9350
16a5f9e1fdb3
cache idx_vector result in matrices once used for indexing
Jaroslav Hajek <highegg@gmail.com>
parents:
9146
diff
changeset
|
67 : octave_base_value (), range (r), idx_cache () |
2376 | 68 { |
10313 | 69 if (range.nelem () < 0 && range.nelem () != -2) |
70 ::error ("invalid range"); | |
2376 | 71 } |
72 | |
73 octave_range (const octave_range& r) | |
11586
12df7854fa7c
strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents:
11584
diff
changeset
|
74 : octave_base_value (), range (r.range), |
9350
16a5f9e1fdb3
cache idx_vector result in matrices once used for indexing
Jaroslav Hajek <highegg@gmail.com>
parents:
9146
diff
changeset
|
75 idx_cache (r.idx_cache ? new idx_vector (*r.idx_cache) : 0) |
16a5f9e1fdb3
cache idx_vector result in matrices once used for indexing
Jaroslav Hajek <highegg@gmail.com>
parents:
9146
diff
changeset
|
76 { } |
2376 | 77 |
9479
d9716e3ee0dd
supply optimized compiled sub2ind & ind2sub
Jaroslav Hajek <highegg@gmail.com>
parents:
9350
diff
changeset
|
78 octave_range (const Range& r, const idx_vector& cache) |
d9716e3ee0dd
supply optimized compiled sub2ind & ind2sub
Jaroslav Hajek <highegg@gmail.com>
parents:
9350
diff
changeset
|
79 : octave_base_value (), range (r), idx_cache () |
d9716e3ee0dd
supply optimized compiled sub2ind & ind2sub
Jaroslav Hajek <highegg@gmail.com>
parents:
9350
diff
changeset
|
80 { |
d9716e3ee0dd
supply optimized compiled sub2ind & ind2sub
Jaroslav Hajek <highegg@gmail.com>
parents:
9350
diff
changeset
|
81 set_idx_cache (cache); |
d9716e3ee0dd
supply optimized compiled sub2ind & ind2sub
Jaroslav Hajek <highegg@gmail.com>
parents:
9350
diff
changeset
|
82 } |
d9716e3ee0dd
supply optimized compiled sub2ind & ind2sub
Jaroslav Hajek <highegg@gmail.com>
parents:
9350
diff
changeset
|
83 |
9350
16a5f9e1fdb3
cache idx_vector result in matrices once used for indexing
Jaroslav Hajek <highegg@gmail.com>
parents:
9146
diff
changeset
|
84 ~octave_range (void) { clear_cached_info (); } |
2376 | 85 |
5759 | 86 octave_base_value *clone (void) const { return new octave_range (*this); } |
6127 | 87 |
88 // A range is really just a special kind of real matrix object. In | |
89 // the places where we need to call empty_clone, it makes more sense | |
90 // to create an empty matrix (0x0) instead of an empty range (1x0). | |
91 octave_base_value *empty_clone (void) const { return new octave_matrix (); } | |
2376 | 92 |
8345
c777f3ce02d8
smarter conversion lookup
Jaroslav Hajek <highegg@gmail.com>
parents:
7922
diff
changeset
|
93 type_conv_info numeric_conversion_function (void) const; |
2410 | 94 |
5759 | 95 octave_base_value *try_narrowing_conversion (void); |
2376 | 96 |
4247 | 97 octave_value subsref (const std::string& type, |
10313 | 98 const std::list<octave_value_list>& idx); |
3933 | 99 |
7651
443a8f5a50fd
require both subsref variants to be defined in octave_value subclasses
John W. Eaton <jwe@octave.org>
parents:
7638
diff
changeset
|
100 octave_value_list subsref (const std::string& type, |
10313 | 101 const std::list<octave_value_list>& idx, int) |
7651
443a8f5a50fd
require both subsref variants to be defined in octave_value subclasses
John W. Eaton <jwe@octave.org>
parents:
7638
diff
changeset
|
102 { return subsref (type, idx); } |
4271 | 103 |
5885 | 104 octave_value do_index_op (const octave_value_list& idx, |
10313 | 105 bool resize_ok = false); |
2436 | 106 |
10605
1834132fb50b
allow non-integer ranges as indices conditionally
John W. Eaton <jwe@octave.org>
parents:
10313
diff
changeset
|
107 idx_vector index_vector (void) const; |
2376 | 108 |
4563 | 109 dim_vector dims (void) const |
11586
12df7854fa7c
strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents:
11584
diff
changeset
|
110 { |
5275 | 111 octave_idx_type n = range.nelem (); |
4563 | 112 return dim_vector (n > 0, n); |
113 } | |
3195 | 114 |
5731 | 115 octave_value resize (const dim_vector& dv, bool fill = false) const; |
116 | |
4915 | 117 |
4792 | 118 size_t byte_size (void) const { return 3 * sizeof (double); } |
4791 | 119 |
4627 | 120 octave_value reshape (const dim_vector& new_dims) const |
4901 | 121 { return NDArray (array_value().reshape (new_dims)); } |
4627 | 122 |
5434 | 123 octave_value permute (const Array<int>& vec, bool inv = false) const |
124 { return NDArray (array_value().permute (vec, inv)); } | |
125 | |
6999 | 126 octave_value squeeze (void) const { return range; } |
127 | |
8458
d254a21e0120
reimplement full as method of octave_base_value
Jaroslav Hajek <highegg@gmail.com>
parents:
8437
diff
changeset
|
128 octave_value full_value (void) const { return range.matrix_value (); } |
d254a21e0120
reimplement full as method of octave_base_value
Jaroslav Hajek <highegg@gmail.com>
parents:
8437
diff
changeset
|
129 |
2376 | 130 bool is_defined (void) const { return true; } |
131 | |
2974 | 132 bool is_constant (void) const { return true; } |
133 | |
2376 | 134 bool is_range (void) const { return true; } |
135 | |
4017 | 136 octave_value all (int dim = 0) const; |
137 | |
138 octave_value any (int dim = 0) const; | |
2376 | 139 |
8366
8b1a2555c4e2
implement diagonal matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
8345
diff
changeset
|
140 octave_value diag (octave_idx_type k = 0) const; |
7620
36594d5bbe13
Move diag function into the octave_value class
David Bateman <dbateman@free.fr>
parents:
7576
diff
changeset
|
141 |
7463
2467639bd8c0
eliminate UNDEFINED sort mode
John W. Eaton <jwe@octave.org>
parents:
7458
diff
changeset
|
142 octave_value sort (octave_idx_type dim = 0, sortmode mode = ASCENDING) const |
7458 | 143 { return range.sort (dim, mode); } |
144 | |
145 octave_value sort (Array<octave_idx_type>& sidx, octave_idx_type dim = 0, | |
10313 | 146 sortmode mode = ASCENDING) const |
7458 | 147 { return range.sort (sidx, dim, mode); } |
148 | |
8734
767ed8cc6634
rename internal issorted and issorted_rows functions to is_sorted and is_sorted_rows
John W. Eaton <jwe@octave.org>
parents:
8733
diff
changeset
|
149 sortmode is_sorted (sortmode mode = UNSORTED) const |
8721
e9cb742df9eb
imported patch sort3.diff
Jaroslav Hajek <highegg@gmail.com>
parents:
8458
diff
changeset
|
150 { return range.is_sorted (mode); } |
e9cb742df9eb
imported patch sort3.diff
Jaroslav Hajek <highegg@gmail.com>
parents:
8458
diff
changeset
|
151 |
8733
3ef774603887
rename all uses of sortrows_idx to sort_rows_idx
John W. Eaton <jwe@octave.org>
parents:
8721
diff
changeset
|
152 Array<octave_idx_type> sort_rows_idx (sortmode) const |
11570
57632dea2446
attempt better backward compatibility for Array constructors
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
153 { return Array<octave_idx_type> (dim_vector (1, 0)); } |
8721
e9cb742df9eb
imported patch sort3.diff
Jaroslav Hajek <highegg@gmail.com>
parents:
8458
diff
changeset
|
154 |
8734
767ed8cc6634
rename internal issorted and issorted_rows functions to is_sorted and is_sorted_rows
John W. Eaton <jwe@octave.org>
parents:
8733
diff
changeset
|
155 sortmode is_sorted_rows (sortmode mode = UNSORTED) const |
8721
e9cb742df9eb
imported patch sort3.diff
Jaroslav Hajek <highegg@gmail.com>
parents:
8458
diff
changeset
|
156 { return mode ? mode : ASCENDING; } |
e9cb742df9eb
imported patch sort3.diff
Jaroslav Hajek <highegg@gmail.com>
parents:
8458
diff
changeset
|
157 |
9685 | 158 builtin_type_t builtin_type (void) const { return btyp_double; } |
159 | |
2376 | 160 bool is_real_type (void) const { return true; } |
161 | |
5895 | 162 bool is_double_type (void) const { return true; } |
163 | |
7576 | 164 bool is_float_type (void) const { return true; } |
165 | |
3678 | 166 bool is_numeric_type (void) const { return true; } |
167 | |
2376 | 168 bool is_true (void) const; |
169 | |
3145 | 170 double double_value (bool = false) const; |
2376 | 171 |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7740
diff
changeset
|
172 float float_value (bool = false) const; |
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7740
diff
changeset
|
173 |
3145 | 174 double scalar_value (bool frc_str_conv = false) const |
175 { return double_value (frc_str_conv); } | |
2916 | 176 |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7740
diff
changeset
|
177 float float_scalar_value (bool frc_str_conv = false) const |
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7740
diff
changeset
|
178 { return float_value (frc_str_conv); } |
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7740
diff
changeset
|
179 |
3145 | 180 Matrix matrix_value (bool = false) const |
2376 | 181 { return range.matrix_value (); } |
182 | |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7740
diff
changeset
|
183 FloatMatrix float_matrix_value (bool = false) const |
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7740
diff
changeset
|
184 { return range.matrix_value (); } |
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7740
diff
changeset
|
185 |
4668 | 186 NDArray array_value (bool = false) const |
187 { return range.matrix_value (); } | |
188 | |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7740
diff
changeset
|
189 FloatNDArray float_array_value (bool = false) const |
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7740
diff
changeset
|
190 { return FloatMatrix (range.matrix_value ()); } |
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7740
diff
changeset
|
191 |
9146
a48c500e48e1
support range->string conversions
Jaroslav Hajek <highegg@gmail.com>
parents:
8971
diff
changeset
|
192 charNDArray char_array_value (bool = false) const; |
11586
12df7854fa7c
strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents:
11584
diff
changeset
|
193 |
6934 | 194 // FIXME -- it would be better to have Range::intXNDArray_value |
195 // functions to avoid the intermediate conversion to a matrix | |
196 // object. | |
197 | |
6932 | 198 int8NDArray |
199 int8_array_value (void) const { return int8NDArray (array_value ()); } | |
200 | |
201 int16NDArray | |
202 int16_array_value (void) const { return int16NDArray (array_value ()); } | |
203 | |
204 int32NDArray | |
205 int32_array_value (void) const { return int32NDArray (array_value ()); } | |
206 | |
207 int64NDArray | |
208 int64_array_value (void) const { return int64NDArray (array_value ()); } | |
209 | |
210 uint8NDArray | |
211 uint8_array_value (void) const { return uint8NDArray (array_value ()); } | |
212 | |
213 uint16NDArray | |
214 uint16_array_value (void) const { return uint16NDArray (array_value ()); } | |
215 | |
216 uint32NDArray | |
217 uint32_array_value (void) const { return uint32NDArray (array_value ()); } | |
218 | |
219 uint64NDArray | |
220 uint64_array_value (void) const { return uint64NDArray (array_value ()); } | |
221 | |
6928 | 222 SparseMatrix sparse_matrix_value (bool = false) const |
223 { return SparseMatrix (range.matrix_value ()); } | |
224 | |
225 SparseComplexMatrix sparse_complex_matrix_value (bool = false) const | |
226 { return SparseComplexMatrix (sparse_matrix_value ()); } | |
227 | |
3145 | 228 Complex complex_value (bool = false) const; |
2376 | 229 |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7740
diff
changeset
|
230 FloatComplex float_complex_value (bool = false) const; |
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7740
diff
changeset
|
231 |
10613
e103fb2182ce
use internal variable instead of warning state to control whether to allow non-integer ranges as indices
John W. Eaton <jwe@octave.org>
parents:
10605
diff
changeset
|
232 boolNDArray bool_array_value (bool warn = false) const; |
5898 | 233 |
3145 | 234 ComplexMatrix complex_matrix_value (bool = false) const |
3587 | 235 { return ComplexMatrix (range.matrix_value ()); } |
2376 | 236 |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7740
diff
changeset
|
237 FloatComplexMatrix float_complex_matrix_value (bool = false) const |
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7740
diff
changeset
|
238 { return FloatComplexMatrix (range.matrix_value ()); } |
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7740
diff
changeset
|
239 |
4668 | 240 ComplexNDArray complex_array_value (bool = false) const |
241 { return ComplexMatrix (range.matrix_value ()); } | |
242 | |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7740
diff
changeset
|
243 FloatComplexNDArray float_complex_array_value (bool = false) const |
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7740
diff
changeset
|
244 { return FloatComplexMatrix (range.matrix_value ()); } |
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7740
diff
changeset
|
245 |
2376 | 246 Range range_value (void) const { return range; } |
247 | |
5279 | 248 octave_value convert_to_str_internal (bool pad, bool force, char type) const; |
2449 | 249 |
3523 | 250 void print (std::ostream& os, bool pr_as_read_syntax = false) const; |
2901 | 251 |
3523 | 252 void print_raw (std::ostream& os, bool pr_as_read_syntax = false) const; |
2901 | 253 |
3523 | 254 bool print_name_tag (std::ostream& os, const std::string& name) const; |
2376 | 255 |
6974 | 256 bool save_ascii (std::ostream& os); |
4687 | 257 |
258 bool load_ascii (std::istream& is); | |
259 | |
260 bool save_binary (std::ostream& os, bool& save_as_floats); | |
261 | |
11586
12df7854fa7c
strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents:
11584
diff
changeset
|
262 bool load_binary (std::istream& is, bool swap, |
10313 | 263 oct_mach_info::float_format fmt); |
4687 | 264 |
265 #if defined (HAVE_HDF5) | |
266 bool save_hdf5 (hid_t loc_id, const char *name, bool save_as_floats); | |
267 | |
9881
b3089dba88bf
Remove HDF5 cruft for older versions of HDF5
Kacper Kowalik
parents:
9812
diff
changeset
|
268 bool load_hdf5 (hid_t loc_id, const char *name); |
4687 | 269 #endif |
270 | |
5051 | 271 int write (octave_stream& os, int block_size, |
10313 | 272 oct_data_conv::data_type output_type, int skip, |
273 oct_mach_info::float_format flt_fmt) const | |
5051 | 274 { |
5775 | 275 // FIXME -- could be more memory efficient by having a |
5051 | 276 // special case of the octave_stream::write method for ranges. |
277 | |
278 return os.write (matrix_value (), block_size, output_type, skip, | |
10313 | 279 flt_fmt); |
5051 | 280 } |
281 | |
5900 | 282 mxArray *as_mxArray (void) const; |
283 | |
9812
f80c566bc751
improve unary mapper system
Jaroslav Hajek <highegg@gmail.com>
parents:
9685
diff
changeset
|
284 octave_value map (unary_mapper_t umap) const |
f80c566bc751
improve unary mapper system
Jaroslav Hajek <highegg@gmail.com>
parents:
9685
diff
changeset
|
285 { |
f80c566bc751
improve unary mapper system
Jaroslav Hajek <highegg@gmail.com>
parents:
9685
diff
changeset
|
286 octave_matrix m (matrix_value ()); |
f80c566bc751
improve unary mapper system
Jaroslav Hajek <highegg@gmail.com>
parents:
9685
diff
changeset
|
287 return m.map (umap); |
7503
8c32f95c2639
convert mapper functions to new format
David Bateman <dbateman@free.fr>
parents:
7463
diff
changeset
|
288 } |
8c32f95c2639
convert mapper functions to new format
David Bateman <dbateman@free.fr>
parents:
7463
diff
changeset
|
289 |
2376 | 290 private: |
291 | |
292 Range range; | |
293 | |
9350
16a5f9e1fdb3
cache idx_vector result in matrices once used for indexing
Jaroslav Hajek <highegg@gmail.com>
parents:
9146
diff
changeset
|
294 idx_vector set_idx_cache (const idx_vector& idx) const |
16a5f9e1fdb3
cache idx_vector result in matrices once used for indexing
Jaroslav Hajek <highegg@gmail.com>
parents:
9146
diff
changeset
|
295 { |
16a5f9e1fdb3
cache idx_vector result in matrices once used for indexing
Jaroslav Hajek <highegg@gmail.com>
parents:
9146
diff
changeset
|
296 delete idx_cache; |
16a5f9e1fdb3
cache idx_vector result in matrices once used for indexing
Jaroslav Hajek <highegg@gmail.com>
parents:
9146
diff
changeset
|
297 idx_cache = idx ? new idx_vector (idx) : 0; |
16a5f9e1fdb3
cache idx_vector result in matrices once used for indexing
Jaroslav Hajek <highegg@gmail.com>
parents:
9146
diff
changeset
|
298 return idx; |
16a5f9e1fdb3
cache idx_vector result in matrices once used for indexing
Jaroslav Hajek <highegg@gmail.com>
parents:
9146
diff
changeset
|
299 } |
16a5f9e1fdb3
cache idx_vector result in matrices once used for indexing
Jaroslav Hajek <highegg@gmail.com>
parents:
9146
diff
changeset
|
300 |
16a5f9e1fdb3
cache idx_vector result in matrices once used for indexing
Jaroslav Hajek <highegg@gmail.com>
parents:
9146
diff
changeset
|
301 void clear_cached_info (void) const |
16a5f9e1fdb3
cache idx_vector result in matrices once used for indexing
Jaroslav Hajek <highegg@gmail.com>
parents:
9146
diff
changeset
|
302 { |
16a5f9e1fdb3
cache idx_vector result in matrices once used for indexing
Jaroslav Hajek <highegg@gmail.com>
parents:
9146
diff
changeset
|
303 delete idx_cache; idx_cache = 0; |
11586
12df7854fa7c
strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents:
11584
diff
changeset
|
304 } |
9350
16a5f9e1fdb3
cache idx_vector result in matrices once used for indexing
Jaroslav Hajek <highegg@gmail.com>
parents:
9146
diff
changeset
|
305 |
16a5f9e1fdb3
cache idx_vector result in matrices once used for indexing
Jaroslav Hajek <highegg@gmail.com>
parents:
9146
diff
changeset
|
306 mutable idx_vector *idx_cache; |
16a5f9e1fdb3
cache idx_vector result in matrices once used for indexing
Jaroslav Hajek <highegg@gmail.com>
parents:
9146
diff
changeset
|
307 |
12233
2aafbdac2ca8
Explicitly disallow copying in some classes
Pascal Dupuis <Pascal.Dupuis@uclouvain.be>
parents:
11586
diff
changeset
|
308 // No assignment. |
2aafbdac2ca8
Explicitly disallow copying in some classes
Pascal Dupuis <Pascal.Dupuis@uclouvain.be>
parents:
11586
diff
changeset
|
309 |
2aafbdac2ca8
Explicitly disallow copying in some classes
Pascal Dupuis <Pascal.Dupuis@uclouvain.be>
parents:
11586
diff
changeset
|
310 octave_range& operator = (const octave_range&); |
2aafbdac2ca8
Explicitly disallow copying in some classes
Pascal Dupuis <Pascal.Dupuis@uclouvain.be>
parents:
11586
diff
changeset
|
311 |
4612 | 312 DECLARE_OCTAVE_ALLOCATOR |
2477 | 313 |
4612 | 314 DECLARE_OV_TYPEID_FUNCTIONS_AND_DATA |
2376 | 315 }; |
316 | |
10613
e103fb2182ce
use internal variable instead of warning state to control whether to allow non-integer ranges as indices
John W. Eaton <jwe@octave.org>
parents:
10605
diff
changeset
|
317 // If TRUE, allow ranges with non-integer elements as array indices. |
e103fb2182ce
use internal variable instead of warning state to control whether to allow non-integer ranges as indices
John W. Eaton <jwe@octave.org>
parents:
10605
diff
changeset
|
318 extern bool Vallow_noninteger_range_as_index; |
e103fb2182ce
use internal variable instead of warning state to control whether to allow non-integer ranges as indices
John W. Eaton <jwe@octave.org>
parents:
10605
diff
changeset
|
319 |
2376 | 320 #endif |