This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From 05b4614e120a93fd73e096264f00695c1c84b75e Mon Sep 17 00:00:00 2001 | |
From: Ivan Samsonov <[email protected]> | |
Date: Wed, 21 Jul 2010 12:43:09 +0400 | |
Subject: [PATCH 1/2] One more spec for Array#delete that rubinius doesn't handle | |
--- | |
spec/ruby/core/array/delete_spec.rb | 6 ++++++ | |
1 files changed, 6 insertions(+), 0 deletions(-) | |
diff --git a/spec/ruby/core/array/delete_spec.rb b/spec/ruby/core/array/delete_spec.rb |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE tsung PUBLIC "SYSTEM" "/opt/local/share/tsung/tsung-1.0.dtd"> | |
<tsung loglevel="info"> | |
<clients> | |
<client host="tsungtest" /> | |
<client host="tsungtest2"/> | |
</clients> | |
<servers> | |
<server host="host" port="3030" type="tcp"/> | |
</servers> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1.8.7 | |
user system total real | |
inject(:+) 9.430000 0.010000 9.440000 ( 9.519405) | |
inject(&:+) 37.380000 0.040000 37.420000 ( 37.846156) | |
inject{|s,e| s+e} 46.090000 0.100000 46.190000 ( 46.701613) | |
1.9.2dev | |
user system total real | |
inject(:+) 3.640000 0.010000 3.650000 ( 3.649725) | |
inject(&:+) 4.870000 0.010000 4.880000 ( 4.893119) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
deviates_on :rubinius do | |
it "raises a RangeError when m is a Bignum" do | |
lambda { @bignum >> bignum_value() }.should raise_error(RangeError) | |
end | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From c1bc7bba68c72f068af7cc7eaf80d81d4bedd95e Mon Sep 17 00:00:00 2001 | |
From: Ivan Samsonov <[email protected]> | |
Date: Tue, 15 Jun 2010 00:29:49 +0400 | |
Subject: [PATCH 1/2] Spec for loading unexisting file | |
--- | |
spec/ruby/core/kernel/shared/require.rb | 6 ++++++ | |
1 files changed, 6 insertions(+), 0 deletions(-) | |
diff --git a/spec/ruby/core/kernel/shared/require.rb b/spec/ruby/core/kernel/shared/require.rb |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ruby-1.8.7-p249 > $LOADED_FEATURES << 'ppp'; nil | |
=> nil | |
ruby-1.8.7-p249 > require 'zzz/ppp' | |
LoadError: no such file to load -- zzz/ppp | |
from (irb):2:in `require' | |
from (irb):2 | |
ruby-1.8.7-p249 > require 'ppp' | |
=> false |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/kernel/common/codeloader.rb b/kernel/common/codeloader.rb | |
index 9e86164..3ad12ee 100644 | |
--- a/kernel/common/codeloader.rb | |
+++ b/kernel/common/codeloader.rb | |
@@ -119,7 +119,7 @@ module Rubinius | |
# is not ".so". | |
return loaded?(name[0..-4] + LIBSUFFIX) | |
else | |
- return true if loaded?(name + ".rb") | |
+ return true if loaded?(name) || loaded?(name + ".rb") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/kernel/common/codeloader.rb b/kernel/common/codeloader.rb | |
index 9e86164..3ad12ee 100644 | |
--- a/kernel/common/codeloader.rb | |
+++ b/kernel/common/codeloader.rb | |
@@ -119,7 +119,7 @@ module Rubinius | |
# is not ".so". | |
return loaded?(name[0..-4] + LIBSUFFIX) | |
else | |
- return true if loaded?(name + ".rb") | |
+ return true if loaded?(name) || loaded?(name + ".rb") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/vm/builtin/bignum.cpp b/vm/builtin/bignum.cpp | |
index 9cf4960..56152c0 100644 | |
--- a/vm/builtin/bignum.cpp | |
+++ b/vm/builtin/bignum.cpp | |
@@ -1221,7 +1221,7 @@ namespace rubinius { | |
a->managed = reinterpret_cast<void*>(storage); | |
// Be sure to use the smaller value! | |
- size_t current_bytes = (size_t)a->alloc; | |
+ size_t current_bytes = sizeof(mp_digit) * (size_t)a->alloc; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extern "C" void* MANAGED_REALLOC_MPINT(void* s, mp_int* a, size_t bytes) { | |
assert(s); | |
VM* state = reinterpret_cast<VM*>(s); | |
ByteArray* storage = ByteArray::create(state, bytes); | |
a->managed = reinterpret_cast<void*>(storage); | |
// Be sure to use the smaller value! | |
size_t current_bytes = (size_t)a->alloc; | |
size_t to_copy = bytes; |