GNU Octave  8.1.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
ov-range.h
Go to the documentation of this file.
1 ////////////////////////////////////////////////////////////////////////
2 //
3 // Copyright (C) 1996-2023 The Octave Project Developers
4 //
5 // See the file COPYRIGHT.md in the top-level directory of this
6 // distribution or <https://octave.org/copyright/>.
7 //
8 // This file is part of Octave.
9 //
10 // Octave is free software: you can redistribute it and/or modify it
11 // under the terms of the GNU General Public License as published by
12 // the Free Software Foundation, either version 3 of the License, or
13 // (at your option) any later version.
14 //
15 // Octave is distributed in the hope that it will be useful, but
16 // WITHOUT ANY WARRANTY; without even the implied warranty of
17 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 // GNU General Public License for more details.
19 //
20 // You should have received a copy of the GNU General Public License
21 // along with Octave; see the file COPYING. If not, see
22 // <https://www.gnu.org/licenses/>.
23 //
24 ////////////////////////////////////////////////////////////////////////
25 
26 #if ! defined (octave_ov_range_h)
27 #define octave_ov_range_h 1
28 
29 #include "octave-config.h"
30 
31 #include <cstdlib>
32 
33 #include <iosfwd>
34 #include <string>
35 #include <type_traits>
36 
37 #include "Array-fwd.h"
38 #include "Range.h"
39 
40 #include "lo-mappers.h"
41 #include "lo-utils.h"
42 #include "mx-base.h"
43 #include "str-vec.h"
44 
45 #include "error.h"
46 #include "oct-stream.h"
47 #include "ov-base.h"
48 #include "ov-range-traits.h"
49 #include "ov-re-mat.h"
50 #include "ov-typeinfo.h"
51 
52 class octave_value_list;
53 
54 // For now, we only need ov_range<double> but we don't attempt to
55 // enforce that restriction.
56 
57 template <typename T>
58 class
60 {
61 public:
62 
63  ov_range (void)
64  : octave_base_value (), m_range (), m_idx_cache () { }
65 
66  ov_range (const octave::range<T>& r)
67  : octave_base_value (), m_range (r), m_idx_cache ()
68  {
69  if (numel () < 0 && numel () != -2)
70  error ("invalid range");
71  }
72 
74  : octave_base_value (), m_range (r.m_range),
75  m_idx_cache (r.m_idx_cache
76  ? new octave::idx_vector (*r.m_idx_cache) : nullptr)
77  { }
78 
79  ov_range (const octave::range<T>& r, const octave::idx_vector& cache)
80  : octave_base_value (), m_range (r), m_idx_cache ()
81  {
82  set_idx_cache (cache);
83  }
84 
85  // No assignment.
86  ov_range& operator = (const ov_range&) = delete;
87 
88  ~ov_range (void) { clear_cached_info (); }
89 
90  octave_base_value * clone (void) const
91  {
92  return new ov_range (*this);
93  }
94 
95  // A range is really just a special kind of real matrix object. In
96  // the places where we need to call empty_clone, it makes more sense
97  // to create an empty matrix (0x0) instead of an empty range (1x0).
98 
100  {
101  return new typename octave_value_range_traits<T>::matrix_type ();
102  }
103 
104  OCTINTERP_API type_conv_info numeric_conversion_function (void) const;
105 
106  OCTINTERP_API octave_base_value * try_narrowing_conversion (void);
107 
109 
110  // We don't need to override all three forms of subsref. The using
111  // declaration will avoid warnings about partially-overloaded virtual
112  // functions.
114 
115  octave_value subsref (const std::string& type,
116  const std::list<octave_value_list>& idx);
117 
118  octave_value_list subsref (const std::string& type,
119  const std::list<octave_value_list>& idx, int)
120  { return subsref (type, idx); }
121 
122  OCTINTERP_API octave_value
123  do_index_op (const octave_value_list& idx, bool resize_ok = false);
124 
125  OCTINTERP_API octave::idx_vector index_vector (bool require_integers = false) const;
126 
127  dim_vector dims (void) const
128  {
129  octave_idx_type n = numel ();
130  return dim_vector (n > 0, n);
131  }
132 
133  octave_idx_type numel (void) const { return m_range.numel (); }
134 
135  octave_idx_type nnz (void) const
136  {
137  // FIXME: this is a potential waste of memory.
138 
139  octave_value tmp (raw_array_value ());
140  return tmp.nnz ();
141  }
142 
143  OCTINTERP_API octave_value
144  resize (const dim_vector& dv, bool fill = false) const;
145 
146  std::size_t byte_size (void) const { return 3 * sizeof (T); }
147 
148  octave_value reshape (const dim_vector& new_dims) const
149  {
150  return raw_array_value ().reshape (new_dims);
151  }
152 
153  octave_value permute (const Array<int>& vec, bool inv = false) const
154  {
155  return raw_array_value ().permute (vec, inv);
156  }
157 
158  octave_value squeeze (void) const { return m_range; }
159 
160  octave_value full_value (void) const { return raw_array_value (); }
161 
162  bool is_defined (void) const { return true; }
163 
164  bool is_storable (void) const { return m_range.is_storable (); }
165 
166  bool is_constant (void) const { return true; }
167 
168  bool is_range (void) const { return true; }
169 
170  bool is_double_type (void) const { return builtin_type () == btyp_double; }
171 
172  bool is_single_type (void) const { return builtin_type () == btyp_float; }
173 
174  bool isfloat (void) const { return btyp_isfloat (builtin_type ()); }
175 
176  bool is_int8_type (void) const { return builtin_type () == btyp_int8; }
177 
178  bool is_int16_type (void) const { return builtin_type () == btyp_int16; }
179 
180  bool is_int32_type (void) const { return builtin_type () == btyp_int32; }
181 
182  bool is_int64_type (void) const { return builtin_type () == btyp_int64; }
183 
184  bool is_uint8_type (void) const { return builtin_type () == btyp_uint8; }
185 
186  bool is_uint16_type (void) const { return builtin_type () == btyp_uint16; }
187 
188  bool is_uint32_type (void) const { return builtin_type () == btyp_uint32; }
189 
190  bool is_uint64_type (void) const { return builtin_type () == btyp_uint64; }
191 
192  bool isinteger (void) const
193  {
194  return btyp_isinteger (builtin_type ());
195  }
196 
197  bool isreal (void) const { return true; }
198 
199  bool isnumeric (void) const
200  {
201  return btyp_isnumeric (builtin_type ());
202  }
203 
204  bool is_true (void) const { return nnz () == numel (); }
205 
206  octave_value all (int dim = 0) const
207  {
208  // FIXME: this is a potential waste of memory.
209 
210  typedef typename octave_value_range_traits<T>::matrix_type ov_mx_type;
211  typename ov_mx_type::object_type m (raw_array_value ());
212 
213  return m.all (dim);
214  }
215 
216  octave_value any (int dim = 0) const
217  {
218  // FIXME: this is a potential waste of memory.
219 
220  typedef typename octave_value_range_traits<T>::matrix_type ov_mx_type;
221  typename ov_mx_type::object_type m (raw_array_value ());
222 
223  return m.any (dim);
224  }
225 
227  {
228  // FIXME: this is a potential waste of memory.
229 
230  return m_range.diag (k);
231  }
232 
234  {
235  // FIXME: this is a potential waste of memory.
236 
237  typedef typename octave_value_range_traits<T>::matrix_type ov_mx_type;
238  typename ov_mx_type::object_type m (raw_array_value ());
239 
240  return m.diag (nr, nc);
241  }
242 
244  {
245  Array<T> tmp = raw_array_value ();
246  return tmp.sort (dim, mode);
247  }
248 
250  sortmode mode = ASCENDING) const
251  {
252  Array<T> tmp = raw_array_value ();
253  return tmp.sort (sidx, dim, mode);
254  }
255 
257  {
258  return m_range.issorted (mode);
259  }
260 
262  {
263  return Array<octave_idx_type> (dim_vector (1, 0));
264  }
265 
267  {
268  return (mode == UNSORTED) ? ASCENDING : mode;
269  }
270 
271  Array<T> raw_array_value (void) const { return m_range.array_value (); }
272 
273  OCTINTERP_API double double_value (bool = false) const;
274 
275  OCTINTERP_API float float_value (bool = false) const;
276 
277  double scalar_value (bool frc_str_conv = false) const
278  {
279  return double_value (frc_str_conv);
280  }
281 
282  float float_scalar_value (bool frc_str_conv = false) const
283  {
284  return float_value (frc_str_conv);
285  }
286 
287  Matrix matrix_value (bool = false) const
288  {
289  return raw_array_value ();
290  }
291 
292  FloatMatrix float_matrix_value (bool = false) const
293  {
294  return raw_array_value ();
295  }
296 
297  NDArray array_value (bool = false) const
298  {
299  return raw_array_value ();
300  }
301 
302  FloatNDArray float_array_value (bool = false) const
303  {
304  return raw_array_value ();
305  }
306 
307  OCTINTERP_API charNDArray char_array_value (bool = false) const;
308 
309  // FIXME: it would be better to have Range::intXNDArray_value
310  // functions to avoid the intermediate conversion to a matrix
311  // object.
312 
314  {
315  return raw_array_value ();
316  }
317 
319  {
320  return raw_array_value ();
321  }
322 
324  {
325  return raw_array_value ();
326  }
327 
329  {
330  return raw_array_value ();
331  }
332 
334  {
335  return raw_array_value ();
336  }
337 
339  {
340  return raw_array_value ();
341  }
342 
344  {
345  return raw_array_value ();
346  }
347 
349  {
350  return raw_array_value ();
351  }
352 
353  SparseMatrix sparse_matrix_value (bool = false) const
354  {
355  return SparseMatrix (matrix_value ());
356  }
357 
359  {
360  return SparseComplexMatrix (complex_matrix_value ());
361  }
362 
363  OCTINTERP_API Complex complex_value (bool = false) const;
364 
365  OCTINTERP_API FloatComplex float_complex_value (bool = false) const;
366 
367  OCTINTERP_API boolNDArray bool_array_value (bool warn = false) const;
368 
369  ComplexMatrix complex_matrix_value (bool = false) const
370  {
371  return raw_array_value ();
372  }
373 
375  {
376  return raw_array_value ();
377  }
378 
379  ComplexNDArray complex_array_value (bool = false) const
380  {
381  return raw_array_value ();
382  }
383 
385  {
386  return raw_array_value ();
387  }
388 
389  OCTINTERP_API octave::range<double> range_value (void) const;
390 
391 // For now, disable all but ov_range<double>.
392 
393 #if 0
394 
395  OCTINTERP_API octave::range<float> float_range_value (void) const;
396 
397  OCTINTERP_API octave::range<octave_int8> int8_range_value (void) const;
398 
399  OCTINTERP_API octave::range<octave_int16> int16_range_value (void) const;
400 
401  OCTINTERP_API octave::range<octave_int32> int32_range_value (void) const;
402 
403  OCTINTERP_API octave::range<octave_int64> int64_range_value (void) const;
404 
405  OCTINTERP_API octave::range<octave_uint8> uint8_range_value (void) const;
406 
407  OCTINTERP_API octave::range<octave_uint16> uint16_range_value (void) const;
408 
409  OCTINTERP_API octave::range<octave_uint32> uint32_range_value (void) const;
410 
411  OCTINTERP_API octave::range<octave_uint64> uint64_range_value (void) const;
412 
413 #endif
414 
415  OCTINTERP_API octave_value
416  convert_to_str_internal (bool pad, bool force, char type) const;
417 
418  OCTINTERP_API octave_value as_double (void) const;
419  OCTINTERP_API octave_value as_single (void) const;
420 
421  OCTINTERP_API octave_value as_int8 (void) const;
422  OCTINTERP_API octave_value as_int16 (void) const;
423  OCTINTERP_API octave_value as_int32 (void) const;
424  OCTINTERP_API octave_value as_int64 (void) const;
425 
426  OCTINTERP_API octave_value as_uint8 (void) const;
427  OCTINTERP_API octave_value as_uint16 (void) const;
428  OCTINTERP_API octave_value as_uint32 (void) const;
429  OCTINTERP_API octave_value as_uint64 (void) const;
430 
431  OCTINTERP_API void print (std::ostream& os, bool pr_as_read_syntax = false);
432 
433  OCTINTERP_API void
434  print_raw (std::ostream& os, bool pr_as_read_syntax = false) const;
435 
436  OCTINTERP_API bool
437  print_name_tag (std::ostream& os, const std::string& name) const;
438 
439  OCTINTERP_API void short_disp (std::ostream& os) const;
440 
441  OCTINTERP_API float_display_format get_edit_display_format (void) const;
442 
443  OCTINTERP_API std::string
444  edit_display (const float_display_format& fmt,
445  octave_idx_type i, octave_idx_type j) const;
446 
447  OCTINTERP_API bool save_ascii (std::ostream& os);
448 
449  OCTINTERP_API bool load_ascii (std::istream& is);
450 
451  OCTINTERP_API bool save_binary (std::ostream& os, bool save_as_floats);
452 
453  OCTINTERP_API bool
454  load_binary (std::istream& is, bool swap,
456 
457  OCTINTERP_API bool
458  save_hdf5 (octave_hdf5_id loc_id, const char *name, bool flag);
459 
460  OCTINTERP_API bool load_hdf5 (octave_hdf5_id loc_id, const char *name);
461 
462  int write (octave::stream& os, int block_size,
463  oct_data_conv::data_type output_type, int skip,
464  octave::mach_info::float_format flt_fmt) const
465  {
466  // FIXME: could be more memory efficient by having a
467  // special case of the octave::stream::write method for ranges.
468 
469  return os.write (matrix_value (), block_size, output_type, skip, flt_fmt);
470  }
471 
472  OCTINTERP_API mxArray * as_mxArray (bool interleaved) const;
473 
475  {
476  octave_value tmp (raw_array_value ());
477  return tmp.map (umap);
478  }
479 
480  OCTINTERP_API octave_value fast_elem_extract (octave_idx_type n) const;
481 
482 protected:
483 
484  octave::range<T> m_range;
485 
487  {
488  delete m_idx_cache;
489  m_idx_cache = (idx ? new octave::idx_vector (idx) : nullptr);
490  return idx;
491  }
492 
493  void clear_cached_info (void) const
494  {
495  delete m_idx_cache; m_idx_cache = nullptr;
496  }
497 
499 
501 
503 };
504 
506 
507 // For now, disable all but ov_range<double>.
508 
509 #if 0
510 
520 
521 #endif
522 
523 // Specializations.
524 
525 template <>
526 OCTINTERP_API octave::range<double>
528 
529 // For now, disable all but ov_range<double>.
530 
531 #if 0
532 
533 template <>
534 OCTINTERP_API octave::range<float>
536 
537 template <>
538 OCTINTERP_API octave::range<octave_int8>
540 
541 template <>
542 OCTINTERP_API octave::range<octave_int16>
544 
545 template <>
546 OCTINTERP_API octave::range<octave_int32>
548 
549 template <>
550 OCTINTERP_API octave::range<octave_int64>
552 
553 template <>
554 OCTINTERP_API octave::range<octave_uint8>
556 
557 template <>
558 OCTINTERP_API octave::range<octave_uint16>
560 
561 template <>
562 OCTINTERP_API octave::range<octave_uint32>
564 
565 template <>
566 OCTINTERP_API octave::range<octave_uint64>
568 
569 #endif
570 
571 // The following specializations are here to preserve previous Range
572 // performance until solutions can be generalized for other types.
573 
574 template <>
575 OCTINTERP_API octave::idx_vector
576 ov_range<double>::index_vector (bool require_integers) const;
577 
578 template <>
579 OCTINTERP_API octave_idx_type
581 
582 // The following specialization is also historical baggage. For double
583 // ranges, we can produce special double-valued diagnoal matrix objects
584 // but Octave currently provides only double and Complex diagonal matrix
585 // objects.
586 
587 template <>
588 OCTINTERP_API octave_value
590 
591 template <>
592 OCTINTERP_API octave_value
594 
595 template <>
596 OCTINTERP_API void
597 ov_range<double>::print_raw (std::ostream& os, bool pr_as_read_syntax) const;
598 
599 
601 
602 // For now, disable all but ov_range<double>.
603 
604 #if 0
605 
606 typedef ov_range<float> octave_float_range;
607 
608 typedef ov_range<octave_int8> octave_int8_range;
609 typedef ov_range<octave_int16> octave_int16_range;
610 typedef ov_range<octave_int32> octave_int32_range;
611 typedef ov_range<octave_int64> octave_int64_range;
612 
613 typedef ov_range<octave_uint8> octave_uint8_range;
614 typedef ov_range<octave_uint16> octave_uint16_range;
615 typedef ov_range<octave_uint32> octave_uint32_range;
616 typedef ov_range<octave_uint64> octave_uint64_range;
617 
618 #endif
619 
621 
622 #endif
OCTARRAY_API Array< T, Alloc > sort(int dim=0, sortmode mode=ASCENDING) const
Size of the specified dimension.
Definition: Array-base.cc:1783
Definition: dMatrix.h:42
Vector representing the dimensions (size) of an Array.
Definition: dim-vector.h:94
virtual octave_value subsref(const std::string &type, const std::list< octave_value_list > &idx)
Definition: ov-base.cc:200
void resize(octave_idx_type n, const octave_value &rfv=octave_value())
Definition: ovl.h:117
octave_value_list & operator=(const octave_value_list &obj)=default
octave_idx_type nnz(void) const
Definition: ov.h:610
octave_value permute(const Array< int > &vec, bool inv=false) const
Definition: ov.h:619
octave_value reshape(const dim_vector &dv) const
Definition: ov.h:616
octave_value map(octave_base_value::unary_mapper_t umap) const
Definition: ov.h:1637
octave_value diag(octave_idx_type k=0) const
Definition: ov.h:1534
ComplexMatrix complex_matrix_value(bool=false) const
Definition: ov-range.h:369
double scalar_value(bool frc_str_conv=false) const
Definition: ov-range.h:277
octave::idx_vector set_idx_cache(const octave::idx_vector &idx) const
Definition: ov-range.h:486
octave_value map(unary_mapper_t umap) const
Definition: ov-range.h:474
ov_range(const ov_range< T > &r)
Definition: ov-range.h:73
uint8NDArray uint8_array_value(void) const
Definition: ov-range.h:333
bool is_int16_type(void) const
Definition: ov-range.h:178
float float_scalar_value(bool frc_str_conv=false) const
Definition: ov-range.h:282
bool is_int8_type(void) const
Definition: ov-range.h:176
octave_idx_type numel(void) const
Definition: ov-range.h:133
dim_vector dims(void) const
Definition: ov-range.h:127
bool is_int64_type(void) const
Definition: ov-range.h:182
sortmode is_sorted_rows(sortmode mode=UNSORTED) const
Definition: ov-range.h:266
octave_value diag(octave_idx_type k=0) const
Definition: ov-range.h:226
ov_range(const octave::range< T > &r)
Definition: ov-range.h:66
int64NDArray int64_array_value(void) const
Definition: ov-range.h:328
static octave_hdf5_id hdf5_save_type
Definition: ov-range.h:500
bool is_uint16_type(void) const
Definition: ov-range.h:186
octave_value sort(octave_idx_type dim=0, sortmode mode=ASCENDING) const
Definition: ov-range.h:243
SparseMatrix sparse_matrix_value(bool=false) const
Definition: ov-range.h:353
Array< T > raw_array_value(void) const
Definition: ov-range.h:271
bool is_single_type(void) const
Definition: ov-range.h:172
FloatNDArray float_array_value(bool=false) const
Definition: ov-range.h:302
sortmode issorted(sortmode mode=UNSORTED) const
Definition: ov-range.h:256
bool is_constant(void) const
Definition: ov-range.h:166
bool isfloat(void) const
Definition: ov-range.h:174
FloatComplexMatrix float_complex_matrix_value(bool=false) const
Definition: ov-range.h:374
OCTINTERP_API void print_raw(std::ostream &os, bool pr_as_read_syntax=false) const
Definition: ov-range.cc:581
NDArray array_value(bool=false) const
Definition: ov-range.h:297
bool is_uint8_type(void) const
Definition: ov-range.h:184
octave_value squeeze(void) const
Definition: ov-range.h:158
octave_value all(int dim=0) const
Definition: ov-range.h:206
uint64NDArray uint64_array_value(void) const
Definition: ov-range.h:348
bool isnumeric(void) const
Definition: ov-range.h:199
int16NDArray int16_array_value(void) const
Definition: ov-range.h:318
bool is_uint32_type(void) const
Definition: ov-range.h:188
OCTINTERP_API octave::range< double > range_value(void) const
Definition: ov-range.cc:417
uint16NDArray uint16_array_value(void) const
Definition: ov-range.h:338
bool isreal(void) const
Definition: ov-range.h:197
octave::range< T > m_range
Definition: ov-range.h:484
bool is_storable(void) const
Definition: ov-range.h:164
bool isinteger(void) const
Definition: ov-range.h:192
octave_value_list subsref(const std::string &type, const std::list< octave_value_list > &idx, int)
Definition: ov-range.h:118
ov_range(void)
Definition: ov-range.h:63
bool is_range(void) const
Definition: ov-range.h:168
void clear_cached_info(void) const
Definition: ov-range.h:493
octave_value any(int dim=0) const
Definition: ov-range.h:216
octave_base_value * clone(void) const
Definition: ov-range.h:90
octave_value full_value(void) const
Definition: ov-range.h:160
ComplexNDArray complex_array_value(bool=false) const
Definition: ov-range.h:379
octave_value diag(octave_idx_type nr, octave_idx_type nc) const
Definition: ov-range.h:233
octave::idx_vector * m_idx_cache
Definition: ov-range.h:498
int8NDArray int8_array_value(void) const
Definition: ov-range.h:313
FloatMatrix float_matrix_value(bool=false) const
Definition: ov-range.h:292
std::size_t byte_size(void) const
Definition: ov-range.h:146
ov_range(const octave::range< T > &r, const octave::idx_vector &cache)
Definition: ov-range.h:79
Matrix matrix_value(bool=false) const
Definition: ov-range.h:287
SparseComplexMatrix sparse_complex_matrix_value(bool=false) const
Definition: ov-range.h:358
bool is_uint64_type(void) const
Definition: ov-range.h:190
Array< octave_idx_type > sort_rows_idx(sortmode) const
Definition: ov-range.h:261
~ov_range(void)
Definition: ov-range.h:88
octave_value reshape(const dim_vector &new_dims) const
Definition: ov-range.h:148
int write(octave::stream &os, int block_size, oct_data_conv::data_type output_type, int skip, octave::mach_info::float_format flt_fmt) const
Definition: ov-range.h:462
uint32NDArray uint32_array_value(void) const
Definition: ov-range.h:343
bool is_int32_type(void) const
Definition: ov-range.h:180
octave_value permute(const Array< int > &vec, bool inv=false) const
Definition: ov-range.h:153
bool is_defined(void) const
Definition: ov-range.h:162
bool is_true(void) const
Definition: ov-range.h:204
FloatComplexNDArray float_complex_array_value(bool=false) const
Definition: ov-range.h:384
bool is_double_type(void) const
Definition: ov-range.h:170
octave_idx_type nnz(void) const
Definition: ov-range.h:135
builtin_type_t builtin_type(void) const
Definition: ov-range.h:108
octave_value sort(Array< octave_idx_type > &sidx, octave_idx_type dim=0, sortmode mode=ASCENDING) const
Definition: ov-range.h:249
OCTINTERP_API octave::idx_vector index_vector(bool require_integers=false) const
Definition: ov-range.cc:304
octave_base_value * empty_clone(void) const
Definition: ov-range.h:99
int32NDArray int32_array_value(void) const
Definition: ov-range.h:323
void error(const char *fmt,...)
Definition: error.cc:979
octave::idx_vector idx_vector
Definition: idx-vector.h:1039
float_format
Definition: mach-info.h:38
class OCTAVE_API SparseMatrix
Definition: mx-fwd.h:55
class OCTAVE_API SparseComplexMatrix
Definition: mx-fwd.h:56
T octave_idx_type m
Definition: mx-inlines.cc:773
octave_idx_type n
Definition: mx-inlines.cc:753
T * r
Definition: mx-inlines.cc:773
std::complex< double > Complex
Definition: oct-cmplx.h:33
std::complex< float > FloatComplex
Definition: oct-cmplx.h:34
int64_t octave_hdf5_id
sortmode
Definition: oct-sort.h:97
@ UNSORTED
Definition: oct-sort.h:97
@ ASCENDING
Definition: oct-sort.h:97
T::size_type numel(const T &str)
Definition: oct-string.cc:71
static double as_double(OCTAVE_TIME_T sec, long usec)
Definition: oct-time.h:35
bool btyp_isnumeric(builtin_type_t btyp)
Definition: ov-base.h:107
bool btyp_isinteger(builtin_type_t btyp)
Definition: ov-base.h:110
#define DECLARE_TEMPLATE_OV_TYPEID_SPECIALIZATIONS(cls, type)
Definition: ov-base.h:203
#define DECLARE_OV_TYPEID_FUNCTIONS_AND_DATA
Definition: ov-base.h:181
bool btyp_isfloat(builtin_type_t btyp)
Definition: ov-base.h:113
builtin_type_t
Definition: ov-base.h:83
@ btyp_double
Definition: ov-base.h:84
@ btyp_int32
Definition: ov-base.h:90
@ btyp_float
Definition: ov-base.h:85
@ btyp_uint16
Definition: ov-base.h:93
@ btyp_int64
Definition: ov-base.h:91
@ btyp_uint64
Definition: ov-base.h:95
@ btyp_int16
Definition: ov-base.h:89
@ btyp_uint32
Definition: ov-base.h:94
@ btyp_uint8
Definition: ov-base.h:92
@ btyp_int8
Definition: ov-base.h:88
ov_range< double > octave_double_range
Definition: ov-range.h:600
octave_double_range octave_range
Definition: ov-range.h:620
static float_display_format get_edit_display_format(const octave_value &val)