pike.git / src / builtin_functions.c

version» Context lines:

pike.git/src/builtin_functions.c:8691:    (multiset)(map(indices(arr),fun,@extra)); */    push_svalue(Pike_sp-args); /* take indices from arr */    free_svalue(Pike_sp-args-1); /* move it to top of stack */    mark_free_svalue (Pike_sp-args-1);    f_indices(1); /* call f_indices */    Pike_sp--;    dmalloc_touch_svalue(Pike_sp);    Pike_sp[-args]=Pike_sp[0]; /* move it back */    f_map(args);    -  /* FIXME: Handle multisets with values like mappings. */ -  push_multiset (mkmultiset_2 (Pike_sp[-1].u.array, NULL, NULL)); +  push_multiset (mkmultiset (Pike_sp[-1].u.array));    free_array (Pike_sp[-2].u.array);    dmalloc_touch_svalue(Pike_sp-1);    Pike_sp[-2] = Pike_sp[-1];    Pike_sp--;    return;       case T_STRING:    /* multiset ret =    (string)(map((array)arr,fun,@extra)); */    push_svalue(Pike_sp-args); /* take indices from arr */
pike.git/src/builtin_functions.c:9130:    case T_MULTISET:    push_svalue(Pike_sp-args); /* take indices from arr */    free_svalue(Pike_sp-args-1); /* move it to top of stack */    mark_free_svalue (Pike_sp-args-1);    f_indices(1); /* call f_indices */    Pike_sp--;    dmalloc_touch_svalue(Pike_sp);    Pike_sp[-args]=Pike_sp[0]; /* move it back */    f_filter(args);    -  /* FIXME: Handle multisets with values like mappings. */ -  push_multiset (mkmultiset_2 (Pike_sp[-1].u.array, NULL, NULL)); +  push_multiset (mkmultiset (Pike_sp[-1].u.array));    free_array (Pike_sp[-2].u.array);    Pike_sp[-2] = Pike_sp[-1];    dmalloc_touch_svalue(Pike_sp-1);    Pike_sp--;    return;       case T_STRING:    push_svalue(Pike_sp-args); /* take indices from arr */    free_svalue(Pike_sp-args-1); /* move it to top of stack */    mark_free_svalue (Pike_sp-args-1);