Branch: Tag:

2001-02-20

2001-02-20 15:59:51 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Made push_type_int{,_backwards}() static.
Introduced push_int_type() and push_object_type{,_backwards}().

Rev: src/builtin_functions.c:1.344
Rev: src/encode.c:1.82
Rev: src/language.yacc:1.225
Rev: src/operators.c:1.125
Rev: src/pike_types.c:1.148
Rev: src/pike_types.h:1.49
Rev: src/svalue.c:1.94

5:   \*/   /**/   #include "global.h" - RCSID("$Id: pike_types.c,v 1.147 2001/02/19 23:50:02 grubba Exp $"); + RCSID("$Id: pike_types.c,v 1.148 2001/02/20 15:59:50 grubba Exp $");   #include <ctype.h>   #include "svalue.h"   #include "pike_types.h"
244:    reverse((char *)(Pike_compiler->type_stackp-a),a,1);   }    - void push_type_int(INT32 i) + static void push_type_int(INT32 i)   {    ptrdiff_t e;    for(e = 0; e < (ptrdiff_t)sizeof(i); e++)    push_type(DO_NOT_WARN((unsigned char)((i>>(e*8)) & 0xff)));   }    - void push_type_int_backwards(INT32 i) + static void push_type_int_backwards(INT32 i)   {    int e;    for(e=(int)sizeof(i);e-->0;)    push_type( (i>>(e*8)) & 0xff );   }    -  + void push_int_type(INT32 min, INT32 max) + { +  push_type_int(max); +  push_type_int(min); +  push_type(T_INT); + } +  + void push_object_type(int flag, INT32 id) + { +  push_type_int(id); +  push_type(flag); +  push_type(T_OBJECT); + } +  + void push_object_type_backwards(int flag, INT32 id) + { +  unsafe_push_type(T_OBJECT); +  unsafe_push_type(flag); +  push_type_int_backwards(id); + } +    INT32 extract_type_int(char *p)   {    int e;