Branch: Tag:

2021-01-03

2021-01-03 14:21:41 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Compiler [Typechecker]: Fixed more issues with subtraction of functions.

Function type subtraction now seems to be compatible with pike_types_le().

4727:    */    if (avoidable && bvoidable) {    /* FIXME: What if tmp only differs due to remapping? */ +  if (tmp && tmp->type == T_VOID) { +  free_type(tmp); +  tmp = NULL; +  }    if (tmp != a->car) {    if (!tmp) { -  push_remap_markers(a->cdr, NULL, remap, remap_flags); +  tmp = low_type_binop(op, a->cdr, b->cdr, remap, +  PT_FLAG_CMP_VOIDABLE, +  0, remap_flags); +  if (tmp) { +  push_finished_type(tmp);    push_type(T_VOID);    push_type(T_MANY); -  +  free_type(tmp);    return pop_unfinished_type();    } -  +  pop_stack_mark(); +  return NULL; +  }    /* FIXME: What about tmp->type == T_VOID? */    push_type(T_MIXED);    push_finished_type(tmp);