pike.git/
src/
interpret_functions.h
Branch:
Tag:
Non-build tags
All tags
No tags
2003-02-15
2003-02-15 14:09:44 by Henrik Grubbström (Grubba) <grubba@grubba.org>
eaf117dd7aa34020129fe0c0f853d2aba7601edd (
22
lines) (+
5
/-
17
)
[
Show
|
Annotate
]
Branch:
7.9
F_ASSIGN_GLOBAL no longer uses GLOBAL_FROM_INT().
Rev: src/interpret_functions.h:1.134
2:
|| This file is part of Pike. For copyright information see COPYRIGHT. || Pike is distributed under GPL, LGPL and MPL. See the file COPYING || for more information.
-
|| $Id: interpret_functions.h,v 1.
133
2003/
01
/
30
14:
14
:
56
grubba Exp $
+
|| $Id: interpret_functions.h,v 1.
134
2003/
02
/
15
14:
09
:
44
grubba Exp $
*/ /*
921:
}); OPCODE1(F_ASSIGN_GLOBAL, "assign global", 0, {
-
struct identifier *i;
-
INT32 tmp=arg1 + Pike_fp->context.identifier_level;
-
if(!Pike_fp->current_
object
->prog)
-
Pike
_
error("Cannot access global variables in destructed object.\n");
-
-
i=ID
_
FROM
_
INT
(Pike_fp->current_object
->prog
,
tmp);
-
if(!IDENTIFIER_IS_VARIABLE(i->identifier_flags))
-
Pike_error("Cannot
assign
functions
or
constants.\n");
-
if(i->run_time_type
==
PIKE_T_MIXED)
-
{
-
assign_svalue((struct
svalue
*)GLOBAL_FROM_INT(tmp),
Pike_sp-1);
-
}else{
-
assign
_
to_short_svalue((union anything *)GLOBAL_FROM_INT(tmp),
-
i
->
run
_
time_type
,
+
object_
low
_
set
_
index
(Pike_fp->current_object,
+
arg1
+
Pike
_
fp
->
context.identifier
_
level
,
Pike_sp-1);
-
}
+
}); OPCODE1(F_ASSIGN_GLOBAL_AND_POP, "assign global and pop", 0, {