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

29124 Коммитов

Автор SHA1 Сообщение Дата
shugo a29c648d9c * lib/rbconfig/obsolete.rb (respond_to_missing?): use send because
RbConfig.respond_to_missing? is now private.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38769 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-10 17:13:09 +00:00
ko1 5849920066 * vm_core.h (VM_DEBUG_BP_CHECK): set 0 as default.
This flag specifies checking BP consistency on each frame popping.
  Now, we don't have any trouble on it, so I remove it.
  If you feel any bugs about VM execution, then set it to 1.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38768 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-10 13:03:39 +00:00
nagachika da6ddf240e * ChangeLog: fix a typo for r38761.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38767 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-10 12:29:48 +00:00
takano32 8cada3837f * cont.c: define FIBER_USE_NATIVE as 0 in ia64.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38766 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-10 12:05:40 +00:00
takano32 bd0be3c4fd Thu Jan 10 19:39:05 2013 TAKANO `takano32' Mitsuhiro <tak@no32.tk>
* thread.c: fix RB_GC_SAVE_MACHINE_REGISTER_STACK define for ia64.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38765 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-10 10:45:05 +00:00
nobu 1a920c7f9b Makefile.in: continue if Makefile unchanged
* Makefile.in, win32/Makefile.sub ($(MKFILES)): continue if Makefile
  unchanged.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38764 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-10 08:45:42 +00:00
nobu b7b183f682 win32/rm.bat: fix infinite loop
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38763 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-10 08:44:19 +00:00
eregon 8307cb90a0 * numeric.c (do_coerce): fix comment and adjust indent
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38762 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-10 08:12:58 +00:00
shugo 4707fdea01 * vm_insnhelper.c (vm_search_super_method): raise a TypeError
instead of a NotImplementError if self is not an instance of the
  current class.  [ruby-dev:39772] [Bug #2402]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38761 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-10 07:51:35 +00:00
nobu a5ddc2e196 extconf.rb: have_header
* ext/tk/extconf.rb (find_tcltk_header): use have_header instead of
  try_cpp, which is incredibly slow with VC.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38760 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-10 07:47:20 +00:00
shugo 42eadff3a1 * numeric.c (do_coerce): remove an unused variable.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38759 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-10 06:57:17 +00:00
kazu 72f9805109 fix a typo
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38758 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-10 06:49:25 +00:00
shugo 2cdd17b458 * tool/gen_dummy_probes.rb: remove comments in probes.d to fix the
compilation error introduced by r38755.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38757 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-10 06:39:55 +00:00
mrkn 9aa75d08ce * numeric.c (do_coerce): speed optimization by using rb_check_funcall
instead of rb_rescue + rb_funcall.
  This fix is based on the patch by Benoit Daloze.
  [Bug #7645] [ruby-core:51213]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38756 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-10 06:30:23 +00:00
tenderlove 9ef6eefbd3 * probes.d: updating probes to be more symmetrical, adding
documentation.

* load.c: ditto

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38755 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-10 02:16:00 +00:00
tenderlove b104e2524d * ext/psych/lib/psych/scalar_scanner.rb: strip trailing dots from
floats so that Float() will not raise an exception.

* test/psych/test_numeric.rb: test to ensure "1." can be loaded

* test/psych/test_string.rb: make sure "1." can round trip

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38754 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-09 19:26:45 +00:00
tenderlove ac8b1869c0 * ext/psych/lib/psych/visitors/yaml_tree.rb: ascii only binary strings
will be dumped as unicode.  Thanks Paul Kunysch!

* test/psych/test_string.rb: appropriate test

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38753 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-09 19:26:36 +00:00
svn 113c81219d * 2013-01-10
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38752 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-09 18:38:45 +00:00
ko1 a5e2f3221a * compile.c (compile_array_): modify wrong optimization.
A script "[print(1)]; print(2)" should output "12".
  However, the compiler had eliminted "[print(1)]" expression
  because it is void expression (unused array).
  Of course, side-effect should be remained.
  This issue is reported by Masaya Tarui.
* bootstraptest/test_literal.rb: add a test.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38751 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-09 18:38:41 +00:00
glass 62efc6f305 * load.c (load_lock): if thread shield is destroyed and there is no
waiting thread, insert new thread shield into load_table.
  [Bug #7530] [ruby-core:50645]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38750 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-09 13:14:09 +00:00
glass 94b4e7c783 * load.c (load_lock): revert r38744. it should acquire new thread
shield.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38749 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-09 13:14:05 +00:00
nobu 4e323c0a9d vm.c: initialize root_svar
* vm.c (th_init, ruby_thread_init): initialize root_svar with Qnil,
  since lep_svar_place() expects uninitialized svar to be nil, not 0.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38748 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-09 06:40:30 +00:00
nobu f608b1b8dc test_flip.rb: flip-flop shared by threads
* test/ruby/test_flip.rb (TestFlip#test_shared_thread): flip-flop
  should be separated per threads

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38747 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-09 05:32:33 +00:00
naruse 193e1fc810 Add RUBYOPT=>nil to avoid false negative
add RUBYOPT=nil to suppress circular require warnings to avoid false negative
with stderr assertion.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38746 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-09 04:56:34 +00:00
glass 1ff3e23fe8 * test/ruby/test_require.rb: improve test for r38744.
fix to use Tempfile instead of temporary file in current directory.
  the patch is from nobu (Nobuyoshi Nakada).

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38745 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-09 04:26:15 +00:00
glass bc0577c6c8 * load.c (load_lock): fix not to delete thread shield twice.
it may break the shield locked by another thread.
  [Bug #7530] [ruby-core:50645]

* test/ruby/test_require.rb: a test for above.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38744 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-09 00:59:30 +00:00
nobu 4ddf057b9a compile.c: adjust indent
* compile.c (iseq_compile_each): adjust indent.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38743 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-08 18:47:05 +00:00
svn cbd1f2571a * 2013-01-09
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38742 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-08 17:13:33 +00:00
nobu 8ad7143327 ruby.h: align
* include/ruby/ruby.h (RBasic): to be aligned on a VALUE size
  boundary.  [Bug #7647]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38741 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-08 17:13:26 +00:00
nobu a00b29a67f insns.def: adjust indent
* insns.def (getlocal, defined): adjust indent.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38740 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-08 05:57:42 +00:00
nobu 69b716111f vm_core.h: flip_cnt in rb_iseq_t
* vm_core.h (rb_iseq_t): move flip_cnt from struct iseq_compile_data,
  because it has same life span as enclosing iseq.  [Bug #7671]
  [ruby-core:51296]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38739 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-08 05:41:44 +00:00
mrkn bdb18e5ffa Fix wrong English in ChangeLog
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38738 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-08 03:40:21 +00:00
nobu dbdaf98cb8 * README (install): note about distclean-ext.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38737 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-08 02:18:46 +00:00
svn 91c6d576b6 * 2013-01-08
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38736 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-07 22:26:55 +00:00
kazu 8253cb26da fix a typo
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38735 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-07 22:26:00 +00:00
mrkn 1be6a498ba * ext/bigdecimal/bigdecimal.c (rmpd_power_by_big_decimal):
add RB_GC_GUARD to prevent the immediate object is GCed too early.
  This patch was made by Yusuke Endoh.  [Bug #7044] [ruby-core:47632]

* test/bigdecimal/test_bigdecimal.rb: add a reproduction test for
  the issue [Bug #7044]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38734 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-07 14:42:52 +00:00
shugo 19768b6cac * vm_method.c (Init_eval_method): main.public and main.private
should be private.

* proc.c (Init_Proc): main.define_method should be private.

* test/ruby/test_module.rb: related test.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38732 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-07 12:42:48 +00:00
shugo 4722c20661 * eval.c (Init_eval): main.include should be private.
[ruby-core:51293] [Bug #7670]

* test/ruby/test_module.rb (test_top_include_is_private): a new test
  for the above change.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38731 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-07 11:55:17 +00:00
shugo 04fd9aceab * NEWS: remove description about `require "refinement"'.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38730 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-07 11:30:43 +00:00
shugo 9cadf0c039 * eval.c (Init_eval): enable Refinements by default.
[ruby-core:51286] [Bug #7667]

* eval.c (rb_mod_refine, top_using): show a warning when
  Module#refine or main.using is called at the first time.

* ext/refinement/*: removed the extension library "refinement".

* test/ruby/test_refinement.rb: fix for the above changes.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38729 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-07 11:22:31 +00:00
ko1 06f2a86f1a * include/ruby/ruby.h (RUBY_EVENT_SPECIFIED_LINE): make it special.
This flag is not contained by RUBY_EVENT_TRACEPOINT_ALL.
  This event is experimental one. It is possible to remove/rename
  flag name after 2.0.1.
* vm_trace.c (get_event_id): return :line if SPECIFIED_LINE was
  occurred. `:specified_line' never been returned.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38728 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-07 08:38:25 +00:00
nobu 80ad3e2a43 test_syntax.rb: assert_not_label
* test/ruby/test_syntax.rb (TestSyntax#assert_not_label): need to eval
  in the current binding.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38727 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-07 07:50:27 +00:00
nobu e489dc1ff4 parse.y: bare kwrest_mark
* parse.y (f_kwrest): allow bare kwrest_mark as valid syntax.  its
  semantics is still undefined.  [Bug #7662] [ruby-core:51269]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38725 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-07 06:42:13 +00:00
nobu 38da1a5398 parse.y: duplicated kwrest name
* parse.y (f_kwrest): reject duplicated kwrest argument name.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38724 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-07 06:32:01 +00:00
nobu 86c0eae56e envutil.rb: assert_syntax_error
* test/ruby/envutil.rb (Test::Unit::Assertions#assert_syntax_error):
  new assertion for syntax error and error message.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38723 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-07 06:29:48 +00:00
nobu 5551307dd3 envutil.rb: optional fname
* test/ruby/envutil.rb (Test::Unit::Assertions#assert_valid_syntax):
  make fname optional for inline source.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38722 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-07 06:29:44 +00:00
ko1 b8e6fd6ffe * vm_trace.c (rb_threadptr_exec_event_hooks_orig): pop tag before
JUMP_TAG() if frame is `finish' frame.
  Without this patch, there is an inconsistency between control
  frame stack and tags stack.
  [Bug #7668]
* test/ruby/test_settracefunc.rb: add a test for above.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38721 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-07 06:24:46 +00:00
usa 6e4b187bfe * Makefile.in, common.mk (fake, yes-fake, no-make): these dependecies
are not platform dependent.

* win32/Makefile.sub ($(arch)-fake.rb): workaround.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38720 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-07 06:23:15 +00:00
nobu 8f1be27017 vm_insnhelper.c: keyrest should not overwrite rest arg
* vm_insnhelper.c (vm_callee_setup_arg_complex, vm_yield_setup_block_args):
  set keyrest hash after making rest array, so that the last element
  will not be overwritten.  [ruby-core:51278] [Bug #7665]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38719 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-07 03:09:28 +00:00
nobu 04d244642d * NEWS: adjust indent.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38718 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-07 01:44:42 +00:00