1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00
Commit graph

20 commits

Author SHA1 Message Date
nahi
e56f2abe4b * ext/digest/sha2/sha2.c (SHA256_Update, SHA512_Update): avoid Bus
Error caused by unalignment access on Sparc-Solaris (and possibly on
  other similar environment.) This patch just do memcpy always instead
  of checking architecture. I see no perf drop on my 64bit env. For
  more details, see #4320.

* test/digest/test_digest.rb: add test for unalignment access.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32546 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-07-15 03:03:31 +00:00
nobu
6d8c13bc61 * test/with_different_ofs.rb (DifferentOFS): should not affect
original classes.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30380 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-12-26 02:15:55 +00:00
nobu
ef99044673 * test/csv: DifferentOFS needs to be include in each classes.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30370 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-12-25 13:49:14 +00:00
nobu
3e7c68119c * test/digest/test_digest_extend.rb (TestDigestExtend#setup):
should not depend on the result of previous tests
* test/with_diffent_ofs.rb (DifferentOFS::WithDifferentOFS): give
  name.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30368 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-12-25 13:32:48 +00:00
nobu
7df8b94926 * test/with_diffent_ofs.rb (DifferentOFS): test suite for test
suites affected by $,.
* test/digest/test_digest_extend.rb (TestDigestExtend): should not
  assume $, invariant.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30367 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-12-25 13:08:07 +00:00
knu
74cacd0df4 * ext/digest/digest.c (rb_digest_class_init): Define
Digest::Class.new(). [Feature #3954]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29528 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-10-18 04:26:06 +00:00
nobu
83a827ac9b * vm.c (vm_backtrace_each): skip allocator frames which have no
name.  [ruby-core:32231]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29205 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-09-09 14:25:56 +00:00
nobu
fd1762b45b * test/digest/test_digest.rb (test_eq): use descriptive assertion.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27586 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-05-02 05:56:35 +00:00
akr
48d402db88 use require_relative.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26542 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-02-02 13:58:56 +00:00
knu
d8f265b332 * ext/digest/digest.c (rb_digest_instance_hexdigest_bang): Fix
rdoc.

* ext/digest/lib/digest.rb (Digest::Class.base64digest)
  (Digest::Instance#base64digest{,!}): New methods.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26339 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-01-17 19:12:10 +00:00
nahi
115fa14f28 * test/digest/test_digest_extend.rb: added tests for digest framework.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25970 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-12-01 09:03:29 +00:00
nahi
c7b0dbd002 * test/digest/test_digest_extend.rb: Added tests for current digest
framework.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25925 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-11-25 15:08:06 +00:00
knu
541ecc66d8 * test/digest/test_digest_hmac.rb: added.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11221 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-10-25 08:16:48 +00:00
knu
f678390e1f * ext/digest/digest.c (Init_digest): Digest::Base.new() does no
longer take an initial string to feed.  This change allows
  subclasses to take hashing parameters.  A statement such as
  ``md = Digest::MD5.new(s)'' can be easily rewritten as
  ``md = Digest::MD5.new << s'' or
  ``md = Digest::MD5.new.update(s)''.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11154 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-10-13 11:58:05 +00:00
matz
ccf99b9ce6 * eval.c (ev_const_get): simplified using rb_const_get_fallback().
* eval.c (ev_const_defined): adopt to ev_const_get() using
  rb_const_defined_fallback().

* variable.c (rb_const_get_fallback): new function to implement
  constant search.

* variable.c (rb_const_defined_fallback): new function to
  implement constant definition check.

* variable.c (rb_const_get_0): adopt to new behavior.  constants
  are looked up in the order of: current class, super classes (but
  Object), lexically external classes/modules, and Object.

* variable.c (rb_const_defined_0): ditto.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@9949 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-02-17 08:40:52 +00:00
ocean
52dca16384 * lib/drb/drb.rb (DRbServer.default_safe_level): fix typo.
* test/digest/test_digest.rb: separate test case for each algorithms.
  (Thanks nobu) [ruby-dev:25412]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@7991 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-02-17 11:16:57 +00:00
matz
e77ddaf0d1 * array.c (rb_ary_delete): element comparison might change array
size. [ruby-dev:24273]

* parse.y: make ruby parser reentrant. merge ripper parser to the
  real one.  this change makes ruby require bison.

* file.c (rb_file_truncate): clear stdio buffer before truncating
  the file.  [ruby-dev:24191]

* ext/digest/digest.c: use rb_obj_class() instead of CLASS_OF
  which might return singleton class.  [ruby-dev:24202]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@6919 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2004-09-17 09:24:13 +00:00
akr
08907d87e0 add test for [ruby-dev:24060], [ruby-dev:24065], [ruby-dev:24103],
[ruby-dev:24190], [ruby-dev:24191], [ruby-dev:24194], [ruby-dev:24197],
[ruby-dev:24202], [ruby-dev:24213], [ruby-dev:24223] and [ruby-dev:24228].


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@6865 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2004-09-07 05:32:26 +00:00
nobu
e45c4cd1ac * test/digest/test_digest.rb (test_eq): show failed class.
* test/ruby/test_iterator.rb (test_break, test_return_trace_func):
  test localjump destination.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4783 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-15 23:38:10 +00:00
knu
6d9c20d6a3 * test/digest/test_digest.rb: Moved from ext/digest/test.rb.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4765 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-10-14 19:34:46 +00:00