Skip to content
Browse files

Move primitive ByteArray#reverse to bootstrap.

  • Loading branch information...
1 parent a81a80d commit 467a1bde0303d955b52404e053c325c33b3822f8 @headius headius committed May 24, 2011
Showing with 5 additions and 5 deletions.
  1. +5 −0 kernel/bootstrap/bytearray.rb
  2. +0 −5 kernel/common/bytearray.rb
View
5 kernel/bootstrap/bytearray.rb
@@ -89,5 +89,10 @@ def utf8_char(offset)
Ruby.primitive :bytearray_get_utf8_char
raise ArgumentError, "unable to extract utf8 character"
end
+
+ def reverse(start, total)
+ Ruby.primitive :bytearray_reverse
+ raise PrimitiveFailure, "ByteArray#reverse primitive failed"
+ end
end
end
View
5 kernel/common/bytearray.rb
@@ -23,9 +23,4 @@ def inspect
def <=>(other)
compare_bytes other, size, other.size
end
-
- def reverse(start, total)
- Ruby.primitive :bytearray_reverse
- raise PrimitiveFailure, "ByteArray#reverse primitive failed"
- end
end

0 comments on commit 467a1bd

Please sign in to comment.
Something went wrong with that request. Please try again.