Sha256: e3802a2c4e0efc83164b372b779708887b49c556a8acc0ab708e6d2992cca8db
Contents?: true
Size: 421 Bytes
Versions: 11
Compression:
Stored size: 421 Bytes
Contents
#include "false_class_ext.h" static VALUE cFalseClass; void Init_false_class_ext() { cFalseClass = rb_const_get(rb_cObject, rb_intern("FalseClass")); rb_define_method(cFalseClass, "to_json", (VALUE(*)(ANYARGS)) &to_json, -1); } /** * Returns a JSON string for false: 'false'. */ static VALUE to_json(argc, argv, self) int argc; VALUE *argv; VALUE self; { return rb_funcall(self, rb_intern("to_s"), 0); }
Version data entries
11 entries across 11 versions & 1 rubygems