pike.git/
src/
interpret_functions.h
Branch:
Tag:
Non-build tags
All tags
No tags
2003-02-15
2003-02-15 14:14:28 by Henrik Grubbström (Grubba) <grubba@grubba.org>
557146af681dcb70afd55fb8378489acd7f2a829 (
24
lines) (+
5
/-
19
)
[
Show
|
Annotate
]
Branch:
7.9
F_LOCAL_2_GLOBAL no longer uses GLOBAL_FROM_INT().
Rev: src/interpret_functions.h:1.136
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.
135
2003/02/15 14:
11
:
48
grubba Exp $
+
|| $Id: interpret_functions.h,v 1.
136
2003/02/15 14:
14
:
28
grubba Exp $
*/ /*
436:
}); OPCODE2(F_LOCAL_2_GLOBAL, "global = local", 0, {
-
INT32 tmp = arg1 + Pike
_
fp->context.identifier
_
level;
-
struct identifier *i;
-
-
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)
,
+
object
_
low
_
set_index
(Pike_fp->current_object
,
+
arg1
+
Pike_fp
->
context.identifier
_
level
,
Pike_fp->locals + arg2);
-
}else{
-
assign_to_short_svalue((union anything *)GLOBAL_FROM_INT(tmp),
-
i->run_time_type,
-
Pike_fp->locals + arg2);
-
}
+
}); OPCODE2(F_GLOBAL_2_LOCAL, "local = global", 0, {