summaryrefslogtreecommitdiff
path: root/eval.c
AgeCommit message (Collapse)Author
2008-07-07merge revision(s) 17832:shyouhei
* eval.c (rb_longjmp): duplicate the thrown exception to set backtrace if it was frozen. clear all raised flags. * eval.c (stack_check): leave clearing flag to rb_longjmp. * eval.c (rb_thread_set_raised, rb_thread_reset_raised): use generic flags. * eval.c (Init_Proc), gc.c (Init_GC): freeze preallocated special exceptions. * gc.c (rb_memerror): use thread raised flag instead of static flag, and raise nomem_error without backtrace if failed to make backtrace. [ruby-dev:34724] * gc.c (ruby_xmalloc): increase malloc_increase only if malloc succeeds. failed malloc size can be huge. it may increase malloc_limit too big which cause less GC and memory full. (ruby_xrealloc): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@17928 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-29merge revision(s) 17636:shyouhei
* eval.c (rb_obj_respond_to): use RTEST to test the result of respond_to? method. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@17715 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-29merge revision(s) 17581:shyouhei
* eval.c (rb_call0): wrong condition to check insecure method. a patch from Keita Yamaguchi <keita.yamaguchi at gmail.com>. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@17694 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-29merge revision(s) 17547:shyouhei
* eval.c (PUSH_FRAME, PUSH_CLASS): Add volatile to avoid a possible optimization bug on OS X/PPC. This at least makes build with gcc -O1 and `make test' pass. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@17678 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-29merge revision(s) 16507:shyouhei
* eval.c (search_method, remove_method, error_print, rb_alias) (rb_eval, rb_rescue2, search_required, Init_eval, rb_thread_create), gc.c (rb_source_filename, Init_stack), io.c (rb_io_getline), parse.y (rb_id2name, rb_parser_free): suppress warnings. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@17646 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-28merge revision(s) 16536:shyouhei
* eval.c (rb_copy_node_scope), node.h: Rename from copy_node_scope and export. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@17628 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-16merge revision(s) 16514:shyouhei
* proc.c (proc_dup): should copy safe_level from src proc properly. a patch from Keita Yamaguchi <keita.yamaguchi at gmail.com> git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@17359 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-15merge revision(s) 16564:shyouhei
* marshal.c (reentrant_check): check reentrance via callcc. [ruby-dev:34802] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@17319 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-15merge revision(s) 16385:shyouhei
* eval.c (is_defined): add NODE_OP_ASGN_{OR,AND}. "defined?(a||=1)" should not operate assignment. [ruby-dev:34645] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@17294 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-09merge revision(s) 15054:shyouhei
* eval.c (eval): check if backtrace is empty. [ruby-core:15040] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@17049 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-07merge revision(s) 15005:shyouhei
* eval.c (rb_define_alloc_func, rb_undef_alloc_func): should define/undef on a signleton class. [ruby-core:09959] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@17014 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-07merge revision(s) 14086:shyouhei
* eval.c (error_print): put newline unless multiple line message ends with a newline. [ruby-dev:32429] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@16970 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-07merge revision(s) 13957:shyouhei
* eval.c (rb_alias): do not call hook functions until initialization finishes. [ruby-talk:279538] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@16951 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-04merge revision(s) 13586:shyouhei
* eval.c (remove_method): should not remove undef place holder. [ruby-dev:31817] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@16816 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-23 * eval.c, intern.h, ext/thread/thread.c: should not free queue whileshyouhei
any live threads are waiting. [ruby-dev:30653] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@13495 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-07* eval.c (rb_thread_start_0): should unset time_thread_alive_p.shyouhei
[ruby-talk:257219], [ruby-core:11542], [ruby-dev:31253] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@13401 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-07 * eval.c (mnew): should preserve noex as safe_level.shyouhei
* eval.c (rb_call0): tighten security check condition.. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@13387 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-22 * eval.c (get_backtrace): check the result more.shyouhei
[ruby-dev:31261] [ruby-bugs-12398] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@13190 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-22 * eval.c (ruby_cleanup): return EXIT_FAILURE if any exceptions occuredshyouhei
in at_exit blocks. [ruby-core:11263] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@13148 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-21 * eval.c (rb_kill_thread): renamed in order to get rid of conflictshyouhei
with a BeOS system function. [ruby-core:10830] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@13138 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-06-08* eval.c (rb_thread_cancel_timer): fix undefined functionshyouhei
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@12493 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-06-08* eval.c (rb_eval_cmd): just return if no exceptions.shyouhei
[ruby-dev:30820] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@12485 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-06-08 * eval.c (rb_eval_cmd): just return if no exceptions.shyouhei
[ruby-dev:30820] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@12483 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-06-08* eval.c (rb_eval_cmd): just return if no exceptions.shyouhei
[ruby-dev:30820] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@12482 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-06-07* eval.c, intern.h, ext/thread/thread.c: should not free queueshyouhei
while any live threads are waiting. [ruby-dev:30653] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@12469 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-06-07* eval.c (method_inspect): show proper class name.shyouhei
[ruby-talk:248647], Thanks Calamitas. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@12459 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-05-26* eval.c (mnew): call of super via a method object should work again.shyouhei
[ruby-talk:248647], Thanks Calamitas. * test/ruby/test_method.rb (TestMethod::test_method_super): test for above fix. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@12391 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-05-22* process.c (proc_exec_v): terminate timer thread in advance.shyouhei
[ruby-dev:30581], Thanks H. Holon. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@12343 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-05-22merge -c 12267shyouhei
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@12330 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-05-22merge -c 12187shyouhei
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@12319 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-05-22merge -c 12127shyouhei
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@12310 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-05-22merge -c 12126shyouhei
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@12309 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-05-22merge -c 12123shyouhei
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@12308 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-03-11* eval.c (error_handle): no message when exiting by signal.knu
* eval.c (ruby_cleanup): re-send signal. [ruby-dev:30516] * eval.c (rb_thread_interrupt): instantiate SignalException. * eval.c (rb_thread_signal_raise): now takes signal number instead of signal name. * intern.h (rb_thread_signal_raise, ruby_default_signal): prototypes. * signal.c (esignal_init): takes a signal number and an optional signal name. * signal.c (interrupt_init): pass SIGINT always. * signal.c (ruby_default_signal): invoke system default signal handler. * signal.c (rb_signal_exec, trap): handle SIGTERM. [ruby-dev:30505] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@12027 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-03-03* eval.c (stack_check): Unset inline to fix build with GCC 3.4.6;knu
submitted by: NISHIMATSU Takeshi <t_nissie AT yahoo.co.jp> in [ruby-list:43218]. cf. http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24556 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@11972 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-03-03* eval.c (rb_provided): return true only for features loaded fromknu
.rb files, and not search actual library type. [ruby-dev:30414] * eval.c (rb_feature_p): check loading_tbl if the given ext is empty. [ruby-dev:30452] * eval.c (rb_feature_p): fix possible buffer overrun. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@11966 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-03-03* env.h (SCOPE_CLONE): Introduce a new scope flag to prevent aknu
local_tbl region from getting freed many times; submitted by Chikanaga Tomoyuki <chikanag AT nippon-control-system.co.jp> in [ruby-dev:30460]. * eval.c (proc_invoke): Ditto. * gc.c (obj_free): Ditto. * parse.y (top_local_setup_gen): Ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@11965 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-02-19* configure.in, defines.h, eval.c (rb_feature_p, rb_provided,knu
load_wait, search_required, rb_require_safe), ext/extmk.rb: Fix a bug where a statically linked extension cannot be autoloaded. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_6@11781 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-01-31* eval.c (rb_iterate): need to PUSH_ITER in proper order.matz
[ruby-core:10125] * test/ruby/test_iterator.rb (TestIterator::test_block_given_within_iterator): add new test. [ruby-core:10125] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@11606 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-01-27* parse.y (dyna_var_lookup): should not alter dvar->val not tomatz
destroy living value. [ruby-core:10076] * parse.y (dyna_init): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@11582 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-12-09* eval.c (ruby_cleanup): keep the exception till after END blocks.nobu
[ruby-core:09675] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@11373 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-11-24* eval.c (rb_mod_define_method): set implicit visibility only whenmatz
it's called for the target class (ruby_cbase). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@11304 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-11-08* eval.c (BEGIN_CALLARGS): ruby_block may be NULL even whenmatz
ITER_PRE. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@11298 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-10-31* eval.c (rb_call0): fixed bug of zsuper with both of opt and rest.usa
fixed: [ruby-list:42928] * test/ruby/test_super.rb: add tests to check above bug. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@11252 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-10-04* eval.c (rb_call): check protected visibility based on real self,matz
not ruby_frame->self. [ruby-talk:217822] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@11080 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-09-23* eval.c (rb_thread_save_context, rb_thread_restore_context):why
sandbox hook to save and restore sandbox state. * eval.c (thread_no_ensure): added THREAD_NO_ENSURE thread flag. * eval.c (rb_thread_kill_bang): Thread#kill! uses the above flag to circumvent ensure, in order to prevent endless loops. [ruby-core:08768] * eval.c (rb_thread_kill): fix Thread#kill docs, which returns the thread object in all cases. * node.h: expose the rb_jmpbuf_t and rb_thread_t structs, along with the thread flags. used by the sandbox extension. * ruby.h: extern rb_eThreadError, so sandbox can swap it. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@11000 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-09-10* eval.c (rb_require_safe): prevent extension from loading twice.nobu
fixed: [ruby-dev:29523] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10903 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-09-10* eval.c (stack_extend): fixed prototype.nobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10902 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-09-01* common.mk, configure.in, defines.h, eval.c, gc.c, main.c,akr
numeric.c, ruby.h, ia64.s: backport IA64 HP-UX support. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10827 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-08-31* eval.c (ruby_init): rename top_cref to ruby_top_cref and export,why
along with ruby_cref, for use by the sandbox. [ruby-core:08762] * node.h: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10803 b2dd03c8-39d4-4d8f-98ff-823fe69b080e