mulang-ruby 1.1.0 → 1.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/lib/mulang/ruby/ast_processor.rb +9 -1
- data/lib/mulang/ruby/sexp.rb +18 -5
- data/lib/mulang/ruby/version.rb +1 -1
- data/mulang-ruby.gemspec +1 -1
- metadata +5 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9ce25f9ddfa919462478020c4996eb79df700ffe92846a351823c330d7e011ed
|
4
|
+
data.tar.gz: 13a07d738b7ff03172b3c52cc2d2c5596fd8e14afac84fc920a6185acd9773ec
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 93ecfa1b6813275b19b0a598725a14df5269c7f5728ac0e77eb665c4fca702ae148f67311bc8c502648bd2f04d3cfad456f09377d98ff0d1e95d87ca7ffc8aa6
|
7
|
+
data.tar.gz: 770b47bd8c440644c8ee7e54b6d8ccaec6dd6ccee562c238cee09e8992061bfb5d6cf99b97e92abb72dc9bd2ba1d5366050487e9c3c10270ef77fe52ce1b2096
|
data/README.md
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
[![Build Status](https://travis-ci.org/mumuki/mulang-ruby.svg)](https://travis-ci.org/mumuki/mulang-ruby)
|
1
|
+
[![Build Status](https://travis-ci.org/mumuki/mulang-ruby.svg?branch=master)](https://travis-ci.org/mumuki/mulang-ruby)
|
2
2
|
[![Code Climate](https://codeclimate.com/github/mumuki/mulang-ruby/badges/gpa.svg)](https://codeclimate.com/github/mumuki/mulang-ruby)
|
3
3
|
[![Test Coverage](https://codeclimate.com/github/mumuki/mulang-ruby/badges/coverage.svg)](https://codeclimate.com/github/mumuki/mulang-ruby)
|
4
4
|
|
@@ -70,7 +70,14 @@ module Mulang::Ruby
|
|
70
70
|
id, args, body = *node
|
71
71
|
body ||= s(:nil)
|
72
72
|
|
73
|
-
|
73
|
+
case id
|
74
|
+
when :equal?, :eql?, :==
|
75
|
+
method :EqualMethod, process_all(args), process(body)
|
76
|
+
when :hash
|
77
|
+
method :HashMethod, process_all(args), process(body)
|
78
|
+
else
|
79
|
+
simple_method id, process_all(args), process(body)
|
80
|
+
end
|
74
81
|
end
|
75
82
|
|
76
83
|
def on_block(node)
|
@@ -174,5 +181,6 @@ module Mulang::Ruby
|
|
174
181
|
|
175
182
|
ms :Send, process(receptor), message, (process_all(args) + extra_args)
|
176
183
|
end
|
184
|
+
|
177
185
|
end
|
178
186
|
end
|
data/lib/mulang/ruby/sexp.rb
CHANGED
@@ -21,11 +21,24 @@ module Mulang::Ruby
|
|
21
21
|
end
|
22
22
|
|
23
23
|
def simple_method(name, args, body)
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
24
|
+
{
|
25
|
+
tag: :Method,
|
26
|
+
contents: [
|
27
|
+
name,
|
28
|
+
[
|
29
|
+
[ args, {tag: :UnguardedBody, contents: body }]
|
30
|
+
]
|
31
|
+
]
|
32
|
+
}
|
33
|
+
end
|
34
|
+
|
35
|
+
def method(tag, args, body)
|
36
|
+
{
|
37
|
+
tag: tag,
|
38
|
+
contents: [
|
39
|
+
[ args, {tag: :UnguardedBody, contents: body }]
|
40
|
+
]
|
41
|
+
}
|
29
42
|
end
|
30
43
|
|
31
44
|
def simple_send(sender, message, args)
|
data/lib/mulang/ruby/version.rb
CHANGED
data/mulang-ruby.gemspec
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mulang-ruby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Franco Leonardo Bulgarelli
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-12-18 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -100,14 +100,14 @@ dependencies:
|
|
100
100
|
requirements:
|
101
101
|
- - "~>"
|
102
102
|
- !ruby/object:Gem::Version
|
103
|
-
version: '3.
|
103
|
+
version: '3.4'
|
104
104
|
type: :runtime
|
105
105
|
prerelease: false
|
106
106
|
version_requirements: !ruby/object:Gem::Requirement
|
107
107
|
requirements:
|
108
108
|
- - "~>"
|
109
109
|
- !ruby/object:Gem::Version
|
110
|
-
version: '3.
|
110
|
+
version: '3.4'
|
111
111
|
description: Ruby - Mulang Parser
|
112
112
|
email:
|
113
113
|
- franco@mumuki.org
|
@@ -153,7 +153,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
153
153
|
version: '0'
|
154
154
|
requirements: []
|
155
155
|
rubyforge_project:
|
156
|
-
rubygems_version: 2.7.
|
156
|
+
rubygems_version: 2.7.3
|
157
157
|
signing_key:
|
158
158
|
specification_version: 4
|
159
159
|
summary: Ruby integration for the Mulang Language Analyzer
|