diff scripts/strings/index.m @ 3759:110bc441a954

[project @ 2000-12-16 01:25:12 by jwe]
author jwe
date Sat, 16 Dec 2000 01:25:13 +0000
parents f8dde1807dee
children 8389e78e67d4
line wrap: on
line diff
--- a/scripts/strings/index.m
+++ b/scripts/strings/index.m
@@ -48,6 +48,10 @@
     [nr_s, l_s] = size (s);
     [nr_t, l_t] = size (t);
 
+    if (nr_s == 0 || nr_t == 0)
+      return;
+    endif
+
     if (nr_s != 1 || nr_t != 1)
       error ("index: arguments cannot be string arrays");
     endif