Sha256: aa956dd85be6ac43d911060edc632e09e1b93ca3d6ecc8bc3c73e9a9211e9ebd

Contents?: true

Size: 362 Bytes

Versions: 22

Compression:

Stored size: 362 Bytes

Contents

#include "v8_str.h"
#include "v8.h"
#include "v8_ref.h"

using namespace v8;

VALUE v8_str_new(VALUE clazz, VALUE str) {
  HandleScope handles;
  return V8_Ref_Create(clazz, String::New(RSTRING_PTR(str)));
}

VALUE v8_str_to_s(VALUE self){
  HandleScope handles;
  Local<String> str = V8_Ref_Get<String>(self);
  return rb_str_new2(*String::AsciiValue(str));
}

Version data entries

22 entries across 22 versions & 1 rubygems

Version Path
therubyracer-0.6.3 ext/v8/v8_str.cpp
therubyracer-0.6.2 ext/v8/v8_str.cpp
therubyracer-0.6.1 ext/v8/v8_str.cpp
therubyracer-0.6.0 ext/v8/v8_str.cpp
therubyracer-0.5.5 ext/v8/v8_str.cpp
therubyracer-0.5.4 ext/v8/v8_str.cpp
therubyracer-0.5.3 ext/v8/v8_str.cpp
therubyracer-0.5.2-x86-darwin-10 ext/v8/v8_str.cpp
therubyracer-0.5.2 ext/v8/v8_str.cpp
therubyracer-0.5.1-x86-darwin-9 ext/v8/v8_str.cpp
therubyracer-0.5.1-x86-darwin-10 ext/v8/v8_str.cpp
therubyracer-0.5.1 ext/v8/v8_str.cpp
therubyracer-0.5.0-x86-darwin-9 ext/v8/v8_str.cpp
therubyracer-0.5.0-x86-linux ext/v8/v8_str.cpp
therubyracer-0.5.0-x86_64-linux ext/v8/v8_str.cpp
therubyracer-0.4.9-x86_64-linux ext/v8/v8_str.cpp
therubyracer-0.5.0-x86-darwin-10 ext/v8/v8_str.cpp
therubyracer-0.5.0 ext/v8/v8_str.cpp
therubyracer-0.4.9-x86-linux ext/v8/v8_str.cpp
therubyracer-0.4.9-x86-darwin-10 ext/v8/v8_str.cpp