From 0e30abaff2d7bad556c3d9c27197c97e2485cf6c Mon Sep 17 00:00:00 2001 From: Bill Robertson Date: Sat, 9 Jan 2010 10:52:30 -0500 Subject: [PATCH] methods too --- ext/v8/converters.cpp | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/ext/v8/converters.cpp b/ext/v8/converters.cpp index 9247435..f9fc598 100644 --- a/ext/v8/converters.cpp +++ b/ext/v8/converters.cpp @@ -28,17 +28,11 @@ Local RB2V8(VALUE value) { VALUE valueClass = rb_class_of(value); - if(valueClass == rb_cProc) { + if(valueClass == rb_cProc || valueClass == rb_cMethod) { Local t = FunctionTemplate::New(RacerRubyInvocationCallback, External::Wrap((void *)value)); - return t->GetFunction(); - - printf("** This is a proc! We should do something different.\n"); + return t->GetFunction(); } - else if(valueClass == rb_cMethod) { - printf("** This is a method! We should do something different.\n"); - } - - + convert_rb_to_v8_t convert; return convert(value); }