skylight 0.3.1 → 0.3.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +5 -0
- data/ext/skylight_native.c +7 -2
- data/lib/skylight.rb +1 -1
- data/lib/skylight/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d35e2f9002822fce35de8e6057507c7580f96481
|
4
|
+
data.tar.gz: 3579cfe7ab62384b05ac59c3151c25f33b86a000
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: fdde6a8043068fa425b4ef412e895fe0fd9c0ebb99776e8505069357eb7ed59ba8134ac6a1e16f35882162eebc49d5ab6230340bdd59cc7e4e4859154e2264a5
|
7
|
+
data.tar.gz: 000c1d8ca54a68d00d7c099cf57f8704ba97563d0e384950acb643066cf23029c5cff2664a4884491af69881f49f176e4237ad2f4e940e9e78d67f62aaedeb89
|
data/CHANGELOG.md
CHANGED
data/ext/skylight_native.c
CHANGED
@@ -1,6 +1,10 @@
|
|
1
1
|
#include <ruby.h>
|
2
2
|
#include <stdbool.h>
|
3
3
|
|
4
|
+
#ifdef HAVE_RUBY_ENCODING_H
|
5
|
+
#include <ruby/encoding.h>
|
6
|
+
#endif
|
7
|
+
|
4
8
|
/**
|
5
9
|
* Ruby helpers
|
6
10
|
*/
|
@@ -64,8 +68,9 @@ typedef struct {
|
|
64
68
|
} RustSlice;
|
65
69
|
|
66
70
|
typedef rust_str * RustString;
|
67
|
-
|
68
|
-
#define
|
71
|
+
typedef RustString RustVector;
|
72
|
+
#define VEC2STR(vector) ({ RustVector v = (vector); VALUE ret = rb_str_new((char *)v->data, v->fill); ret; })
|
73
|
+
#define SLICE2STR(slice) ({ RustSlice s = (slice); VALUE str = rb_str_new(s.data, s.len); rb_enc_associate(str, rb_utf8_encoding()); str; })
|
69
74
|
#define STR2SLICE(string) ({ RustSlice s; VALUE rb_str = (string); s.data = RSTRING_PTR(rb_str); s.len = RSTRING_LEN(rb_str); s; })
|
70
75
|
|
71
76
|
#define UnwrapOption(T, val, transform) ({ T * v = (val); VALUE ret; if (v == NULL) ret = Qnil; else ret = transform(*v); ret; })
|
data/lib/skylight.rb
CHANGED
@@ -19,6 +19,7 @@ module Skylight
|
|
19
19
|
autoload :Api, 'skylight/api'
|
20
20
|
autoload :CLI, 'skylight/cli'
|
21
21
|
autoload :Config, 'skylight/config'
|
22
|
+
autoload :Helpers, 'skylight/helpers'
|
22
23
|
|
23
24
|
module Util
|
24
25
|
autoload :Logging, 'skylight/util/logging'
|
@@ -45,7 +46,6 @@ module Skylight
|
|
45
46
|
end
|
46
47
|
|
47
48
|
autoload :GC, 'skylight/gc'
|
48
|
-
autoload :Helpers, 'skylight/helpers'
|
49
49
|
autoload :Instrumenter, 'skylight/instrumenter'
|
50
50
|
autoload :Messages, 'skylight/messages'
|
51
51
|
autoload :Middleware, 'skylight/middleware'
|
data/lib/skylight/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: skylight
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tilde, Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-03-
|
11
|
+
date: 2014-03-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|