Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- extern "C" {
- void ruby_sysinit(int *, char ***);
- void ruby_init(void);
- void ruby_set_argv(int, char **);
- void rb_vm_init_compiler(void);
- void *rb_vm_top_self(void);
- void rb_vm_print_current_exception(void);
- void rb_exit(int);
- void *(void *, void *);
- void *(void *, void *);
- }
- int main(int argc, char **argv)
- {
- ruby_sysinit(&argc, &argv);
- if (argc > 0) {
- argc--;
- argv++;
- }
- ruby_init();
- ruby_set_argv(argc, argv);
- rb_vm_init_compiler();
- try {
- void *self = rb_vm_top_self();
- (self, 0);
- (self, 0);
- }
- catch (...) {
- rb_vm_print_current_exception();
- rb_exit(1);
- }
- rb_exit(0);
- }
Add Comment
Please, Sign In to add comment