rubinius-melbourne 1.0.0.8 → 1.1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.gitignore +1 -0
- data/ext/rubinius/melbourne/extconf.rb +14 -6
- data/ext/rubinius/melbourne/melbourne.cpp +4 -5
- data/lib/rubinius/melbourne/version.rb +2 -2
- data/lib/rubinius/melbourne.rb +4 -4
- data/rubinius-melbourne.gemspec +2 -2
- metadata +27 -26
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b188777f947911e3fb23967ada0b692a1e5b4233
|
4
|
+
data.tar.gz: 20e1ca1dc23c54693eae04d2fe64655f57d63b54
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 61766445e09b8e2784926fc9a933d624d368b93981fb8da5cfe812e655b35ba11d375e75f3da275f43f7d95b00898b6b623a8cd834005ec44e9328fd3232dd9f
|
7
|
+
data.tar.gz: b72dc888959e1fb54a048f800ceac07c8dfee1eaf799ea7e1d549abf8336ea7db0cc150d2501aa7bc9b3a446a268cc292908e910df5bc9fa362e7e5451997530
|
data/.gitignore
CHANGED
@@ -1,10 +1,11 @@
|
|
1
1
|
require 'rbconfig'
|
2
2
|
|
3
|
-
# Fake out Rubinius::
|
3
|
+
# Fake out Rubinius::ToolSets for bootstrapping
|
4
4
|
module Rubinius
|
5
|
-
module
|
5
|
+
module ToolSets
|
6
6
|
def self.current
|
7
7
|
@current ||= Module.new
|
8
|
+
@current.const_set :ToolSet, @current
|
8
9
|
end
|
9
10
|
end
|
10
11
|
end
|
@@ -13,14 +14,21 @@ require File.expand_path("../../../../lib/rubinius/melbourne/version", __FILE__)
|
|
13
14
|
|
14
15
|
path = File.expand_path "../namespace.h", __FILE__
|
15
16
|
File.open path, "wb" do |f|
|
16
|
-
version = Rubinius::
|
17
|
+
version = Rubinius::ToolSets.current::ToolSet::Melbourne::VERSION
|
18
|
+
|
19
|
+
if ENV["MELBOURNE_SPEC_VERSION"]
|
20
|
+
# Alter the version to not match any possible loaded version
|
21
|
+
version = version.split(".").map { |x| x + 1 }.join(".")
|
22
|
+
end
|
23
|
+
|
17
24
|
melbourne = "melbourne_#{version.gsub(/\./, "_")}"
|
25
|
+
|
18
26
|
f.puts "#define MELBOURNE #{melbourne}"
|
19
27
|
f.puts "#define MELBOURNE_FILE_TO_AST #{melbourne}_file_to_ast"
|
20
28
|
f.puts "#define MELBOURNE_STRING_TO_AST #{melbourne}_string_to_ast"
|
21
29
|
end
|
22
30
|
|
23
|
-
unless File.
|
31
|
+
unless File.exist? "Makefile" and
|
24
32
|
File.mtime("Makefile") > File.mtime(__FILE__)
|
25
33
|
cxx = ENV["CXX"] || RbConfig::CONFIG["CXX"] || "g++"
|
26
34
|
cxxflags = "#{ENV["CXXFLAGS"] || ENV["CPPFLAGS"] ||
|
@@ -37,7 +45,7 @@ unless File.exists? "Makefile" and
|
|
37
45
|
archincdirs = []
|
38
46
|
incdirs.each do |x|
|
39
47
|
dir = "#{x}/#{RbConfig::CONFIG["arch"]}"
|
40
|
-
archincdirs << dir if File.
|
48
|
+
archincdirs << dir if File.exist? dir
|
41
49
|
end
|
42
50
|
incdirs.concat archincdirs
|
43
51
|
|
@@ -101,7 +109,7 @@ unless File.exists? "Makefile" and
|
|
101
109
|
dldflags = ENV["LDFLAGS"] || RbConfig::CONFIG["LDFLAGS"] || ""
|
102
110
|
dldflags += " #{RbConfig::CONFIG["DLDFLAGS"]}"
|
103
111
|
libpath = "-L. -L#{RbConfig::CONFIG["libdir"]}"
|
104
|
-
libs = RbConfig::CONFIG["LIBS"]
|
112
|
+
libs = "#{RbConfig::CONFIG["LIBS"]} #{RbConfig::CONFIG["LIBRUBYARG_SHARED"]}"
|
105
113
|
install_path = Dir.pwd.sub %r[/ext/rubinius/melbourne$], "/lib/rubinius/melbourne"
|
106
114
|
|
107
115
|
File.open "Makefile", "wb" do |f|
|
@@ -37,7 +37,7 @@ VALUE MELBOURNE_FILE_TO_AST(VALUE self, VALUE fname, VALUE start) {
|
|
37
37
|
}
|
38
38
|
|
39
39
|
void Init_melbourne(void) {
|
40
|
-
VALUE rb_cMelbourne,
|
40
|
+
VALUE rb_cMelbourne, rb_mToolSets, rb_mToolSet;
|
41
41
|
|
42
42
|
MELBOURNE::init_symbols();
|
43
43
|
|
@@ -45,10 +45,9 @@ void Init_melbourne(void) {
|
|
45
45
|
VALUE rb_mRubinius = rb_const_get(rb_cObject, rb_intern("Rubinius"));
|
46
46
|
#endif
|
47
47
|
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
rb_cMelbourne = rb_define_class_under(rb_mTS, "Melbourne", rb_cObject);
|
48
|
+
rb_mToolSets = rb_const_get(rb_mRubinius, rb_intern("ToolSets"));
|
49
|
+
rb_mToolSet = rb_funcall(rb_mToolSets, rb_intern("current"), 0);
|
50
|
+
rb_cMelbourne = rb_define_class_under(rb_mToolSet, "Melbourne", rb_cObject);
|
52
51
|
rb_define_method(rb_cMelbourne, "string_to_ast",
|
53
52
|
RUBY_METHOD_FUNC(MELBOURNE_STRING_TO_AST), 3);
|
54
53
|
rb_define_method(rb_cMelbourne, "file_to_ast",
|
data/lib/rubinius/melbourne.rb
CHANGED
@@ -3,7 +3,7 @@ require "rubinius/melbourne/version"
|
|
3
3
|
|
4
4
|
class String
|
5
5
|
def to_ast(name="(eval)", line=1)
|
6
|
-
Rubinius::
|
6
|
+
Rubinius::ToolSets.get(:runtime)::Melbourne.parse_string self, name, line
|
7
7
|
end
|
8
8
|
|
9
9
|
def to_sexp(name="(eval)", line=1)
|
@@ -13,7 +13,7 @@ end
|
|
13
13
|
|
14
14
|
class File
|
15
15
|
def self.to_ast(name, line=1)
|
16
|
-
Rubinius::
|
16
|
+
Rubinius::ToolSets.get(:runtime)::Melbourne.parse_file name, line
|
17
17
|
end
|
18
18
|
|
19
19
|
def self.to_sexp(name, line=1)
|
@@ -21,7 +21,7 @@ class File
|
|
21
21
|
end
|
22
22
|
end
|
23
23
|
|
24
|
-
module Rubinius::
|
24
|
+
module Rubinius::ToolSets.current::ToolSet
|
25
25
|
class Melbourne
|
26
26
|
attr_accessor :transforms
|
27
27
|
attr_accessor :magic_handler
|
@@ -74,7 +74,7 @@ module Rubinius::ToolSet.current::TS
|
|
74
74
|
end
|
75
75
|
|
76
76
|
def parse_file
|
77
|
-
unless @name and File.
|
77
|
+
unless @name and File.exist? @name
|
78
78
|
raise Errno::ENOENT, @name.inspect
|
79
79
|
end
|
80
80
|
|
data/rubinius-melbourne.gemspec
CHANGED
@@ -16,9 +16,9 @@ Gem::Specification.new do |gem|
|
|
16
16
|
gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
|
17
17
|
gem.name = "rubinius-melbourne"
|
18
18
|
gem.require_paths = ["lib"]
|
19
|
-
gem.version = Rubinius::
|
19
|
+
gem.version = Rubinius::ToolSets.current::ToolSet::Melbourne::VERSION
|
20
20
|
|
21
|
-
gem.add_runtime_dependency "rubinius-toolset"
|
21
|
+
gem.add_runtime_dependency "rubinius-toolset", "~> 2.0"
|
22
22
|
|
23
23
|
gem.add_development_dependency "mspec", "~> 1.5"
|
24
24
|
gem.add_development_dependency "rake", "~> 10.0"
|
metadata
CHANGED
@@ -1,57 +1,57 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rubinius-melbourne
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.0
|
4
|
+
version: 1.1.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Brian Shirai
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2014-03-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rubinius-toolset
|
15
|
-
|
15
|
+
version_requirements: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- -
|
17
|
+
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: '0'
|
20
|
-
|
21
|
-
prerelease: false
|
22
|
-
version_requirements: !ruby/object:Gem::Requirement
|
19
|
+
version: '2.0'
|
20
|
+
requirement: !ruby/object:Gem::Requirement
|
23
21
|
requirements:
|
24
|
-
- -
|
22
|
+
- - "~>"
|
25
23
|
- !ruby/object:Gem::Version
|
26
|
-
version: '0'
|
24
|
+
version: '2.0'
|
25
|
+
prerelease: false
|
26
|
+
type: :runtime
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: mspec
|
29
|
-
|
29
|
+
version_requirements: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- - ~>
|
31
|
+
- - "~>"
|
32
32
|
- !ruby/object:Gem::Version
|
33
33
|
version: '1.5'
|
34
|
-
|
35
|
-
prerelease: false
|
36
|
-
version_requirements: !ruby/object:Gem::Requirement
|
34
|
+
requirement: !ruby/object:Gem::Requirement
|
37
35
|
requirements:
|
38
|
-
- - ~>
|
36
|
+
- - "~>"
|
39
37
|
- !ruby/object:Gem::Version
|
40
38
|
version: '1.5'
|
39
|
+
prerelease: false
|
40
|
+
type: :development
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: rake
|
43
|
-
|
43
|
+
version_requirements: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
|
-
- - ~>
|
45
|
+
- - "~>"
|
46
46
|
- !ruby/object:Gem::Version
|
47
47
|
version: '10.0'
|
48
|
-
|
49
|
-
prerelease: false
|
50
|
-
version_requirements: !ruby/object:Gem::Requirement
|
48
|
+
requirement: !ruby/object:Gem::Requirement
|
51
49
|
requirements:
|
52
|
-
- - ~>
|
50
|
+
- - "~>"
|
53
51
|
- !ruby/object:Gem::Version
|
54
52
|
version: '10.0'
|
53
|
+
prerelease: false
|
54
|
+
type: :development
|
55
55
|
description: Ruby parser extracted from MRI.
|
56
56
|
email:
|
57
57
|
- brixen@gmail.com
|
@@ -60,7 +60,7 @@ extensions:
|
|
60
60
|
- ext/rubinius/melbourne/extconf.rb
|
61
61
|
extra_rdoc_files: []
|
62
62
|
files:
|
63
|
-
- .gitignore
|
63
|
+
- ".gitignore"
|
64
64
|
- Gemfile
|
65
65
|
- LICENSE
|
66
66
|
- README.md
|
@@ -102,18 +102,19 @@ require_paths:
|
|
102
102
|
- lib
|
103
103
|
required_ruby_version: !ruby/object:Gem::Requirement
|
104
104
|
requirements:
|
105
|
-
- -
|
105
|
+
- - ">="
|
106
106
|
- !ruby/object:Gem::Version
|
107
107
|
version: '0'
|
108
108
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
109
109
|
requirements:
|
110
|
-
- -
|
110
|
+
- - ">="
|
111
111
|
- !ruby/object:Gem::Version
|
112
112
|
version: '0'
|
113
113
|
requirements: []
|
114
114
|
rubyforge_project:
|
115
|
-
rubygems_version: 2.
|
115
|
+
rubygems_version: 2.2.2
|
116
116
|
signing_key:
|
117
117
|
specification_version: 4
|
118
118
|
summary: Rubinius Ruby Parser.
|
119
119
|
test_files: []
|
120
|
+
has_rdoc:
|