diff scripts/general/shift.m @ 4460:cef48c4b902d

[project @ 2003-07-11 18:37:48 by jwe]
author jwe
date Fri, 11 Jul 2003 18:37:48 +0000
parents 3192d1c40195
children a0997c4d1d54
line wrap: on
line diff
--- a/scripts/general/shift.m
+++ b/scripts/general/shift.m
@@ -49,11 +49,9 @@
     error ("shift: b must be an integer");
   endif
 
-  elo = empty_list_elements_ok;
-
+  save_warn_empty_list_elements = warn_empty_list_elements;
   unwind_protect
-
-    empty_list_elements_ok = 1;
+    warn_empty_list_elements = 0;
 
     if (b >= 0)
       b = rem (b, nr);
@@ -68,9 +66,7 @@
     endif
 
   unwind_protect_cleanup
-
-    empty_list_elements_ok = elo;
-
+    warn_empty_list_elements = save_warn_empty_list_elements;
   end_unwind_protect
 
   if (nc == 0)