summaryrefslogtreecommitdiffstats
path: root/eval.c
Commit message (Collapse)AuthorAgeFilesLines
* * parse.y (arg): too much NEW_LIST()matz2006-04-191-4/+4
| | | | | | | * eval.c (SETUP_ARGS0): remove unnecessary access to nd_alen. git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@10101 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (rb_eval): use ARGSCAT for NODE_OP_ASGN1.matz2006-04-191-16/+15
| | | | | | | | | | | | | | | | | [ruby-dev:28585] * parse.y (list_concat): revert last change. * parse.y (arg): use NODE_ARGSCAT for placeholder. * lib/getoptlong.rb (GetoptLong::get): RDoc update patch from mathew <meta at pobox.com>. [ruby-core:07738] * variable.c (rb_const_set): raise error when no target klass is supplied. [ruby-dev:28582] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@10100 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c: block_unique should be 1, not frame_unique.matz2006-04-171-2/+2
| | | | | | | [ruby-dev:28577] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@10094 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (backtrace): reports aliased method names in a generatedmatz2006-03-281-8/+10
| | | | | | | | | | | | | | | | | backtrace. a patch from "U.Nakamura" <usa at garbagecollect.jp>. [ruby-dev:28471] * eval.c (rb_call0): insecure calling should be checked for non NODE_SCOPE method invocations too. * eval.c (rb_alias): should preserve the current safe level as well as method definition. * eval.c (yield_under_i): pass self again for instance_eval(). [ruby-dev:28466] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@10063 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (method_missing): should support argument splat inmatz2006-03-231-3/+14
| | | | | | | super. [ruby-talk:185438] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@10047 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/rdoc/ri/ri_paths.rb (RI::Paths): adding paths from rubygemsmatz2006-03-031-0/+1
| | | | | | | | | | | directories. a patch from Eric Hodel <drbrain at segment7.net>. [ruby-core:07423] * eval.c (rb_thread_fd_writable): should not re-schedule output from KILLED thread (must be error printing). git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@10020 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (SETUP_ARGS0): fixed memory corruption. [ruby-dev:28360]ocean2006-02-231-1/+1
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9985 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/rational.rb (Integer::gcd): replaced by gcd4 inmatz2006-02-201-1/+1
| | | | | | | | | | [ruby-core:07390]. [ruby-core:07377] * eval.c: initial value for block_unique must be 1. [ruby-talk:180420] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9965 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (rb_thread_wait_for): sleep should always sleep formatz2006-02-171-1/+1
| | | | | | | specified amount of time. [ruby-talk:180067] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9944 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (backtrace): frame->orig_func may not be initialized.matz2006-02-151-7/+6
| | | | | | | [ruby-core:07367] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9942 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (rb_eval): NODE_OP_ASGN1 should allow splat in itsmatz2006-02-151-25/+26
| | | | | | | | | | | | | argument list. [ruby-core:07366] * parse.y (arg): avoid unnecessary extra argument. [ruby-core:07366] * eval.c (rb_eval): honor visibility on OP_ASGN1 and OP_ASGN2. [ruby-core:07366] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9941 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (yield_under_i): should not pass self as an argument tomatz2006-02-151-1/+1
| | | | | | | the block for instance_eval. [ruby-core:07364] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9937 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (rb_obj_instance_eval): should no singleton classes formatz2006-02-151-1/+1
| | | | | | | true, false, and nil. [ruby-dev:28186] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9936 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (DMETHOD_P): accessing wrong frame. [ruby-dev:28181]matz2006-02-141-1/+2
| | | | | | | * eval.c (proc_invoke): preserve FRAME_DMETH flag. git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9935 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (rb_call0): argument update propagation. [ruby-dev:28044]matz2006-02-131-93/+89
| | | | | | | * env.h: remove argc member from struct FRAME. git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9920 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (eval): should push class from binding if supplied.matz2006-02-131-0/+2
| | | | | | | [ruby-core:07347] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9917 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (eval): no need to push ruby_class. [ruby-dev:28176]matz2006-02-111-16/+18
| | | | | | | | | * eval.c (rb_f_autoload): check if ruby_cbase is nil (during instance_eval for objects cannot have singleton classes, e.g. fixnums and symbols). [ruby-dev:28178] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9912 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c: apply the FreeBSD getcontext/setcontext workaroundakr2006-02-041-1/+1
| | | | | | | only before FreeBSD 7-CURRENT. git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9886 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (eval): need not to protect $SAFE value.matz2006-02-021-1/+0
| | | | | | | | | | [ruby-core:07177] * struct.c (rb_struct_select): update RDoc description. [ruby-core:7254] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9873 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (POST_GETCONTEXT): define separately from PRE_GETCONTEXT onakr2006-01-221-39/+44
| | | | | | | IA64 to avoid reusing variable address. git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9852 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (ruby_setjmp): workaround for FreeBSD/i386akr2006-01-221-14/+25
| | | | | | | | getcontext/setcontext bug. [ruby-dev:28263] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9850 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (FUNCTION_CALL_MAY_RETURN_TWICE): use only for SPARC and IA64akr2006-01-201-2/+18
| | | | | | | before gcc 4.0.3. git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9847 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (FUNCTION_CALL_MAY_RETURN_TWICE): don't clobber %l7 of SPARCakr2006-01-181-1/+15
| | | | | | | | | | | if enable-shared. (ruby_setjmp): call FUNCTION_CALL_MAY_RETURN_TWICE after getcontext too. reported by Pav Lucistnik and Marius Strobl. http://lists.freebsd.org/pipermail/freebsd-sparc64/2006-January/003739.html git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9844 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (rb_thread_save_context): should not recycle scope object usednobu2005-12-311-0/+1
| | | | | | | in a thread. fixed: [ruby-dev:28177] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9781 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* avoid a GC problem with RUBY_ALWAYS_GC= ./ruby -e ''.akr2005-12-291-1/+4
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9764 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (rb_gc_mark_threads): leave unmarked threads which won't wakenobu2005-12-291-0/+36
| | | | | | | | | | up alone, and mark threads in the loading table. [ruby-dev:28154] * eval.c (rb_gc_abort_threads), gc.c (gc_sweep): kill unmarked threads. [ruby-dev:28172] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9760 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (rb_eval), gc.c (gc_mark_children), node.h (NEW_ALIAS,nobu2005-12-261-3/+4
| | | | | | | | | NEW_VALIAS), parse.y (fitem): allow dynamic symbols to NODE_UNDEF and NODE_ALIAS. backported from trunk. fixed: [ruby-dev:28105] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9738 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (ev_const_get): fixed a bug in constant reference duringmatz2005-12-261-11/+14
| | | | | | | | | | | | | instance_eval. [yarv-dev:707] * eval.c (ev_const_defined): ditto. * lib/yaml.rb (YAML::add_domain_type): typo fixed. a patch from Joel VanderWerf <vjoel at path.berkeley.edu>. [ruby-talk:165285] [ruby-core:6995] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9736 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (eval_under_i): evaluate source in caller's frame.nobu2005-12-201-2/+7
| | | | | | | | | | [ruby-dev:28076] * eval.c (rb_call_super): use original method name on exception. [ruby-dev:28078] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9725 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (bmcall): fix a GC problem by tail call onakr2005-12-161-1/+4
| | | | | | | IA64 with gcc 4.0.3 20051216 (prerelease). git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9704 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* precedes registering global VALUE variables before initializing it.akr2005-12-121-4/+4
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9677 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/digest/digest.c (rb_digest_base_s_digest): add volatile tomatz2005-12-121-3/+3
| | | | | | | | | | | protect temporary context object. [ruby-dev:27979] * ext/iconv/iconv.c (Init_iconv): rb_gc_register_address() should be called before actual variable initialization. [ruby-dev:27986] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9673 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (umethod_bind): adjust invoking class for module method.nobu2005-12-071-3/+13
| | | | | | | [ruby-dev:27964] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9658 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (call_trace_func): klass parameter should be amatz2005-12-071-1/+1
| | | | | | | class/module that defines calling method. [ruby-talk:169307] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9656 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (exec_under): avoid accessing ruby_frame->prev.matz2005-12-061-1/+1
| | | | | | | [ruby-dev:27948] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9646 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (rb_funcall2): allow to call protected methods.nobu2005-11-301-3/+3
| | | | | | | fixed: [ruby-dev:27890] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9640 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (rb_call_super): should call method_missing if super ismatz2005-11-011-5/+10
| | | | | | | | | | called from Kernel method. * eval.c (exec_under): frame during eval should preserve external information. git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9491 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * rubysig.h (CHECK_INTS): prevent signal handler to run duringmatz2005-10-191-7/+6
| | | | | | | | | | | | | | | | critical section. [ruby-core:04039] * eval.c (load_wait): need not to call rb_thread_schedule() explicitly. [ruby-core:04039] * eval.c (rb_thread_schedule): clear rb_thread_critical. [ruby-core:04039] * st.c (st_free_table): do not call free() but xfree(). [ruby-core:06205] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9417 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c, gc.c, time.c: made internal symbols static. [ruby-dev:27435]nobu2005-10-181-1/+1
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9413 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (rb_obj_respond_to): check if obj responds to the givennobu2005-10-111-9/+20
| | | | | | | | | method with the given visibility. [ruby-dev:27408] * eval.c (rb_respond_to): conform to Object#respond_to?. [ruby-dev:27411] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9376 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (Init_Binding): add Binding#dup method. [yarv-dev:666]nobu2005-10-081-0/+1
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9362 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * evalc. (rb_f_send): underscores need to be escaped.nobu2005-09-281-1/+1
| | | | | | | fixed by Doug Kearns. [ruby-core:06053] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9335 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (ev_const_get), variable.c (rb_const_get_0): retry only whennobu2005-09-281-1/+1
| | | | | | | | | | autoload succeeded. * variable.c (rb_autoload_load): now return true if autoload succeeded. fixed: [ruby-dev:27331] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9333 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (set_trace_func): add rb_secure(4) to prevent addingmatz2005-09-261-0/+1
| | | | | | | | | | tracing function. * lib/delegate.rb: document update from James Edward Gray II <james@grayproductions.net>. [ruby-core:05942] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9317 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (unknown_node): show more information. [ruby-dev:26196]akr2005-09-241-1/+9
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9300 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (thread_mark): mark th->last_status. [ruby-dev:27179]akr2005-09-201-0/+1
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9249 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (BEGIN_CALLARGS): pop halfly pushed status.nobu2005-09-131-1/+3
| | | | | | | fixed: [ruby-dev:26881] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9150 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (rb_call0): prohibit calling tainted method (>2) whenmatz2005-09-091-5/+17
| | | | | | | | | | $SAFE == 0. * sprintf.c (rb_f_sprintf): warn "too many argument" on verbose mode (-v/-w); backported from 1.9. [ruby-dev:26963] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9108 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (rb_thread_switch): convert all exceptions tonobu2005-09-071-0/+4
| | | | | | | | | | SystemExit. fixed: [ruby-core:05724] * eval.c (rb_thread_terminated): show backtrace before propagate exceptions to main thread. git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9092 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (rb_call0): wrong condition for $SAFE restoration.matz2005-09-011-1/+1
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9064 b2dd03c8-39d4-4d8f-98ff-823fe69b080e