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

36627 Коммитов

Автор SHA1 Сообщение Дата
svn b38142e972 * 2014-08-19
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47218 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-19 01:13:36 +00:00
nobu a198bb3929 thread.c: check initialized
* ext/thread/thread.c (get_array): check instance variables are
  initialized properly.  [ruby-core:63826][Bug #10062]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47217 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-19 01:13:24 +00:00
nobu 1d196e0d2b sprintf.c: rational 'f' format
* sprintf.c (rb_str_format): support rational 'f' format.
  [ruby-core:64382] [Bug #10136]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47214 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-18 08:06:48 +00:00
nobu 22892ca6c2 sprintf.c: remove magic numbers
* sprintf.c (rb_str_format): name default float precision and
  remove unused initial value.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47213 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-18 08:06:37 +00:00
nobu 1767764791 test_time_tz.rb: has_lisbon_tz
* test/ruby/test_time_tz.rb (has_lisbon_tz): separate from
  has_right_tz.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47212 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-18 00:04:32 +00:00
svn 52e0f11b35 * remove trailing spaces.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47211 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-17 23:04:23 +00:00
svn 0a7a01378c * 2014-08-18
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47210 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-17 23:04:20 +00:00
hsbt 70ea6d28c1 * spec/default.mspec: use 2.2 definition.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47209 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-17 23:04:10 +00:00
ktsj 6bce41b3b7 * gc.c (obj_memsize_of): don't calculate memsize of T_NODE
when called from check_gen_consistency. It fixes segmentation
  fault on RGENGC_CHECK_MODE >= 1 introduced by r47188.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47208 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-17 10:51:33 +00:00
suke b62ce0e964 * ext/win32ole/win32ole.c (ole_invoke): use RHASH_SIZE instead of
calling Hash#length method.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47207 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-17 08:10:38 +00:00
svn 5a2c3ae883 * 2014-08-17
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47206 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-17 00:50:45 +00:00
nobu 8ac65c462d win32/configure.bat: fix eol-style
* win32/configure.bat: reset svn:eol-style to CRLF, and revert
  r47015.  r47017 just reverted the contents but did not reset it.
  `svn export` converts CRLF to LF due to this property.
  [ruby-core:64414] [Bug #10145]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47205 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-17 00:50:36 +00:00
kazu f4c837858e fix typos [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47204 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-16 14:29:43 +00:00
suke bd6e27dc47 * ext/win32ole/win32ole_event.c (evs_length): use RARRAY_LEN instead
of calling Array#length method.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47203 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-16 10:34:24 +00:00
nobu 2fd7e29255 test_ruby_mode.rb: trivial refinement
* test/misc/test_ruby_mode.rb (run_emacs): ensure to remove a
  temporary file.

* test/misc/test_ruby_mode.rb (assert_indent): show diff between
  expected and actual results.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47202 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-16 06:22:48 +00:00
nobu 4c7038c177 test_gem_ext_builder.rb: fix wrong skip condition
* test/rubygems/test_gem_ext_builder.rb (test_build_extensions_extconf_bad):
  fix wrong skip condition by removing wrong expace, String#include?
  does not turn a string argument into a regexp.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47201 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-16 04:49:47 +00:00
nobu d0f71e5072 rake/backtrace.rb: exclude mere prefix
* lib/rake/backtrace.rb (Rake::Backtrace): exclude mere prefix and
  exec_prefix, which match too much.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47200 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-16 03:56:17 +00:00
nobu 04408eae54 rake/backtrace.rb: remove wrong value
* lib/rake/backtrace.rb (Rake::Backtrace::SYS_KEYS): only names
  end with prefix or libdir, not just include them.  libdirname is
  not a key of path name.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47199 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-16 03:48:21 +00:00
nobu 3636e08858 string.c: rb_setup_fake_str
* string.c (rb_setup_fake_str): setup fake string from C pointer,
  length, and encoding.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47198 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-16 03:36:47 +00:00
nobu a669514e63 node.h: extract NODE functions from gc.c
* node.h (rb_gc_free_node, rb_node_memsize, rb_gc_mark_node):
  extract functions for NODE from obj_free(), obj_memsize_of(),
  gc_mark_children() in gc.c.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47197 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-16 01:53:10 +00:00
normal ed2e8b2e70 time.c (time_timespec): fix tv_nsec overflow
test/ruby/test_float.rb (test_sleep_with_Float) causes tv_nsec
to hit 1000000000 exactly.  This bug is currently hidden from
our test by the platform-dependent native_cond_timeout
functions, but a future native_cond_timedwait implementation may
prefer relative timeouts to match ConditionVariable#wait
semantics more closely.
[Bug #10144]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47196 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-16 01:27:19 +00:00
svn e51a55903e * 2014-08-16
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47195 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-16 00:55:47 +00:00
nobu 8f98ee19b5 ChangeLog: fix name
* ChangeLog: fix newly added function name.  [ci skip]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47194 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-16 00:55:36 +00:00
svn da7e13a055 * properties.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47193 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-15 11:36:25 +00:00
suke cd3d7fe846 * ext/win32ole/win32ole.c: seperate WIN32OLE_EVENT src from
win32ole.c.
* ext/win32ole/win32ole.h: ditto.
* ext/win32ole/win32ole_event.c: ditto.
* ext/win32ole/win32ole_event.h: ditto.
* ext/win32ole/depend: ditto.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47192 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-15 11:36:12 +00:00
ko1 3e759ed78d * iseq.c (rb_iseq_clone): Should not insert write barrier from
non-RVALUE data (to non-RVALUE data, of course).
  Ruby 2.1 also has a same problem.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47191 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-15 10:39:27 +00:00
ko1 6f7366c206 * string.c (setup_fake_str): fake strings should not set class by
RBASIC_SET_CLASS() because it insert write barriers to fake
  (non-RVALUE) structure.
  It can cause unexpected behaviour.
  Ruby 2.1 also have a same problem (setup_fake_str() in parse.y).
* symbol.c (setup_fake_str): ditto.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47190 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-15 10:37:42 +00:00
ko1 b5e89e44f1 * array.c (rb_ary_tmp_new): added.
This function creates internal use only array (which is completely
  hided by ObjectSpace.each_object) with filling nil.
  Otherwise, it can be incldues strange VALUEs.
* internal.h: added.
* node.h: use rb_ary_tmp_new_fill() for MEMO.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47189 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-15 10:32:58 +00:00
nobu 85691b9578 gc.c: memsize of T_NODE
* gc.c (obj_memsize_of): fix size of T_NODE and comments.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47188 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-15 03:00:31 +00:00
hsbt e5c9e56893 * lib/gserver.rb: removed unmaintained code.
[ruby-core:40313][Feature #5480]
* lib/xmlrpc/httpserver.rb: ditto.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47187 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-15 01:21:18 +00:00
normal 90037145dd rb_{thread,context,fiber}_struct: trivial packing
* vm_core.h (rb_thread_struct): reorder to pack
* cont.c (rb_context_struct, rb_fiber_struct): ditto
  On x86-64, these changes reduces:
  rb_thread_struct to 1000 bytes (from 1016)
  rb_context_struct to 1288 bytes (from 1312)
  rb_fiber_struct to 2272 bytes (from 2304)

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47186 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-15 00:25:34 +00:00
normal fdb2fc0b04 thread_pthread: prefer rb_nativethread* types/functions
This will make it easier for us to try alternative mutex/condvar
implementations while still using pthreads for thread management.
[Feature #10134]

* thread_pthread.h: define RB_NATIVETHREAD_LOCK_INIT and
  RB_NATIVETHREAD_COND_INIT macros

* thread_pthread.c (native_mutex_lock, native_mutex_unlock,
  native_mutex_trylock, native_mutex_initialize,
  native_mutex_destroy, native_cond_wait):
  use rb_nativethread_lock_t instead of pthread_mutex_t

* thread_pthread.c (native_mutex_debug): make argument type-agnostic
  to avoid later cast.

* thread_pthread.c (register_cached_thread_and_wait):
  replace PTHREAD_COND_INITIALIZER with RB_NATIVETHREAD_COND_INIT,
  use native_mutex_{lock,unlock}

* thread_pthread.c (use_cached_thread):
  use native_mutex_{lock,unlock}

* thread_pthread.c (native_sleep):
  use rb_nativethread_lock_t to match th->interrupt_lock,
  use native_mutex_{lock,unlock}

* thread_pthread.c (timer_thread_lock): use rb_nativethread_lock_t type

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47185 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-15 00:17:53 +00:00
nobu bef5ddbb71 parser.y: warning with VALUE for ripper
* parse.y (ripper_warnV, ripper_warningV): add versions using
  VALUE for ripper.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47184 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-14 23:32:06 +00:00
normal d279f68f21 cont.c (cont_mark): fix typo in unused path [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47183 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-14 23:12:04 +00:00
normal 54e546c6c6 vm.c (rb_thread_mark): update comment about marking `me'
[ruby-core:64340] [ruby-core:64341]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47182 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-14 21:10:06 +00:00
svn 500fbe7666 * 2014-08-15
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47181 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-14 20:55:39 +00:00
normal ee4acc36aa README.EXT: preliminary documentation for RB_GC_GUARD
[Bug #10100] [ruby-core:60741]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47180 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-14 20:55:27 +00:00
akr 05e756f367 Revert r46977. [ruby-core:63857] [Bug #10071]
The removed comment is useful to understand the behind idea to
solve the year 2038 problem.

The broken link is replaced to refer the internet archive.
0eed69757d (commitcomment-7166665)



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47179 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-14 13:10:07 +00:00
nobu fbd13e9240 test_io.rb: investigation
* test/ruby/test_io.rb (test_readpartial_locktmp): check if the
  reader thread is alive before write.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47178 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-14 02:26:56 +00:00
kazu 78d3e33cd9 fix typos and styles [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47177 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-13 17:17:24 +00:00
svn 8337f69501 * properties.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47176 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-13 15:28:41 +00:00
svn 91aba27aaa * 2014-08-14
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47175 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-13 15:28:38 +00:00
suke 96b27e5a97 * ext/win32ole/win32ole.c: seperate WIN32OLE_RECORD src from
win32ole.c
* ext/win32ole/win32ole.h: ditto.
* ext/win32ole/win32ole_record.c: ditto.
* ext/win32ole/win32ole_record.h: ditto.
* ext/win32ole/depend: ditto.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47174 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-13 15:28:26 +00:00
svn 77db03023c * properties.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47173 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-13 12:46:49 +00:00
suke 51b4ccd618 * ext/win32ole/win32ole.c: seperate WIN32OLE_VARIANT src from
win32ole.c.
* ext/win32ole/win32ole.h: ditto.
* ext/win32ole/win32ole_variant.c: ditto.
* ext/win32ole/win32ole_variant.c: ditto.
* ext/win32ole/depend: ditto.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47172 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-13 12:46:23 +00:00
nobu 02c86ce1ee parse.y: preserve encodings
* parse.y (shadowing_lvar, warn_unused_var),
  (reg_named_capture_assign_iter): preserve encodings in warning
  messages.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47171 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-13 12:20:13 +00:00
nobu 5129155a25 test_parse.rb: for warnings
* test/ruby/test_parse.rb (TestParse): add tests for parser warnings.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47170 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-13 12:17:57 +00:00
nobu 979d413fab envutil.rb: fix argument order
* test/ruby/envutil.rb (Test::Test#assert_warning): fix expected
  and actual results order.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47169 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-13 12:16:30 +00:00
suke fe8b513378 * ext/win32ole/win32ole.c: remove unused variable.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47168 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-13 11:10:42 +00:00
suke 651b31e367 * ext/win32ole/win32ole.c(ole_search_handler_method, rescue_callback,
folerecord_inspect): use PRIsVALUE in rb_sprintf.

* ext/win32ole/win32ole_param.c(foleparam_inspect): ditto.

* ext/win32ole/win32ole_variable.c(folevariable_inspect): use
  PRIsVALUE in rb_sprintf, use rb_inspect.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47167 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-08-13 10:35:20 +00:00