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

21215 Коммитов

Автор SHA1 Сообщение Дата
svn 8f709e143a * 2010-10-28
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29615 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-27 18:16:46 +00:00
ko1 b36aa7af03 * ext/objspace/objspace.c (memsize_of): fix rdoc.
* ext/objspace/objspace.c (total_memsize_of_all_objects): added.
* test/objspace/test_objspace.rb:
  - add a test for ObjectSpace.total_memsize_of_all_objects.
  - add two tests for ObjectSpace.memsize_of (for nil and Fixnum).



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29614 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-27 18:16:39 +00:00
nobu 430c1d3fe4 * ext/iconv/iconv.c (Init_iconv): warn deprecated use.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29613 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-27 14:55:31 +00:00
usa 5cf605b1d2 * bignum.c (rb_big2long, rb_big2ulong): rb2ulong() returns VALUE, but
its real range is ulong. So, if the size of VALUE is bigger than
  ulong, upper bits are always zero even if the actual value is
  negative.
  fixed #3490


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29612 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-27 09:54:27 +00:00
usa 7a5d45fc3c * test/ruby/test_io.rb (TestIO#pipe): should close write end of pipe
before closing read end, to get rid of timing problem.

* test/ruby/test_io_m17n.rb (TestIO_M17N#pipe): ditto.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29611 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-27 09:28:08 +00:00
usa 1503e320d9 * win32/win32.c (rb_w32_getppid): support Win64.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29610 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-27 09:15:02 +00:00
usa f30e1877b2 * thread_win32.c (w32_error): should get error no only once, because
the result of the second getting will indicate the error of the
  first FormatMessage() call.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29609 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-27 06:08:37 +00:00
usa c265d57595 * ruby/test_io_m17n.rb (TestIO_M17N#pipe): fixed the mistake of previous
commit.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29608 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-27 05:56:01 +00:00
usa a012bf6ed4 * test/ruby/test_io.rb (TestIO#pipe): need to propagate exceptions
in read/write thread. fix r29541.

* test/ruby/test_io_m17n.rb (TestIO_M17N#pipe): ditto.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29607 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-27 04:53:34 +00:00
usa 6223582f2a * class.c (clone_const): need to return value. fix r29602.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29606 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-27 03:06:27 +00:00
usa 6ef1aa7964 * include/ruby/ruby.h (NUM2LONG_internal): add cast to get rid of a
non GCC compiler warning. this is intentional type conversion.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29605 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-27 03:00:26 +00:00
naruse bb2dc7e986 * cont.c: apply documentation patch by Run Paint Run Run.
[ruby-core:32915]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29604 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-27 00:26:29 +00:00
mame b88c9aa1fe * object.c (Init_Object), constant.h, variable.c
(rb_mod_private_constant, rb_mod_public_constant,
  set_const_visibility, rb_const_get_0): add Module#public_constant
  and private_constant.  [ruby-dev:39685][ruby-core:32698]

* test/ruby/test_module.rb: add tests for above.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29603 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-26 17:27:44 +00:00
mame a115768161 * class.c, constant.h, gc.c, method.h, object.c, variable.c,
vm_insnhelper.c: use struct rb_constant_entry_t as entry of
  RCLASS_CONST_TBL.  RCLASS_CONST_TBL has contained VALUE of constant
  directly.  Now instead rb_const_entry_t is contained in
  RCLASS_CONST_TBL,  rb_const_entry_t is managed by malloc, and
  have not only the value itself but also visibility flag.
  This is another preparation for private constant (see
  [ruby-dev:39685][ruby-core:32698]).

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29602 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-26 17:27:32 +00:00
svn e169ea0cac * 2010-10-27
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29601 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-26 17:27:24 +00:00
mame 2285a8d813 * class.c, gc.c, object.c, variable.c, vm_insnhelper.c,
include/ruby/ruby.h: separate RCLASS_CONST_TBL from RCLASS_IV_TBL.
  RCLASS_IV_TBL has contained not only instance variable table but
  also constant table.  Now the two table are separated to
  RCLASS_CONST_TBL and RCLASS_IV_TBL.  This is a preparation for
  private constant (see [ruby-dev:39685][ruby-core:32698]).

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29600 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-26 17:27:21 +00:00
naruse 6ca3ad34a0 * lib/scanf.rb (extract_float): allow 2.e+2 style.
[ruby-dev:42452] #3978

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29599 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-26 12:39:33 +00:00
nobu 767d70841a * Makefile.in (ASFLAGS): needs INCFLAGS.
* configure.in (rb_cv_dynamic_alloca): check if extra source for
  dynamic size alloca.

* missing/x86_64-chkstk.s (___chkstk): necessary for alloca of
  amd64-mingw32msvc-gcc on Ubutu.

* thread_win32.c (ruby_alloca_chkstk): check stack overflow

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29598 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-26 09:09:45 +00:00
nobu 67d7448fca * vsnprintf.c (BSD_vfprintf): suppress warnings.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29597 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-26 09:09:39 +00:00
nobu 51d25ca8c0 * template/ruby.pc.in (Libs): needs DLDFLAGS.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29596 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-26 09:04:59 +00:00
nobu 749ad16aa7 * common.mk (pkgconfig-data): moved from Makefile.in.
* tool/rbinstall.rb: install pc file only if non-empty.
  [ruby-core:32901] #3983

* win32/Makefile.sub (ruby_pc): create pc file.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29595 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-26 03:47:15 +00:00
nobu fd74e1414c * .gitignore: ignore pkg-config metadata file.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29594 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-26 03:44:56 +00:00
nobu 7b410abfb8 * configure.in (rb_cv_gcc_atomic_builtins): check for atomic
builtins, all are not available in Apple derivative gcc.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29593 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-26 00:13:37 +00:00
nobu 3ea90fc38e * signal.c: fix typo.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29592 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-25 23:46:27 +00:00
nobu 4d9a6ab181 * Makefile.in (pkgconfig-data): create pkg-config metadata file.
* tool/rbinstall.rb: install pkg-config metadata file.

* template/ruby.pc.in: template of pkg-config metadata file.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29591 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-25 15:29:32 +00:00
shyouhei a6ed06e513 ispell.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29590 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-25 07:57:51 +00:00
shyouhei 2c770d676c * signal.c (rb_atomic_t): GCC (of at least recent versions)
has  ubiquitos  support  for  atomic  operations.   On  that
  compiler a C  program can isse a memory  barrier using these
  dedicated  instructions.  According to  the GCC  manual they
  cargo culted  this feature form  the Itanium ABI  so chances
  are that  other compilers  could also support  this feature.
  But so far GCC is the  only compiler that I know to have it.
  Also note that this works on non-Itanium machines.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29589 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-25 07:46:53 +00:00
nobu 0d78d991ca * test/ruby/test_array.rb (test_rotate!): fix expected message.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29588 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-25 00:34:14 +00:00
nobu bbf0fd4e9c * vsnprintf.c (BSD_vfprintf): prec digits fractal part should be
appended to 0 if prec is given.  [ruby-dev:42453] #3979

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29587 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-24 21:21:40 +00:00
ko1 df26e9d44e * common.mk (run.gdb): Quit gdb on 'make gdb' when
no signals are received.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29586 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-24 18:00:20 +00:00
svn 7bbea01a5a * 2010-10-25
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29585 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-24 15:30:30 +00:00
tadf 4fcd5e3fc1 * lib/date.rb: some corrections of documentation.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29584 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-24 15:30:25 +00:00
nobu 23e8deaf0d * array.c, gc.c, hash.c, object.c, string.c, struct.c,
transcode.c, variable.c, vm.c, vm_insnhelper.c, vm_method.c:
  replace calls to rb_error_frozen() with rb_check_frozen().  a
  patch from Run Paint Run Run at [ruby-core:32014]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29583 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-24 08:14:05 +00:00
nobu 58d3597e74 * include/ruby/intern.h (rb_check_frozen): optimize.
[ruby-core:32878]



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29582 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-24 08:05:55 +00:00
nobu 5383964f98 * lib/test/unit.rb (Test::Unit::Mini#run): abort if interrupted.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29581 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-24 06:16:36 +00:00
nobu b560b08014 * lib/test/unit.rb (Test::Unit::Mini#run_test_suites): show the
result even when interrupted on the way.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29580 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-24 05:18:12 +00:00
nobu 071e1ba1f8 * lib/test/unit.rb (Test::Unit::Mini#run_test_suites): ensure
output sync mode to be restored.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29579 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-24 05:13:55 +00:00
nobu 98ac9b8667 * vm.c (vm_define_method): defined method is run with the default
public visibility regardless the visibility context of definition.
  [ruby-core:30638]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29578 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-24 05:11:26 +00:00
tenderlove 8a40d614a3 * lib/test/unit.rb: make test/unit play nicely with the rake test
loader. [ruby-core:32864]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29577 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-24 03:11:20 +00:00
nobu 4e3fda080c * test/ruby/test_rubyoptions.rb (test_segv_test): follow up the
change at r29556.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29576 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-23 15:25:20 +00:00
nobu c2fdd98eb0 * lib/mkmf.rb: $extmk should be true for test/runner.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29558 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-23 05:40:11 +00:00
svn 874ab2e639 * 2010-10-23
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29557 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-23 02:02:56 +00:00
ko1 3bd7384c76 * vm_dump.c (rb_vm_bugreport): fix to add bug outputs.
- loaded script ($0)
  - loaded features ($")
  - process memory map on Linux (/proc/self/maps)
* vm_dump.c (rb_vmdebug_stack_dump_raw): fix header message.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29556 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-23 02:02:50 +00:00
nobu cb9ffb8d1c * lib/test/unit/assertions.rb (Test::Unit::Assertions#assert):
assertion message must not be nil.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29555 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-22 05:50:17 +00:00
naruse e1d1571256 * lib/test/unit/assertions.rb (Test::Unit::Assertions#assert):
treat nil case. Please run test-all before commit such change.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29554 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-22 05:10:40 +00:00
ryan b3ee43bb6e Cleaned up clevar in test/unit's override of assert
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29553 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-21 21:15:06 +00:00
svn c400795c8c * 2010-10-22
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29552 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-21 15:03:58 +00:00
ko1 e923b67707 * gc.c (gc_lazy_sweep): Variable declarations should be at
the head of block.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29551 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-21 15:03:56 +00:00
nobu e5db83ec65 * gc.c (objspace_each_objects, rb_objspace_each_objects): use
struct.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29550 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-21 14:56:55 +00:00
nobu 48b4512f76 * gc.c (objspace_each_objects): fix return with no value.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29549 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-21 14:52:02 +00:00