diff src/ov.cc @ 4478:7afd4bf05aa8

[project @ 2003-07-30 19:15:31 by jwe]
author jwe
date Wed, 30 Jul 2003 19:15:31 +0000
parents af308ca1a354
children e944fbe3fff2
line wrap: on
line diff
--- a/src/ov.cc	Wed Jul 30 17:26:32 2003 +0000
+++ b/src/ov.cc	Wed Jul 30 19:15:31 2003 +0000
@@ -99,12 +99,6 @@
 // If TRUE, print the name along with the value.
 bool Vprint_answer_id_name;
 
-// Should operations on empty matrices return empty matrices or an
-// error?  A positive value means yes.  A negative value means yes,
-// but print a warning message.  Zero means it should be considered an
-// error.
-int Vpropagate_empty_matrices;
-
 // How many levels of structure elements should we print?
 int Vstruct_levels_to_print;
 
@@ -413,6 +407,13 @@
   maybe_mutate ();
 }
 
+octave_value::octave_value (const ArrayN<double>& a)
+  : rep (new octave_double_nd_array (a))
+{
+  rep->count = 1;
+  maybe_mutate ();
+}
+
 octave_value::octave_value (const DiagMatrix& d)
   : rep (new octave_matrix (d))
 {
@@ -448,6 +449,15 @@
   maybe_mutate ();
 }
 
+#if 0
+octave_value::octave_value (const ArrayN<Complex>& a)
+  : rep (new octave_complex_nd_array (a))
+{
+  rep->count = 1;
+  maybe_mutate ();
+}
+#endif
+
 octave_value::octave_value (const ComplexDiagMatrix& d)
   : rep (new octave_complex_matrix (d))
 {
@@ -1796,14 +1806,6 @@
 }
 
 static int
-propagate_empty_matrices (void)
-{
-  Vpropagate_empty_matrices = check_preference ("propagate_empty_matrices");
-
-  return 0;
-}
-
-static int
 warn_resize_on_range_error (void)
 {
   Vwarn_resize_on_range_error
@@ -1859,14 +1861,6 @@
 values are printed.  The default value is 1.\n\
 @end defvr");
 
-  DEFVAR (propagate_empty_matrices, true, propagate_empty_matrices,
-    "-*- texinfo -*-\n\
-@defvr {Built-in Variable} propagate_empty_matrices\n\
-If the value of @code{propagate_empty_matrices} is nonzero,\n\
-functions like @code{inverse} and @code{svd} will return an empty matrix\n\
-if they are given one as an argument.  The default value is 1.\n\
-@end defvr");
-
   DEFVAR (silent_functions, false, silent_functions,
     "-*- texinfo -*-\n\
 @defvr {Built-in Variable} silent_functions\n\