Ruby 1.9.2p136(2010-12-25revision30365)

- Main Page
- Modules
- Data Structures
- Files

- File List
- Globals

Data Structures | Defines | Functions | Variables

# prelude.c File Reference

`#include "ruby/ruby.h"`
`#include "vm_core.h"`
Include dependency graph for prelude.c:

Go to the source code of this file.

## Data Structures
struct | prelude_env
## Defines
#define | PRELUDE_COUNT 5
## Functions
static VALUE | prelude_prefix_path (VALUE self)
VALUE | rb_iseq_compile_with_option (VALUE src, VALUE file, VALUE filepath, VALUE line, VALUE opt)
static void | prelude_eval (VALUE code, VALUE name, VALUE line)
static VALUE | prelude_require (VALUE self, VALUE nth)
void | Init_prelude (void)
## Variables
static const char | prelude_name0 [] = "<internal:prelude>"
static const char | prelude_code0 [] = "end\n"
static const char | prelude_name1 [] = "<internal:enc/prelude>"
static const char | prelude_code1 [] = "end\n"
static const char | prelude_name2 [] = "<internal:gem_prelude>"
static const char | prelude_code2 [] = "\n"
static const char | prelude_name3 [] = "<internal:lib/rubygems/defaults>"
static const char | prelude_code3 [] = "\n"
static const char | prelude_name4 [] = "<internal:lib/rubygems/custom_require>"
static const char | prelude_code4 [] = "\n"

## Define Documentation

#define PRELUDE_COUNT 5

Definition at line 447 of file prelude.c.

Referenced by prelude_require().

## Function Documentation

void Init_prelude | ( | void |  | ) |

Definition at line 498 of file prelude.c.

References Data_Wrap_Struct, INT2FIX, name, prelude_env::prefix_path, prelude_code0, prelude_code1, prelude_code2, prelude_code3, prelude_code4, prelude_eval(), prelude_name0, prelude_name1, prelude_name2, prelude_prefix_path(), prelude_require(), rb_cData, rb_cObject, rb_const_remove(), rb_const_set(), rb_define_singleton_method(), rb_gc_force_recycle(), rb_intern, and rb_usascii_str_new().

static void prelude_eval | ( | VALUE | code,
|  | VALUE | name,
|  | VALUE | line
| ) |  | `[static]`

Definition at line 466 of file prelude.c.

References Qnil, Qtrue, rb_iseq_compile_with_option(), and rb_iseq_eval().

Referenced by Init_prelude(), and prelude_require().

static VALUE prelude_prefix_path | ( | VALUE | self | ) | `[static]`

Definition at line 457 of file prelude.c.

References DATA_PTR, and prelude_env::prefix_path.

Referenced by Init_prelude().

static VALUE prelude_require | ( | VALUE | self,
|  | VALUE | nth
| ) |  | `[static]`

Definition at line 472 of file prelude.c.

References DATA_PTR, FIX2INT, INT2FIX, name, prelude_code3, prelude_code4, PRELUDE_COUNT, prelude_eval(), prelude_name3, prelude_name4, Qfalse, Qtrue, and rb_usascii_str_new().

Referenced by Init_prelude().

VALUE rb_iseq_compile_with_option | ( | VALUE | src,
|  | VALUE | file,
|  | VALUE | filepath,
|  | VALUE | line,
|  | VALUE | opt
| ) |  |

Definition at line 549 of file iseq.c.

References rb_thread_struct::base_block, GET_THREAD, rb_block_struct::iseq, ISEQ_TYPE_EVAL, ISEQ_TYPE_TOP, make_compile_option(), rb_iseq_struct::name, NUM2INT, parse_string(), Qfalse, rb_iseq_new_with_opt(), rb_str_new2(), rb_iseq_struct::self, StringValue, and StringValueCStr.

## Variable Documentation

const char prelude_code0[] = "end\n"`[static]`

Definition at line 11 of file prelude.c.

Referenced by Init_prelude().

const char prelude_code1[] = "end\n"`[static]`

Definition at line 46 of file prelude.c.

Referenced by Init_prelude().

const char prelude_code2[] = "\n"`[static]`

Definition at line 56 of file prelude.c.

Referenced by Init_prelude().

const char prelude_code3[] = "\n"`[static]`

Definition at line 295 of file prelude.c.

Referenced by Init_prelude(), and prelude_require().

const char prelude_code4[] = "\n"`[static]`

Definition at line 400 of file prelude.c.

Referenced by Init_prelude(), and prelude_require().

const char prelude_name0[] = "<internal:prelude>"`[static]`

Definition at line 10 of file prelude.c.

Referenced by Init_prelude().

const char prelude_name1[] = "<internal:enc/prelude>"`[static]`

Definition at line 45 of file prelude.c.

Referenced by Init_prelude().

const char prelude_name2[] = "<internal:gem_prelude>"`[static]`

Definition at line 55 of file prelude.c.

Referenced by Init_prelude().

const char prelude_name3[] = "<internal:lib/rubygems/defaults>"`[static]`

Definition at line 294 of file prelude.c.

Referenced by prelude_require().

const char prelude_name4[] = "<internal:lib/rubygems/custom_require>"`[static]`

Definition at line 399 of file prelude.c.

Referenced by prelude_require().