00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024 #include "Array-flags.h"
00025 #include "Range.h"
00026 #include "idx-vector.h"
00027 #include "lo-error.h"
00028
00029 #if 0
00030
00031 template <class T>
00032 ArrayN<T>
00033 ArrayN<T>::value (void)
00034 {
00035 ArrayN<T> retval;
00036
00037 int n_idx = index_count ();
00038
00039 if (n_idx > 1)
00040 {
00041 Array<idx_vector> ra_idx (n_idx);
00042
00043 idx_vector *tmp = get_idx ();
00044
00045 for (int i = 0; i < n_idx; i++)
00046 ra_idx(i) = tmp[i];
00047
00048 return index (ra_idx);
00049 }
00050 else if (n_idx == 1)
00051 {
00052 idx_vector *tmp = get_idx ();
00053
00054 idx_vector ra_idx = tmp[0];
00055
00056 return index (ra_idx);
00057 }
00058 else
00059 (*current_liboctave_error_handler)
00060 ("invalid number of indices for array expression");
00061
00062 clear_index ();
00063
00064 return retval;
00065 }
00066
00067 #endif
00068
00069
00070
00071
00072
00073