Mercurial > octave
annotate libinterp/octave-value/ov.h @ 31260:c5c8bf50449c
Improve performance of isfield from linear time to constant time (bug #58105)
Patch author: Anonymous in Bug #58105 Comment #7
https://savannah.gnu.org/bugs/index.php?58105#comment7
The isfield function was taking time proportional to the number of
fields in a struct to determine whether something was a member or not.
With this change, isfield performance becomes constant irrespective
of the number of fields, speeding up performance by over 200X, and
also allowing the use of struct as a hashmap if the user desires.
ov-base.h: Add new isfield function declaration
ov-base.cc: Add new isfield function definition
ov-struct.h: Add new isfield function definitions
ov-struct.cc: Do not call map_value
ov.h: Add new isfield function definition
author | Arun Giridhar <arungiridhar@gmail.com> |
---|---|
date | Wed, 05 Oct 2022 10:35:31 -0400 |
parents | eba0a86471b9 |
children | 9a0ce9eea1b7 e88a07dec498 |
rev | line source |
---|---|
27923
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
1 //////////////////////////////////////////////////////////////////////// |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
2 // |
30564
796f54d4ddbf
update Octave Project Developers copyright for the new year
John W. Eaton <jwe@octave.org>
parents:
30510
diff
changeset
|
3 // Copyright (C) 1996-2022 The Octave Project Developers |
27923
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
4 // |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
5 // See the file COPYRIGHT.md in the top-level directory of this |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
6 // distribution or <https://octave.org/copyright/>. |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
7 // |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
8 // This file is part of Octave. |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
9 // |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
10 // Octave is free software: you can redistribute it and/or modify it |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
11 // under the terms of the GNU General Public License as published by |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
12 // the Free Software Foundation, either version 3 of the License, or |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
13 // (at your option) any later version. |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
14 // |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
15 // Octave is distributed in the hope that it will be useful, but |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
16 // WITHOUT ANY WARRANTY; without even the implied warranty of |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
17 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
18 // GNU General Public License for more details. |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
19 // |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
20 // You should have received a copy of the GNU General Public License |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
21 // along with Octave; see the file COPYING. If not, see |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
22 // <https://www.gnu.org/licenses/>. |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
23 // |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
24 //////////////////////////////////////////////////////////////////////// |
2376 | 25 |
20791
f7084eae3318
maint: Use Octave coding conventions for #if statements.
Rik <rik@octave.org>
parents:
20768
diff
changeset
|
26 #if ! defined (octave_ov_h) |
17822
ebb3ef964372
maint: Use common #define syntax "octave_filename_h" in h_files.
Rik <rik@octave.org>
parents:
17787
diff
changeset
|
27 #define octave_ov_h 1 |
2376 | 28 |
21244
1473547f50f5
include octave-config.h in public header files
John W. Eaton <jwe@octave.org>
parents:
21139
diff
changeset
|
29 #include "octave-config.h" |
1473547f50f5
include octave-config.h in public header files
John W. Eaton <jwe@octave.org>
parents:
21139
diff
changeset
|
30 |
2376 | 31 #include <cstdlib> |
32 | |
8950
d865363208d6
include <iosfwd> instead of <iostream> in header files
John W. Eaton <jwe@octave.org>
parents:
8920
diff
changeset
|
33 #include <iosfwd> |
2376 | 34 #include <string> |
4219 | 35 #include <list> |
29476
c74ff452e2bb
avoid memory leaks when returning handles to nested functions
John W. Eaton <jwe@octave.org>
parents:
29358
diff
changeset
|
36 #include <memory> |
23678
dcba41788495
new struct/map constructors
John W. Eaton <jwe@octave.org>
parents:
23615
diff
changeset
|
37 #include <map> |
2376 | 38 |
39 #include "Range.h" | |
5828 | 40 #include "data-conv.h" |
2376 | 41 #include "idx-vector.h" |
5828 | 42 #include "mach-info.h" |
2376 | 43 #include "mx-base.h" |
23059
b98ebcd7f11c
move some octave stream classes into octave namespace
John W. Eaton <jwe@octave.org>
parents:
22755
diff
changeset
|
44 #include "oct-sort.h" |
4254 | 45 #include "oct-time.h" |
2942 | 46 #include "str-vec.h" |
47 | |
29960
939bef0b66e0
merge "namespace octave" and OCTAVE_NAMESPACE_BEGIN/END blocks
John W. Eaton <jwe@octave.org>
parents:
29954
diff
changeset
|
48 OCTAVE_NAMESPACE_BEGIN |
939bef0b66e0
merge "namespace octave" and OCTAVE_NAMESPACE_BEGIN/END blocks
John W. Eaton <jwe@octave.org>
parents:
29954
diff
changeset
|
49 |
29476
c74ff452e2bb
avoid memory leaks when returning handles to nested functions
John W. Eaton <jwe@octave.org>
parents:
29358
diff
changeset
|
50 class stack_frame; |
24540
46440078d73b
don't use singleton for octave_value_typeinfo
John W. Eaton <jwe@octave.org>
parents:
24534
diff
changeset
|
51 class type_info; |
29960
939bef0b66e0
merge "namespace octave" and OCTAVE_NAMESPACE_BEGIN/END blocks
John W. Eaton <jwe@octave.org>
parents:
29954
diff
changeset
|
52 |
939bef0b66e0
merge "namespace octave" and OCTAVE_NAMESPACE_BEGIN/END blocks
John W. Eaton <jwe@octave.org>
parents:
29954
diff
changeset
|
53 OCTAVE_NAMESPACE_END |
24540
46440078d73b
don't use singleton for octave_value_typeinfo
John W. Eaton <jwe@octave.org>
parents:
24534
diff
changeset
|
54 |
3351 | 55 class Cell; |
24668
d4dd741b2794
new octave_value functions for formatting output
John W. Eaton <jwe@octave.org>
parents:
24643
diff
changeset
|
56 class float_format; |
15149
62a35ae7d6a2
use forward decls for mxArray in ov.h and ov-base.h
John W. Eaton <jwe@octave.org>
parents:
15140
diff
changeset
|
57 class mxArray; |
10742
604e13a89c7f
initial code for structs rewrite
Jaroslav Hajek <highegg@gmail.com>
parents:
10670
diff
changeset
|
58 class octave_map; |
604e13a89c7f
initial code for structs rewrite
Jaroslav Hajek <highegg@gmail.com>
parents:
10670
diff
changeset
|
59 class octave_scalar_map; |
2974 | 60 class octave_function; |
4700 | 61 class octave_user_function; |
4342 | 62 class octave_fcn_handle; |
2376 | 63 class octave_value_list; |
64 | |
28123
4963f23b145c
move mex type definitions to separate file
John W. Eaton <jwe@octave.org>
parents:
27923
diff
changeset
|
65 #include "mxtypes.h" |
4963f23b145c
move mex type definitions to separate file
John W. Eaton <jwe@octave.org>
parents:
27923
diff
changeset
|
66 |
23059
b98ebcd7f11c
move some octave stream classes into octave namespace
John W. Eaton <jwe@octave.org>
parents:
22755
diff
changeset
|
67 #include "oct-stream.h" |
5759 | 68 #include "ov-base.h" |
2376 | 69 |
70 class | |
6109 | 71 OCTINTERP_API |
2974 | 72 octave_value |
2376 | 73 { |
74 public: | |
75 | |
3203 | 76 enum unary_op |
77 { | |
6518 | 78 op_not, // not |
79 op_uplus, // uplus | |
80 op_uminus, // uminus | |
81 op_transpose, // transpose | |
82 op_hermitian, // ctranspose | |
3525 | 83 op_incr, |
84 op_decr, | |
3203 | 85 num_unary_ops, |
86 unknown_unary_op | |
87 }; | |
88 | |
2376 | 89 enum binary_op |
90 { | |
6518 | 91 op_add, // plus |
92 op_sub, // minus | |
93 op_mul, // mtimes | |
94 op_div, // mrdivide | |
95 op_pow, // mpower | |
96 op_ldiv, // mldivide | |
97 op_lt, // lt | |
98 op_le, // le | |
99 op_eq, // eq | |
100 op_ge, // ge | |
101 op_gt, // gt | |
102 op_ne, // ne | |
103 op_el_mul, // times | |
104 op_el_div, // rdivide | |
105 op_el_pow, // power | |
106 op_el_ldiv, // ldivide | |
107 op_el_and, // and | |
108 op_el_or, // or | |
3525 | 109 op_struct_ref, |
2376 | 110 num_binary_ops, |
111 unknown_binary_op | |
112 }; | |
113 | |
7800
5861b95e9879
support for compound operators, implement trans_mul, mul_trans, herm_mul and mul_herm
Jaroslav Hajek <highegg@gmail.com>
parents:
7789
diff
changeset
|
114 enum compound_binary_op |
5861b95e9879
support for compound operators, implement trans_mul, mul_trans, herm_mul and mul_herm
Jaroslav Hajek <highegg@gmail.com>
parents:
7789
diff
changeset
|
115 { |
5861b95e9879
support for compound operators, implement trans_mul, mul_trans, herm_mul and mul_herm
Jaroslav Hajek <highegg@gmail.com>
parents:
7789
diff
changeset
|
116 // ** compound operations ** |
11586
12df7854fa7c
strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
117 op_trans_mul, |
7800
5861b95e9879
support for compound operators, implement trans_mul, mul_trans, herm_mul and mul_herm
Jaroslav Hajek <highegg@gmail.com>
parents:
7789
diff
changeset
|
118 op_mul_trans, |
11586
12df7854fa7c
strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
119 op_herm_mul, |
7800
5861b95e9879
support for compound operators, implement trans_mul, mul_trans, herm_mul and mul_herm
Jaroslav Hajek <highegg@gmail.com>
parents:
7789
diff
changeset
|
120 op_mul_herm, |
9661
afcf852256d2
optimize / and '\ for triangular matrices
Jaroslav Hajek <highegg@gmail.com>
parents:
9657
diff
changeset
|
121 op_trans_ldiv, |
afcf852256d2
optimize / and '\ for triangular matrices
Jaroslav Hajek <highegg@gmail.com>
parents:
9657
diff
changeset
|
122 op_herm_ldiv, |
8982
dc6bda6f9994
implement compound logical ops
Jaroslav Hajek <highegg@gmail.com>
parents:
8960
diff
changeset
|
123 op_el_not_and, |
dc6bda6f9994
implement compound logical ops
Jaroslav Hajek <highegg@gmail.com>
parents:
8960
diff
changeset
|
124 op_el_not_or, |
dc6bda6f9994
implement compound logical ops
Jaroslav Hajek <highegg@gmail.com>
parents:
8960
diff
changeset
|
125 op_el_and_not, |
dc6bda6f9994
implement compound logical ops
Jaroslav Hajek <highegg@gmail.com>
parents:
8960
diff
changeset
|
126 op_el_or_not, |
7800
5861b95e9879
support for compound operators, implement trans_mul, mul_trans, herm_mul and mul_herm
Jaroslav Hajek <highegg@gmail.com>
parents:
7789
diff
changeset
|
127 num_compound_binary_ops, |
5861b95e9879
support for compound operators, implement trans_mul, mul_trans, herm_mul and mul_herm
Jaroslav Hajek <highegg@gmail.com>
parents:
7789
diff
changeset
|
128 unknown_compound_binary_op |
5861b95e9879
support for compound operators, implement trans_mul, mul_trans, herm_mul and mul_herm
Jaroslav Hajek <highegg@gmail.com>
parents:
7789
diff
changeset
|
129 }; |
5861b95e9879
support for compound operators, implement trans_mul, mul_trans, herm_mul and mul_herm
Jaroslav Hajek <highegg@gmail.com>
parents:
7789
diff
changeset
|
130 |
2880 | 131 enum assign_op |
132 { | |
3525 | 133 op_asn_eq, |
134 op_add_eq, | |
135 op_sub_eq, | |
136 op_mul_eq, | |
137 op_div_eq, | |
138 op_ldiv_eq, | |
4018 | 139 op_pow_eq, |
3525 | 140 op_el_mul_eq, |
141 op_el_div_eq, | |
142 op_el_ldiv_eq, | |
4018 | 143 op_el_pow_eq, |
3525 | 144 op_el_and_eq, |
145 op_el_or_eq, | |
2880 | 146 num_assign_ops, |
147 unknown_assign_op | |
148 }; | |
149 | |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
150 static OCTINTERP_API binary_op assign_op_to_binary_op (assign_op); |
15140
6ea86e1d0f5f
Support +=, -=, *=, ect. in JIT
Max Brister <max@2bass.com>
parents:
15057
diff
changeset
|
151 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
152 static OCTINTERP_API assign_op binary_op_to_assign_op (binary_op); |
9607
1be3c73ed7b5
reuse temporary arrays in nested expressions
Jaroslav Hajek <highegg@gmail.com>
parents:
9521
diff
changeset
|
153 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
154 static OCTINTERP_API std::string unary_op_as_string (unary_op); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
155 static OCTINTERP_API std::string unary_op_fcn_name (unary_op); |
3203 | 156 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
157 static OCTINTERP_API std::string binary_op_as_string (binary_op); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
158 static OCTINTERP_API std::string binary_op_fcn_name (binary_op); |
2376 | 159 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
160 static OCTINTERP_API std::string binary_op_fcn_name (compound_binary_op); |
7800
5861b95e9879
support for compound operators, implement trans_mul, mul_trans, herm_mul and mul_herm
Jaroslav Hajek <highegg@gmail.com>
parents:
7789
diff
changeset
|
161 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
162 static OCTINTERP_API std::string assign_op_as_string (assign_op); |
2880 | 163 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
164 static OCTINTERP_API octave_value |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
165 empty_conv (const std::string& type, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
166 const octave_value& rhs = octave_value ()); |
3933 | 167 |
2376 | 168 enum magic_colon { magic_colon_t }; |
169 | |
8992
d12f44a5dce3
implement fast octave_value constructor
Jaroslav Hajek <highegg@gmail.com>
parents:
8982
diff
changeset
|
170 octave_value (void) |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
171 : m_rep (nil_rep ()) |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
172 { |
30139
c789e728d57a
Backed out changeset 938794bc82b7
John W. Eaton <jwe@octave.org>
parents:
30133
diff
changeset
|
173 m_rep->count++; |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
174 } |
8992
d12f44a5dce3
implement fast octave_value constructor
Jaroslav Hajek <highegg@gmail.com>
parents:
8982
diff
changeset
|
175 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
176 OCTINTERP_API octave_value (short int i); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
177 OCTINTERP_API octave_value (unsigned short int i); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
178 OCTINTERP_API octave_value (int i); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
179 OCTINTERP_API octave_value (unsigned int i); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
180 OCTINTERP_API octave_value (long int i); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
181 OCTINTERP_API octave_value (unsigned long int i); |
4353 | 182 |
21013
7f4c6d594e3d
Finish renaming mapper function finite to isfinite.
Rik <rik@octave.org>
parents:
21012
diff
changeset
|
183 // FIXME: These are kluges. They turn into doubles internally, which will |
7f4c6d594e3d
Finish renaming mapper function finite to isfinite.
Rik <rik@octave.org>
parents:
21012
diff
changeset
|
184 // break for very large values. We just use them to store things like |
7f4c6d594e3d
Finish renaming mapper function finite to isfinite.
Rik <rik@octave.org>
parents:
21012
diff
changeset
|
185 // 64-bit ino_t, etc, and hope that those values are never actually larger |
7f4c6d594e3d
Finish renaming mapper function finite to isfinite.
Rik <rik@octave.org>
parents:
21012
diff
changeset
|
186 // than can be represented exactly in a double. |
4353 | 187 |
21354
06d15e4e611a
move public data type macros to octave-config.h
John W. Eaton <jwe@octave.org>
parents:
21294
diff
changeset
|
188 #if defined (OCTAVE_HAVE_LONG_LONG_INT) |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
189 OCTINTERP_API octave_value (long long int i); |
4353 | 190 #endif |
21354
06d15e4e611a
move public data type macros to octave-config.h
John W. Eaton <jwe@octave.org>
parents:
21294
diff
changeset
|
191 #if defined (OCTAVE_HAVE_UNSIGNED_LONG_LONG_INT) |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
192 OCTINTERP_API octave_value (unsigned long long int i); |
4353 | 193 #endif |
194 | |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
195 OCTINTERP_API octave_value (octave::sys::time t); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
196 OCTINTERP_API octave_value (double d); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
197 OCTINTERP_API octave_value (float d); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
198 OCTINTERP_API octave_value (const Array<octave_value>& a, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
199 bool is_cs_list = false); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
200 OCTINTERP_API octave_value (const Cell& c, bool is_cs_list = false); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
201 OCTINTERP_API octave_value (const Matrix& m, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
202 const MatrixType& t = MatrixType ()); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
203 OCTINTERP_API octave_value (const FloatMatrix& m, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
204 const MatrixType& t = MatrixType ()); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
205 OCTINTERP_API octave_value (const NDArray& nda); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
206 OCTINTERP_API octave_value (const FloatNDArray& nda); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
207 OCTINTERP_API octave_value (const Array<double>& m); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
208 OCTINTERP_API octave_value (const Array<float>& m); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
209 OCTINTERP_API octave_value (const DiagMatrix& d); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
210 OCTINTERP_API octave_value (const DiagArray2<double>& d); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
211 OCTINTERP_API octave_value (const DiagArray2<float>& d); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
212 OCTINTERP_API octave_value (const DiagArray2<Complex>& d); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
213 OCTINTERP_API octave_value (const DiagArray2<FloatComplex>& d); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
214 OCTINTERP_API octave_value (const FloatDiagMatrix& d); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
215 OCTINTERP_API octave_value (const RowVector& v); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
216 OCTINTERP_API octave_value (const FloatRowVector& v); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
217 OCTINTERP_API octave_value (const ColumnVector& v); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
218 OCTINTERP_API octave_value (const FloatColumnVector& v); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
219 OCTINTERP_API octave_value (const Complex& C); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
220 OCTINTERP_API octave_value (const FloatComplex& C); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
221 OCTINTERP_API octave_value (const ComplexMatrix& m, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
222 const MatrixType& t = MatrixType ()); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
223 OCTINTERP_API octave_value (const FloatComplexMatrix& m, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
224 const MatrixType& t = MatrixType ()); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
225 OCTINTERP_API octave_value (const ComplexNDArray& cnda); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
226 OCTINTERP_API octave_value (const FloatComplexNDArray& cnda); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
227 OCTINTERP_API octave_value (const Array<Complex>& m); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
228 OCTINTERP_API octave_value (const Array<FloatComplex>& m); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
229 OCTINTERP_API octave_value (const ComplexDiagMatrix& d); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
230 OCTINTERP_API octave_value (const FloatComplexDiagMatrix& d); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
231 OCTINTERP_API octave_value (const ComplexRowVector& v); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
232 OCTINTERP_API octave_value (const FloatComplexRowVector& v); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
233 OCTINTERP_API octave_value (const ComplexColumnVector& v); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
234 OCTINTERP_API octave_value (const FloatComplexColumnVector& v); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
235 OCTINTERP_API octave_value (const PermMatrix& p); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
236 OCTINTERP_API octave_value (bool b); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
237 OCTINTERP_API octave_value (const boolMatrix& bm, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
238 const MatrixType& t = MatrixType ()); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
239 OCTINTERP_API octave_value (const boolNDArray& bnda); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
240 OCTINTERP_API octave_value (const Array<bool>& bnda); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
241 OCTINTERP_API octave_value (char c, char type = '\''); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
242 OCTINTERP_API octave_value (const char *s, char type = '\''); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
243 OCTINTERP_API octave_value (const std::string& s, char type = '\''); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
244 OCTINTERP_API octave_value (const string_vector& s, char type = '\''); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
245 OCTINTERP_API octave_value (const charMatrix& chm, char type = '\''); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
246 OCTINTERP_API octave_value (const charNDArray& chnda, char type = '\''); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
247 OCTINTERP_API octave_value (const Array<char>& chnda, char type = '\''); |
21134
2e5c1f766ac9
provide replacement hints for deprecated C++ functions
John W. Eaton <jwe@octave.org>
parents:
21076
diff
changeset
|
248 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
249 OCTINTERP_API octave_value (const SparseMatrix& m, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
250 const MatrixType& t = MatrixType ()); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
251 OCTINTERP_API octave_value (const Sparse<double>& m, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
252 const MatrixType& t = MatrixType ()); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
253 OCTINTERP_API octave_value (const SparseComplexMatrix& m, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
254 const MatrixType& t = MatrixType ()); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
255 OCTINTERP_API octave_value (const Sparse<Complex>& m, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
256 const MatrixType& t = MatrixType ()); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
257 OCTINTERP_API octave_value (const SparseBoolMatrix& bm, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
258 const MatrixType& t = MatrixType ()); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
259 OCTINTERP_API octave_value (const Sparse<bool>& m, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
260 const MatrixType& t = MatrixType ()); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
261 OCTINTERP_API octave_value (const octave_int8& i); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
262 OCTINTERP_API octave_value (const octave_int16& i); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
263 OCTINTERP_API octave_value (const octave_int32& i); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
264 OCTINTERP_API octave_value (const octave_int64& i); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
265 OCTINTERP_API octave_value (const octave_uint8& i); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
266 OCTINTERP_API octave_value (const octave_uint16& i); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
267 OCTINTERP_API octave_value (const octave_uint32& i); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
268 OCTINTERP_API octave_value (const octave_uint64& i); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
269 OCTINTERP_API octave_value (const int8NDArray& inda); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
270 OCTINTERP_API octave_value (const Array<octave_int8>& inda); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
271 OCTINTERP_API octave_value (const int16NDArray& inda); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
272 OCTINTERP_API octave_value (const Array<octave_int16>& inda); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
273 OCTINTERP_API octave_value (const int32NDArray& inda); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
274 OCTINTERP_API octave_value (const Array<octave_int32>& inda); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
275 OCTINTERP_API octave_value (const int64NDArray& inda); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
276 OCTINTERP_API octave_value (const Array<octave_int64>& inda); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
277 OCTINTERP_API octave_value (const uint8NDArray& inda); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
278 OCTINTERP_API octave_value (const Array<octave_uint8>& inda); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
279 OCTINTERP_API octave_value (const uint16NDArray& inda); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
280 OCTINTERP_API octave_value (const Array<octave_uint16>& inda); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
281 OCTINTERP_API octave_value (const uint32NDArray& inda); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
282 OCTINTERP_API octave_value (const Array<octave_uint32>& inda); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
283 OCTINTERP_API octave_value (const uint64NDArray& inda); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
284 OCTINTERP_API octave_value (const Array<octave_uint64>& inda); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
285 OCTINTERP_API octave_value (const Array<octave_idx_type>& inda, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
286 bool zero_based = false, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
287 bool cache_index = false); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
288 OCTINTERP_API octave_value (const Array<std::string>& cellstr); |
29569
29a1f8fd8ee6
move idx_vector classes inside octave namespace
John W. Eaton <jwe@octave.org>
parents:
29478
diff
changeset
|
289 OCTINTERP_API octave_value (const octave::idx_vector& idx, bool lazy = true); |
29954
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
290 |
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
291 private: |
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
292 |
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
293 // Remove when public constructors that use this function are removed. |
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
294 static OCTINTERP_API octave_base_value * |
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
295 make_range_rep_deprecated (double base, double inc, double limit); |
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
296 |
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
297 // Remove when public constructors that use this function are removed. |
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
298 static OCTINTERP_API octave_base_value * |
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
299 make_range_rep_deprecated (const Range& r, bool force_range); |
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
300 |
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
301 public: |
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
302 |
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
303 #if defined (OCTAVE_PROVIDE_DEPRECATED_SYMBOLS) |
28638
98192ec1621f
replace Range with range<double>
John W. Eaton <jwe@octave.org>
parents:
28633
diff
changeset
|
304 OCTAVE_DEPRECATED (7, "use 'octave_value (range<double>&)' instead") |
30510
84344af9b019
ov.h: Don't mark definitions in header with visibility flags.
Markus Mützel <markus.muetzel@gmx.de>
parents:
30390
diff
changeset
|
305 octave_value (double base, double limit, double inc) |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
306 : m_rep (make_range_rep_deprecated (base, inc, limit)) |
29954
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
307 { |
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
308 maybe_mutate (); |
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
309 } |
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
310 |
28638
98192ec1621f
replace Range with range<double>
John W. Eaton <jwe@octave.org>
parents:
28633
diff
changeset
|
311 OCTAVE_DEPRECATED (7, "use 'octave_value (range<double>&)' instead") |
30510
84344af9b019
ov.h: Don't mark definitions in header with visibility flags.
Markus Mützel <markus.muetzel@gmx.de>
parents:
30390
diff
changeset
|
312 octave_value (const Range& r, bool force_range = false) |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
313 : m_rep (make_range_rep_deprecated (r, force_range)) |
29954
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
314 { |
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
315 maybe_mutate (); |
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
316 } |
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
317 #endif |
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
318 |
30835
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
319 OCTINTERP_API octave_value (const octave::range<double>& r, |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
320 bool force_range = false); |
30835
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
321 |
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
322 // For now, disable all but range<double>. |
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
323 |
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
324 #if 0 |
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
325 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
326 OCTINTERP_API octave_value (const octave::range<float>& r, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
327 bool force_range = false); |
30835
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
328 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
329 OCTINTERP_API octave_value (const octave::range<octave_int8>& r, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
330 bool force_range = false); |
30835
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
331 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
332 OCTINTERP_API octave_value (const octave::range<octave_int16>& r, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
333 bool force_range = false); |
30835
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
334 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
335 OCTINTERP_API octave_value (const octave::range<octave_int32>& r, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
336 bool force_range = false); |
30835
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
337 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
338 OCTINTERP_API octave_value (const octave::range<octave_int64>& r, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
339 bool force_range = false); |
30835
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
340 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
341 OCTINTERP_API octave_value (const octave::range<octave_uint8>& r, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
342 bool force_range = false); |
30835
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
343 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
344 OCTINTERP_API octave_value (const octave::range<octave_uint16>& r, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
345 bool force_range = false); |
30835
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
346 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
347 OCTINTERP_API octave_value (const octave::range<octave_uint32>& r, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
348 bool force_range = false); |
30835
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
349 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
350 OCTINTERP_API octave_value (const octave::range<octave_uint64>& r, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
351 bool force_range = false); |
30835
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
352 |
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
353 OCTINTERP_API octave_value (const octave::range<char>& r, char type, |
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
354 bool force_range = false); |
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
355 #endif |
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
356 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
357 OCTINTERP_API octave_value (const octave_map& m); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
358 OCTINTERP_API octave_value (const octave_scalar_map& m); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
359 OCTINTERP_API octave_value (const std::map<std::string, octave_value>&); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
360 OCTINTERP_API octave_value (const octave_map& m, const std::string& id, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
361 const std::list<std::string>& plist); |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
362 OCTINTERP_API octave_value (const octave_scalar_map& m, const std::string& id, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
363 const std::list<std::string>& plist); |
23352
778fdffc09df
deprecate "octave_value (octave_value_list, bool)" constructor
John W. Eaton <jwe@octave.org>
parents:
23220
diff
changeset
|
364 |
23913
062ce545b21e
mark octave_value from octave_value_list constructor explicit
John W. Eaton <jwe@octave.org>
parents:
23881
diff
changeset
|
365 // This one is explicit because it can cause some trouble to |
062ce545b21e
mark octave_value from octave_value_list constructor explicit
John W. Eaton <jwe@octave.org>
parents:
23881
diff
changeset
|
366 // accidentally create a cs-list when one was not intended. |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
367 explicit OCTINTERP_API octave_value (const octave_value_list& m); |
23352
778fdffc09df
deprecate "octave_value (octave_value_list, bool)" constructor
John W. Eaton <jwe@octave.org>
parents:
23220
diff
changeset
|
368 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
369 OCTINTERP_API octave_value (octave_value::magic_colon); |
2376 | 370 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
371 OCTINTERP_API octave_value (octave_base_value *new_rep, bool borrow = false); |
21134
2e5c1f766ac9
provide replacement hints for deprecated C++ functions
John W. Eaton <jwe@octave.org>
parents:
21076
diff
changeset
|
372 |
2376 | 373 // Copy constructor. |
374 | |
375 octave_value (const octave_value& a) | |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
376 : m_rep (a.m_rep) |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
377 { |
30139
c789e728d57a
Backed out changeset 938794bc82b7
John W. Eaton <jwe@octave.org>
parents:
30133
diff
changeset
|
378 m_rep->count++; |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
379 } |
2376 | 380 |
27352
7335ebd4c798
define some move constructors and assignment operators
John W. Eaton <jwe@octave.org>
parents:
27216
diff
changeset
|
381 octave_value (octave_value&& a) |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
382 : m_rep (a.m_rep) |
27352
7335ebd4c798
define some move constructors and assignment operators
John W. Eaton <jwe@octave.org>
parents:
27216
diff
changeset
|
383 { |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
384 a.m_rep = nullptr; |
27352
7335ebd4c798
define some move constructors and assignment operators
John W. Eaton <jwe@octave.org>
parents:
27216
diff
changeset
|
385 } |
7335ebd4c798
define some move constructors and assignment operators
John W. Eaton <jwe@octave.org>
parents:
27216
diff
changeset
|
386 |
3933 | 387 // This should only be called for derived types. |
388 | |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
389 OCTINTERP_API octave_base_value * clone (void) const; |
3933 | 390 |
23446
cd4e1ee28716
maint: Use convention 'void * fcn ()' for functions which return pointers.
Rik <rik@octave.org>
parents:
23433
diff
changeset
|
391 octave_base_value * empty_clone (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
392 { return m_rep->empty_clone (); } |
3933 | 393 |
21013
7f4c6d594e3d
Finish renaming mapper function finite to isfinite.
Rik <rik@octave.org>
parents:
21012
diff
changeset
|
394 // Delete the representation of this constant if the count drops to zero. |
2376 | 395 |
6338 | 396 ~octave_value (void) |
397 { | |
27352
7335ebd4c798
define some move constructors and assignment operators
John W. Eaton <jwe@octave.org>
parents:
27216
diff
changeset
|
398 // Because we define a move constructor and a move assignment |
7335ebd4c798
define some move constructors and assignment operators
John W. Eaton <jwe@octave.org>
parents:
27216
diff
changeset
|
399 // operator, rep may be a nullptr here. We should only need to |
7335ebd4c798
define some move constructors and assignment operators
John W. Eaton <jwe@octave.org>
parents:
27216
diff
changeset
|
400 // protect the move assignment operator in a similar way. |
7335ebd4c798
define some move constructors and assignment operators
John W. Eaton <jwe@octave.org>
parents:
27216
diff
changeset
|
401 |
30139
c789e728d57a
Backed out changeset 938794bc82b7
John W. Eaton <jwe@octave.org>
parents:
30133
diff
changeset
|
402 if (m_rep && --m_rep->count == 0 && m_rep != nil_rep ()) |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
403 delete m_rep; |
6338 | 404 } |
2376 | 405 |
406 void make_unique (void) | |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
407 { |
30139
c789e728d57a
Backed out changeset 938794bc82b7
John W. Eaton <jwe@octave.org>
parents:
30133
diff
changeset
|
408 if (m_rep->count > 1) |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
409 { |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
410 octave_base_value *r = m_rep->unique_clone (); |
13985
43cc49c7abd1
Use thread-safe atomic reference counting (GCC and MSVC).
Michael Goffioul <michael.goffioul@gmail.com>
parents:
13874
diff
changeset
|
411 |
30139
c789e728d57a
Backed out changeset 938794bc82b7
John W. Eaton <jwe@octave.org>
parents:
30133
diff
changeset
|
412 if (--m_rep->count == 0 && m_rep != nil_rep ()) |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
413 delete m_rep; |
13985
43cc49c7abd1
Use thread-safe atomic reference counting (GCC and MSVC).
Michael Goffioul <michael.goffioul@gmail.com>
parents:
13874
diff
changeset
|
414 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
415 m_rep = r; |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
416 } |
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
417 } |
2376 | 418 |
8546
3d8a914c580e
improve parser indexed assigment code
Jaroslav Hajek <highegg@gmail.com>
parents:
8531
diff
changeset
|
419 // This uniquifies the value if it is referenced by more than a certain |
21013
7f4c6d594e3d
Finish renaming mapper function finite to isfinite.
Rik <rik@octave.org>
parents:
21012
diff
changeset
|
420 // number of shallow copies. This is useful for optimizations where we |
8546
3d8a914c580e
improve parser indexed assigment code
Jaroslav Hajek <highegg@gmail.com>
parents:
8531
diff
changeset
|
421 // know a certain copy, typically within a cell array, to be obsolete. |
3d8a914c580e
improve parser indexed assigment code
Jaroslav Hajek <highegg@gmail.com>
parents:
8531
diff
changeset
|
422 void make_unique (int obsolete_copies) |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
423 { |
30139
c789e728d57a
Backed out changeset 938794bc82b7
John W. Eaton <jwe@octave.org>
parents:
30133
diff
changeset
|
424 if (m_rep->count > obsolete_copies + 1) |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
425 { |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
426 octave_base_value *r = m_rep->unique_clone (); |
13985
43cc49c7abd1
Use thread-safe atomic reference counting (GCC and MSVC).
Michael Goffioul <michael.goffioul@gmail.com>
parents:
13874
diff
changeset
|
427 |
30139
c789e728d57a
Backed out changeset 938794bc82b7
John W. Eaton <jwe@octave.org>
parents:
30133
diff
changeset
|
428 if (--m_rep->count == 0 && m_rep != nil_rep ()) |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
429 delete m_rep; |
13985
43cc49c7abd1
Use thread-safe atomic reference counting (GCC and MSVC).
Michael Goffioul <michael.goffioul@gmail.com>
parents:
13874
diff
changeset
|
430 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
431 m_rep = r; |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
432 } |
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
433 } |
8546
3d8a914c580e
improve parser indexed assigment code
Jaroslav Hajek <highegg@gmail.com>
parents:
8531
diff
changeset
|
434 |
29476
c74ff452e2bb
avoid memory leaks when returning handles to nested functions
John W. Eaton <jwe@octave.org>
parents:
29358
diff
changeset
|
435 // Convert any nested function handles in this object to use weak |
c74ff452e2bb
avoid memory leaks when returning handles to nested functions
John W. Eaton <jwe@octave.org>
parents:
29358
diff
changeset
|
436 // references to their enclosing stack frame context. Used to break |
c74ff452e2bb
avoid memory leaks when returning handles to nested functions
John W. Eaton <jwe@octave.org>
parents:
29358
diff
changeset
|
437 // shared_ptr reference cycles for handles to nested functions |
c74ff452e2bb
avoid memory leaks when returning handles to nested functions
John W. Eaton <jwe@octave.org>
parents:
29358
diff
changeset
|
438 // (closures). |
c74ff452e2bb
avoid memory leaks when returning handles to nested functions
John W. Eaton <jwe@octave.org>
parents:
29358
diff
changeset
|
439 void break_closure_cycles (const std::shared_ptr<octave::stack_frame>&); |
c74ff452e2bb
avoid memory leaks when returning handles to nested functions
John W. Eaton <jwe@octave.org>
parents:
29358
diff
changeset
|
440 |
2376 | 441 // Simple assignment. |
442 | |
443 octave_value& operator = (const octave_value& a) | |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
444 { |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
445 if (m_rep != a.m_rep) |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
446 { |
30139
c789e728d57a
Backed out changeset 938794bc82b7
John W. Eaton <jwe@octave.org>
parents:
30133
diff
changeset
|
447 if (--m_rep->count == 0 && m_rep != nil_rep ()) |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
448 delete m_rep; |
2376 | 449 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
450 m_rep = a.m_rep; |
30139
c789e728d57a
Backed out changeset 938794bc82b7
John W. Eaton <jwe@octave.org>
parents:
30133
diff
changeset
|
451 m_rep->count++; |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
452 } |
2376 | 453 |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
454 return *this; |
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
455 } |
2376 | 456 |
27352
7335ebd4c798
define some move constructors and assignment operators
John W. Eaton <jwe@octave.org>
parents:
27216
diff
changeset
|
457 octave_value& operator = (octave_value&& a) |
7335ebd4c798
define some move constructors and assignment operators
John W. Eaton <jwe@octave.org>
parents:
27216
diff
changeset
|
458 { |
7335ebd4c798
define some move constructors and assignment operators
John W. Eaton <jwe@octave.org>
parents:
27216
diff
changeset
|
459 // Because we define a move constructor and a move assignment |
7335ebd4c798
define some move constructors and assignment operators
John W. Eaton <jwe@octave.org>
parents:
27216
diff
changeset
|
460 // operator, rep may be a nullptr here. We should only need to |
7335ebd4c798
define some move constructors and assignment operators
John W. Eaton <jwe@octave.org>
parents:
27216
diff
changeset
|
461 // protect the destructor in a similar way. |
7335ebd4c798
define some move constructors and assignment operators
John W. Eaton <jwe@octave.org>
parents:
27216
diff
changeset
|
462 |
7335ebd4c798
define some move constructors and assignment operators
John W. Eaton <jwe@octave.org>
parents:
27216
diff
changeset
|
463 if (this != &a) |
7335ebd4c798
define some move constructors and assignment operators
John W. Eaton <jwe@octave.org>
parents:
27216
diff
changeset
|
464 { |
30139
c789e728d57a
Backed out changeset 938794bc82b7
John W. Eaton <jwe@octave.org>
parents:
30133
diff
changeset
|
465 if (m_rep && --m_rep->count == 0 && m_rep != nil_rep ()) |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
466 delete m_rep; |
27352
7335ebd4c798
define some move constructors and assignment operators
John W. Eaton <jwe@octave.org>
parents:
27216
diff
changeset
|
467 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
468 m_rep = a.m_rep; |
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
469 a.m_rep = nullptr; |
27352
7335ebd4c798
define some move constructors and assignment operators
John W. Eaton <jwe@octave.org>
parents:
27216
diff
changeset
|
470 } |
7335ebd4c798
define some move constructors and assignment operators
John W. Eaton <jwe@octave.org>
parents:
27216
diff
changeset
|
471 |
7335ebd4c798
define some move constructors and assignment operators
John W. Eaton <jwe@octave.org>
parents:
27216
diff
changeset
|
472 return *this; |
7335ebd4c798
define some move constructors and assignment operators
John W. Eaton <jwe@octave.org>
parents:
27216
diff
changeset
|
473 } |
7335ebd4c798
define some move constructors and assignment operators
John W. Eaton <jwe@octave.org>
parents:
27216
diff
changeset
|
474 |
30139
c789e728d57a
Backed out changeset 938794bc82b7
John W. Eaton <jwe@octave.org>
parents:
30133
diff
changeset
|
475 octave_idx_type get_count (void) const { return m_rep->count; } |
3239 | 476 |
8345
c777f3ce02d8
smarter conversion lookup
Jaroslav Hajek <highegg@gmail.com>
parents:
8150
diff
changeset
|
477 octave_base_value::type_conv_info numeric_conversion_function (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
478 { return m_rep->numeric_conversion_function (); } |
2376 | 479 |
8345
c777f3ce02d8
smarter conversion lookup
Jaroslav Hajek <highegg@gmail.com>
parents:
8150
diff
changeset
|
480 octave_base_value::type_conv_info numeric_demotion_function (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
481 { return m_rep->numeric_demotion_function (); } |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7761
diff
changeset
|
482 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
483 OCTINTERP_API void maybe_mutate (void); |
2409 | 484 |
5759 | 485 octave_value squeeze (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
486 { return m_rep->squeeze (); } |
4532 | 487 |
8458
d254a21e0120
reimplement full as method of octave_base_value
Jaroslav Hajek <highegg@gmail.com>
parents:
8456
diff
changeset
|
488 // The result of full(). |
d254a21e0120
reimplement full as method of octave_base_value
Jaroslav Hajek <highegg@gmail.com>
parents:
8456
diff
changeset
|
489 octave_value full_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
490 { return m_rep->full_value (); } |
8458
d254a21e0120
reimplement full as method of octave_base_value
Jaroslav Hajek <highegg@gmail.com>
parents:
8456
diff
changeset
|
491 |
22283
564203123065
move single and double type conversion functions to ov.cc
John W. Eaton <jwe@octave.org>
parents:
22197
diff
changeset
|
492 // Type conversions. |
564203123065
move single and double type conversion functions to ov.cc
John W. Eaton <jwe@octave.org>
parents:
22197
diff
changeset
|
493 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
494 octave_value as_double (void) const { return m_rep->as_double (); } |
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
495 octave_value as_single (void) const { return m_rep->as_single (); } |
22296
8b18f46f6427
revamp double, single, int type conversions
John W. Eaton <jwe@octave.org>
parents:
22283
diff
changeset
|
496 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
497 octave_value as_int8 (void) const { return m_rep->as_int8 (); } |
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
498 octave_value as_int16 (void) const { return m_rep->as_int16 (); } |
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
499 octave_value as_int32 (void) const { return m_rep->as_int32 (); } |
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
500 octave_value as_int64 (void) const { return m_rep->as_int64 (); } |
22296
8b18f46f6427
revamp double, single, int type conversions
John W. Eaton <jwe@octave.org>
parents:
22283
diff
changeset
|
501 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
502 octave_value as_uint8 (void) const { return m_rep->as_uint8 (); } |
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
503 octave_value as_uint16 (void) const { return m_rep->as_uint16 (); } |
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
504 octave_value as_uint32 (void) const { return m_rep->as_uint32 (); } |
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
505 octave_value as_uint64 (void) const { return m_rep->as_uint64 (); } |
22283
564203123065
move single and double type conversion functions to ov.cc
John W. Eaton <jwe@octave.org>
parents:
22197
diff
changeset
|
506 |
23446
cd4e1ee28716
maint: Use convention 'void * fcn ()' for functions which return pointers.
Rik <rik@octave.org>
parents:
23433
diff
changeset
|
507 octave_base_value * try_narrowing_conversion (void) |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
508 { return m_rep->try_narrowing_conversion (); } |
2409 | 509 |
9329
67fc970dad7d
improve indexed assignment using indexed numel
Jaroslav Hajek <highegg@gmail.com>
parents:
9151
diff
changeset
|
510 // Close to dims (), but can be overloaded for classes. |
67fc970dad7d
improve indexed assignment using indexed numel
Jaroslav Hajek <highegg@gmail.com>
parents:
9151
diff
changeset
|
511 Matrix size (void) |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
512 { return m_rep->size (); } |
9329
67fc970dad7d
improve indexed assignment using indexed numel
Jaroslav Hajek <highegg@gmail.com>
parents:
9151
diff
changeset
|
513 |
26922
072d0610cc56
avoid some overloaded virtual warnings (bug #55741)
John W. Eaton <jwe@octave.org>
parents:
26916
diff
changeset
|
514 // FIXME: should this function be deprecated and removed? It supports |
072d0610cc56
avoid some overloaded virtual warnings (bug #55741)
John W. Eaton <jwe@octave.org>
parents:
26916
diff
changeset
|
515 // an undocumented feature of Matlab. |
072d0610cc56
avoid some overloaded virtual warnings (bug #55741)
John W. Eaton <jwe@octave.org>
parents:
26916
diff
changeset
|
516 octave_idx_type xnumel (const octave_value_list& idx) |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
517 { return m_rep->xnumel (idx); } |
9329
67fc970dad7d
improve indexed assignment using indexed numel
Jaroslav Hajek <highegg@gmail.com>
parents:
9151
diff
changeset
|
518 |
26916
9cd4b045fe3d
avoid some overloaded virtual warnings (bug #55741)
John W. Eaton <jwe@octave.org>
parents:
26655
diff
changeset
|
519 // FIXME: Do we really need all these different versions of subsref |
9cd4b045fe3d
avoid some overloaded virtual warnings (bug #55741)
John W. Eaton <jwe@octave.org>
parents:
26655
diff
changeset
|
520 // and related functions? |
9cd4b045fe3d
avoid some overloaded virtual warnings (bug #55741)
John W. Eaton <jwe@octave.org>
parents:
26655
diff
changeset
|
521 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
522 OCTINTERP_API octave_value |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
523 single_subsref (const std::string& type, const octave_value_list& idx); |
4271 | 524 |
5759 | 525 octave_value subsref (const std::string& type, |
8551
906f976d35a8
further improve struct&cell indexing & indexed assignment
Jaroslav Hajek <highegg@gmail.com>
parents:
8546
diff
changeset
|
526 const std::list<octave_value_list>& idx) |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
527 { return m_rep->subsref (type, idx); } |
3933 | 528 |
8551
906f976d35a8
further improve struct&cell indexing & indexed assignment
Jaroslav Hajek <highegg@gmail.com>
parents:
8546
diff
changeset
|
529 octave_value subsref (const std::string& type, |
906f976d35a8
further improve struct&cell indexing & indexed assignment
Jaroslav Hajek <highegg@gmail.com>
parents:
8546
diff
changeset
|
530 const std::list<octave_value_list>& idx, |
906f976d35a8
further improve struct&cell indexing & indexed assignment
Jaroslav Hajek <highegg@gmail.com>
parents:
8546
diff
changeset
|
531 bool auto_add) |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
532 { return m_rep->subsref (type, idx, auto_add); } |
8551
906f976d35a8
further improve struct&cell indexing & indexed assignment
Jaroslav Hajek <highegg@gmail.com>
parents:
8546
diff
changeset
|
533 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
534 OCTINTERP_API octave_value_list |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
535 subsref (const std::string& type, const std::list<octave_value_list>& idx, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
536 int nargout); |
3933 | 537 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
538 OCTINTERP_API octave_value |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
539 next_subsref (const std::string& type, |
29572
aef11bb4e6d1
use std::size_t and std::ptrdiff_t in C++ code (bug #60471)
John W. Eaton <jwe@octave.org>
parents:
29569
diff
changeset
|
540 const std::list<octave_value_list>& idx, std::size_t skip = 1); |
3933 | 541 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
542 OCTINTERP_API octave_value_list |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
543 next_subsref (int nargout, const std::string& type, |
29572
aef11bb4e6d1
use std::size_t and std::ptrdiff_t in C++ code (bug #60471)
John W. Eaton <jwe@octave.org>
parents:
29569
diff
changeset
|
544 const std::list<octave_value_list>& idx, std::size_t skip = 1); |
4994 | 545 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
546 OCTINTERP_API octave_value |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
547 next_subsref (bool auto_add, const std::string& type, |
29572
aef11bb4e6d1
use std::size_t and std::ptrdiff_t in C++ code (bug #60471)
John W. Eaton <jwe@octave.org>
parents:
29569
diff
changeset
|
548 const std::list<octave_value_list>& idx, std::size_t skip = 1); |
8551
906f976d35a8
further improve struct&cell indexing & indexed assignment
Jaroslav Hajek <highegg@gmail.com>
parents:
8546
diff
changeset
|
549 |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
550 octave_value index_op (const octave_value_list& idx, bool resize_ok = false) |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
551 { |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
552 return m_rep->do_index_op (idx, resize_ok); |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
553 } |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
554 |
29954
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
555 #if defined (OCTAVE_PROVIDE_DEPRECATED_SYMBOLS) |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
556 OCTAVE_DEPRECATED (7, "use 'octave_value::index_op' instead") |
5759 | 557 octave_value do_index_op (const octave_value_list& idx, |
10313 | 558 bool resize_ok = false) |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
559 { |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
560 return index_op (idx, resize_ok); |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
561 } |
29954
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
562 #endif |
3933 | 563 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
564 OCTINTERP_API octave_value |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
565 subsasgn (const std::string& type, const std::list<octave_value_list>& idx, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
566 const octave_value& rhs); |
2376 | 567 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
568 OCTINTERP_API octave_value |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
569 undef_subsasgn (const std::string& type, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
570 const std::list<octave_value_list>& idx, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
571 const octave_value& rhs); |
12171
d08901c05c1b
fix bug in class assignment to undefined object with index
John W. Eaton <jwe@octave.org>
parents:
11586
diff
changeset
|
572 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
573 OCTINTERP_API octave_value& |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
574 assign (assign_op op, const std::string& type, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
575 const std::list<octave_value_list>& idx, const octave_value& rhs); |
2948 | 576 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
577 OCTINTERP_API octave_value& assign (assign_op, const octave_value& rhs); |
2948 | 578 |
29569
29a1f8fd8ee6
move idx_vector classes inside octave namespace
John W. Eaton <jwe@octave.org>
parents:
29478
diff
changeset
|
579 octave::idx_vector index_vector (bool require_integers = false) const |
18130
e473c4853afc
enable non-integer ranges as indices by default and deprecate preference
John W. Eaton <jwe@octave.org>
parents:
17870
diff
changeset
|
580 { |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
581 return m_rep->index_vector (require_integers); |
18130
e473c4853afc
enable non-integer ranges as indices by default and deprecate preference
John W. Eaton <jwe@octave.org>
parents:
17870
diff
changeset
|
582 } |
2376 | 583 |
584 // Size. | |
585 | |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
586 dim_vector dims (void) const { return m_rep->dims (); } |
26078
0549d088f50e
move get_dims_str from variables.cc to octave_value class
John W. Eaton <jwe@octave.org>
parents:
25054
diff
changeset
|
587 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
588 OCTINTERP_API std::string get_dims_str (void) const; |
4513 | 589 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
590 octave_idx_type rows (void) const { return m_rep->rows (); } |
4563 | 591 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
592 octave_idx_type columns (void) const { return m_rep->columns (); } |
3195 | 593 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
594 OCTINTERP_API octave_idx_type length (void) const; |
4554 | 595 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
596 int ndims (void) const { return m_rep->ndims (); } |
4563 | 597 |
14846
460a3c6d8bf1
maint: Use Octave coding convention for cuddled parenthis in function calls with empty argument lists.
Rik <octave@nomad.inbox5.com>
parents:
14770
diff
changeset
|
598 bool all_zero_dims (void) const { return dims ().all_zero (); } |
5164 | 599 |
23590
eb3c7abad98f
ov.h: Directly call replacement functions from deprecated functions.
Rik <rik@octave.org>
parents:
23589
diff
changeset
|
600 // Are the dimensions of this constant zero by zero? |
eb3c7abad98f
ov.h: Directly call replacement functions from deprecated functions.
Rik <rik@octave.org>
parents:
23589
diff
changeset
|
601 bool is_zero_by_zero (void) const |
eb3c7abad98f
ov.h: Directly call replacement functions from deprecated functions.
Rik <rik@octave.org>
parents:
23589
diff
changeset
|
602 { return (ndims () == 2 && rows () == 0 && columns () == 0); } |
eb3c7abad98f
ov.h: Directly call replacement functions from deprecated functions.
Rik <rik@octave.org>
parents:
23589
diff
changeset
|
603 |
5759 | 604 octave_idx_type numel (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
605 { return m_rep->numel (); } |
4559 | 606 |
29654
d13d090cb03a
use std::size_t and std::ptrdiff_t in C++ code (bug #60471)
John W. Eaton <jwe@octave.org>
parents:
29476
diff
changeset
|
607 std::size_t byte_size (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
608 { return m_rep->byte_size (); } |
4791 | 609 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
610 octave_idx_type nnz (void) const { return m_rep->nnz (); } |
5602 | 611 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
612 octave_idx_type nzmax (void) const { return m_rep->nzmax (); } |
5604 | 613 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
614 octave_idx_type nfields (void) const { return m_rep->nfields (); } |
5900 | 615 |
5759 | 616 octave_value reshape (const dim_vector& dv) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
617 { return m_rep->reshape (dv); } |
4567 | 618 |
5759 | 619 octave_value permute (const Array<int>& vec, bool inv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
620 { return m_rep->permute (vec, inv); } |
4593 | 621 |
622 octave_value ipermute (const Array<int>& vec) const | |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
623 { return m_rep->permute (vec, true); } |
4593 | 624 |
5759 | 625 octave_value resize (const dim_vector& dv, bool fill = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
626 { return m_rep->resize (dv, fill);} |
4915 | 627 |
5785 | 628 MatrixType matrix_type (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
629 { return m_rep->matrix_type (); } |
5785 | 630 |
631 MatrixType matrix_type (const MatrixType& typ) const | |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
632 { return m_rep->matrix_type (typ); } |
5785 | 633 |
21013
7f4c6d594e3d
Finish renaming mapper function finite to isfinite.
Rik <rik@octave.org>
parents:
21012
diff
changeset
|
634 // Does this constant have a type? Both of these are provided since it is |
7f4c6d594e3d
Finish renaming mapper function finite to isfinite.
Rik <rik@octave.org>
parents:
21012
diff
changeset
|
635 // sometimes more natural to write is_undefined() instead of ! is_defined(). |
2376 | 636 |
5759 | 637 bool is_defined (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
638 { return m_rep->is_defined (); } |
2376 | 639 |
640 bool is_undefined (void) const | |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
641 { return ! is_defined (); } |
2376 | 642 |
30852
95725e6ad9c1
restore part of the old octave_range class as octave_legacy_range
John W. Eaton <jwe@octave.org>
parents:
30835
diff
changeset
|
643 bool is_legacy_object (void) const |
95725e6ad9c1
restore part of the old octave_range class as octave_legacy_range
John W. Eaton <jwe@octave.org>
parents:
30835
diff
changeset
|
644 { return m_rep->is_legacy_object (); } |
95725e6ad9c1
restore part of the old octave_range class as octave_legacy_range
John W. Eaton <jwe@octave.org>
parents:
30835
diff
changeset
|
645 |
23577
80c42f4cca13
maint: Deprecate is_empty and replace with isempty.
Rik <rik@octave.org>
parents:
23576
diff
changeset
|
646 bool isempty (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
647 { return m_rep->isempty (); } |
23577
80c42f4cca13
maint: Deprecate is_empty and replace with isempty.
Rik <rik@octave.org>
parents:
23576
diff
changeset
|
648 |
23576
00e518162fda
maint: Deprecate is_cell and replace with iscell.
Rik <rik@octave.org>
parents:
23575
diff
changeset
|
649 bool iscell (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
650 { return m_rep->iscell (); } |
23576
00e518162fda
maint: Deprecate is_cell and replace with iscell.
Rik <rik@octave.org>
parents:
23575
diff
changeset
|
651 |
23575
e95738a119da
maint: Deprecate is_cellstr and replace with iscellstr.
Rik <rik@octave.org>
parents:
23502
diff
changeset
|
652 bool iscellstr (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
653 { return m_rep->iscellstr (); } |
23575
e95738a119da
maint: Deprecate is_cellstr and replace with iscellstr.
Rik <rik@octave.org>
parents:
23502
diff
changeset
|
654 |
5759 | 655 bool is_real_scalar (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
656 { return m_rep->is_real_scalar (); } |
2376 | 657 |
5759 | 658 bool is_real_matrix (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
659 { return m_rep->is_real_matrix (); } |
2376 | 660 |
5759 | 661 bool is_complex_scalar (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
662 { return m_rep->is_complex_scalar (); } |
2376 | 663 |
5759 | 664 bool is_complex_matrix (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
665 { return m_rep->is_complex_matrix (); } |
2376 | 666 |
5881 | 667 bool is_bool_scalar (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
668 { return m_rep->is_bool_scalar (); } |
5881 | 669 |
5759 | 670 bool is_bool_matrix (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
671 { return m_rep->is_bool_matrix (); } |
4587 | 672 |
5759 | 673 bool is_char_matrix (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
674 { return m_rep->is_char_matrix (); } |
2376 | 675 |
8366
8b1a2555c4e2
implement diagonal matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
8346
diff
changeset
|
676 bool is_diag_matrix (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
677 { return m_rep->is_diag_matrix (); } |
8366
8b1a2555c4e2
implement diagonal matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
8346
diff
changeset
|
678 |
8371
c3f7e2549abb
make det & inv aware of diagonal & permutation matrices
Jaroslav Hajek <highegg@gmail.com>
parents:
8367
diff
changeset
|
679 bool is_perm_matrix (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
680 { return m_rep->is_perm_matrix (); } |
8371
c3f7e2549abb
make det & inv aware of diagonal & permutation matrices
Jaroslav Hajek <highegg@gmail.com>
parents:
8367
diff
changeset
|
681 |
5759 | 682 bool is_string (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
683 { return m_rep->is_string (); } |
2376 | 684 |
5759 | 685 bool is_sq_string (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
686 { return m_rep->is_sq_string (); } |
5279 | 687 |
5280 | 688 bool is_dq_string (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
689 { return m_rep->is_string () && ! m_rep->is_sq_string (); } |
5280 | 690 |
5759 | 691 bool is_range (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
692 { return m_rep->is_range (); } |
2376 | 693 |
23584
7ed6b258db91
maint: Deprecate is_map and replace with isstruct.
Rik <rik@octave.org>
parents:
23583
diff
changeset
|
694 bool isstruct (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
695 { return m_rep->isstruct (); } |
23584
7ed6b258db91
maint: Deprecate is_map and replace with isstruct.
Rik <rik@octave.org>
parents:
23583
diff
changeset
|
696 |
23683
ffd27f53fc79
make +package function calls work again (bug #51295, #51296)
John W. Eaton <jwe@octave.org>
parents:
23680
diff
changeset
|
697 bool is_classdef_meta (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
698 { return m_rep->is_classdef_meta (); } |
23683
ffd27f53fc79
make +package function calls work again (bug #51295, #51296)
John W. Eaton <jwe@octave.org>
parents:
23680
diff
changeset
|
699 |
19110
fa48651fbb8a
isstruct for classdef objects should not return true.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
19103
diff
changeset
|
700 bool is_classdef_object (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
701 { return m_rep->is_classdef_object (); } |
23843
a52eb3f210af
maint: Strip trailing whitespace from source files.
John W. Eaton <jwe@octave.org>
parents:
23838
diff
changeset
|
702 |
23865
d56c18dc1373
new predicates for classdef_superclass_ref objects
John W. Eaton <jwe@octave.org>
parents:
23843
diff
changeset
|
703 bool is_classdef_superclass_ref (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
704 { return m_rep->is_classdef_superclass_ref (); } |
23865
d56c18dc1373
new predicates for classdef_superclass_ref objects
John W. Eaton <jwe@octave.org>
parents:
23843
diff
changeset
|
705 |
23838
6e0fd7e3c262
Fix argument lookup in '+' package functions (Bug #51532).
Piotr Held <pjheld@gmail.com>
parents:
23683
diff
changeset
|
706 bool is_package (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
707 { return m_rep->is_package (); } |
19110
fa48651fbb8a
isstruct for classdef objects should not return true.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
19103
diff
changeset
|
708 |
23587
0c468af9dc00
maint: Deprecate is_object and replace with isobject.
Rik <rik@octave.org>
parents:
23586
diff
changeset
|
709 bool isobject (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
710 { return m_rep->isobject (); } |
23587
0c468af9dc00
maint: Deprecate is_object and replace with isobject.
Rik <rik@octave.org>
parents:
23586
diff
changeset
|
711 |
23578
7b47b7c2d6c7
maint: Deprecate is_java and replace with isjava.
Rik <rik@octave.org>
parents:
23577
diff
changeset
|
712 bool isjava (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
713 { return m_rep->isjava (); } |
23578
7b47b7c2d6c7
maint: Deprecate is_java and replace with isjava.
Rik <rik@octave.org>
parents:
23577
diff
changeset
|
714 |
5759 | 715 bool is_cs_list (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
716 { return m_rep->is_cs_list (); } |
3977 | 717 |
5759 | 718 bool is_magic_colon (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
719 { return m_rep->is_magic_colon (); } |
2376 | 720 |
28588
ee9b1081471f
allow integer constants > flintmax to be represented exactly (bug #45945)
John W. Eaton <jwe@octave.org>
parents:
28444
diff
changeset
|
721 bool is_magic_int (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
722 { return m_rep->is_magic_int (); } |
28588
ee9b1081471f
allow integer constants > flintmax to be represented exactly (bug #45945)
John W. Eaton <jwe@octave.org>
parents:
28444
diff
changeset
|
723 |
23589
63950abd2f81
maint: Deprecate is_null_type and replace with isnull.
Rik <rik@octave.org>
parents:
23588
diff
changeset
|
724 bool isnull (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
725 { return m_rep->isnull (); } |
23589
63950abd2f81
maint: Deprecate is_null_type and replace with isnull.
Rik <rik@octave.org>
parents:
23588
diff
changeset
|
726 |
2376 | 727 // Are any or all of the elements in this constant nonzero? |
728 | |
5759 | 729 octave_value all (int dim = 0) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
730 { return m_rep->all (dim); } |
2376 | 731 |
5759 | 732 octave_value any (int dim = 0) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
733 { return m_rep->any (dim); } |
2376 | 734 |
9685 | 735 builtin_type_t builtin_type (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
736 { return m_rep->builtin_type (); } |
9685 | 737 |
5895 | 738 // Floating point types. |
739 | |
740 bool is_double_type (void) const | |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
741 { return m_rep->is_double_type (); } |
5895 | 742 |
743 bool is_single_type (void) const | |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
744 { return m_rep->is_single_type (); } |
5895 | 745 |
23585
570170b6eb09
maint: Deprecate is_float_type and replace with isfloat.
Rik <rik@octave.org>
parents:
23584
diff
changeset
|
746 bool isfloat (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
747 { return m_rep->isfloat (); } |
23585
570170b6eb09
maint: Deprecate is_float_type and replace with isfloat.
Rik <rik@octave.org>
parents:
23584
diff
changeset
|
748 |
5895 | 749 // Integer types. |
750 | |
751 bool is_int8_type (void) const | |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
752 { return m_rep->is_int8_type (); } |
5895 | 753 |
754 bool is_int16_type (void) const | |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
755 { return m_rep->is_int16_type (); } |
5895 | 756 |
757 bool is_int32_type (void) const | |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
758 { return m_rep->is_int32_type (); } |
5895 | 759 |
760 bool is_int64_type (void) const | |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
761 { return m_rep->is_int64_type (); } |
5895 | 762 |
763 bool is_uint8_type (void) const | |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
764 { return m_rep->is_uint8_type (); } |
5895 | 765 |
766 bool is_uint16_type (void) const | |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
767 { return m_rep->is_uint16_type (); } |
5895 | 768 |
769 bool is_uint32_type (void) const | |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
770 { return m_rep->is_uint32_type (); } |
5895 | 771 |
772 bool is_uint64_type (void) const | |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
773 { return m_rep->is_uint64_type (); } |
5895 | 774 |
23586
f6c5db0a02e7
maint: Deprecate is_numeric_type and replace with isnumeric.
Rik <rik@octave.org>
parents:
23585
diff
changeset
|
775 bool isinteger (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
776 { return m_rep->isinteger (); } |
23586
f6c5db0a02e7
maint: Deprecate is_numeric_type and replace with isnumeric.
Rik <rik@octave.org>
parents:
23585
diff
changeset
|
777 |
2376 | 778 // Other type stuff. |
779 | |
23579
c20a0fa91c0c
maint: Deprecate is_bool_type and replace with islogical.
Rik <rik@octave.org>
parents:
23578
diff
changeset
|
780 bool islogical (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
781 { return m_rep->islogical (); } |
23579
c20a0fa91c0c
maint: Deprecate is_bool_type and replace with islogical.
Rik <rik@octave.org>
parents:
23578
diff
changeset
|
782 |
23582
0cc2011d800e
maint: Deprecate is_real_type and replace with isreal.
Rik <rik@octave.org>
parents:
23581
diff
changeset
|
783 bool isreal (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
784 { return m_rep->isreal (); } |
23582
0cc2011d800e
maint: Deprecate is_real_type and replace with isreal.
Rik <rik@octave.org>
parents:
23581
diff
changeset
|
785 |
23581
c3075ae020e1
maint: Deprecate is_complex_type and replace with iscomplex.
Rik <rik@octave.org>
parents:
23580
diff
changeset
|
786 bool iscomplex (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
787 { return m_rep->iscomplex (); } |
23581
c3075ae020e1
maint: Deprecate is_complex_type and replace with iscomplex.
Rik <rik@octave.org>
parents:
23580
diff
changeset
|
788 |
5759 | 789 bool is_scalar_type (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
790 { return m_rep->is_scalar_type (); } |
2376 | 791 |
5759 | 792 bool is_matrix_type (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
793 { return m_rep->is_matrix_type (); } |
2376 | 794 |
23586
f6c5db0a02e7
maint: Deprecate is_numeric_type and replace with isnumeric.
Rik <rik@octave.org>
parents:
23585
diff
changeset
|
795 bool isnumeric (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
796 { return m_rep->isnumeric (); } |
23586
f6c5db0a02e7
maint: Deprecate is_numeric_type and replace with isnumeric.
Rik <rik@octave.org>
parents:
23585
diff
changeset
|
797 |
23583
b7747a2c88b2
maint: Deprecate is_sparse_type and replace with issparse.
Rik <rik@octave.org>
parents:
23582
diff
changeset
|
798 bool issparse (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
799 { return m_rep->issparse (); } |
23583
b7747a2c88b2
maint: Deprecate is_sparse_type and replace with issparse.
Rik <rik@octave.org>
parents:
23582
diff
changeset
|
800 |
2376 | 801 // Does this constant correspond to a truth value? |
802 | |
5759 | 803 bool is_true (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
804 { return m_rep->is_true (); } |
2376 | 805 |
8346
8302788f09db
fix empty matrix handling in switch statement
Jaroslav Hajek <highegg@gmail.com>
parents:
8345
diff
changeset
|
806 // Do two constants match (in a switch statement)? |
11586
12df7854fa7c
strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
807 |
8346
8302788f09db
fix empty matrix handling in switch statement
Jaroslav Hajek <highegg@gmail.com>
parents:
8345
diff
changeset
|
808 bool is_equal (const octave_value&) const; |
8302788f09db
fix empty matrix handling in switch statement
Jaroslav Hajek <highegg@gmail.com>
parents:
8345
diff
changeset
|
809 |
5759 | 810 bool is_constant (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
811 { return m_rep->is_constant (); } |
2974 | 812 |
5759 | 813 bool is_function_handle (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
814 { return m_rep->is_function_handle (); } |
4654 | 815 |
13241
2a8dcb5b3a00
improve default indexing for objects
John W. Eaton <jwe@octave.org>
parents:
13110
diff
changeset
|
816 bool is_anonymous_function (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
817 { return m_rep->is_anonymous_function (); } |
13241
2a8dcb5b3a00
improve default indexing for objects
John W. Eaton <jwe@octave.org>
parents:
13110
diff
changeset
|
818 |
5759 | 819 bool is_inline_function (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
820 { return m_rep->is_inline_function (); } |
4954 | 821 |
5759 | 822 bool is_function (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
823 { return m_rep->is_function (); } |
2891 | 824 |
7336 | 825 bool is_user_script (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
826 { return m_rep->is_user_script (); } |
7336 | 827 |
828 bool is_user_function (void) const | |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
829 { return m_rep->is_user_function (); } |
7336 | 830 |
7719
87eda1f8faaa
octave_user_code: new base class for octave_user_script and octave_user_function
John W. Eaton <jwe@octave.org>
parents:
7638
diff
changeset
|
831 bool is_user_code (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
832 { return m_rep->is_user_code (); } |
7719
87eda1f8faaa
octave_user_code: new base class for octave_user_script and octave_user_function
John W. Eaton <jwe@octave.org>
parents:
7638
diff
changeset
|
833 |
5759 | 834 bool is_builtin_function (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
835 { return m_rep->is_builtin_function (); } |
3325 | 836 |
5759 | 837 bool is_dld_function (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
838 { return m_rep->is_dld_function (); } |
3325 | 839 |
5864 | 840 bool is_mex_function (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
841 { return m_rep->is_mex_function (); } |
5864 | 842 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
843 void erase_subfunctions (void) { m_rep->erase_subfunctions (); } |
7876
8447a5024650
clear subfunctions when clearing parent function
John W. Eaton <jwe@octave.org>
parents:
7800
diff
changeset
|
844 |
2376 | 845 // Values. |
846 | |
2891 | 847 octave_value eval (void) { return *this; } |
848 | |
5759 | 849 short int |
4254 | 850 short_value (bool req_int = false, bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
851 { return m_rep->short_value (req_int, frc_str_conv); } |
4254 | 852 |
5759 | 853 unsigned short int |
4254 | 854 ushort_value (bool req_int = false, bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
855 { return m_rep->ushort_value (req_int, frc_str_conv); } |
4254 | 856 |
5759 | 857 int int_value (bool req_int = false, bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
858 { return m_rep->int_value (req_int, frc_str_conv); } |
3202 | 859 |
5759 | 860 unsigned int |
4254 | 861 uint_value (bool req_int = false, bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
862 { return m_rep->uint_value (req_int, frc_str_conv); } |
4254 | 863 |
5759 | 864 int nint_value (bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
865 { return m_rep->nint_value (frc_str_conv); } |
3202 | 866 |
5759 | 867 long int |
4254 | 868 long_value (bool req_int = false, bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
869 { return m_rep->long_value (req_int, frc_str_conv); } |
4254 | 870 |
5759 | 871 unsigned long int |
4254 | 872 ulong_value (bool req_int = false, bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
873 { return m_rep->ulong_value (req_int, frc_str_conv); } |
4254 | 874 |
16323
e769440b39db
provide int64 extractors for octave_value class
John W. Eaton <jwe@octave.org>
parents:
16091
diff
changeset
|
875 int64_t |
e769440b39db
provide int64 extractors for octave_value class
John W. Eaton <jwe@octave.org>
parents:
16091
diff
changeset
|
876 int64_value (bool req_int = false, bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
877 { return m_rep->int64_value (req_int, frc_str_conv); } |
16323
e769440b39db
provide int64 extractors for octave_value class
John W. Eaton <jwe@octave.org>
parents:
16091
diff
changeset
|
878 |
e769440b39db
provide int64 extractors for octave_value class
John W. Eaton <jwe@octave.org>
parents:
16091
diff
changeset
|
879 uint64_t |
e769440b39db
provide int64 extractors for octave_value class
John W. Eaton <jwe@octave.org>
parents:
16091
diff
changeset
|
880 uint64_value (bool req_int = false, bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
881 { return m_rep->uint64_value (req_int, frc_str_conv); } |
16323
e769440b39db
provide int64 extractors for octave_value class
John W. Eaton <jwe@octave.org>
parents:
16091
diff
changeset
|
882 |
6133 | 883 octave_idx_type |
8017
260294a5520f
octave_value::idx_type_value: move definition to ov.cc from ov.h
John W. Eaton <jwe@octave.org>
parents:
7885
diff
changeset
|
884 idx_type_value (bool req_int = false, bool frc_str_conv = false) const; |
6133 | 885 |
5759 | 886 double double_value (bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
887 { return m_rep->double_value (frc_str_conv); } |
2376 | 888 |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7761
diff
changeset
|
889 float float_value (bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
890 { return m_rep->float_value (frc_str_conv); } |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7761
diff
changeset
|
891 |
5759 | 892 double scalar_value (bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
893 { return m_rep->scalar_value (frc_str_conv); } |
2916 | 894 |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7761
diff
changeset
|
895 float float_scalar_value (bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
896 { return m_rep->float_scalar_value (frc_str_conv); } |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7761
diff
changeset
|
897 |
5759 | 898 Matrix matrix_value (bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
899 { return m_rep->matrix_value (frc_str_conv); } |
2376 | 900 |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7761
diff
changeset
|
901 FloatMatrix float_matrix_value (bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
902 { return m_rep->float_matrix_value (frc_str_conv); } |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7761
diff
changeset
|
903 |
5759 | 904 NDArray array_value (bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
905 { return m_rep->array_value (frc_str_conv); } |
4505 | 906 |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7761
diff
changeset
|
907 FloatNDArray float_array_value (bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
908 { return m_rep->float_array_value (frc_str_conv); } |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7761
diff
changeset
|
909 |
5759 | 910 Complex complex_value (bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
911 { return m_rep->complex_value (frc_str_conv); } |
2376 | 912 |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7761
diff
changeset
|
913 FloatComplex float_complex_value (bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
914 { return m_rep->float_complex_value (frc_str_conv); } |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7761
diff
changeset
|
915 |
5759 | 916 ComplexMatrix complex_matrix_value (bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
917 { return m_rep->complex_matrix_value (frc_str_conv); } |
2376 | 918 |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
919 FloatComplexMatrix |
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
920 float_complex_matrix_value (bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
921 { return m_rep->float_complex_matrix_value (frc_str_conv); } |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7761
diff
changeset
|
922 |
5759 | 923 ComplexNDArray complex_array_value (bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
924 { return m_rep->complex_array_value (frc_str_conv); } |
4550 | 925 |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
926 FloatComplexNDArray |
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
927 float_complex_array_value (bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
928 { return m_rep->float_complex_array_value (frc_str_conv); } |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7761
diff
changeset
|
929 |
5943 | 930 bool bool_value (bool warn = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
931 { return m_rep->bool_value (warn); } |
4550 | 932 |
5943 | 933 boolMatrix bool_matrix_value (bool warn = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
934 { return m_rep->bool_matrix_value (warn); } |
4550 | 935 |
5943 | 936 boolNDArray bool_array_value (bool warn = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
937 { return m_rep->bool_array_value (warn); } |
4550 | 938 |
5759 | 939 charMatrix char_matrix_value (bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
940 { return m_rep->char_matrix_value (frc_str_conv); } |
2376 | 941 |
5759 | 942 charNDArray char_array_value (bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
943 { return m_rep->char_array_value (frc_str_conv); } |
4550 | 944 |
5759 | 945 SparseMatrix sparse_matrix_value (bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
946 { return m_rep->sparse_matrix_value (frc_str_conv); } |
5164 | 947 |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
948 SparseComplexMatrix |
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
949 sparse_complex_matrix_value (bool frc_str_conv = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
950 { return m_rep->sparse_complex_matrix_value (frc_str_conv); } |
5164 | 951 |
9852
aabf7a8c2e57
implement sparse logical conversion
Jaroslav Hajek <highegg@gmail.com>
parents:
9835
diff
changeset
|
952 SparseBoolMatrix sparse_bool_matrix_value (bool warn = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
953 { return m_rep->sparse_bool_matrix_value (warn); } |
5164 | 954 |
8916
a2878ba31a9e
add diag & perm matrix query methods to octave_value
Jaroslav Hajek <highegg@gmail.com>
parents:
8811
diff
changeset
|
955 DiagMatrix diag_matrix_value (bool force = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
956 { return m_rep->diag_matrix_value (force); } |
11586
12df7854fa7c
strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
957 |
8916
a2878ba31a9e
add diag & perm matrix query methods to octave_value
Jaroslav Hajek <highegg@gmail.com>
parents:
8811
diff
changeset
|
958 FloatDiagMatrix float_diag_matrix_value (bool force = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
959 { return m_rep->float_diag_matrix_value (force); } |
11586
12df7854fa7c
strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
960 |
8916
a2878ba31a9e
add diag & perm matrix query methods to octave_value
Jaroslav Hajek <highegg@gmail.com>
parents:
8811
diff
changeset
|
961 ComplexDiagMatrix complex_diag_matrix_value (bool force = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
962 { return m_rep->complex_diag_matrix_value (force); } |
11586
12df7854fa7c
strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
963 |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
964 FloatComplexDiagMatrix |
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
965 float_complex_diag_matrix_value (bool force = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
966 { return m_rep->float_complex_diag_matrix_value (force); } |
8916
a2878ba31a9e
add diag & perm matrix query methods to octave_value
Jaroslav Hajek <highegg@gmail.com>
parents:
8811
diff
changeset
|
967 |
a2878ba31a9e
add diag & perm matrix query methods to octave_value
Jaroslav Hajek <highegg@gmail.com>
parents:
8811
diff
changeset
|
968 PermMatrix perm_matrix_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
969 { return m_rep->perm_matrix_value (); } |
11586
12df7854fa7c
strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
970 |
5759 | 971 octave_int8 int8_scalar_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
972 { return m_rep->int8_scalar_value (); } |
4910 | 973 |
5759 | 974 octave_int16 int16_scalar_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
975 { return m_rep->int16_scalar_value (); } |
4910 | 976 |
5759 | 977 octave_int32 int32_scalar_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
978 { return m_rep->int32_scalar_value (); } |
4910 | 979 |
5759 | 980 octave_int64 int64_scalar_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
981 { return m_rep->int64_scalar_value (); } |
4910 | 982 |
5759 | 983 octave_uint8 uint8_scalar_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
984 { return m_rep->uint8_scalar_value (); } |
4910 | 985 |
5759 | 986 octave_uint16 uint16_scalar_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
987 { return m_rep->uint16_scalar_value (); } |
4910 | 988 |
5759 | 989 octave_uint32 uint32_scalar_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
990 { return m_rep->uint32_scalar_value (); } |
4910 | 991 |
5759 | 992 octave_uint64 uint64_scalar_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
993 { return m_rep->uint64_scalar_value (); } |
4910 | 994 |
5759 | 995 int8NDArray int8_array_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
996 { return m_rep->int8_array_value (); } |
4906 | 997 |
5759 | 998 int16NDArray int16_array_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
999 { return m_rep->int16_array_value (); } |
4906 | 1000 |
5759 | 1001 int32NDArray int32_array_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1002 { return m_rep->int32_array_value (); } |
4906 | 1003 |
5759 | 1004 int64NDArray int64_array_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1005 { return m_rep->int64_array_value (); } |
4906 | 1006 |
5759 | 1007 uint8NDArray uint8_array_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1008 { return m_rep->uint8_array_value (); } |
4906 | 1009 |
5759 | 1010 uint16NDArray uint16_array_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1011 { return m_rep->uint16_array_value (); } |
4906 | 1012 |
5759 | 1013 uint32NDArray uint32_array_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1014 { return m_rep->uint32_array_value (); } |
4906 | 1015 |
5759 | 1016 uint64NDArray uint64_array_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1017 { return m_rep->uint64_array_value (); } |
4906 | 1018 |
5759 | 1019 std::string string_value (bool force = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1020 { return m_rep->string_value (force); } |
2376 | 1021 |
20990
fc9cca99b2de
Deprecate all_strings, replace with string_vector_value.
Rik <rik@octave.org>
parents:
20791
diff
changeset
|
1022 string_vector string_vector_value (bool pad = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1023 { return m_rep->string_vector_value (pad); } |
20990
fc9cca99b2de
Deprecate all_strings, replace with string_vector_value.
Rik <rik@octave.org>
parents:
20791
diff
changeset
|
1024 |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1025 Cell cell_value (void) const; |
2376 | 1026 |
8732 | 1027 Array<std::string> cellstr_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1028 { return m_rep->cellstr_value (); } |
8732 | 1029 |
30835
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
1030 octave::range<double> range_value (void) const |
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
1031 { return m_rep->range_value (); } |
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
1032 |
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
1033 // For now, disable all but range<double>. |
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
1034 |
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
1035 #if 0 |
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
1036 |
28646
e26201931ea3
new template class for octave_range objects
John W. Eaton <jwe@octave.org>
parents:
28639
diff
changeset
|
1037 octave::range<float> float_range_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1038 { return m_rep->float_range_value (); } |
28646
e26201931ea3
new template class for octave_range objects
John W. Eaton <jwe@octave.org>
parents:
28639
diff
changeset
|
1039 |
e26201931ea3
new template class for octave_range objects
John W. Eaton <jwe@octave.org>
parents:
28639
diff
changeset
|
1040 octave::range<octave_int8> int8_range_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1041 { return m_rep->int8_range_value (); } |
28646
e26201931ea3
new template class for octave_range objects
John W. Eaton <jwe@octave.org>
parents:
28639
diff
changeset
|
1042 |
e26201931ea3
new template class for octave_range objects
John W. Eaton <jwe@octave.org>
parents:
28639
diff
changeset
|
1043 octave::range<octave_int16> int16_range_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1044 { return m_rep->int16_range_value (); } |
28646
e26201931ea3
new template class for octave_range objects
John W. Eaton <jwe@octave.org>
parents:
28639
diff
changeset
|
1045 |
e26201931ea3
new template class for octave_range objects
John W. Eaton <jwe@octave.org>
parents:
28639
diff
changeset
|
1046 octave::range<octave_int32> int32_range_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1047 { return m_rep->int32_range_value (); } |
28646
e26201931ea3
new template class for octave_range objects
John W. Eaton <jwe@octave.org>
parents:
28639
diff
changeset
|
1048 |
e26201931ea3
new template class for octave_range objects
John W. Eaton <jwe@octave.org>
parents:
28639
diff
changeset
|
1049 octave::range<octave_int64> int64_range_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1050 { return m_rep->int64_range_value (); } |
10742
604e13a89c7f
initial code for structs rewrite
Jaroslav Hajek <highegg@gmail.com>
parents:
10670
diff
changeset
|
1051 |
28646
e26201931ea3
new template class for octave_range objects
John W. Eaton <jwe@octave.org>
parents:
28639
diff
changeset
|
1052 octave::range<octave_uint8> uint8_range_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1053 { return m_rep->uint8_range_value (); } |
28646
e26201931ea3
new template class for octave_range objects
John W. Eaton <jwe@octave.org>
parents:
28639
diff
changeset
|
1054 |
e26201931ea3
new template class for octave_range objects
John W. Eaton <jwe@octave.org>
parents:
28639
diff
changeset
|
1055 octave::range<octave_uint16> uint16_range_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1056 { return m_rep->uint16_range_value (); } |
28646
e26201931ea3
new template class for octave_range objects
John W. Eaton <jwe@octave.org>
parents:
28639
diff
changeset
|
1057 |
e26201931ea3
new template class for octave_range objects
John W. Eaton <jwe@octave.org>
parents:
28639
diff
changeset
|
1058 octave::range<octave_uint32> uint32_range_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1059 { return m_rep->uint32_range_value (); } |
28646
e26201931ea3
new template class for octave_range objects
John W. Eaton <jwe@octave.org>
parents:
28639
diff
changeset
|
1060 |
e26201931ea3
new template class for octave_range objects
John W. Eaton <jwe@octave.org>
parents:
28639
diff
changeset
|
1061 octave::range<octave_uint64> uint64_range_value (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1062 { return m_rep->uint64_range_value (); } |
28646
e26201931ea3
new template class for octave_range objects
John W. Eaton <jwe@octave.org>
parents:
28639
diff
changeset
|
1063 |
30835
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
1064 #endif |
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
1065 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1066 OCTINTERP_API octave_map map_value (void) const; |
10742
604e13a89c7f
initial code for structs rewrite
Jaroslav Hajek <highegg@gmail.com>
parents:
10670
diff
changeset
|
1067 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1068 OCTINTERP_API octave_scalar_map scalar_map_value (void) const; |
10742
604e13a89c7f
initial code for structs rewrite
Jaroslav Hajek <highegg@gmail.com>
parents:
10670
diff
changeset
|
1069 |
5759 | 1070 string_vector map_keys (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1071 { return m_rep->map_keys (); } |
3933 | 1072 |
31260
c5c8bf50449c
Improve performance of isfield from linear time to constant time (bug #58105)
Arun Giridhar <arungiridhar@gmail.com>
parents:
30854
diff
changeset
|
1073 bool isfield (const std::string& field_name) const |
c5c8bf50449c
Improve performance of isfield from linear time to constant time (bug #58105)
Arun Giridhar <arungiridhar@gmail.com>
parents:
30854
diff
changeset
|
1074 { return m_rep->isfield (field_name); } |
c5c8bf50449c
Improve performance of isfield from linear time to constant time (bug #58105)
Arun Giridhar <arungiridhar@gmail.com>
parents:
30854
diff
changeset
|
1075 |
29654
d13d090cb03a
use std::size_t and std::ptrdiff_t in C++ code (bug #60471)
John W. Eaton <jwe@octave.org>
parents:
29476
diff
changeset
|
1076 std::size_t nparents (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1077 { return m_rep->nparents (); } |
9151 | 1078 |
1079 std::list<std::string> parent_class_name_list (void) const | |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1080 { return m_rep->parent_class_name_list (); } |
9151 | 1081 |
9010
f914834836e7
Partial implementation of derived classes using the old form with "@" files.
rtshort@smoketree.phaselocked.com
parents:
8992
diff
changeset
|
1082 string_vector parent_class_names (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1083 { return m_rep->parent_class_names (); } |
9010
f914834836e7
Partial implementation of derived classes using the old form with "@" files.
rtshort@smoketree.phaselocked.com
parents:
8992
diff
changeset
|
1084 |
f914834836e7
Partial implementation of derived classes using the old form with "@" files.
rtshort@smoketree.phaselocked.com
parents:
8992
diff
changeset
|
1085 octave_base_value * |
f914834836e7
Partial implementation of derived classes using the old form with "@" files.
rtshort@smoketree.phaselocked.com
parents:
8992
diff
changeset
|
1086 find_parent_class (const std::string& parent_class_name) |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1087 { return m_rep->find_parent_class (parent_class_name); } |
9010
f914834836e7
Partial implementation of derived classes using the old form with "@" files.
rtshort@smoketree.phaselocked.com
parents:
8992
diff
changeset
|
1088 |
19103
56bc1464ec59
Implement "isa" for classdef objects.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
18416
diff
changeset
|
1089 bool is_instance_of (const std::string& cls_name) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1090 { return m_rep->is_instance_of (cls_name); } |
19103
56bc1464ec59
Implement "isa" for classdef objects.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
18416
diff
changeset
|
1091 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1092 OCTINTERP_API octave_classdef * |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1093 classdef_object_value (bool silent = false) const; |
23881
5aec653c88e7
new function for accessing classdef objects
John W. Eaton <jwe@octave.org>
parents:
23865
diff
changeset
|
1094 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1095 OCTINTERP_API octave_function * |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1096 function_value (bool silent = false) const; |
2974 | 1097 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1098 OCTINTERP_API octave_user_function * |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1099 user_function_value (bool silent = false) const; |
7761
5adeea5de26c
symbol table reporting functions
John W. Eaton <jwe@octave.org>
parents:
7740
diff
changeset
|
1100 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1101 OCTINTERP_API octave_user_script * |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1102 user_script_value (bool silent = false) const; |
4700 | 1103 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1104 OCTINTERP_API octave_user_code * user_code_value (bool silent = false) const; |
7719
87eda1f8faaa
octave_user_code: new base class for octave_user_script and octave_user_function
John W. Eaton <jwe@octave.org>
parents:
7638
diff
changeset
|
1105 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1106 OCTINTERP_API octave_fcn_handle * |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1107 fcn_handle_value (bool silent = false) const; |
4343 | 1108 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1109 OCTINTERP_API octave_value_list list_value (void) const; |
2880 | 1110 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1111 OCTINTERP_API ColumnVector |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1112 column_vector_value (bool frc_str_conv = false, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1113 bool frc_vec_conv = false) const; |
2376 | 1114 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1115 OCTINTERP_API ComplexColumnVector |
3419 | 1116 complex_column_vector_value (bool frc_str_conv = false, |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
1117 bool frc_vec_conv = false) const; |
2376 | 1118 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1119 OCTINTERP_API RowVector |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1120 row_vector_value (bool frc_str_conv = false, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1121 bool frc_vec_conv = false) const; |
3419 | 1122 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1123 OCTINTERP_API ComplexRowVector |
3419 | 1124 complex_row_vector_value (bool frc_str_conv = false, |
10313 | 1125 bool frc_vec_conv = false) const; |
3419 | 1126 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1127 OCTINTERP_API FloatColumnVector |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1128 float_column_vector_value (bool frc_str_conv = false, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1129 bool frc_vec_conv = false) const; |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7761
diff
changeset
|
1130 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1131 OCTINTERP_API FloatComplexColumnVector |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7761
diff
changeset
|
1132 float_complex_column_vector_value (bool frc_str_conv = false, |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
1133 bool frc_vec_conv = false) const; |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7761
diff
changeset
|
1134 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1135 OCTINTERP_API FloatRowVector |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1136 float_row_vector_value (bool frc_str_conv = false, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1137 bool frc_vec_conv = false) const; |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7761
diff
changeset
|
1138 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1139 OCTINTERP_API FloatComplexRowVector |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7761
diff
changeset
|
1140 float_complex_row_vector_value (bool frc_str_conv = false, |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
1141 bool frc_vec_conv = false) const; |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7761
diff
changeset
|
1142 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1143 OCTINTERP_API Array<int> |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1144 int_vector_value (bool req_int = false, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1145 bool frc_str_conv = false, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1146 bool frc_vec_conv = false) const; |
4044 | 1147 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1148 OCTINTERP_API Array<octave_idx_type> |
8811 | 1149 octave_idx_type_vector_value (bool req_int = false, |
10313 | 1150 bool frc_str_conv = false, |
1151 bool frc_vec_conv = false) const; | |
8811 | 1152 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1153 OCTINTERP_API Array<double> |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1154 vector_value (bool frc_str_conv = false, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1155 bool frc_vec_conv = false) const; |
3419 | 1156 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1157 OCTINTERP_API Array<Complex> |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1158 complex_vector_value (bool frc_str_conv = false, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1159 bool frc_vec_conv = false) const; |
3419 | 1160 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1161 OCTINTERP_API Array<float> |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1162 float_vector_value (bool frc_str_conv = false, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1163 bool frc_vec_conv = false) const; |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7761
diff
changeset
|
1164 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1165 OCTINTERP_API Array<FloatComplex> |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
1166 float_complex_vector_value (bool frc_str_conv = false, |
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
1167 bool frc_vec_conv = false) const; |
7789
82be108cc558
First attempt at single precision tyeps
David Bateman <dbateman@free.fr>
parents:
7761
diff
changeset
|
1168 |
21013
7f4c6d594e3d
Finish renaming mapper function finite to isfinite.
Rik <rik@octave.org>
parents:
21012
diff
changeset
|
1169 // Extract values of specific types without any implicit type conversions. |
7f4c6d594e3d
Finish renaming mapper function finite to isfinite.
Rik <rik@octave.org>
parents:
21012
diff
changeset
|
1170 // Throw an error if an object is the wrong type for the requested value |
7f4c6d594e3d
Finish renaming mapper function finite to isfinite.
Rik <rik@octave.org>
parents:
21012
diff
changeset
|
1171 // extraction. |
20700
68e3a747ca02
rename octave_value value extractors that accept error message args
John W. Eaton <jwe@octave.org>
parents:
20696
diff
changeset
|
1172 // |
21013
7f4c6d594e3d
Finish renaming mapper function finite to isfinite.
Rik <rik@octave.org>
parents:
21012
diff
changeset
|
1173 // These functions are intended to provide a simple way to extract values of |
7f4c6d594e3d
Finish renaming mapper function finite to isfinite.
Rik <rik@octave.org>
parents:
21012
diff
changeset
|
1174 // specific types and display error messages that are more meaningful than |
7f4c6d594e3d
Finish renaming mapper function finite to isfinite.
Rik <rik@octave.org>
parents:
21012
diff
changeset
|
1175 // the generic "error: wrong type argument 'cell'" message. |
20700
68e3a747ca02
rename octave_value value extractors that accept error message args
John W. Eaton <jwe@octave.org>
parents:
20696
diff
changeset
|
1176 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1177 OCTINTERP_API short int xshort_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1178 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1179 OCTINTERP_API unsigned short int xushort_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1180 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1181 OCTINTERP_API int xint_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1182 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1183 OCTINTERP_API unsigned int xuint_value (const char *fmt, ...) const; |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1184 |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1185 OCTINTERP_API int xnint_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1186 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1187 OCTINTERP_API long int xlong_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1188 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1189 OCTINTERP_API unsigned long int xulong_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1190 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1191 OCTINTERP_API int64_t xint64_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1192 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1193 OCTINTERP_API uint64_t xuint64_value (const char *fmt, ...) const; |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1194 |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1195 OCTINTERP_API octave_idx_type xidx_type_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1196 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1197 OCTINTERP_API double xdouble_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1198 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1199 OCTINTERP_API float xfloat_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1200 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1201 OCTINTERP_API double xscalar_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1202 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1203 OCTINTERP_API float xfloat_scalar_value (const char *fmt, ...) const; |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1204 |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1205 OCTINTERP_API Matrix xmatrix_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1206 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1207 OCTINTERP_API FloatMatrix xfloat_matrix_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1208 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1209 OCTINTERP_API NDArray xarray_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1210 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1211 OCTINTERP_API FloatNDArray xfloat_array_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1212 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1213 OCTINTERP_API Complex xcomplex_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1214 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1215 OCTINTERP_API FloatComplex xfloat_complex_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1216 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1217 OCTINTERP_API ComplexMatrix |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1218 xcomplex_matrix_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1219 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1220 OCTINTERP_API FloatComplexMatrix |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1221 xfloat_complex_matrix_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1222 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1223 OCTINTERP_API ComplexNDArray |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1224 xcomplex_array_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1225 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1226 OCTINTERP_API FloatComplexNDArray |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1227 xfloat_complex_array_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1228 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1229 OCTINTERP_API bool xbool_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1230 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1231 OCTINTERP_API boolMatrix xbool_matrix_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1232 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1233 OCTINTERP_API boolNDArray xbool_array_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1234 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1235 OCTINTERP_API charMatrix xchar_matrix_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1236 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1237 OCTINTERP_API charNDArray xchar_array_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1238 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1239 OCTINTERP_API SparseMatrix xsparse_matrix_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1240 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1241 OCTINTERP_API SparseComplexMatrix |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1242 xsparse_complex_matrix_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1243 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1244 OCTINTERP_API SparseBoolMatrix |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1245 xsparse_bool_matrix_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1246 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1247 OCTINTERP_API DiagMatrix xdiag_matrix_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1248 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1249 OCTINTERP_API FloatDiagMatrix |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1250 xfloat_diag_matrix_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1251 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1252 OCTINTERP_API ComplexDiagMatrix |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1253 xcomplex_diag_matrix_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1254 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1255 OCTINTERP_API FloatComplexDiagMatrix |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1256 xfloat_complex_diag_matrix_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1257 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1258 OCTINTERP_API PermMatrix xperm_matrix_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1259 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1260 OCTINTERP_API octave_int8 xint8_scalar_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1261 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1262 OCTINTERP_API octave_int16 xint16_scalar_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1263 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1264 OCTINTERP_API octave_int32 xint32_scalar_value (const char *fmt, ...) const; |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1265 |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1266 OCTINTERP_API octave_int64 xint64_scalar_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1267 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1268 OCTINTERP_API octave_uint8 xuint8_scalar_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1269 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1270 OCTINTERP_API octave_uint16 xuint16_scalar_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1271 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1272 OCTINTERP_API octave_uint32 xuint32_scalar_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1273 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1274 OCTINTERP_API octave_uint64 xuint64_scalar_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1275 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1276 OCTINTERP_API int8NDArray xint8_array_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1277 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1278 OCTINTERP_API int16NDArray xint16_array_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1279 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1280 OCTINTERP_API int32NDArray xint32_array_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1281 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1282 OCTINTERP_API int64NDArray xint64_array_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1283 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1284 OCTINTERP_API uint8NDArray xuint8_array_value (const char *fmt, ...) const; |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1285 |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1286 OCTINTERP_API uint16NDArray xuint16_array_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1287 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1288 OCTINTERP_API uint32NDArray xuint32_array_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1289 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1290 OCTINTERP_API uint64NDArray xuint64_array_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1291 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1292 OCTINTERP_API std::string xstring_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1293 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1294 OCTINTERP_API string_vector xstring_vector_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1295 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1296 OCTINTERP_API Cell xcell_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1297 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1298 OCTINTERP_API Array<std::string> xcellstr_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1299 |
30835
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
1300 OCTINTERP_API octave::range<double> |
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
1301 xrange_value (const char *fmt, ...) const; |
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
1302 |
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
1303 // For now, disable all but range<double>. |
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
1304 |
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
1305 #if 0 |
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
1306 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1307 OCTINTERP_API octave::range<float> |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1308 xfloat_range_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1309 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1310 OCTINTERP_API octave::range<octave_int8> |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1311 xint8_range_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1312 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1313 OCTINTERP_API octave::range<octave_int16> |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1314 xint16_range_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1315 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1316 OCTINTERP_API octave::range<octave_int32> |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1317 xint32_range_value (const char *fmt, ...) const; |
20700
68e3a747ca02
rename octave_value value extractors that accept error message args
John W. Eaton <jwe@octave.org>
parents:
20696
diff
changeset
|
1318 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1319 OCTINTERP_API octave::range<octave_int64> |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1320 xint64_range_value (const char *fmt, ...) const; |
20700
68e3a747ca02
rename octave_value value extractors that accept error message args
John W. Eaton <jwe@octave.org>
parents:
20696
diff
changeset
|
1321 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1322 OCTINTERP_API octave::range<octave_uint8> |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1323 xuint8_range_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1324 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1325 OCTINTERP_API octave::range<octave_uint16> |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1326 xuint16_range_value (const char *fmt, ...) const; |
20700
68e3a747ca02
rename octave_value value extractors that accept error message args
John W. Eaton <jwe@octave.org>
parents:
20696
diff
changeset
|
1327 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1328 OCTINTERP_API octave::range<octave_uint32> |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1329 xuint32_range_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1330 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1331 OCTINTERP_API octave::range<octave_uint64> |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1332 xuint64_range_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1333 |
30835
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
1334 #endif |
2989202f92f8
only allow range<FLOAT> to be instantiated
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
1335 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1336 OCTINTERP_API octave_map xmap_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1337 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1338 OCTINTERP_API octave_scalar_map |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1339 xscalar_map_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1340 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1341 OCTINTERP_API ColumnVector xcolumn_vector_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1342 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1343 OCTINTERP_API ComplexColumnVector |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1344 xcomplex_column_vector_value (const char *fmt, ...) const; |
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1345 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1346 OCTINTERP_API RowVector xrow_vector_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1347 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1348 OCTINTERP_API ComplexRowVector |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1349 xcomplex_row_vector_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1350 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1351 OCTINTERP_API FloatColumnVector |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1352 xfloat_column_vector_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1353 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1354 OCTINTERP_API FloatComplexColumnVector |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1355 xfloat_complex_column_vector_value (const char *fmt, ...) const; |
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1356 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1357 OCTINTERP_API FloatRowVector |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1358 xfloat_row_vector_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1359 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1360 OCTINTERP_API FloatComplexRowVector |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1361 xfloat_complex_row_vector_value (const char *fmt, ...) const; |
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1362 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1363 OCTINTERP_API Array<int> xint_vector_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1364 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1365 OCTINTERP_API Array<octave_idx_type> |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1366 xoctave_idx_type_vector_value (const char *fmt, ...) const; |
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1367 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1368 OCTINTERP_API Array<double> xvector_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1369 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1370 OCTINTERP_API Array<Complex> |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1371 xcomplex_vector_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1372 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1373 OCTINTERP_API Array<float> xfloat_vector_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1374 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1375 OCTINTERP_API Array<FloatComplex> |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1376 xfloat_complex_vector_value (const char *fmt, ...) const; |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1377 |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1378 OCTINTERP_API octave_function * xfunction_value (const char *fmt, ...) const; |
20703
85e5efae848a
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20700
diff
changeset
|
1379 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1380 OCTINTERP_API octave_user_function * |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1381 xuser_function_value (const char *fmt, ...) const; |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1382 |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1383 OCTINTERP_API octave_user_script * |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1384 xuser_script_value (const char *fmt, ...) const; |
20741
a5ab31b52ae8
eliminate more uses of error_state
John W. Eaton <jwe@octave.org>
parents:
20704
diff
changeset
|
1385 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1386 OCTINTERP_API octave_user_code * |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1387 xuser_code_value (const char *fmt, ...) const; |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1388 |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1389 OCTINTERP_API octave_fcn_handle * |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1390 xfcn_handle_value (const char *fmt, ...) const; |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1391 |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1392 OCTINTERP_API octave_value_list xlist_value (const char *fmt, ...) const; |
20768
7655b399abff
eliminate trailing whitespace in source files we maintain
John W. Eaton <jwe@octave.org>
parents:
20741
diff
changeset
|
1393 |
8523
ad3afaaa19c1
implement non-copying contiguous range indexing
Jaroslav Hajek <highegg@gmail.com>
parents:
8458
diff
changeset
|
1394 // Possibly economize a lazy-indexed value. |
8150
283989f2da9b
make null assignment matlab compatible
Jaroslav Hajek <highegg@gmail.com>
parents:
8017
diff
changeset
|
1395 |
8523
ad3afaaa19c1
implement non-copying contiguous range indexing
Jaroslav Hajek <highegg@gmail.com>
parents:
8458
diff
changeset
|
1396 void maybe_economize (void) |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1397 { m_rep->maybe_economize (); } |
8523
ad3afaaa19c1
implement non-copying contiguous range indexing
Jaroslav Hajek <highegg@gmail.com>
parents:
8458
diff
changeset
|
1398 |
8531
b01fef323c24
add some explaining comments
Jaroslav Hajek <highegg@gmail.com>
parents:
8523
diff
changeset
|
1399 // The following two hook conversions are called on any octave_value prior to |
b01fef323c24
add some explaining comments
Jaroslav Hajek <highegg@gmail.com>
parents:
8523
diff
changeset
|
1400 // storing it to a "permanent" location, like a named variable, a cell or a |
11586
12df7854fa7c
strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
1401 // struct component, or a return value of a function. |
8523
ad3afaaa19c1
implement non-copying contiguous range indexing
Jaroslav Hajek <highegg@gmail.com>
parents:
8458
diff
changeset
|
1402 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1403 OCTINTERP_API octave_value storable_value (void) const; |
8150
283989f2da9b
make null assignment matlab compatible
Jaroslav Hajek <highegg@gmail.com>
parents:
8017
diff
changeset
|
1404 |
21751
b571fc85953f
maint: Use two spaces after period to indicate sentence break.
Rik <rik@octave.org>
parents:
21739
diff
changeset
|
1405 // Ditto, but in place, i.e., equivalent to *this = this->storable_value (), |
8531
b01fef323c24
add some explaining comments
Jaroslav Hajek <highegg@gmail.com>
parents:
8523
diff
changeset
|
1406 // but possibly more efficient. |
8150
283989f2da9b
make null assignment matlab compatible
Jaroslav Hajek <highegg@gmail.com>
parents:
8017
diff
changeset
|
1407 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1408 OCTINTERP_API void make_storable_value (void); |
8150
283989f2da9b
make null assignment matlab compatible
Jaroslav Hajek <highegg@gmail.com>
parents:
8017
diff
changeset
|
1409 |
21076
b433f9990452
strip trailing whitespace from files
John W. Eaton <jwe@octave.org>
parents:
21040
diff
changeset
|
1410 // FIXME: These should probably be private. |
21013
7f4c6d594e3d
Finish renaming mapper function finite to isfinite.
Rik <rik@octave.org>
parents:
21012
diff
changeset
|
1411 // Conversions. If a user of this class wants a certain kind of constant, |
7f4c6d594e3d
Finish renaming mapper function finite to isfinite.
Rik <rik@octave.org>
parents:
21012
diff
changeset
|
1412 // he should simply ask for it, and we should convert it if possible. |
2376 | 1413 |
5279 | 1414 octave_value convert_to_str (bool pad = false, bool force = false, |
10313 | 1415 char type = '\'') const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1416 { return m_rep->convert_to_str (pad, force, type); } |
4452 | 1417 |
5759 | 1418 octave_value |
5279 | 1419 convert_to_str_internal (bool pad, bool force, char type) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1420 { return m_rep->convert_to_str_internal (pad, force, type); } |
2376 | 1421 |
5759 | 1422 void convert_to_row_or_column_vector (void) |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1423 { m_rep->convert_to_row_or_column_vector (); } |
2376 | 1424 |
5759 | 1425 bool print_as_scalar (void) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1426 { return m_rep->print_as_scalar (); } |
4604 | 1427 |
18416
bcd71a2531d3
Support disp/display overloading in classdef
Michael Goffioul <michael.goffioul@gmail.com>
parents:
18402
diff
changeset
|
1428 void print (std::ostream& os, bool pr_as_read_syntax = false) |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1429 { m_rep->print (os, pr_as_read_syntax); } |
2376 | 1430 |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
1431 void print_raw (std::ostream& os, bool pr_as_read_syntax = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1432 { m_rep->print_raw (os, pr_as_read_syntax); } |
2903 | 1433 |
5759 | 1434 bool print_name_tag (std::ostream& os, const std::string& name) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1435 { return m_rep->print_name_tag (os, name); } |
2376 | 1436 |
13110
2d5035847529
Add Júlio Hoffimann Mendes to contributors.in
John W. Eaton <jwe@octave.org>
parents:
12171
diff
changeset
|
1437 void print_with_name (std::ostream& os, const std::string& name) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1438 { m_rep->print_with_name (os, name, true); } |
2376 | 1439 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1440 void short_disp (std::ostream& os) const { m_rep->short_disp (os); } |
16468
0f143f68078d
use signal/slot for updating workspace instead of using event listener
John W. Eaton <jwe@octave.org>
parents:
16323
diff
changeset
|
1441 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1442 OCTINTERP_API float_display_format get_edit_display_format (void) const; |
24668
d4dd741b2794
new octave_value functions for formatting output
John W. Eaton <jwe@octave.org>
parents:
24643
diff
changeset
|
1443 |
d4dd741b2794
new octave_value functions for formatting output
John W. Eaton <jwe@octave.org>
parents:
24643
diff
changeset
|
1444 std::string edit_display (const float_display_format& fmt, |
d4dd741b2794
new octave_value functions for formatting output
John W. Eaton <jwe@octave.org>
parents:
24643
diff
changeset
|
1445 octave_idx_type i, octave_idx_type j) const |
24643
78aff6f14227
more variable editor improvements; allow more variable types to be edited
John W. Eaton <jwe@octave.org>
parents:
24624
diff
changeset
|
1446 { |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1447 return m_rep->edit_display (fmt, i, j); |
24643
78aff6f14227
more variable editor improvements; allow more variable types to be edited
John W. Eaton <jwe@octave.org>
parents:
24624
diff
changeset
|
1448 } |
78aff6f14227
more variable editor improvements; allow more variable types to be edited
John W. Eaton <jwe@octave.org>
parents:
24624
diff
changeset
|
1449 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1450 int type_id (void) const { return m_rep->type_id (); } |
2376 | 1451 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1452 std::string type_name (void) const { return m_rep->type_name (); } |
5759 | 1453 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1454 std::string class_name (void) const { return m_rep->class_name (); } |
4612 | 1455 |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1456 // Unary operations that are member functions. There are also some |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1457 // non-member functions for unary and binary operations declared |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1458 // below, outside of the octave_value class declaration. |
2376 | 1459 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1460 OCTINTERP_API octave_value& non_const_unary_op (unary_op op); |
7800
5861b95e9879
support for compound operators, implement trans_mul, mul_trans, herm_mul and mul_herm
Jaroslav Hajek <highegg@gmail.com>
parents:
7789
diff
changeset
|
1461 |
29954
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
1462 #if defined (OCTAVE_PROVIDE_DEPRECATED_SYMBOLS) |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1463 OCTAVE_DEPRECATED (7, "use 'octave_value::non_const_unary_op' instead") |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1464 octave_value& do_non_const_unary_op (unary_op op) |
19749
c913247c85a8
make colon function work (bug #44290)
John W. Eaton <jwe@octave.org>
parents:
19697
diff
changeset
|
1465 { |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1466 return non_const_unary_op (op); |
19749
c913247c85a8
make colon function work (bug #44290)
John W. Eaton <jwe@octave.org>
parents:
19697
diff
changeset
|
1467 } |
29954
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
1468 #endif |
19749
c913247c85a8
make colon function work (bug #44290)
John W. Eaton <jwe@octave.org>
parents:
19697
diff
changeset
|
1469 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1470 OCTINTERP_API octave_value& |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1471 non_const_unary_op (unary_op op, const std::string& type, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1472 const std::list<octave_value_list>& idx); |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1473 |
29954
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
1474 #if defined (OCTAVE_PROVIDE_DEPRECATED_SYMBOLS) |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1475 OCTAVE_DEPRECATED (7, "use 'octave_value::non_const_unary_op' instead") |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1476 octave_value& do_non_const_unary_op (unary_op op, const std::string& type, |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1477 const std::list<octave_value_list>& idx) |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1478 { |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1479 return non_const_unary_op (op, type, idx); |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1480 } |
29954
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
1481 #endif |
19749
c913247c85a8
make colon function work (bug #44290)
John W. Eaton <jwe@octave.org>
parents:
19697
diff
changeset
|
1482 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1483 const octave_base_value& get_rep (void) const { return *m_rep; } |
3301 | 1484 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1485 bool is_copy_of (const octave_value& val) const { return m_rep == val.m_rep; } |
8456
c1709a45b45b
optimize structure components access
Jaroslav Hajek <highegg@gmail.com>
parents:
8437
diff
changeset
|
1486 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1487 OCTINTERP_API void |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1488 print_info (std::ostream& os, const std::string& prefix = "") const; |
3933 | 1489 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1490 bool save_ascii (std::ostream& os) { return m_rep->save_ascii (os); } |
4687 | 1491 |
30852
95725e6ad9c1
restore part of the old octave_range class as octave_legacy_range
John W. Eaton <jwe@octave.org>
parents:
30835
diff
changeset
|
1492 OCTINTERP_API bool load_ascii (std::istream& is); |
4687 | 1493 |
26399
586413770c7f
pass save_as_floats by value in octave_value save_binary functions
John W. Eaton <jwe@octave.org>
parents:
26377
diff
changeset
|
1494 bool save_binary (std::ostream& os, bool save_as_floats) |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1495 { return m_rep->save_binary (os, save_as_floats); } |
4687 | 1496 |
30852
95725e6ad9c1
restore part of the old octave_range class as octave_legacy_range
John W. Eaton <jwe@octave.org>
parents:
30835
diff
changeset
|
1497 OCTINTERP_API bool load_binary (std::istream& is, bool swap, |
95725e6ad9c1
restore part of the old octave_range class as octave_legacy_range
John W. Eaton <jwe@octave.org>
parents:
30835
diff
changeset
|
1498 octave::mach_info::float_format fmt); |
4687 | 1499 |
19863
09ed6f7538dd
avoid needing to include hdf5 in public header files (bug #44370, #43180)
John W. Eaton <jwe@octave.org> and Mike Miller <mtmiller@ieee.org>
parents:
19749
diff
changeset
|
1500 bool save_hdf5 (octave_hdf5_id loc_id, const char *name, |
09ed6f7538dd
avoid needing to include hdf5 in public header files (bug #44370, #43180)
John W. Eaton <jwe@octave.org> and Mike Miller <mtmiller@ieee.org>
parents:
19749
diff
changeset
|
1501 bool save_as_floats) |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1502 { return m_rep->save_hdf5 (loc_id, name, save_as_floats); } |
4687 | 1503 |
30852
95725e6ad9c1
restore part of the old octave_range class as octave_legacy_range
John W. Eaton <jwe@octave.org>
parents:
30835
diff
changeset
|
1504 OCTINTERP_API bool load_hdf5 (octave_hdf5_id loc_id, const char *name); |
4687 | 1505 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1506 OCTINTERP_API int |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1507 write (octave::stream& os, int block_size, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1508 oct_data_conv::data_type output_type, int skip, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1509 octave::mach_info::float_format flt_fmt) const; |
4944 | 1510 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1511 octave_base_value * internal_rep (void) const { return m_rep; } |
4901 | 1512 |
30232
a2936935c7c8
attempt to limit possible const_cast damage
John W. Eaton <jwe@octave.org>
parents:
30139
diff
changeset
|
1513 // These functions exist to support the MEX interface. |
5900 | 1514 // You should not use them anywhere else. |
30232
a2936935c7c8
attempt to limit possible const_cast damage
John W. Eaton <jwe@octave.org>
parents:
30139
diff
changeset
|
1515 |
a2936935c7c8
attempt to limit possible const_cast damage
John W. Eaton <jwe@octave.org>
parents:
30139
diff
changeset
|
1516 OCTINTERP_API const void * |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1517 mex_get_data (mxClassID class_id = mxUNKNOWN_CLASS, |
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1518 mxComplexity complexity = mxREAL) const; |
5900 | 1519 |
30232
a2936935c7c8
attempt to limit possible const_cast damage
John W. Eaton <jwe@octave.org>
parents:
30139
diff
changeset
|
1520 const octave_idx_type * mex_get_ir (void) const |
a2936935c7c8
attempt to limit possible const_cast damage
John W. Eaton <jwe@octave.org>
parents:
30139
diff
changeset
|
1521 { |
a2936935c7c8
attempt to limit possible const_cast damage
John W. Eaton <jwe@octave.org>
parents:
30139
diff
changeset
|
1522 return m_rep->mex_get_ir (); |
a2936935c7c8
attempt to limit possible const_cast damage
John W. Eaton <jwe@octave.org>
parents:
30139
diff
changeset
|
1523 } |
5900 | 1524 |
30232
a2936935c7c8
attempt to limit possible const_cast damage
John W. Eaton <jwe@octave.org>
parents:
30139
diff
changeset
|
1525 const octave_idx_type * |
a2936935c7c8
attempt to limit possible const_cast damage
John W. Eaton <jwe@octave.org>
parents:
30139
diff
changeset
|
1526 mex_get_jc (void) const |
a2936935c7c8
attempt to limit possible const_cast damage
John W. Eaton <jwe@octave.org>
parents:
30139
diff
changeset
|
1527 { |
a2936935c7c8
attempt to limit possible const_cast damage
John W. Eaton <jwe@octave.org>
parents:
30139
diff
changeset
|
1528 return m_rep->mex_get_jc (); |
a2936935c7c8
attempt to limit possible const_cast damage
John W. Eaton <jwe@octave.org>
parents:
30139
diff
changeset
|
1529 } |
5900 | 1530 |
28126
4c21f99b4ad5
handle interleaved complex data and new typed data access functions for mex
John W. Eaton <jwe@octave.org>
parents:
28123
diff
changeset
|
1531 mxArray * as_mxArray (bool interleaved = false) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1532 { return m_rep->as_mxArray (interleaved); } |
5900 | 1533 |
7620
36594d5bbe13
Move diag function into the octave_value class
David Bateman <dbateman@free.fr>
parents:
7576
diff
changeset
|
1534 octave_value diag (octave_idx_type k = 0) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1535 { return m_rep->diag (k); } |
7620
36594d5bbe13
Move diag function into the octave_value class
David Bateman <dbateman@free.fr>
parents:
7576
diff
changeset
|
1536 |
14557
e8e86ae3abbc
make diag (x, m, n) return a proper diagonal matrix object (bug #36099)
John W. Eaton <jwe@octave.org>
parents:
14528
diff
changeset
|
1537 octave_value diag (octave_idx_type m, octave_idx_type n) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1538 { return m_rep->diag (m, n); } |
14557
e8e86ae3abbc
make diag (x, m, n) return a proper diagonal matrix object (bug #36099)
John W. Eaton <jwe@octave.org>
parents:
14528
diff
changeset
|
1539 |
7463
2467639bd8c0
eliminate UNDEFINED sort mode
John W. Eaton <jwe@octave.org>
parents:
7433
diff
changeset
|
1540 octave_value sort (octave_idx_type dim = 0, sortmode mode = ASCENDING) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1541 { return m_rep->sort (dim, mode); } |
30390
a61e1a0f6024
maint: style check C++ files in libinterp/ ahead of 7.1 release.
Rik <rik@octave.org>
parents:
30232
diff
changeset
|
1542 octave_value sort (Array<octave_idx_type>& sidx, octave_idx_type dim = 0, |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
1543 sortmode mode = ASCENDING) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1544 { return m_rep->sort (sidx, dim, mode); } |
7433 | 1545 |
23588
0549061d35b9
maint: Deprecate is_sorted and replace with issorted.
Rik <rik@octave.org>
parents:
23587
diff
changeset
|
1546 sortmode issorted (sortmode mode = UNSORTED) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1547 { return m_rep->issorted (mode); } |
23588
0549061d35b9
maint: Deprecate is_sorted and replace with issorted.
Rik <rik@octave.org>
parents:
23587
diff
changeset
|
1548 |
8733
3ef774603887
rename all uses of sortrows_idx to sort_rows_idx
John W. Eaton <jwe@octave.org>
parents:
8732
diff
changeset
|
1549 Array<octave_idx_type> sort_rows_idx (sortmode mode = ASCENDING) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1550 { return m_rep->sort_rows_idx (mode); } |
8721
e9cb742df9eb
imported patch sort3.diff
Jaroslav Hajek <highegg@gmail.com>
parents:
8676
diff
changeset
|
1551 |
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
|
1552 sortmode is_sorted_rows (sortmode mode = UNSORTED) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1553 { return m_rep->is_sorted_rows (mode); } |
8721
e9cb742df9eb
imported patch sort3.diff
Jaroslav Hajek <highegg@gmail.com>
parents:
8676
diff
changeset
|
1554 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1555 void lock (void) { m_rep->lock (); } |
7489
8e4592e49fa7
don't clear locked functions
John W. Eaton <jwe@octave.org>
parents:
7463
diff
changeset
|
1556 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1557 void unlock (void) { m_rep->unlock (); } |
7489
8e4592e49fa7
don't clear locked functions
John W. Eaton <jwe@octave.org>
parents:
7463
diff
changeset
|
1558 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1559 bool islocked (void) const { return m_rep->islocked (); } |
7489
8e4592e49fa7
don't clear locked functions
John W. Eaton <jwe@octave.org>
parents:
7463
diff
changeset
|
1560 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1561 void call_object_destructor (void) { return m_rep->call_object_destructor (); } |
26655
cca0548f7b86
refactor calling object destructor
John W. Eaton <jwe@octave.org>
parents:
26399
diff
changeset
|
1562 |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1563 octave_value dump (void) const { return m_rep->dump (); } |
7761
5adeea5de26c
symbol table reporting functions
John W. Eaton <jwe@octave.org>
parents:
7740
diff
changeset
|
1564 |
9813
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1565 #define MAPPER_FORWARD(F) \ |
22197
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1566 octave_value F (void) const \ |
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1567 { \ |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1568 return m_rep->map (octave_base_value::umap_ ## F); \ |
22197
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1569 } |
9813
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1570 |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1571 MAPPER_FORWARD (abs) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1572 MAPPER_FORWARD (acos) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1573 MAPPER_FORWARD (acosh) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1574 MAPPER_FORWARD (angle) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1575 MAPPER_FORWARD (arg) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1576 MAPPER_FORWARD (asin) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1577 MAPPER_FORWARD (asinh) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1578 MAPPER_FORWARD (atan) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1579 MAPPER_FORWARD (atanh) |
10414
2a8b1db1e2ca
implement built-in cbrt
Jaroslav Hajek <highegg@gmail.com>
parents:
10391
diff
changeset
|
1580 MAPPER_FORWARD (cbrt) |
9813
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1581 MAPPER_FORWARD (ceil) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1582 MAPPER_FORWARD (conj) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1583 MAPPER_FORWARD (cos) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1584 MAPPER_FORWARD (cosh) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1585 MAPPER_FORWARD (erf) |
9835
1bb1ed717d2f
implement built-in erfinv
Jaroslav Hajek <highegg@gmail.com>
parents:
9813
diff
changeset
|
1586 MAPPER_FORWARD (erfinv) |
14770
cb85e836d035
New function: erfcinv (bug #36607)
Axel Mathéi <axel.mathei@gmail.com>
parents:
14557
diff
changeset
|
1587 MAPPER_FORWARD (erfcinv) |
9813
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1588 MAPPER_FORWARD (erfc) |
10391
59e34bcdff13
implement built-in erfcx
Jaroslav Hajek <highegg@gmail.com>
parents:
10325
diff
changeset
|
1589 MAPPER_FORWARD (erfcx) |
15696
2fac72a256ce
Add complex erf,erfc,erfcx,erfi,dawson routines from Faddeeva package.
Steven G. Johnson <stevenj@alum.mit.edu>
parents:
15487
diff
changeset
|
1590 MAPPER_FORWARD (erfi) |
2fac72a256ce
Add complex erf,erfc,erfcx,erfi,dawson routines from Faddeeva package.
Steven G. Johnson <stevenj@alum.mit.edu>
parents:
15487
diff
changeset
|
1591 MAPPER_FORWARD (dawson) |
9813
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1592 MAPPER_FORWARD (exp) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1593 MAPPER_FORWARD (expm1) |
21013
7f4c6d594e3d
Finish renaming mapper function finite to isfinite.
Rik <rik@octave.org>
parents:
21012
diff
changeset
|
1594 MAPPER_FORWARD (isfinite) |
9813
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1595 MAPPER_FORWARD (fix) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1596 MAPPER_FORWARD (floor) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1597 MAPPER_FORWARD (gamma) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1598 MAPPER_FORWARD (imag) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1599 MAPPER_FORWARD (isinf) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1600 MAPPER_FORWARD (isna) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1601 MAPPER_FORWARD (isnan) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1602 MAPPER_FORWARD (lgamma) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1603 MAPPER_FORWARD (log) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1604 MAPPER_FORWARD (log2) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1605 MAPPER_FORWARD (log10) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1606 MAPPER_FORWARD (log1p) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1607 MAPPER_FORWARD (real) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1608 MAPPER_FORWARD (round) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1609 MAPPER_FORWARD (roundb) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1610 MAPPER_FORWARD (signum) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1611 MAPPER_FORWARD (sin) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1612 MAPPER_FORWARD (sinh) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1613 MAPPER_FORWARD (sqrt) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1614 MAPPER_FORWARD (tan) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1615 MAPPER_FORWARD (tanh) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1616 |
21013
7f4c6d594e3d
Finish renaming mapper function finite to isfinite.
Rik <rik@octave.org>
parents:
21012
diff
changeset
|
1617 // These functions are prefixed with X to avoid potential macro conflicts. |
9813
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1618 |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1619 MAPPER_FORWARD (xisalnum) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1620 MAPPER_FORWARD (xisalpha) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1621 MAPPER_FORWARD (xisascii) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1622 MAPPER_FORWARD (xiscntrl) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1623 MAPPER_FORWARD (xisdigit) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1624 MAPPER_FORWARD (xisgraph) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1625 MAPPER_FORWARD (xislower) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1626 MAPPER_FORWARD (xisprint) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1627 MAPPER_FORWARD (xispunct) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1628 MAPPER_FORWARD (xisspace) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1629 MAPPER_FORWARD (xisupper) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1630 MAPPER_FORWARD (xisxdigit) |
15487
ecf5be238b4a
provide signbit mapper for real values
John W. Eaton <jwe@octave.org>
parents:
15429
diff
changeset
|
1631 MAPPER_FORWARD (xsignbit) |
9813
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1632 MAPPER_FORWARD (xtolower) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1633 MAPPER_FORWARD (xtoupper) |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1634 |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1635 #undef MAPPER_FORWARD |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1636 |
8fa32b527d9a
improve & partially revert previous change
Jaroslav Hajek <highegg@gmail.com>
parents:
9812
diff
changeset
|
1637 octave_value map (octave_base_value::unary_mapper_t umap) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1638 { return m_rep->map (umap); } |
7503
8c32f95c2639
convert mapper functions to new format
David Bateman <dbateman@free.fr>
parents:
7489
diff
changeset
|
1639 |
27216
823b4bcf79fc
unless necessary for formatting or code, use ' instead of `
John W. Eaton <jwe@octave.org>
parents:
26922
diff
changeset
|
1640 //! Extract the n-th element, aka 'val(n)'. |
24624
ce2eb28e0a6d
doc: make all Doxygen comment blocks more consistent
Mike Miller <mtmiller@octave.org>
parents:
24620
diff
changeset
|
1641 //! |
27216
823b4bcf79fc
unless necessary for formatting or code, use ' instead of `
John W. Eaton <jwe@octave.org>
parents:
26922
diff
changeset
|
1642 //! @return Result is undefined if 'val' is not an array type |
24624
ce2eb28e0a6d
doc: make all Doxygen comment blocks more consistent
Mike Miller <mtmiller@octave.org>
parents:
24620
diff
changeset
|
1643 //! or @p n is out of range. |
ce2eb28e0a6d
doc: make all Doxygen comment blocks more consistent
Mike Miller <mtmiller@octave.org>
parents:
24620
diff
changeset
|
1644 //! |
ce2eb28e0a6d
doc: make all Doxygen comment blocks more consistent
Mike Miller <mtmiller@octave.org>
parents:
24620
diff
changeset
|
1645 //! @warning Function calls should never error. |
ce2eb28e0a6d
doc: make all Doxygen comment blocks more consistent
Mike Miller <mtmiller@octave.org>
parents:
24620
diff
changeset
|
1646 |
10670
654fbde5dceb
make cellfun's fast scalar collection mechanism public
Jaroslav Hajek <highegg@gmail.com>
parents:
10614
diff
changeset
|
1647 octave_value |
654fbde5dceb
make cellfun's fast scalar collection mechanism public
Jaroslav Hajek <highegg@gmail.com>
parents:
10614
diff
changeset
|
1648 fast_elem_extract (octave_idx_type n) const |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1649 { return m_rep->fast_elem_extract (n); } |
10670
654fbde5dceb
make cellfun's fast scalar collection mechanism public
Jaroslav Hajek <highegg@gmail.com>
parents:
10614
diff
changeset
|
1650 |
27216
823b4bcf79fc
unless necessary for formatting or code, use ' instead of `
John W. Eaton <jwe@octave.org>
parents:
26922
diff
changeset
|
1651 //! Assign the n-th element, aka 'val(n) = x'. |
24624
ce2eb28e0a6d
doc: make all Doxygen comment blocks more consistent
Mike Miller <mtmiller@octave.org>
parents:
24620
diff
changeset
|
1652 //! |
27216
823b4bcf79fc
unless necessary for formatting or code, use ' instead of `
John W. Eaton <jwe@octave.org>
parents:
26922
diff
changeset
|
1653 //! @returns false if 'val' is not an array type, |
24624
ce2eb28e0a6d
doc: make all Doxygen comment blocks more consistent
Mike Miller <mtmiller@octave.org>
parents:
24620
diff
changeset
|
1654 //! @p x is not a matching scalar type, |
ce2eb28e0a6d
doc: make all Doxygen comment blocks more consistent
Mike Miller <mtmiller@octave.org>
parents:
24620
diff
changeset
|
1655 //! or @p n is out of range. |
ce2eb28e0a6d
doc: make all Doxygen comment blocks more consistent
Mike Miller <mtmiller@octave.org>
parents:
24620
diff
changeset
|
1656 //! |
ce2eb28e0a6d
doc: make all Doxygen comment blocks more consistent
Mike Miller <mtmiller@octave.org>
parents:
24620
diff
changeset
|
1657 //! @warning Function calls should never error. |
ce2eb28e0a6d
doc: make all Doxygen comment blocks more consistent
Mike Miller <mtmiller@octave.org>
parents:
24620
diff
changeset
|
1658 |
24040
8e8dbabd6e84
ov.h(fast_elem_insert): Remove "virtual" declaration.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
23913
diff
changeset
|
1659 bool |
10670
654fbde5dceb
make cellfun's fast scalar collection mechanism public
Jaroslav Hajek <highegg@gmail.com>
parents:
10614
diff
changeset
|
1660 fast_elem_insert (octave_idx_type n, const octave_value& x) |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
1661 { |
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
1662 make_unique (); |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1663 return m_rep->fast_elem_insert (n, x); |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
1664 } |
10670
654fbde5dceb
make cellfun's fast scalar collection mechanism public
Jaroslav Hajek <highegg@gmail.com>
parents:
10614
diff
changeset
|
1665 |
2376 | 1666 protected: |
1667 | |
24040
8e8dbabd6e84
ov.h(fast_elem_insert): Remove "virtual" declaration.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
23913
diff
changeset
|
1668 //! The real representation. |
30128
5616702bffac
maint: use "m_" prefix for member variable "m_rep" in class octave_value.
Rik <rik@octave.org>
parents:
30012
diff
changeset
|
1669 octave_base_value *m_rep; |
2413 | 1670 |
3933 | 1671 private: |
2903 | 1672 |
30390
a61e1a0f6024
maint: style check C++ files in libinterp/ ahead of 7.1 release.
Rik <rik@octave.org>
parents:
30232
diff
changeset
|
1673 static OCTINTERP_API octave_base_value * nil_rep (void); |
21573
f3f8e1d3e399
avoid mulitple definitions of static function-scope vars (bug #47372)
John W. Eaton <jwe@octave.org>
parents:
20087
diff
changeset
|
1674 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1675 OCTINTERP_API assign_op unary_op_to_assign_op (unary_op op); |
3205 | 1676 |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1677 OCTINTERP_API binary_op op_eq_to_binary_op (assign_op op); |
3204 | 1678 |
9521 | 1679 // This declaration protects against constructing octave_value from |
1680 // const octave_base_value* which actually silently calls octave_value (bool). | |
29234
853e60367cb6
Set API tags in files in libinterp/octave-value (patch #8919).
Markus Mützel <markus.muetzel@gmx.de>
parents:
28900
diff
changeset
|
1681 OCTINTERP_API octave_value (const octave_base_value *); |
9521 | 1682 |
2376 | 1683 }; |
1684 | |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1685 // Non-member unary and binary operations on octave_value objects. |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1686 |
29960
939bef0b66e0
merge "namespace octave" and OCTAVE_NAMESPACE_BEGIN/END blocks
John W. Eaton <jwe@octave.org>
parents:
29954
diff
changeset
|
1687 OCTAVE_NAMESPACE_BEGIN |
939bef0b66e0
merge "namespace octave" and OCTAVE_NAMESPACE_BEGIN/END blocks
John W. Eaton <jwe@octave.org>
parents:
29954
diff
changeset
|
1688 |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1689 extern OCTINTERP_API octave_value |
28857
43ad651cf5a0
eliminate unnecessary uses of octave:: namespace qualifier
John W. Eaton <jwe@octave.org>
parents:
28646
diff
changeset
|
1690 unary_op (type_info& ti, octave_value::unary_op op, |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1691 const octave_value& a); |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1692 |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1693 extern OCTINTERP_API octave_value |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1694 unary_op (octave_value::unary_op op, const octave_value& a); |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1695 |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1696 extern OCTINTERP_API octave_value |
28857
43ad651cf5a0
eliminate unnecessary uses of octave:: namespace qualifier
John W. Eaton <jwe@octave.org>
parents:
28646
diff
changeset
|
1697 binary_op (type_info& ti, octave_value::binary_op op, |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1698 const octave_value& a, const octave_value& b); |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1699 |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1700 extern OCTINTERP_API octave_value |
28857
43ad651cf5a0
eliminate unnecessary uses of octave:: namespace qualifier
John W. Eaton <jwe@octave.org>
parents:
28646
diff
changeset
|
1701 binary_op (type_info& ti, octave_value::compound_binary_op op, |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1702 const octave_value& a, const octave_value& b); |
24565
dbec1e04f499
accept type_info obj as arg to binary_op, unary_op, and cat_op functions
John W. Eaton <jwe@octave.org>
parents:
24540
diff
changeset
|
1703 |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1704 extern OCTINTERP_API octave_value |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1705 binary_op (octave_value::binary_op op, const octave_value& a, |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1706 const octave_value& b); |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1707 |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1708 extern OCTINTERP_API octave_value |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1709 binary_op (octave_value::compound_binary_op op, const octave_value& a, |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1710 const octave_value& b); |
5508 | 1711 |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1712 extern OCTINTERP_API octave_value |
28857
43ad651cf5a0
eliminate unnecessary uses of octave:: namespace qualifier
John W. Eaton <jwe@octave.org>
parents:
28646
diff
changeset
|
1713 cat_op (type_info& ti, const octave_value& a, |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1714 const octave_value& b, const Array<octave_idx_type>& ra_idx); |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1715 |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1716 extern OCTINTERP_API octave_value |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1717 cat_op (const octave_value& a, const octave_value& b, |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1718 const Array<octave_idx_type>& ra_idx); |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1719 |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1720 extern OCTINTERP_API octave_value |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1721 colon_op (const octave_value& base, const octave_value& increment, |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1722 const octave_value& limit, bool is_for_cmd_expr = false); |
5508 | 1723 |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1724 inline octave_value |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1725 colon_op (const octave_value& base, const octave_value& limit, |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1726 bool is_for_cmd_expr = false) |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1727 { |
28633
c897ec8fb5d1
refactor octave_value colon_op function
John W. Eaton <jwe@octave.org>
parents:
28631
diff
changeset
|
1728 // Note, we need to pass an undefined octave_value object instead of |
c897ec8fb5d1
refactor octave_value colon_op function
John W. Eaton <jwe@octave.org>
parents:
28631
diff
changeset
|
1729 // octave_value (1.0) so that we can properly detect the |
c897ec8fb5d1
refactor octave_value colon_op function
John W. Eaton <jwe@octave.org>
parents:
28631
diff
changeset
|
1730 // two-argument case and correctly pass just two arguments to any |
c897ec8fb5d1
refactor octave_value colon_op function
John W. Eaton <jwe@octave.org>
parents:
28631
diff
changeset
|
1731 // user-defined function that is provided if either base or limit is |
c897ec8fb5d1
refactor octave_value colon_op function
John W. Eaton <jwe@octave.org>
parents:
28631
diff
changeset
|
1732 // an object. |
c897ec8fb5d1
refactor octave_value colon_op function
John W. Eaton <jwe@octave.org>
parents:
28631
diff
changeset
|
1733 |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1734 return colon_op (base, octave_value (), limit, is_for_cmd_expr); |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1735 } |
29960
939bef0b66e0
merge "namespace octave" and OCTAVE_NAMESPACE_BEGIN/END blocks
John W. Eaton <jwe@octave.org>
parents:
29954
diff
changeset
|
1736 |
939bef0b66e0
merge "namespace octave" and OCTAVE_NAMESPACE_BEGIN/END blocks
John W. Eaton <jwe@octave.org>
parents:
29954
diff
changeset
|
1737 OCTAVE_NAMESPACE_END |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1738 |
29954
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
1739 #if defined (OCTAVE_PROVIDE_DEPRECATED_SYMBOLS) |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1740 OCTAVE_DEPRECATED (7, "use 'octave::unary_op' instead") |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1741 inline octave_value |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1742 do_unary_op (octave::type_info& ti, octave_value::unary_op op, |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1743 const octave_value& a) |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1744 { |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1745 return octave::unary_op (ti, op, a); |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1746 } |
24565
dbec1e04f499
accept type_info obj as arg to binary_op, unary_op, and cat_op functions
John W. Eaton <jwe@octave.org>
parents:
24540
diff
changeset
|
1747 |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1748 OCTAVE_DEPRECATED (7, "use 'octave::unary_op' instead") |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1749 inline octave_value |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1750 do_unary_op (octave_value::unary_op op, const octave_value& a) |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1751 { |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1752 return octave::unary_op (op, a); |
29954
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
1753 } |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1754 |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1755 OCTAVE_DEPRECATED (7, "use 'octave::binary_op' instead") |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1756 inline octave_value |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1757 do_binary_op (octave::type_info& ti, octave_value::binary_op op, |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1758 const octave_value& a, const octave_value& b) |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1759 { |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1760 return octave::binary_op (ti, op, a, b); |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1761 } |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1762 |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1763 OCTAVE_DEPRECATED (7, "use 'octave::binary_op' instead") |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1764 inline octave_value |
24565
dbec1e04f499
accept type_info obj as arg to binary_op, unary_op, and cat_op functions
John W. Eaton <jwe@octave.org>
parents:
24540
diff
changeset
|
1765 do_binary_op (octave::type_info& ti, octave_value::compound_binary_op op, |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1766 const octave_value& a, const octave_value& b) |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1767 { |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1768 return octave::binary_op (ti, op, a, b); |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1769 } |
5508 | 1770 |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1771 OCTAVE_DEPRECATED (7, "use 'octave::binary_op' instead") |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1772 inline octave_value |
24565
dbec1e04f499
accept type_info obj as arg to binary_op, unary_op, and cat_op functions
John W. Eaton <jwe@octave.org>
parents:
24540
diff
changeset
|
1773 do_binary_op (octave_value::binary_op op, const octave_value& a, |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1774 const octave_value& b) |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1775 { |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1776 return octave::binary_op (op, a, b); |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1777 } |
24565
dbec1e04f499
accept type_info obj as arg to binary_op, unary_op, and cat_op functions
John W. Eaton <jwe@octave.org>
parents:
24540
diff
changeset
|
1778 |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1779 OCTAVE_DEPRECATED (7, "use 'octave::binary_op' instead") |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1780 inline octave_value |
24565
dbec1e04f499
accept type_info obj as arg to binary_op, unary_op, and cat_op functions
John W. Eaton <jwe@octave.org>
parents:
24540
diff
changeset
|
1781 do_binary_op (octave_value::compound_binary_op op, const octave_value& a, |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1782 const octave_value& b) |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1783 { |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1784 return octave::binary_op (op, a, b); |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1785 } |
24565
dbec1e04f499
accept type_info obj as arg to binary_op, unary_op, and cat_op functions
John W. Eaton <jwe@octave.org>
parents:
24540
diff
changeset
|
1786 |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1787 OCTAVE_DEPRECATED (7, "use 'octave::cat_op' instead") |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1788 inline octave_value |
24565
dbec1e04f499
accept type_info obj as arg to binary_op, unary_op, and cat_op functions
John W. Eaton <jwe@octave.org>
parents:
24540
diff
changeset
|
1789 do_cat_op (octave::type_info& ti, const octave_value& a, |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1790 const octave_value& b, const Array<octave_idx_type>& ra_idx) |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1791 { |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1792 return octave::cat_op (ti, a, b, ra_idx); |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1793 } |
24565
dbec1e04f499
accept type_info obj as arg to binary_op, unary_op, and cat_op functions
John W. Eaton <jwe@octave.org>
parents:
24540
diff
changeset
|
1794 |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1795 OCTAVE_DEPRECATED (7, "use 'octave::cat_op' instead") |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1796 inline octave_value |
24565
dbec1e04f499
accept type_info obj as arg to binary_op, unary_op, and cat_op functions
John W. Eaton <jwe@octave.org>
parents:
24540
diff
changeset
|
1797 do_cat_op (const octave_value& a, const octave_value& b, |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1798 const Array<octave_idx_type>& ra_idx) |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1799 { |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1800 return octave::cat_op (a, b, ra_idx); |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1801 } |
7800
5861b95e9879
support for compound operators, implement trans_mul, mul_trans, herm_mul and mul_herm
Jaroslav Hajek <highegg@gmail.com>
parents:
7789
diff
changeset
|
1802 |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1803 OCTAVE_DEPRECATED (7, "use 'octave::colon_op' instead") |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1804 inline octave_value |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1805 do_colon_op (const octave_value& base, const octave_value& increment, |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1806 const octave_value& limit, bool is_for_cmd_expr = false) |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1807 { |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1808 return octave::colon_op (base, increment, limit, is_for_cmd_expr); |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1809 } |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1810 |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1811 OCTAVE_DEPRECATED (7, "use 'octave::colon_op' instead") |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1812 inline octave_value |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1813 do_colon_op (const octave_value& base, const octave_value& limit, |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1814 bool is_for_cmd_expr = false) |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1815 { |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1816 return octave::colon_op (base, limit, is_for_cmd_expr); |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1817 } |
29954
4c88a452519c
rename OCTAVE_USE_DEPRECATED_FUNCTIONS macro and attempt to make it work
John W. Eaton <jwe@octave.org>
parents:
29655
diff
changeset
|
1818 #endif |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1819 |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1820 #define OV_UNOP_FN(name) \ |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1821 inline octave_value \ |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1822 name (const octave_value& a) \ |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1823 { \ |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1824 return octave::unary_op (octave_value::name, a); \ |
3203 | 1825 } |
1826 | |
22197
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1827 #define OV_UNOP_OP(name, op) \ |
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1828 inline octave_value \ |
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1829 operator op (const octave_value& a) \ |
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1830 { \ |
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1831 return name (a); \ |
3203 | 1832 } |
1833 | |
22197
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1834 #define OV_UNOP_FN_OP(name, op) \ |
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1835 OV_UNOP_FN (name) \ |
3203 | 1836 OV_UNOP_OP (name, op) |
1837 | |
3525 | 1838 OV_UNOP_FN_OP (op_not, !) |
6518 | 1839 OV_UNOP_FN_OP (op_uplus, +) |
3525 | 1840 OV_UNOP_FN_OP (op_uminus, -) |
3203 | 1841 |
3525 | 1842 OV_UNOP_FN (op_transpose) |
1843 OV_UNOP_FN (op_hermitian) | |
3203 | 1844 |
1845 // No simple way to define these for prefix and suffix ops? | |
1846 // | |
1847 // incr | |
1848 // decr | |
1849 | |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1850 #define OV_BINOP_FN(name) \ |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1851 inline octave_value \ |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1852 name (const octave_value& a1, const octave_value& a2) \ |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1853 { \ |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1854 return octave::binary_op (octave_value::name, a1, a2); \ |
3203 | 1855 } |
1856 | |
22197
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1857 #define OV_BINOP_OP(name, op) \ |
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1858 inline octave_value \ |
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1859 operator op (const octave_value& a1, const octave_value& a2) \ |
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1860 { \ |
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1861 return name (a1, a2); \ |
3203 | 1862 } |
1863 | |
22197
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1864 #define OV_BINOP_FN_OP(name, op) \ |
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1865 OV_BINOP_FN (name) \ |
3203 | 1866 OV_BINOP_OP (name, op) |
1867 | |
3525 | 1868 OV_BINOP_FN_OP (op_add, +) |
1869 OV_BINOP_FN_OP (op_sub, -) | |
1870 OV_BINOP_FN_OP (op_mul, *) | |
1871 OV_BINOP_FN_OP (op_div, /) | |
3203 | 1872 |
3525 | 1873 OV_BINOP_FN (op_pow) |
1874 OV_BINOP_FN (op_ldiv) | |
3203 | 1875 |
3525 | 1876 OV_BINOP_FN_OP (op_lt, <) |
1877 OV_BINOP_FN_OP (op_le, <=) | |
1878 OV_BINOP_FN_OP (op_eq, ==) | |
1879 OV_BINOP_FN_OP (op_ge, >=) | |
1880 OV_BINOP_FN_OP (op_gt, >) | |
1881 OV_BINOP_FN_OP (op_ne, !=) | |
3203 | 1882 |
3525 | 1883 OV_BINOP_FN (op_el_mul) |
1884 OV_BINOP_FN (op_el_div) | |
1885 OV_BINOP_FN (op_el_pow) | |
1886 OV_BINOP_FN (op_el_ldiv) | |
1887 OV_BINOP_FN (op_el_and) | |
1888 OV_BINOP_FN (op_el_or) | |
3203 | 1889 |
3525 | 1890 OV_BINOP_FN (op_struct_ref) |
3203 | 1891 |
28631
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1892 #define OV_COMP_BINOP_FN(name) \ |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1893 inline octave_value \ |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1894 name (const octave_value& a1, const octave_value& a2) \ |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1895 { \ |
70cdf8de553d
move non-member octave_value operator functions to octave namespace
John W. Eaton <jwe@octave.org>
parents:
28588
diff
changeset
|
1896 return octave::binary_op (octave_value::name, a1, a2); \ |
7800
5861b95e9879
support for compound operators, implement trans_mul, mul_trans, herm_mul and mul_herm
Jaroslav Hajek <highegg@gmail.com>
parents:
7789
diff
changeset
|
1897 } |
5861b95e9879
support for compound operators, implement trans_mul, mul_trans, herm_mul and mul_herm
Jaroslav Hajek <highegg@gmail.com>
parents:
7789
diff
changeset
|
1898 |
5861b95e9879
support for compound operators, implement trans_mul, mul_trans, herm_mul and mul_herm
Jaroslav Hajek <highegg@gmail.com>
parents:
7789
diff
changeset
|
1899 OV_COMP_BINOP_FN (op_trans_mul) |
5861b95e9879
support for compound operators, implement trans_mul, mul_trans, herm_mul and mul_herm
Jaroslav Hajek <highegg@gmail.com>
parents:
7789
diff
changeset
|
1900 OV_COMP_BINOP_FN (op_mul_trans) |
5861b95e9879
support for compound operators, implement trans_mul, mul_trans, herm_mul and mul_herm
Jaroslav Hajek <highegg@gmail.com>
parents:
7789
diff
changeset
|
1901 OV_COMP_BINOP_FN (op_herm_mul) |
5861b95e9879
support for compound operators, implement trans_mul, mul_trans, herm_mul and mul_herm
Jaroslav Hajek <highegg@gmail.com>
parents:
7789
diff
changeset
|
1902 OV_COMP_BINOP_FN (op_mul_herm) |
5861b95e9879
support for compound operators, implement trans_mul, mul_trans, herm_mul and mul_herm
Jaroslav Hajek <highegg@gmail.com>
parents:
7789
diff
changeset
|
1903 |
24540
46440078d73b
don't use singleton for octave_value_typeinfo
John W. Eaton <jwe@octave.org>
parents:
24534
diff
changeset
|
1904 extern OCTINTERP_API void install_types (octave::type_info&); |
2376 | 1905 |
9657
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1906 // Templated value extractors. |
30723
08b08b7f05b2
Replace direct calls to C library assert() with Octave specialty functions in libinterp/ (bug #61753)
Arun Giridhar <arungiridhar@gmail.com> and Rik <rik@octave.org>
parents:
30565
diff
changeset
|
1907 // FIXME: would be more consistent to use panic_impossible(), rather than |
08b08b7f05b2
Replace direct calls to C library assert() with Octave specialty functions in libinterp/ (bug #61753)
Arun Giridhar <arungiridhar@gmail.com> and Rik <rik@octave.org>
parents:
30565
diff
changeset
|
1908 // assert(), but including "error.h" leads to compilation errors. |
21139
538b57866b90
consistently use "typename" intead of "class" in template declarations
John W. Eaton <jwe@octave.org>
parents:
21134
diff
changeset
|
1909 template <typename Value> |
9657
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1910 inline Value octave_value_extract (const octave_value&) |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
1911 { assert (false); } |
9657
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1912 |
22197
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1913 #define DEF_VALUE_EXTRACTOR(VALUE,MPREFIX) \ |
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1914 template <> \ |
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1915 inline VALUE octave_value_extract<VALUE> (const octave_value& v) \ |
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1916 { \ |
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1917 return v.MPREFIX ## _value (); \ |
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1918 } |
9657
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1919 |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1920 DEF_VALUE_EXTRACTOR (double, scalar) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1921 DEF_VALUE_EXTRACTOR (float, float_scalar) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1922 DEF_VALUE_EXTRACTOR (Complex, complex) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1923 DEF_VALUE_EXTRACTOR (FloatComplex, float_complex) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1924 DEF_VALUE_EXTRACTOR (bool, bool) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1925 |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1926 DEF_VALUE_EXTRACTOR (octave_int8, int8_scalar) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1927 DEF_VALUE_EXTRACTOR (octave_int16, int16_scalar) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1928 DEF_VALUE_EXTRACTOR (octave_int32, int32_scalar) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1929 DEF_VALUE_EXTRACTOR (octave_int64, int64_scalar) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1930 DEF_VALUE_EXTRACTOR (octave_uint8, uint8_scalar) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1931 DEF_VALUE_EXTRACTOR (octave_uint16, uint16_scalar) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1932 DEF_VALUE_EXTRACTOR (octave_uint32, uint32_scalar) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1933 DEF_VALUE_EXTRACTOR (octave_uint64, uint64_scalar) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1934 |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1935 DEF_VALUE_EXTRACTOR (NDArray, array) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1936 DEF_VALUE_EXTRACTOR (FloatNDArray, float_array) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1937 DEF_VALUE_EXTRACTOR (ComplexNDArray, complex_array) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1938 DEF_VALUE_EXTRACTOR (FloatComplexNDArray, float_complex_array) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1939 DEF_VALUE_EXTRACTOR (boolNDArray, bool_array) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1940 |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1941 DEF_VALUE_EXTRACTOR (charNDArray, char_array) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1942 DEF_VALUE_EXTRACTOR (int8NDArray, int8_array) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1943 DEF_VALUE_EXTRACTOR (int16NDArray, int16_array) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1944 DEF_VALUE_EXTRACTOR (int32NDArray, int32_array) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1945 DEF_VALUE_EXTRACTOR (int64NDArray, int64_array) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1946 DEF_VALUE_EXTRACTOR (uint8NDArray, uint8_array) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1947 DEF_VALUE_EXTRACTOR (uint16NDArray, uint16_array) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1948 DEF_VALUE_EXTRACTOR (uint32NDArray, uint32_array) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1949 DEF_VALUE_EXTRACTOR (uint64NDArray, uint64_array) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1950 |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1951 DEF_VALUE_EXTRACTOR (Matrix, matrix) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1952 DEF_VALUE_EXTRACTOR (FloatMatrix, float_matrix) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1953 DEF_VALUE_EXTRACTOR (ComplexMatrix, complex_matrix) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1954 DEF_VALUE_EXTRACTOR (FloatComplexMatrix, float_complex_matrix) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1955 DEF_VALUE_EXTRACTOR (boolMatrix, bool_matrix) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1956 |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1957 DEF_VALUE_EXTRACTOR (ColumnVector, column_vector) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1958 DEF_VALUE_EXTRACTOR (FloatColumnVector, float_column_vector) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1959 DEF_VALUE_EXTRACTOR (ComplexColumnVector, complex_column_vector) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1960 DEF_VALUE_EXTRACTOR (FloatComplexColumnVector, float_complex_column_vector) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1961 |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1962 DEF_VALUE_EXTRACTOR (RowVector, row_vector) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1963 DEF_VALUE_EXTRACTOR (FloatRowVector, float_row_vector) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1964 DEF_VALUE_EXTRACTOR (ComplexRowVector, complex_row_vector) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1965 DEF_VALUE_EXTRACTOR (FloatComplexRowVector, float_complex_row_vector) |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1966 |
9685 | 1967 DEF_VALUE_EXTRACTOR (DiagMatrix, diag_matrix) |
1968 DEF_VALUE_EXTRACTOR (FloatDiagMatrix, float_diag_matrix) | |
1969 DEF_VALUE_EXTRACTOR (ComplexDiagMatrix, complex_diag_matrix) | |
1970 DEF_VALUE_EXTRACTOR (FloatComplexDiagMatrix, float_complex_diag_matrix) | |
1971 DEF_VALUE_EXTRACTOR (PermMatrix, perm_matrix) | |
1972 | |
9789
97f5de91427b
support sparse templated extractors
Jaroslav Hajek <highegg@gmail.com>
parents:
9732
diff
changeset
|
1973 DEF_VALUE_EXTRACTOR (SparseMatrix, sparse_matrix) |
97f5de91427b
support sparse templated extractors
Jaroslav Hajek <highegg@gmail.com>
parents:
9732
diff
changeset
|
1974 DEF_VALUE_EXTRACTOR (SparseComplexMatrix, sparse_complex_matrix) |
97f5de91427b
support sparse templated extractors
Jaroslav Hajek <highegg@gmail.com>
parents:
9732
diff
changeset
|
1975 DEF_VALUE_EXTRACTOR (SparseBoolMatrix, sparse_bool_matrix) |
9657
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1976 #undef DEF_VALUE_EXTRACTOR |
3c1c3a38ec7b
implement templated octave_value extractor
Jaroslav Hajek <highegg@gmail.com>
parents:
9607
diff
changeset
|
1977 |
22197
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1978 #define DEF_DUMMY_VALUE_EXTRACTOR(VALUE,DEFVAL) \ |
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1979 template <> \ |
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1980 inline VALUE octave_value_extract<VALUE> (const octave_value&) \ |
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1981 { \ |
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1982 assert (false); \ |
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1983 return DEFVAL; \ |
e43d83253e28
refill multi-line macro definitions
John W. Eaton <jwe@octave.org>
parents:
22022
diff
changeset
|
1984 } |
13733
b1186adb567e
Add dummy template specializations with a return value.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
13294
diff
changeset
|
1985 |
b1186adb567e
Add dummy template specializations with a return value.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
13294
diff
changeset
|
1986 DEF_DUMMY_VALUE_EXTRACTOR (char, 0) |
b1186adb567e
Add dummy template specializations with a return value.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
13294
diff
changeset
|
1987 DEF_DUMMY_VALUE_EXTRACTOR (octave_value, octave_value ()) |
b1186adb567e
Add dummy template specializations with a return value.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
13294
diff
changeset
|
1988 #undef DEF_DUMMY_VALUE_EXTRACTOR |
b1186adb567e
Add dummy template specializations with a return value.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
13294
diff
changeset
|
1989 |
2376 | 1990 #endif |