Граф коммитов

1823 Коммитов

Автор SHA1 Сообщение Дата
ko1 534d057e58 * cont.c: Thread local storage should be fiber local.
* bootstraptest/test_knownbug.rb, test/ruby/test_fiber.rb:
  move a fixed test.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13555 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-28 19:04:45 +00:00
ko1 6698dd81e6 * benchmark/driver.rb: fix file selection algorithm.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13540 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-28 03:51:41 +00:00
nobu 4d1450fc96 * process.c (rb_waitpid): no needs to poll. [ruby-dev:31871]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13526 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-26 18:17:43 +00:00
nobu 52866db1fe * parse.y (parser_yyerror): limit error message length.
[ruby-dev:31848]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13514 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-25 20:12:24 +00:00
matz 72ea36112c * eval.c (rb_longjmp): source file information may be NULL.
[ruby-dev:31849]

* eval.c (ruby_finalize_0): clear trace_func before finalization.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13510 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-25 12:40:17 +00:00
matz af4310be97 * lib/weakref.rb (WeakRef): remove debug print. [ruby-dev:31799]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13507 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-24 13:15:34 +00:00
nobu bc5d305843 * eval_method.ci (remove_method): check for undefined method.
[ruby-dev:31816]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13491 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-22 21:16:21 +00:00
nobu 2f4951f01e * ext/stringio/stringio.c (strio_init): separate from strio_initialize
to share with strio_reopen properly.  [ruby-Bugs-13919]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13482 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-21 20:19:51 +00:00
matz f4d9d3d39b * hash.c (hash_equal): should call rb_eql when argument eql is set.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13474 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-20 17:03:41 +00:00
nobu bf6575ef62 * io.c (popen_exec), process.c (rb_spawn): stop other threads before
exec.  [ruby-core:08262]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13471 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-20 08:28:03 +00:00
kou 1b56bcce22 * lib/rss.rb, lib/rss/, test/rss/:
- 0.1.9 -> 0.2.0.
  - supported Slash module.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13446 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-15 04:41:28 +00:00
ko1 8b92f5df32 * insnhelper.ci (vm_expandarray): should be volatile value for GC.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13440 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-14 07:14:13 +00:00
nobu f41c0a54e2 * parse.y (rb_id2str): fixed typo.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13435 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-13 04:47:10 +00:00
nobu 9391daf954 * io.c (rb_io_s_sysopen): should not use alloca for unknowen size
input.  [ruby-dev:31775]

* parse.y (rb_id2str): ditto.

* marshal.c (w_float): use snprintf instead of sprintf.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13430 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-12 06:19:06 +00:00
matz 3ee33a6dbc * range.c (range_step): fixed integer overflow. [ruby-dev:31763]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13422 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-09 16:11:28 +00:00
usa eda22a3411 * 2007-09-08
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13404 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-07 16:48:10 +00:00
matz ae11bc70f1 * io.c (rb_io_getc): forgot to commit rb_enc_mbclen() fix.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13351 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-06 15:30:49 +00:00
nobu 629b1e4324 * string.c (rb_str_succ, rb_str_chop_bang, rb_str_chop): m17n support.
[ruby-dev:31734]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13347 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-06 03:42:12 +00:00
matz c349959778 * string.c (rb_str_splice): integer overflow for length.
[ruby-dev:31739]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13342 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-05 13:06:01 +00:00
suke 9ecd43fa98 * ext/win32ole/win32ole.c: add WIN32OLE_EVENT#unadvise.
* test/win32ole/test_win32ole_event.rb: ditto.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13341 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-04 11:48:53 +00:00
nobu 1acdd51cf9 * common.mk (vm.o): depends on st.h too.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13340 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-03 06:37:11 +00:00
nobu d4cbf95002 * st.c (st_numcmp, st_numhash): use st_data_t instead of long, because
the former may be larger than the latter.

* include/ruby/st.h (CHAR_BIT): get rid of magic number.

* include/ruby/st.h (struct st_table): num_entries never exceed
  num_bins.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13326 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-09-01 02:14:40 +00:00
nobu 7aaf7dac8d * parse.y (assignable_gen): ignore already erred names.
* parse.y (shadowing_lvar_gen): always make new block local variable
  when shadowing outer local variable.  [ruby-dev:31507]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13321 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-30 18:49:00 +00:00
matz 3d7f8c2320 * string.c (str_gsub): should not use mbclen2() which has broken API.
* re.c: remove rb_reg_mbclen2().

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13308 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-29 19:16:02 +00:00
matz 3783246a2e * include/ruby/defines.h (flush_register_windows): call "ta 0x03"
even on Linux/Sparc.  [ruby-dev:31674]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13298 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-29 02:15:03 +00:00
ko1 6244e502cc * thread.c: fix Mutex to be interruptable lock.
* thread_win32.ci, thread_win32.h, thread_pthread.ci, thread_pthread.h:
  prepare native_cond_*() which are based on pthread_cond_*() spec.
* prelude.rb: fix Mutex#synchronize method.
* vm_core.h, include/ruby/intern.h: change unblock function interface
  (to pass some user data).
* file.c, process.c: ditto.
* benchmark/bm_vm2_mutex.rb: add a benchmark for mutex.
* benchmark/bm_vm3_thread_mutex.rb: add a benchmark for mutex
  with contension.
* benchmark/run.rb: fix to remove ENV['RUBYLIB'] for matzruby.
* test/ruby/test_thread.rb: add a test.
* common.mk: fix benchmark options.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13290 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-27 16:48:14 +00:00
matz 98d6d636e3 * enumerator.c (enumerator_next): message changed.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13279 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-26 16:33:45 +00:00
matz 1ba65ebfe9 * include/ruby/encoding.h: remove unused rb_enc_ismbchar().
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13273 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-25 15:27:08 +00:00
ko1 b285d26a16 * compile.c (compile_massign_opt): fix to skip massign optimization
with global variables.
* bootstraptest/test_massign.rb: add some tests for above.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13246 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-24 15:19:00 +00:00
matz 99ab1fed49 * eval.c (rb_f_send_bang): abandon the name funcall for private
aware method call.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13243 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-24 08:15:37 +00:00
matz 3e68736791 * missing/strtod.c: removed. [ruby-dev:31588]
* LEGAL: updated.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13231 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-22 15:05:56 +00:00
ko1 c5e4cd0638 * cont.c: add Fiber#resume and Fiber.yield.
and Fiber::Core class to realize Coroutine.
* include/ruby/intern.h: declare rb_fiber_yield(), rb_fiber_resume(),
* enumerator.c: use above api.
* test/ruby/test_fiber.rb: fix and add tests for above changes.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13130 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-21 18:51:39 +00:00
ko1 ad56f8c611 * enumerator.c (next_i): fix to return with Fiber#yield at
the end of each block.  [ruby-dev:31470]
* enumerator.c (enumerator_next_p): call init_next if not
  initialized.  [ruby-dev:31514]
* test/ruby/test_enumerator.rb: add tests for Enumerator.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13120 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-20 18:58:32 +00:00
nobu f2f08335df * vm_core.h (struct rb_thread_struct): removed first_func_arg and
reuse first_args instead.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13116 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-20 14:17:16 +00:00
ko1 98e7aa679a * insnhelper.ci (vm_callee_setup_arg): fix to mark enough VM stack.
[ruby-dev:31492]



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13109 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-19 03:35:39 +00:00
nobu 69dd06ae68 * eval.c (frame_func_id): return proper method ID.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13082 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-17 16:12:03 +00:00
ko1 e7c3478261 * insns.def (throw): insert a RUBY_VM_CHECK_INTS(). [ruby-dev:31361]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13070 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-16 16:24:18 +00:00
ko1 3efcb087a3 * cont.c (rb_fiber_m_yield): added. use this function
for Fiber#yield instead of rb_fiber_yield.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12946 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-15 17:56:22 +00:00
matz c8c6ab229a * ext/stringio/stringio.c (strio_getc): should returns
one-character string.

* ext/stringio/stringio.c: remove unnecessary prototypes.

* ext/stringio/stringio.c (strio_getbyte): new method.

* ext/stringio/stringio.c (strio_readbyte): new method.

* ext/stringio/stringio.c (strio_ungetc): should take a string as
  an input.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12934 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-15 00:33:33 +00:00
ko1 9cdeae9dad * common.mk: change test order (test -> btest).
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12929 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-14 10:53:06 +00:00
ko1 99b51f6020 * template/yasmdata.rb.tmpl: fix type and name.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12921 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-12 19:02:30 +00:00
nobu 1a7564a0ed * thread.c (thread_start_func_2): not re-raise to main thread if it is
joining the current thread.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12916 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-10 15:01:14 +00:00
nobu d3a1980b96 * parse.y (internal_id_gen): internal ID must be bigger than
tLAST_TOKEN.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12912 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-09 19:47:11 +00:00
matz e2de7c70dc * enum.c (enum_cycle): typo fixed. a patch from Kazuhiro
NISHIYAMA <zn AT mbf.nifty.com>.  [ruby-dev:31362]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12908 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-08 17:03:33 +00:00
nobu 9644a2c02c * common.mk (btest-miniruby, test-sample): split the test target
so that -k option works.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12901 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-08 02:02:45 +00:00
matz b3e977a4c0 * enum.c (enum_cycle): new method to cycle enumerable forever.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12890 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-06 16:26:17 +00:00
nobu ee8f40b5a6 * common.mk (INSNS): not chdir to srcdir.
* lib/vm/instruction.rb (RubyVM::SourceCodeGenerator): --destdir
  option.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12875 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-06 04:00:09 +00:00
nobu 43009063c7 * io.c (pipe_open_v, pipe_open_s): separate array and string
cases.  [ruby-dev:31344]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12870 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-04 19:56:27 +00:00
nobu 899742b269 * lib/mkmf.rb: more verbose message. [ruby-Bugs-12766]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12866 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-02 21:17:37 +00:00
nobu 46e848a65a * sprintf.c (rb_f_sprintf): should not check positional number as
width.  [ruby-core:11838]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12861 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-02 04:46:41 +00:00