ruby-changes:43891
From: nobu <ko1@a...>
Date: Fri, 19 Aug 2016 09:13:00 +0900 (JST)
Subject: [ruby-changes:43891] nobu:r55964 (trunk): vm.c: check TOPLEVEL_BINDING
nobu 2016-08-19 09:12:47 +0900 (Fri, 19 Aug 2016) New Revision: 55964 https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=55964 Log: vm.c: check TOPLEVEL_BINDING * vm.c (vm_set_main_stack): TOPLEVEL_BINDING must be built. http://www.viva64.com/en/b/0414/#ID0EQ1CI [ruby-core:76973] Modified files: trunk/ChangeLog trunk/vm.c Index: ChangeLog =================================================================== --- ChangeLog (revision 55963) +++ ChangeLog (revision 55964) @@ -1,3 +1,8 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1 +Fri Aug 19 09:12:45 2016 Nobuyoshi Nakada <nobu@r...> + + * vm.c (vm_set_main_stack): TOPLEVEL_BINDING must be built. + http://www.viva64.com/en/b/0414/#ID0EQ1CI [ruby-core:76973] + Fri Aug 19 01:00:53 2016 Yuichiro Kaneko <yui-knk@r...> * proc.c (mnew_missing): Remove an unused argument. Index: vm.c =================================================================== --- vm.c (revision 55963) +++ vm.c (revision 55964) @@ -459,11 +459,12 @@ vm_set_main_stack(rb_thread_t *th, const https://github.com/ruby/ruby/blob/trunk/vm.c#L459 rb_binding_t *bind; GetBindingPtr(toplevel_binding, bind); + RUBY_ASSERT_MESG(bind, "TOPLEVEL_BINDING is not built"); vm_set_eval_stack(th, iseq, 0, &bind->block); /* save binding */ - if (bind && iseq->body->local_table_size > 0) { + if (iseq->body->local_table_size > 0) { vm_bind_update_env(bind, vm_make_env_object(th, th->cfp)); } } -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/