language-ruby 0.5.0 → 0.5.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/bin/publish +19 -0
- data/language-ruby.gemspec +2 -3
- data/lib/code/object/list.rb +7 -0
- data/lib/language/atom.rb +0 -1
- data/lib/template/version.rb +1 -1
- data/spec/code/list_spec.rb +2 -0
- metadata +5 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: fbcabd97a0c1b082163275a40c722149ddb952b07040f317323e709c2dc16ece
|
4
|
+
data.tar.gz: 181ba7ec09d0776375c536bbf0ee1b8790233fb739e9760970519190b611ba2f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 44dcd09119cae37706897743ffcbf32ee591b424bd18f00fbb68d769fac350dcd89a8734c0c3606697293b0c29ff097d43a27f23c51c01163fba9228a8513a6d
|
7
|
+
data.tar.gz: 33ddd0fbf8a42a2cb69dc3ecbe63301d51b329ac646de70c2699ab4bddfeae9ebd0e1c283ecdd024719cac010017e325e16c41e448a51d621a9ace037f905e7a
|
data/bin/publish
ADDED
data/language-ruby.gemspec
CHANGED
@@ -3,9 +3,8 @@ require_relative "lib/template/version"
|
|
3
3
|
Gem::Specification.new do |s|
|
4
4
|
s.name = "language-ruby"
|
5
5
|
s.version = ::Template::Version
|
6
|
-
s.summary = "A Parsing Expression Grammar (PEG)"
|
7
|
-
s.description =
|
8
|
-
'A Parsing Expression Grammar (PEG) for making parsers'
|
6
|
+
s.summary = "A Parsing Expression Grammar (PEG) for making parsers"
|
7
|
+
s.description = s.summary
|
9
8
|
s.authors = ["Dorian Marié"]
|
10
9
|
s.email = "dorian@dorianmarie.fr"
|
11
10
|
s.files = `git ls-files`.split($/)
|
data/lib/code/object/list.rb
CHANGED
@@ -55,6 +55,9 @@ class Code
|
|
55
55
|
elsif operator == "<<"
|
56
56
|
sig(arguments) { ::Code::Object }
|
57
57
|
append(value)
|
58
|
+
elsif operator == "include?"
|
59
|
+
sig(arguments) { ::Code::Object }
|
60
|
+
include?(value)
|
58
61
|
else
|
59
62
|
super
|
60
63
|
end
|
@@ -180,6 +183,10 @@ class Code
|
|
180
183
|
self
|
181
184
|
end
|
182
185
|
|
186
|
+
def include?(other)
|
187
|
+
::Code::Object::Boolean.new(raw.include?(other))
|
188
|
+
end
|
189
|
+
|
183
190
|
def first
|
184
191
|
raw.first || ::Code::Object::Nothing.new
|
185
192
|
end
|
data/lib/language/atom.rb
CHANGED
data/lib/template/version.rb
CHANGED
data/spec/code/list_spec.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: language-ruby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.5.
|
4
|
+
version: 0.5.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dorian Marié
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2023-01-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: zeitwerk
|
@@ -43,6 +43,7 @@ files:
|
|
43
43
|
- TODO
|
44
44
|
- bin/code
|
45
45
|
- bin/format
|
46
|
+
- bin/publish
|
46
47
|
- bin/template
|
47
48
|
- bin/test
|
48
49
|
- code-ruby.gemspec
|
@@ -234,10 +235,10 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
234
235
|
- !ruby/object:Gem::Version
|
235
236
|
version: '0'
|
236
237
|
requirements: []
|
237
|
-
rubygems_version: 3.3.
|
238
|
+
rubygems_version: 3.3.26
|
238
239
|
signing_key:
|
239
240
|
specification_version: 4
|
240
|
-
summary: A Parsing Expression Grammar (PEG)
|
241
|
+
summary: A Parsing Expression Grammar (PEG) for making parsers
|
241
242
|
test_files:
|
242
243
|
- spec/code/addition_spec.rb
|
243
244
|
- spec/code/and_operator_spec.rb
|