Ruby
2.4.2p198(2017-09-14revision59899)
main.c
Go to the documentation of this file.
1
/**********************************************************************
2
3
main.c -
4
5
$Author: ko1 $
6
created at: Fri Aug 19 13:19:58 JST 1994
7
8
Copyright (C) 1993-2007 Yukihiro Matsumoto
9
10
**********************************************************************/
11
12
#undef RUBY_EXPORT
13
#include "
ruby.h
"
14
#include "
vm_debug.h
"
15
#ifdef HAVE_LOCALE_H
16
#include <locale.h>
17
#endif
18
#ifdef RUBY_DEBUG_ENV
19
#include <stdlib.h>
20
#endif
21
22
int
23
main
(
int
argc
,
char
**
argv
)
24
{
25
#ifdef RUBY_DEBUG_ENV
26
ruby_set_debug_option
(
getenv
(
"RUBY_DEBUG"
));
27
#endif
28
#ifdef HAVE_LOCALE_H
29
setlocale(LC_CTYPE,
""
);
30
#endif
31
32
ruby_sysinit
(&argc, &argv);
33
{
34
RUBY_INIT_STACK
;
35
ruby_init
();
36
return
ruby_run_node
(
ruby_options
(argc, argv));
37
}
38
}
ruby.h
vm_debug.h
ruby_init
void ruby_init(void)
Definition:
eval.c:74
argc
int argc
Definition:
ruby.c:183
ruby_run_node
#define ruby_run_node
Definition:
goruby.c:3
ruby_set_debug_option
void ruby_set_debug_option(const char *str)
Definition:
debug.c:131
ruby_options
#define ruby_options
Definition:
goruby.c:2
getenv
#define getenv(name)
Definition:
win32.c:71
RUBY_INIT_STACK
#define RUBY_INIT_STACK
A convenience macro to call ruby_init_stack().
Definition:
ruby.h:2457
ruby_sysinit
void ruby_sysinit(int *argc, char ***argv)
Initializes the process for ruby(1).
Definition:
ruby.c:2256
main
int main(int argc, char **argv)
Definition:
main.c:23
argv
char ** argv
Definition:
ruby.c:184
Generated by
1.8.13