Sha256: 045ea49ffc0a0a03d1ffb800001d58658f25db7f2f64f592b4550a88c1149d16
Contents?: true
Size: 1.47 KB
Versions: 1
Compression:
Stored size: 1.47 KB
Contents
/* * MessagePack for Ruby * * Copyright (C) 2008-2012 FURUHASHI Sadayuki * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ #include "packsnap.h" #include "buffer_class.hh" #include "packer_class.hh" #include "unpacker_class.hh" #ifdef COMPAT_HAVE_ENCODING /* see compat.h*/ int s_enc_utf8; int s_enc_ascii8bit; int s_enc_usascii; VALUE s_enc_utf8_value; #endif extern "C" void Init_packsnap(void) { #ifdef COMPAT_HAVE_ENCODING s_enc_ascii8bit = rb_ascii8bit_encindex(); s_enc_utf8 = rb_utf8_encindex(); s_enc_usascii = rb_usascii_encindex(); s_enc_utf8_value = rb_enc_from_encoding(rb_utf8_encoding()); #endif VALUE mMessagePack = rb_define_module("Packsnap"); rb_mPacksnap = mMessagePack; rb_ePacksnap = rb_define_class_under(rb_mPacksnap, "Error", rb_eStandardError); MessagePack_Buffer_module_init(mMessagePack); MessagePack_Packer_module_init(mMessagePack); MessagePack_Unpacker_module_init(mMessagePack); }
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
packsnap-0.0.1 | ext/packsnap/rbinit.cc |