rubymotionlisp 1.0.14 → 1.0.15

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 5de6ce4210bcf029285a399dcdcbfcbfb9e694b0
4
- data.tar.gz: aa4cf373497533635555b76d401d197dad8ab060
3
+ metadata.gz: 5f4b3c67bd17bef8f796339dc765433d67f2ff36
4
+ data.tar.gz: 6ab82bc4182d5a848b35e08b4e1210429e2a9853
5
5
  SHA512:
6
- metadata.gz: ad066de387e6c61c70e5b27e3022f4690a6673aba8bc42f8323618d2d6b6f7f423fdc8b244973bc06d8528a29e6670ee8544c2b3f6a72f924f39213f081272c8
7
- data.tar.gz: d7b568d0fdbc79539e9dbc91c380a4defd3e5bef226a2433728519c4f1702d77f5d7ead5b6c12d78796717b1f5fae95067cd1d51259c0ac6ebcc00950e552d3d
6
+ metadata.gz: f8ca375acf30e6c696a633b1441c33e1dcd2d68086776265ac6a541fb7e707084610c8f9b72d8eca42118ff5ad5462fcd6b1fe2e57b44417c8086802ab7a6160
7
+ data.tar.gz: aac24396c6730c0ed536ea1ab9a3eb27c88ab4b09ee53d5c98a4ad8be933f9a78bdb7aa274ae5a0d03900755f18bc2f6bbf2e4a7aac8d66d7a65e8875eb1cd01
@@ -226,7 +226,7 @@ module Lisp
226
226
 
227
227
 
228
228
  def push_current_code
229
- env.current_code.unshift(self.print_string)
229
+ env.push_code(self.print_string)
230
230
  end
231
231
 
232
232
 
@@ -247,7 +247,7 @@ module Lisp
247
247
  end
248
248
 
249
249
  result = func.apply_to(@cdr, env)
250
- env.current_code.shift() if !Lisp::Debug.eval_in_debug_repl && Lisp::Debug.interactive
250
+ env.pop_code if !Lisp::Debug.eval_in_debug_repl && Lisp::Debug.interactive
251
251
  Lisp::Debug.log_result(result, env)
252
252
  result
253
253
  end
@@ -35,6 +35,30 @@ module Lisp
35
35
  def has_frame?
36
36
  !@frame.nil?
37
37
  end
38
+
39
+
40
+ # --------------------------------------------------------------------------------
41
+ # Exaling code management
42
+
43
+ def push_code(code)
44
+ @current_code.push(code)
45
+ end
46
+
47
+
48
+ def pop_code
49
+ @current_code.pop
50
+ end
51
+
52
+
53
+ def top_code
54
+ @current_code[-1]
55
+ end
56
+
57
+
58
+ def has_code?
59
+ !@current_code.empty?
60
+ end
61
+
38
62
 
39
63
  # Bindings following parent env frame pointer
40
64
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rubymotionlisp
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.14
4
+ version: 1.0.15
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dave Astels
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-03-13 00:00:00.000000000 Z
11
+ date: 2016-03-27 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: An embeddable Lisp as an extension language for RubyMotion
14
14
  email: dastels@icloud.com