2000-05-01 09:42:38 +00:00
|
|
|
/**********************************************************************
|
1998-01-16 12:13:05 +00:00
|
|
|
|
|
|
|
env.h -
|
|
|
|
|
|
|
|
$Author$
|
|
|
|
$Date$
|
|
|
|
created at: Mon Jul 11 11:53:03 JST 1994
|
|
|
|
|
2003-01-16 07:34:03 +00:00
|
|
|
Copyright (C) 1993-2003 Yukihiro Matsumoto
|
2000-05-01 09:42:38 +00:00
|
|
|
|
|
|
|
**********************************************************************/
|
|
|
|
|
1998-01-16 12:13:05 +00:00
|
|
|
#ifndef ENV_H
|
|
|
|
#define ENV_H
|
|
|
|
|
2004-01-11 14:54:44 +00:00
|
|
|
RUBY_EXTERN struct FRAME {
|
1999-01-20 04:59:39 +00:00
|
|
|
VALUE self;
|
1998-01-16 12:13:05 +00:00
|
|
|
int argc;
|
|
|
|
VALUE *argv;
|
|
|
|
ID last_func;
|
2002-08-12 07:39:12 +00:00
|
|
|
ID orig_func;
|
1998-01-16 12:19:22 +00:00
|
|
|
VALUE last_class;
|
1998-01-16 12:13:05 +00:00
|
|
|
struct FRAME *prev;
|
1999-08-13 05:45:20 +00:00
|
|
|
struct FRAME *tmp;
|
2002-08-15 11:49:40 +00:00
|
|
|
struct RNode *node;
|
1998-01-16 12:13:05 +00:00
|
|
|
int iter;
|
2000-08-15 09:04:32 +00:00
|
|
|
int flags;
|
2003-10-20 08:33:49 +00:00
|
|
|
unsigned long uniq;
|
1999-01-20 04:59:39 +00:00
|
|
|
} *ruby_frame;
|
1998-01-16 12:13:05 +00:00
|
|
|
|
1999-01-20 04:59:39 +00:00
|
|
|
void rb_gc_mark_frame _((struct FRAME *));
|
1998-01-16 12:19:22 +00:00
|
|
|
|
2000-08-15 09:04:32 +00:00
|
|
|
#define FRAME_ALLOCA 0
|
|
|
|
#define FRAME_MALLOC 1
|
|
|
|
|
2004-01-11 14:54:44 +00:00
|
|
|
RUBY_EXTERN struct SCOPE {
|
1998-01-16 12:13:05 +00:00
|
|
|
struct RBasic super;
|
|
|
|
ID *local_tbl;
|
|
|
|
VALUE *local_vars;
|
2001-02-02 11:38:20 +00:00
|
|
|
int flags;
|
1999-01-20 04:59:39 +00:00
|
|
|
} *ruby_scope;
|
1998-01-16 12:13:05 +00:00
|
|
|
|
|
|
|
#define SCOPE_ALLOCA 0
|
|
|
|
#define SCOPE_MALLOC 1
|
|
|
|
#define SCOPE_NOSTACK 2
|
2000-08-31 08:08:39 +00:00
|
|
|
#define SCOPE_DONT_RECYCLE 4
|
1998-01-16 12:13:05 +00:00
|
|
|
|
2004-01-11 14:54:44 +00:00
|
|
|
RUBY_EXTERN int ruby_in_eval;
|
1998-01-16 12:13:05 +00:00
|
|
|
|
2004-01-11 14:54:44 +00:00
|
|
|
RUBY_EXTERN VALUE ruby_class;
|
1998-01-16 12:13:05 +00:00
|
|
|
|
|
|
|
struct RVarmap {
|
|
|
|
struct RBasic super;
|
|
|
|
ID id;
|
|
|
|
VALUE val;
|
|
|
|
struct RVarmap *next;
|
|
|
|
};
|
2004-01-11 14:54:44 +00:00
|
|
|
RUBY_EXTERN struct RVarmap *ruby_dyna_vars;
|
1998-01-16 12:13:05 +00:00
|
|
|
|
|
|
|
#endif /* ENV_H */
|