about summary refs log tree commit diff
path: root/Src/subst.c
diff options
context:
space:
mode:
authorBart Schaefer <barts@users.sourceforge.net>2002-05-06 14:46:11 +0000
committerBart Schaefer <barts@users.sourceforge.net>2002-05-06 14:46:11 +0000
commitcefd2de2e181eb4844ccec575322e410e75a1afd (patch)
treed722f6dd4022e9f9d9414d1f2093d0c6ec9e6368 /Src/subst.c
parentb7aa69cb7db6dfa7d80bcbd1792dc9b312104fca (diff)
downloadzsh-cefd2de2e181eb4844ccec575322e410e75a1afd.tar.gz
zsh-cefd2de2e181eb4844ccec575322e410e75a1afd.tar.xz
zsh-cefd2de2e181eb4844ccec575322e410e75a1afd.zip
Split tokenize() into shtokenize() and zshtokenize()
to improve SH_GLOB handling, particularly in completion
Diffstat (limited to 'Src/subst.c')
-rw-r--r--Src/subst.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/Src/subst.c b/Src/subst.c
index 7a0a8b16b..5396cdf6c 100644
--- a/Src/subst.c
+++ b/Src/subst.c
@@ -197,7 +197,7 @@ stringsubst(LinkList list, LinkNode node, int ssub, int asssub)
 		continue;
 	    }
 	    if (!qt && ssub && isset(GLOBSUBST))
-		tokenize(s);
+		shtokenize(s);
 	    l1 = str2 - str3;
 	    l2 = strlen(s);
 	    if (nonempty(pl)) {
@@ -450,14 +450,14 @@ strcatsub(char **d, char *pb, char *pe, char *src, int l, char *s, int glbsub,
     if (!pl && (!s || !*s)) {
 	*d = dest = (copied ? src : dupstring(src));
 	if (glbsub)
-	    tokenize(dest);
+	    shtokenize(dest);
     } else {
 	*d = dest = hcalloc(pl + l + (s ? strlen(s) : 0) + 1);
 	strncpy(dest, pb, pl);
 	dest += pl;
 	strcpy(dest, src);
 	if (glbsub)
-	    tokenize(dest);
+	    shtokenize(dest);
 	dest += l;
 	if (s)
 	    strcpy(dest, s);
@@ -1595,7 +1595,7 @@ paramsubst(LinkList l, LinkNode n, char **str, int qt, int ssub)
 		if (!quoteerr) {
 		    errflag = oef;
 		    if (haserr)
-			tokenize(s);
+			shtokenize(s);
 		} else if (haserr || errflag) {
 		    zerr("parse error in ${...%c...} substitution",
 			 NULL, s[-1]);
@@ -2063,7 +2063,7 @@ paramsubst(LinkList l, LinkNode n, char **str, int qt, int ssub)
 		else {
 		    y = dupstring(x);
 		    if (globsubst)
-			tokenize(y);
+			shtokenize(y);
 		}
 		insertlinknode(l, n, (void *) y), incnode(n);
 	    }