Diff of /src/structcat.cc [18c397] .. [824d47] Maximize Restore

  Switch to side-by-side view

--- a/src/structcat.cc
+++ b/src/structcat.cc
@@ -27,9 +27,9 @@
 
 static Octave_map
 structcat_op_fcn (const Octave_map& m1, const Octave_map& m2,
-		      const dim_vector& dv,
-		      const Array<octave_idx_type>& ra_idx,
-		      const octave_value& fillv)
+                      const dim_vector& dv,
+                      const Array<octave_idx_type>& ra_idx,
+                      const octave_value& fillv)
 {
   Octave_map retval (dv);
 
@@ -44,9 +44,9 @@
       Octave_map::const_iterator pb = m2.seek (m1.key(pa));
 
       if (pb == m2.end ())
-	c.insert (c2, ra_idx);
+        c.insert (c2, ra_idx);
       else
-	c.insert (m2.contents(pb), ra_idx);
+        c.insert (m2.contents(pb), ra_idx);
 
       retval.assign (m1.key(pa), c);
     }
@@ -56,19 +56,19 @@
       Octave_map::const_iterator pb = m1.seek (m2.key(pa));
 
       if (pb == m1.end ())
-	{
-	  Cell c (dv, fillv);
+        {
+          Cell c (dv, fillv);
 
-	  retval.assign (m2.key(pa),
-			 c.insert (m2.contents(pa), ra_idx));
-	}
+          retval.assign (m2.key(pa),
+                         c.insert (m2.contents(pa), ra_idx));
+        }
     }
 
   return retval;
 }
 
 
-DEFUN_DLD (structcat, args, , 
+DEFUN_DLD (structcat, args, ,
   "-*- texinfo -*-\n\
 @deftypefn {Loadable Function} {} structcat (@var{dim}, @var{struct1}, @dots{}, @var{structn})\n\
 @deftypefnx {Loadable Function} {} structcat (@var{dim}, @var{default}, @var{struct1}, @dots{}, @var{structn})\n\
@@ -90,27 +90,27 @@
       octave_idx_type dim = args(0).int_value () - 1;
 
       if (error_state || dim < 0)
-	{
-	  error ("%s: first argument must be a positive integer",
-		 fname.c_str ());
-	  return octave_value ();
-	}
+        {
+          error ("%s: first argument must be a positive integer",
+                 fname.c_str ());
+          return octave_value ();
+        }
 
       octave_idx_type m1_id;
       octave_value fillv;
 
       if (n_args > 1 && args(1).is_scalar_type ())
-	{
-	  m1_id = 2;
+        {
+          m1_id = 2;
 
-	  fillv = args(1);
-	}
+          fillv = args(1);
+        }
       else
-	{
-	  m1_id = 1;
+        {
+          m1_id = 1;
 
-	  fillv = Matrix ();
-	}
+          fillv = Matrix ();
+        }
 
       dim_vector dv;
 
@@ -121,31 +121,31 @@
       Array<octave_idx_type> ra_idx (dim_vector (idx_len, 1), 0);
 
       for (octave_idx_type i = m1_id; i < n_args; i++)
-	{
-	  if (! args(i).is_map ())
-	    {
-	      error ("%s: some argument not a structure", fname.c_str ());
+        {
+          if (! args(i).is_map ())
+            {
+              error ("%s: some argument not a structure", fname.c_str ());
 
-	      return octave_value ();
-	    }
+              return octave_value ();
+            }
 
-	  dim_vector dvi = args(i).dims (), old_dv = dv;
+          dim_vector dvi = args(i).dims (), old_dv = dv;
 
-	  if (! dv.concat (dvi, dim))
-	    {
-	      error ("%s: dimension mismatch", fname.c_str ());
+          if (! dv.concat (dvi, dim))
+            {
+              error ("%s: dimension mismatch", fname.c_str ());
 
-	      return octave_value ();
-	    }
+              return octave_value ();
+            }
 
-	  if (! dvi.all_zero ())
-	    {
-	      retval = structcat_op_fcn (retval, args(i).map_value (),
-					 dv, ra_idx, fillv);
+          if (! dvi.all_zero ())
+            {
+              retval = structcat_op_fcn (retval, args(i).map_value (),
+                                         dv, ra_idx, fillv);
 
-	      ra_idx(dim) += (dim < dvi.length () ? dvi(dim) : 1);
-	    }
-	}  
+              ra_idx(dim) += (dim < dvi.length () ? dvi(dim) : 1);
+            }
+        }
     }
   return octave_value (retval);
 }