Browse files

Removed some alias_method commands to get Yardoc working

  • Loading branch information...
1 parent 094c120 commit 5cb8579ac7182f6d26ade8d9101b6396da30c3df @wedesoft committed Dec 10, 2009
Showing with 7 additions and 15 deletions.
  1. +1 −1 Makefile
  2. +1 −1 binary.gemspec
  3. +4 −4 ext/malloc.cc
  4. +0 −8 lib/malloc_ext.rb
  5. +1 −1 source.gemspec
View
2 Makefile
@@ -2,7 +2,7 @@
.SUFFIXES: .gem .o .cc .hh .rb .tar .gz .bz2
RUBY_VERSION = 1.8
-MALLOC_VERSION = 0.2.1
+MALLOC_VERSION = 0.2.2
CP = cp
RM = rm -Rf
View
2 binary.gemspec
@@ -1,7 +1,7 @@
require 'date'
Gem::Specification.new do |s|
s.name = %q{malloc}
- s.version = '0.2.1'
+ s.version = '0.2.2'
s.platform = Gem::Platform::CURRENT
s.date = Date.today.to_s
s.summary = %q{Object for raw memory allocation and pointer operations}
View
8 ext/malloc.cc
@@ -32,13 +32,13 @@ VALUE Malloc::cRubyClass = Qnil;
VALUE Malloc::init( VALUE rbModule )
{
cRubyClass = rb_define_class_under( rbModule, "Malloc", rb_cObject );
- rb_define_singleton_method( cRubyClass, "new",
+ rb_define_singleton_method( cRubyClass, "orig_new",
RUBY_METHOD_FUNC( mallocNew ), 1 );
- rb_define_method( cRubyClass, "+",
+ rb_define_method( cRubyClass, "orig_plus",
RUBY_METHOD_FUNC( mallocPlus ), 1 );
- rb_define_method( cRubyClass, "read",
+ rb_define_method( cRubyClass, "orig_read",
RUBY_METHOD_FUNC( mallocRead ), 1 );
- rb_define_method( cRubyClass, "write",
+ rb_define_method( cRubyClass, "orig_write",
RUBY_METHOD_FUNC( mallocWrite ), 1 );
return cRubyClass;
}
View
8 lib/malloc_ext.rb
@@ -6,8 +6,6 @@ class Malloc
class << self
- alias_method :orig_new, :new
-
# Create new Malloc object.
#
# @param [size] Number of bytes to allocate.
@@ -25,8 +23,6 @@ def new( size )
# Number of bytes allocated.
attr_reader :size
- alias_method :orig_plus, :+
-
# Operator for doing pointer arithmetic.
#
# @param [offset] Non-negative offset for pointer.
@@ -43,8 +39,6 @@ def +( offset )
private :orig_plus
- alias_method :orig_read, :read
-
# Read data from memory.
#
# @param [length] Number of bytes to read.
@@ -57,8 +51,6 @@ def read( length )
private :orig_read
- alias_method :orig_write, :write
-
# Write data to memory.
#
# @param [string] A string with the data.
View
2 source.gemspec
@@ -1,7 +1,7 @@
require 'date'
Gem::Specification.new do |s|
s.name = %q{malloc}
- s.version = '0.2.1'
+ s.version = '0.2.2'
s.platform = Gem::Platform::RUBY
s.date = Date.today.to_s
s.summary = %q{Object for raw memory allocation and pointer operations}

0 comments on commit 5cb8579

Please sign in to comment.