delorean_lang 0.3.27 → 0.3.28

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 2bfab39c7eb2f5b9b6e1d555a7619fc328bb35ba
4
- data.tar.gz: 500fb6c1f12b2c6720cf44dc364050a8ba000af3
3
+ metadata.gz: f3637427e811009b2113d2b8e37f186c3ce6b959
4
+ data.tar.gz: 35b3e0ed9c5eff4f396010254576ff5d60ad9954
5
5
  SHA512:
6
- metadata.gz: 25fa6a67fa25baa3a5df0cd3490a907d16450d9d99a03569b4183bff6f36c111720ba56d22dc5793ef1ff7877ec2c2170312254a01dcfc70e3c1947c5a361711
7
- data.tar.gz: 31356b5b797cac7920c14e162422f6dcfb89b227ec5fe2b9e66236473418bbcfed3bb610b50fc620a1d32f95886cc9c9db6dcb5ade6641239de7b9a869f65310
6
+ metadata.gz: 0de1a93b5fc187350200eae728b2fc8fec18e5c5dde04b7d3fb4a14bf921c6fc22035452be82fb41bd6e2c5c7a7b3c4424909c6b225a90ade020585ba957f85f
7
+ data.tar.gz: 10ea587d0b3bf5599e88279208a99358a2afc0940bc75fdc5015a1f02c67e3025b7ea592f41e9b9479dec7df2bd785d1ac026995da4e77d2814b36456fa5a347
data/lib/delorean/base.rb CHANGED
@@ -25,6 +25,7 @@ module Delorean
25
25
  member?: [Enumerable, [Object]],
26
26
  empty: "empty?",
27
27
  empty?: [Enumerable],
28
+ except: [Hash, String] + [[nil, String]]*9,
28
29
  reverse: [Array],
29
30
  slice: [Array, Fixnum, Fixnum],
30
31
  each_slice: [Array, Fixnum],
@@ -1,3 +1,3 @@
1
1
  module Delorean
2
- VERSION = "0.3.27"
2
+ VERSION = "0.3.28"
3
3
  end
data/spec/func_spec.rb CHANGED
@@ -191,6 +191,14 @@ describe "Delorean" do
191
191
  engine.evaluate("A", "m").should == 100
192
192
  end
193
193
 
194
+ it "should be able to call hash except" do
195
+ engine.parse defn("A:",
196
+ " h = {'a': 1, 'b':2, 'c': 3}",
197
+ " e = h.except('a', 'c')",
198
+ )
199
+ expect(engine.evaluate("A", "e")).to eq({"b"=>2})
200
+ end
201
+
194
202
  it "should handle RUBY slice function" do
195
203
  x = [[1, 2, [-3]], 4, [5, 6], -3, 4, 5, 0]
196
204
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: delorean_lang
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.27
4
+ version: 0.3.28
5
5
  platform: ruby
6
6
  authors:
7
7
  - Arman Bostani
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-08-17 00:00:00.000000000 Z
11
+ date: 2017-08-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: treetop