pike.git
/
src
/
operators.c
version
»
Context lines:
10
20
40
80
file
none
3
pike.git/src/operators.c:1:
/*\ ||| This file a part of Pike, and is copyright by Fredrik Hubinette ||| Pike is distributed as GPL (General Public License) ||| See the files COPYING and DISCLAIMER for more information. \*/ /**/ #include "global.h" #include <math.h>
-
RCSID("$Id: operators.c,v 1.
90
2001/02/
04
02
:
08
:
13
hubbe Exp $");
+
RCSID("$Id: operators.c,v 1.
91
2001/02/
25
18
:
06
:
55
hubbe Exp $");
#include "interpret.h" #include "svalue.h" #include "multiset.h" #include "mapping.h" #include "array.h" #include "stralloc.h" #include "opcodes.h" #include "operators.h" #include "language.h" #include "pike_memory.h"
pike.git/src/operators.c:427:
static int generate_sum(node *n) { switch(count_args(CDR(n))) { case 1: do_docode(CDR(n),0); return 1; case 2:
-
do_docode(CDR(n),DO_NOT_COPY);
+
do_docode(CDR(n),DO_NOT_COPY
_TOPLEVEL
);
emit2(F_ADD); return 1; default: return 0; } } static node *optimize_eq(node *n) {
pike.git/src/operators.c:764:
static int generate_minus(node *n) { switch(count_args(CDR(n))) { case 1: do_docode(CDR(n),DO_NOT_COPY); emit2(F_NEGATE); return 1; case 2:
-
do_docode(CDR(n),DO_NOT_COPY);
+
do_docode(CDR(n),DO_NOT_COPY
_TOPLEVEL
);
emit2(F_SUBTRACT); return 1; } return 0; } void o_and(void) { if(sp[-1].type != sp[-2].type) {
pike.git/src/operators.c:1427:
/* FIXME: Not appropriate if too many args. */ SIMPLE_TOO_FEW_ARGS_ERROR("`<<", 2); } o_lsh(); } static int generate_lsh(node *n) { if(count_args(CDR(n))==2) {
-
do_docode(CDR(n),DO_NOT_COPY);
+
do_docode(CDR(n),DO_NOT_COPY
_TOPLEVEL
);
emit2(F_LSH); return 1; } return 0; } void o_rsh(void) { if(sp[-2].type != T_INT || sp[-1].type != T_INT) {
pike.git/src/operators.c:1900:
assign_svalue(s,sp-1); pop_n_elems(sp-s-1); } } } static int generate_divide(node *n) { if(count_args(CDR(n))==2) {
-
do_docode(CDR(n),DO_NOT_COPY);
+
do_docode(CDR(n),DO_NOT_COPY
_TOPLEVEL
);
emit2(F_DIVIDE); return 1; } return 0; } void o_mod(void) { if(sp[-2].type != sp[-1].type && !float_promote()) {
pike.git/src/operators.c:2023:
/* FIXME: Not appropriate when too many args. */ SIMPLE_TOO_FEW_ARGS_ERROR("`%", 2); } o_mod(); } static int generate_mod(node *n) { if(count_args(CDR(n))==2) {
-
do_docode(CDR(n),DO_NOT_COPY);
+
do_docode(CDR(n),DO_NOT_COPY
_TOPLEVEL
);
emit2(F_MOD); return 1; } return 0; } void o_not(void) { switch(sp[-1].type) {