Lines Matching +full:y +full:- +full:rp
23 * awk -- functions
36 #include "y.tab.h"
52 * Usage: y = exp(x)
53 * y = exp()
82 * Usage: y = log(x)
83 * y = log()
97 * Usage: y = sqrt(x)
98 * y = sqrt()
112 * Usage: y = sin(x)
124 * Usage: y = cos(x)
135 * Arctangent of y/x.
136 * Usage: z = atan2(y, x)
141 double y, x; in f_atan2() local
145 y = (double)exprreal(getlist(&np)); in f_atan2()
147 return (realnode(atan2(y, x))); in f_atan2()
151 * Set the seed for the random number generator function -- rand.
188 return (realnode((REAL)ldexp(result, expon-15))); in f_rand()
224 register REGEXP rp; in dosub() local
230 rp = getregexp(getlist(&np)); in dosub()
239 switch (REGWDOSUBA(rp, sub, text, &buf, 256, &glob)) { in dosub()
265 register REGEXP rp; in f_match() local
272 rp = getregexp(getlist(&np)); in f_match()
273 if (REGWEXEC(rp, text, 10, match, 0) == REG_OK) { in f_match()
274 pos = match[0].rm_sp-text+1; in f_match()
275 length = match[0].rm_ep - match[0].rm_sp; in f_match()
278 length = -1; in f_match()
280 constant->n_int = length; in f_match()
324 l1--; in f_index()
372 if (snp->n_type == INDEX && snp->n_left == tnp) in f_split()
378 switch (tnp->n_type) { in f_split()
387 if (isstring(tnp->n_flags) && tnp->n_string==_null) in f_split()
402 if (sep->n_type == PARM) in f_split()
403 sep = sep->n_next; in f_split()
404 if (sep->n_type == RE) { in f_split()
406 resep = sep->n_regexp; in f_split()
427 if (otnp->n_type == PARM) in f_split()
428 otnp = otnp->n_next; in f_split()
435 constant->n_int = ++fcount; in f_split()
436 (void)assign(tnp, stringnode(cp,FALLOC|FSENSE,(size_t)(ep-cp))); in f_split()
488 if ((start = (int)exprint(getlist(&np))-1) < 0) in f_substr()
502 n -= start; in f_substr()
526 if (op->f_fp!=FNULL && strcmp(name, op->f_name)==0) { in f_close()
592 if (array->n_type == PARM) in f_asort()
593 array = array->n_next; in f_asort()
594 if (array->n_type != ARRAY) in f_asort()
599 || funcnp->n_type != UFUNC) in f_asort()
606 for (tnp = array->n_alink; tnp != NNULL; tnp = tnp->n_alink) in f_asort()
628 asortfunc->n_left = funcnp; in f_asort()
629 asortfunc->n_right->n_left = array; in f_asort()
630 asarraylen = wcslen(array->n_name)+1; in f_asort()
636 for (tnp = array->n_alink; tnp != NNULL; tnp = tnp->n_alink) in f_asort()
640 * Re-order array to this list in f_asort()
642 qsort((wchar_t *)alist, nel-1, sizeof (NODE *), asortcmp); in f_asort()
646 tnp = tnp->n_alink = *npp; in f_asort()
663 while (np!=NNULL && np->n_type==COMMA) { in nargs()
664 np = np->n_right; in nargs()
687 cp[-1] = towupper(c); in docasetr()
690 cp[-1] = towlower(c); in docasetr()
692 return (stringnode((STRING)str, FNOALLOC, (size_t)(cp-str-1))); in docasetr()
701 asnp1->n_strlen = in asortcmp()
702 wcslen(asnp1->n_string = (*(NODE **)npp1)->n_name+asarraylen); in asortcmp()
703 asnp2->n_strlen = in asortcmp()
704 wcslen(asnp2->n_string = (*(NODE **)npp2)->n_name+asarraylen); in asortcmp()
737 if ((type = ep->type) > (uint)PLOSS) in matherr()
742 ((void) flushesbx(), ep->name), ep->arg1, (INT)exprint(varNR)); in matherr()