Age | Commit message (Collapse) | Author |
|
of truncation on platforms where VALUE is larger than int.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25191 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
a discrete value.
* range.c (discrete_object_p): treat time objects specially to
determine discrete values, since time objects have #succ yet are
discrete (for now at least).
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25170 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25049 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
structures [ruby-core:24759]
* range.c (range_eq, range_eql): ditto for ranges
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25010 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
short-circuit to the outermost level in case of recursion
* test/ruby/test_thread.rb (test_recursive_outer): Test for above
* hash.c (rb_hash_hash): Return a sensible hash for in case of recursion [ruby-core:24648]
* range.c (rb_range_hash): ditto
* struct.c (rb_struct_hash): ditto
* array.c (rb_array_hash): ditto
* test/ruby/test_array.rb (test_hash2): test for above
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24943 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24792 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
over symbols should work like strings. [ruby-core:24780]
* range.c (range_each): ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24573 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24571 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
subclasses of Range. a patch from Marc-Andre Lafortune.
[ruby-core:22190]
* test/ruby/test_range.rb: add assertions for above.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24405 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
recursive key.
(range_hash): use recursive_hash.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24167 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
added for random.c.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24143 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
Marc-Andre Lafortune. [ruby-core:23943]
* object.c (rb_mod_cmp): ditto.
* range.c (range_eq): ditto.
* string.c (rb_str_partition, rb_str_rpartition): ditto.
* struct.c (rb_struct_s_def): ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@23930 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@23357 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@23356 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
needed. small performance improvement.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22574 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22552 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
include/ruby/intern.h: add Murmurhash API. [ruby-dev:37784]
* complex.c (nucomp_hash), array.c (rb_ary_hash), time.c (time_hash),
string.c (rb_str_hsah), object.c (rb_obj_hash), range.c
(range_hash), struct.c (rb_struct_hash), hash.c (rb_any_hash),
rational.c (nurat_hash): use Murmurhash. [ruby-dev:37784]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22317 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
[ruby-dev:37691]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@21330 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
Integer Numeric end values. [ruby-dev:37690] fix: #974
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@21327 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
* range.c (range_step): uses ruby_float_step() for float range.
[ruby-dev:37691]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@21298 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
[BUG] ranges turned into other value in a message of RangeError.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@20095 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
[ruby-core:18835]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19557 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
[ruby-core:18353]
* struct.c (rb_struct_init_copy): made public.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18743 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18653 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
* *.c: no cache in init functions.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@17053 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
value. [ruby-dev:34575]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@16271 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
integers. [ruby-dev:34571]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@16269 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@16265 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
[ruby-dev:34558]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@16256 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
than one. [ruby-dev:34557]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@16255 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@16231 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
uninitialized, which could cause SEGV.
* range.c (range_step): removed duplicated and unreachable code.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15913 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
zero.
* range.c (range_step): add step for each iteration if begin and
end are numeric. [ruby-core:15990]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15911 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
for numeric is done according magnitude of values.
[ruby-core:15907]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15895 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
given.
* bignum.c (rb_big_to_s): ditto.
* enum.c (enum_first): ditto.
* eval_jump.c (rb_f_catch): ditto.
* io.c (rb_obj_display): ditto.
* class.c (rb_obj_singleton_methods): ditto.
* object.c (rb_class_initialize): ditto.
* random.c (rb_f_srand): ditto.
* range.c (range_step): ditto.
* re.c (rb_reg_s_last_match): ditto.
* string.c (rb_str_to_i): ditto.
* string.c (rb_str_each_line): ditto.
* string.c (rb_str_chomp_bang): ditto.
* string.c (rb_str_sum): ditto.
* string.c (str_modifiable): declare inline.
* string.c (str_independent): ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15691 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
methods for non-Range object.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15490 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
case (e.g. (?a ..?z).include(?x)) for performance.
[ruby-core:15481]
* string.c (rb_str_upto): specialize single character case.
* string.c (rb_str_hash): omit coderange scan for performance.
* object.c (rb_check_to_integer): check Fixnum first.
* object.c (rb_to_integer): ditto.
* string.c (rb_str_equal): inline memcmp to avoid unnecessary
rb_str_comparable().
* parse.y (rb_intern2): use US-ASCII encoding.
* parse.y (rb_intern_str): ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15433 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15325 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
string.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14912 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
[ruby-talk:282100]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14107 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
to_splat.
* insnhelper.ci (caller_setup_args): ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14063 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
(rb_struct_define_without_accessor): add allocator to the arguments.
* range.c (range_alloc): re-introduced using rb_struct_alloc_noinit.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14003 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
* range.c (range_alloc): removed.
(Init_Range): use rb_struct_define_without_accessor.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14000 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13741 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13739 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
given. [ruby-core:12697]
* range.c (range_last): returns last n elements if argument is
given.
* array.c (rb_ary_subseq, rb_ary_last): export.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13736 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
(range_loader): make uninitialized range loadable.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13426 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13425 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13422 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
function.
* include/ruby/intern.h (rb_alloc_func_t): declared.
(rb_define_alloc_func): declared.
(rb_marshal_define_compat): declared.
* range.c: use T_STRUCT for Range.
* inits.c: move Init_marshal() prior to Init_Range() because
Init_Range calls rb_marshal_define_compat which needs
marshal's compat_allocator_tbl initialized.
* marshal.c: support marshal format compatibility layer designed for
marshaling T_STRUCT Range using T_OBJECT format.
(rb_marshal_define_compat): defined.
[ruby-dev:31710]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13413 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|