Branch: Tag:

2015-02-08

2015-02-08 19:27:58 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Runtime: o_append_mapping() now cares about setters.

Fixes testsuite test of F_APPEND_MAPPING.

1876:   {    struct svalue *lval = Pike_sp - args;    struct svalue *val = lval + 2; +  int lvalue_type; +    #ifdef PIKE_DEBUG    if (args < 3) {    Pike_fatal("Too few arguments to o_append_mapping(): %d\n", args);
1883:   #endif    args -= 3;    /* Note: val should always be a zero here! */ -  lvalue_to_svalue_no_free(val, lval); +  lvalue_type = lvalue_to_svalue_no_free(val, lval);    -  if (TYPEOF(*val) == T_MAPPING) -  { +  if ((TYPEOF(*val) == T_MAPPING) && (lvalue_type != PIKE_T_GET_SET)) {    struct mapping *m = val->u.mapping;    if( m->refs == 2 )    {