Branch: Tag:

1999-11-25

1999-11-25 00:56:27 by Fredrik Hübinette (Hubbe) <hubbe@hubbe.net>

stricter typechecking implemented

Rev: src/language.yacc:1.137
Rev: src/las.c:1.132
Rev: src/pike_types.c:1.74
Rev: src/svalue.h:1.40
Rev: src/testsuite.in:1.239

5:   \*/   /**/   #include "global.h" - RCSID("$Id: las.c,v 1.131 1999/11/24 21:41:44 hubbe Exp $"); + RCSID("$Id: las.c,v 1.132 1999/11/25 00:56:23 hubbe Exp $");      #include "language.h"   #include "interpret.h"
2021:    if(function_type_max++ > 999)    {    reset_type_stack(); +     push_type(T_MIXED); -  push_type(T_MIXED); /* is varargs */ +  push_type(T_VOID); +  push_type(T_OR); /* return type is void or mixed */ +  +  push_type(T_MIXED); +  push_type(T_VOID); +  push_type(T_OR); /* varargs */ +     push_type(T_MANY);    return;    }
2036:       case F_PUSH_ARRAY: /* We let this ruin type-checking for now.. */    reset_type_stack(); +     push_type(T_MIXED); -  push_type(T_MIXED); /* is varargs */ +  push_type(T_VOID); +  push_type(T_OR); /* return type is void or mixed */ +  +  push_type(T_MIXED); +  push_type(T_VOID); +  push_type(T_OR); /* varargs */ +     push_type(T_MANY);    return;   
2174:    char *name;    INT32 max_args,args;    -  push_type(T_MIXED); /* match any return type, even void */ +  push_type(T_MIXED); /* match any return type */ +  push_type(T_VOID); /* even void */ +  push_type(T_OR); +     push_type(T_VOID); /* not varargs */    push_type(T_MANY);    function_type_max=0;