mirror of
git://git.code.sf.net/p/zsh/code
synced 2024-12-28 16:15:02 +01:00
45583/0007: WC_FUNCDEF: Add a placeholder element.
This commit is contained in:
parent
fd1ef7d770
commit
a3c6c5513d
5 changed files with 13 additions and 4 deletions
|
@ -1,5 +1,8 @@
|
|||
2020-03-22 Daniel Shahaf <d.s@daniel.shahaf.name>
|
||||
|
||||
* 45583/0007: Config/version.mk, Src/exec.c, Src/parse.c,
|
||||
Src/text.c: WC_FUNCDEF: Add a placeholder element.
|
||||
|
||||
* 45583/0006: Src/parse.c: internal: Add some comments for
|
||||
orientation. No functional change.
|
||||
|
||||
|
|
|
@ -27,5 +27,5 @@
|
|||
# This must also serve as a shell script, so do not add spaces around the
|
||||
# `=' signs.
|
||||
|
||||
VERSION=5.8.0.1-dev
|
||||
VERSION_DATE='February 15, 2020'
|
||||
VERSION=5.8.0.2-dev
|
||||
VERSION_DATE='March 19, 2020'
|
||||
|
|
|
@ -5169,6 +5169,7 @@ execfuncdef(Estate state, Eprog redir_prog)
|
|||
sbeg = *state->pc++;
|
||||
nstrs = *state->pc++;
|
||||
npats = *state->pc++;
|
||||
(void) *state->pc++;
|
||||
|
||||
nprg = (end - state->pc);
|
||||
plen = nprg * sizeof(wordcode);
|
||||
|
@ -6138,7 +6139,7 @@ stripkshdef(Eprog prog, char *name)
|
|||
int sbeg = pc[2], nstrs = pc[3], nprg, npats = pc[4], plen, len, i;
|
||||
Patprog *pp;
|
||||
|
||||
pc += 5;
|
||||
pc += 6;
|
||||
|
||||
nprg = end - pc;
|
||||
plen = nprg * sizeof(wordcode);
|
||||
|
|
|
@ -173,6 +173,7 @@ struct heredocs *hdocs;
|
|||
* - followed by offset to first string
|
||||
* - followed by length of string table
|
||||
* - followed by number of patterns for body
|
||||
* - followed by a placeholder
|
||||
* - followed by codes for body
|
||||
* - followed by strings for body
|
||||
* - if number of names is 0, followed by:
|
||||
|
@ -1691,6 +1692,7 @@ par_funcdef(int *cmplx)
|
|||
ecadd(0); /* p + num + 2 */
|
||||
ecadd(0); /* p + num + 3 */
|
||||
ecadd(0); /* p + num + 4 */
|
||||
ecadd(0); /* p + num + 5 */
|
||||
|
||||
nocorrect = 0;
|
||||
incmdpos = 1;
|
||||
|
@ -1730,6 +1732,7 @@ par_funcdef(int *cmplx)
|
|||
ecbuf[p + num + 2] = so - oecssub;
|
||||
ecbuf[p + num + 3] = ecsoffs - so; /* "length of string table" */
|
||||
ecbuf[p + num + 4] = ecnpats; /* "number of patterns for body" */
|
||||
ecbuf[p + num + 5] = 0;
|
||||
ecbuf[p + 1] = num; /* "number of names" */
|
||||
|
||||
ecnpats = onp;
|
||||
|
@ -2053,6 +2056,7 @@ par_simple(int *cmplx, int nr)
|
|||
ecadd(0);
|
||||
ecadd(0);
|
||||
ecadd(0);
|
||||
ecadd(0);
|
||||
|
||||
ecnfunc++;
|
||||
ecssub = so = ecsoffs;
|
||||
|
@ -2108,6 +2112,7 @@ par_simple(int *cmplx, int nr)
|
|||
ecbuf[p + argc + 2] = so - oecssub;
|
||||
ecbuf[p + argc + 3] = ecsoffs - so;
|
||||
ecbuf[p + argc + 4] = ecnpats;
|
||||
ecbuf[p + argc + 5] = 0;
|
||||
|
||||
ecnpats = onp;
|
||||
ecssub = oecssub;
|
||||
|
|
|
@ -600,7 +600,7 @@ gettext2(Estate state)
|
|||
n->u._funcdef.end = end;
|
||||
n->u._funcdef.nargs = nargs;
|
||||
state->strs += *state->pc;
|
||||
state->pc += 3;
|
||||
state->pc += 4;
|
||||
}
|
||||
} else {
|
||||
state->strs = s->u._funcdef.strs;
|
||||
|
|
Loading…
Reference in a new issue