myco 0.1.8 → 0.1.9

Sign up to get free protection for your applications and to get access to all the features.
Files changed (89) hide show
  1. checksums.yaml +4 -4
  2. data/lib/myco/bootstrap/instance.rb +13 -3
  3. data/lib/myco/code_tools/AST.my +0 -2
  4. data/lib/myco/code_tools/AST.my.rb +0 -1
  5. data/lib/myco/code_tools/AST/Block.my +15 -4
  6. data/lib/myco/code_tools/AST/Block.my.rb +16 -3
  7. data/lib/myco/code_tools/AST/DeclareMeme.my +44 -64
  8. data/lib/myco/code_tools/AST/DeclareMeme.my.rb +66 -74
  9. data/lib/myco/code_tools/AST/ToRuby.my +17 -20
  10. data/lib/myco/code_tools/AST/ToRuby.my.rb +24 -22
  11. data/lib/myco/code_tools/Parser.my +2 -1
  12. data/lib/myco/code_tools/Parser.my.rb +2 -1
  13. data/lib/myco/code_tools/parser/MycoBuilder.my +2 -2
  14. data/lib/myco/code_tools/parser/MycoBuilder.my.rb +2 -2
  15. data/lib/myco/code_tools/parser/MycoGrammar.my +28 -21
  16. data/lib/myco/code_tools/parser/MycoGrammar.my.rb +94 -56
  17. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces.my +10 -11
  18. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces.my.rb +10 -9
  19. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/BytecodeHelpers.my +25 -3
  20. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/BytecodeHelpers.my.rb +38 -0
  21. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Capture.my +152 -0
  22. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Capture.my.rb +189 -0
  23. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Common.my +84 -0
  24. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Common.my.rb +114 -0
  25. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Common/Parser.my +139 -0
  26. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/{BytecodeParser.my.rb → Common/Parser.my.rb} +17 -36
  27. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Composite.my +229 -0
  28. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Composite.my.rb +296 -0
  29. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Grammar.my +8 -25
  30. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Grammar.my.rb +9 -37
  31. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Parser.my +139 -37
  32. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Parser.my.rb +206 -36
  33. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Processor.my +21 -12
  34. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Processor.my.rb +45 -24
  35. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Stream.my +99 -0
  36. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Stream.my.rb +152 -0
  37. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Stream/Parser.my +37 -0
  38. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Stream/Parser.my.rb +57 -0
  39. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/String.my +136 -0
  40. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/String.my.rb +147 -0
  41. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/String/Parser.my +45 -0
  42. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/String/Parser.my.rb +85 -0
  43. data/lib/myco/code_tools/parser/pegleromyces/spec/Patterns.test.my +31 -25
  44. data/lib/myco/code_tools/parser/pegleromyces/spec/Patterns.test.my.rb +44 -25
  45. data/lib/myco/code_tools/parser/pegleromyces/spec/Stream/Parser.test.my +49 -0
  46. data/lib/myco/code_tools/parser/pegleromyces/spec/Stream/Parser.test.my.rb +119 -0
  47. data/lib/myco/code_tools/parser/pegleromyces/spec/Stream/Patterns.test.my +131 -0
  48. data/lib/myco/code_tools/parser/pegleromyces/spec/Stream/Patterns.test.my.rb +595 -0
  49. data/lib/myco/code_tools/parser/pegleromyces/spec/{BytecodeParser.test.my → String/Parser.test.my} +41 -2
  50. data/lib/myco/code_tools/parser/pegleromyces/spec/{BytecodeParser.test.my.rb → String/Parser.test.my.rb} +144 -3
  51. data/lib/myco/code_tools/parser/pegleromyces/spec/run.my +4 -10
  52. data/lib/myco/code_tools/parser/pegleromyces/spec/run.my.rb +4 -8
  53. data/lib/myco/core.my +1 -0
  54. data/lib/myco/core.my.rb +1 -0
  55. data/lib/myco/core/BasicObject.my +4 -2
  56. data/lib/myco/core/BasicObject.my.rb +2 -5
  57. data/lib/myco/core/Loop.my +5 -0
  58. data/lib/myco/core/Loop.my.rb +13 -0
  59. data/lib/myco/dev.rb +1 -0
  60. data/lib/myco/dev/profile.rb +12 -0
  61. data/lib/myco/version.rb +3 -3
  62. metadata +54 -59
  63. data/lib/myco/code_tools/AST/DeclareDecorator.my +0 -19
  64. data/lib/myco/code_tools/AST/DeclareDecorator.my.rb +0 -24
  65. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Builder.my +0 -4
  66. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Builder.my.rb +0 -5
  67. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/BytecodeInstructions.my +0 -420
  68. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/BytecodeInstructions.my.rb +0 -415
  69. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/BytecodeParser.my +0 -147
  70. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Constructions.my +0 -183
  71. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Constructions.my.rb +0 -370
  72. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Instructions.my +0 -139
  73. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Instructions.my.rb +0 -284
  74. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Machine.my +0 -37
  75. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Machine.my.rb +0 -24
  76. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Patterns.my +0 -123
  77. data/lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Patterns.my.rb +0 -164
  78. data/lib/myco/code_tools/parser/pegleromyces/spec/Builder.test.my +0 -10
  79. data/lib/myco/code_tools/parser/pegleromyces/spec/Builder.test.my.rb +0 -9
  80. data/lib/myco/code_tools/parser/pegleromyces/spec/BytecodeInstructions.test.my +0 -10
  81. data/lib/myco/code_tools/parser/pegleromyces/spec/BytecodeInstructions.test.my.rb +0 -9
  82. data/lib/myco/code_tools/parser/pegleromyces/spec/Constructions.test.my +0 -229
  83. data/lib/myco/code_tools/parser/pegleromyces/spec/Constructions.test.my.rb +0 -663
  84. data/lib/myco/code_tools/parser/pegleromyces/spec/Instructions.test.my +0 -10
  85. data/lib/myco/code_tools/parser/pegleromyces/spec/Instructions.test.my.rb +0 -9
  86. data/lib/myco/code_tools/parser/pegleromyces/spec/Machine.test.my +0 -13
  87. data/lib/myco/code_tools/parser/pegleromyces/spec/Machine.test.my.rb +0 -20
  88. data/lib/myco/code_tools/parser/pegleromyces/spec/Parser.test.my +0 -54
  89. data/lib/myco/code_tools/parser/pegleromyces/spec/Parser.test.my.rb +0 -215
@@ -1,8 +1,8 @@
1
1
 
2
2
  BasicSpec {
3
- name: "BytecodeParser"
3
+ name: "String::Parser"
4
4
 
5
- new_parser: BytecodeParser { }
5
+ new_parser: String::Parser.new
6
6
 
7
7
  [tests]
8
8
 
@@ -46,6 +46,29 @@ BasicSpec {
46
46
  assert_equal(state.end_idx, 3)
47
47
  }
48
48
 
49
+ it "exposes captures in the reduction environment": {
50
+ parser = new_parser
51
+ parser.grammar = Grammar {
52
+ [rules]
53
+ rule root: abc[:root]
54
+
55
+ rule a: str('a')[:a]
56
+ rule b: str('b')[:b]
57
+ rule c: str('c')[:c]
58
+
59
+ rule abc: r(a+b+c) {[
60
+ captures.keys
61
+ [captures[:a],captures[:b],captures[:c]]
62
+ [a,b,c]
63
+ ]}
64
+ }
65
+ state = parser.parse('abc')
66
+ assert(state.end_idx)
67
+ assert_equal(state.result[:root][0], [:a,:b,:c])
68
+ assert_equal(state.result[:root][1], ["a","b","c"])
69
+ assert_equal(state.result[:root][2], ["a","b","c"])
70
+ }
71
+
49
72
  it "skips memoized rule calls without result corruption": {
50
73
  parser = new_parser
51
74
  parser.grammar = Grammar {
@@ -78,4 +101,20 @@ BasicSpec {
78
101
  state = parser.parse('xyz')
79
102
  assert_equal(state.result.fetch(:root), [:x, :y, :z])
80
103
  }
104
+
105
+ it "can tokenize matches using a custom tokenizer function": {
106
+ parser = new_parser
107
+ parser.grammar = Grammar {
108
+ tokenizer: &|type, source, start, stop| {
109
+ token = [type, source.slice(start, stop - start)]
110
+ }
111
+ character: any.token(:char)
112
+ [rules]
113
+ rule root: (r(character.+[:clist]) { clist })[:root]
114
+ }
115
+ state = parser.parse('xyz')
116
+ assert_equal(state.result.fetch(:root), [
117
+ [:char, "x"], [:char, "y"], [:char, "z"]
118
+ ])
119
+ }
81
120
  }
@@ -2,9 +2,8 @@
2
2
  ::Myco::Component.new([::Myco::FileToplevel], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
3
3
  .tap { |__c__| __c__.__last__ = __c__.component_eval {(::Myco::Component.new([::Myco.find_constant(:BasicSpec)], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
4
4
  .tap { |__c__| __c__.__last__ = __c__.component_eval {(
5
- declare_meme(:name, [], nil, ::Myco.cscope.dup) { |*| ("BytecodeParser")}
6
- declare_meme(:new_parser, [], nil, ::Myco.cscope.dup) { |*| (::Myco::Component.new([::Myco.find_constant(:BytecodeParser)], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
7
- .tap { |__c__| __c__.__last__ = __c__.component_eval {nil}}.instance)}
5
+ declare_meme(:name, [], nil, ::Myco.cscope.dup) { |*| ("String::Parser")}
6
+ declare_meme(:new_parser, [], nil, ::Myco.cscope.dup) { |*| (::Myco.find_constant(:String)::Parser.new)}
8
7
  __category__(:tests).component_eval {(
9
8
  declare_meme(:"can match from a tiny grammar", [[:it, []]], nil, ::Myco.cscope.dup) { |*| (
10
9
  parser = self.new_parser
@@ -97,6 +96,103 @@
97
96
  3
98
97
  )
99
98
  )}
99
+ declare_meme(:"exposes captures in the reduction environment", [[:it, []]], nil, ::Myco.cscope.dup) { |*| (
100
+ parser = self.new_parser
101
+ parser.__send__(
102
+ :grammar=,
103
+ ::Myco::Component.new([::Myco.find_constant(:Grammar)], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
104
+ .tap { |__c__| __c__.__last__ = __c__.component_eval {(__category__(:rules).component_eval {(
105
+ declare_meme(:root, [[:rule, []]], nil, ::Myco.cscope.dup) { |*| (self.abc.__send__(
106
+ :[],
107
+ :root
108
+ ))}
109
+ declare_meme(:a, [[:rule, []]], nil, ::Myco.cscope.dup) { |*| (self.str("a").__send__(
110
+ :[],
111
+ :a
112
+ ))}
113
+ declare_meme(:b, [[:rule, []]], nil, ::Myco.cscope.dup) { |*| (self.str("b").__send__(
114
+ :[],
115
+ :b
116
+ ))}
117
+ declare_meme(:c, [[:rule, []]], nil, ::Myco.cscope.dup) { |*| (self.str("c").__send__(
118
+ :[],
119
+ :c
120
+ ))}
121
+ declare_meme(:abc, [[:rule, []]], nil, ::Myco.cscope.dup) { |*| (self.r(self.a.__send__(
122
+ :+,
123
+ self.b
124
+ ).__send__(
125
+ :+,
126
+ self.c
127
+ )) { || ([
128
+ self.captures.keys,
129
+ [
130
+ self.captures.__send__(
131
+ :[],
132
+ :a
133
+ ),
134
+ self.captures.__send__(
135
+ :[],
136
+ :b
137
+ ),
138
+ self.captures.__send__(
139
+ :[],
140
+ :c
141
+ )
142
+ ],
143
+ [
144
+ self.a,
145
+ self.b,
146
+ self.c
147
+ ]
148
+ ])})}
149
+ )})}}.instance
150
+ )
151
+ state = parser.parse("abc")
152
+ self.assert(state.end_idx)
153
+ self.assert_equal(
154
+ state.result.__send__(
155
+ :[],
156
+ :root
157
+ ).__send__(
158
+ :[],
159
+ 0
160
+ ),
161
+ [
162
+ :a,
163
+ :b,
164
+ :c
165
+ ]
166
+ )
167
+ self.assert_equal(
168
+ state.result.__send__(
169
+ :[],
170
+ :root
171
+ ).__send__(
172
+ :[],
173
+ 1
174
+ ),
175
+ [
176
+ "a",
177
+ "b",
178
+ "c"
179
+ ]
180
+ )
181
+ self.assert_equal(
182
+ state.result.__send__(
183
+ :[],
184
+ :root
185
+ ).__send__(
186
+ :[],
187
+ 2
188
+ ),
189
+ [
190
+ "a",
191
+ "b",
192
+ "c"
193
+ ]
194
+ )
195
+ )}
100
196
  declare_meme(:"skips memoized rule calls without result corruption", [[:it, []]], nil, ::Myco.cscope.dup) { |*| (
101
197
  parser = self.new_parser
102
198
  parser.__send__(
@@ -205,5 +301,50 @@
205
301
  ]
206
302
  )
207
303
  )}
304
+ declare_meme(:"can tokenize matches using a custom tokenizer function", [[:it, []]], nil, ::Myco.cscope.dup) { |*| (
305
+ parser = self.new_parser
306
+ parser.__send__(
307
+ :grammar=,
308
+ ::Myco::Component.new([::Myco.find_constant(:Grammar)], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
309
+ .tap { |__c__| __c__.__last__ = __c__.component_eval {(
310
+ declare_meme(:tokenizer, [], nil, ::Myco.cscope.dup) { |*| (::Object::Proc.new { |type, source, start, stop| (token = [
311
+ type,
312
+ source.slice(
313
+ start,
314
+ stop.__send__(
315
+ :-,
316
+ start
317
+ )
318
+ )
319
+ ])})}
320
+ declare_meme(:character, [], nil, ::Myco.cscope.dup) { |*| (self.any.token(:char))}
321
+ __category__(:rules).component_eval {(declare_meme(:root, [[:rule, []]], nil, ::Myco.cscope.dup) { |*| (self.r(self.character.__send__(:+).__send__(
322
+ :[],
323
+ :clist
324
+ )) { || (self.clist)}.__send__(
325
+ :[],
326
+ :root
327
+ ))})}
328
+ )}}.instance
329
+ )
330
+ state = parser.parse("xyz")
331
+ self.assert_equal(
332
+ state.result.fetch(:root),
333
+ [
334
+ [
335
+ :char,
336
+ "x"
337
+ ],
338
+ [
339
+ :char,
340
+ "y"
341
+ ],
342
+ [
343
+ :char,
344
+ "z"
345
+ ]
346
+ ]
347
+ )
348
+ )}
208
349
  )}
209
350
  )}}.instance)}}.instance
@@ -5,16 +5,10 @@ import '../lib/pegleromyces.my'
5
5
 
6
6
 
7
7
  import 'Patterns.test.my'
8
- import 'Constructions.test.my'
9
-
10
- import 'Instructions.test.my'
11
- import 'Machine.test.my'
12
-
13
- import 'Processor.test.my'
14
- import 'Builder.test.my'
15
8
 
16
9
  import 'Grammar.test.my'
17
- import 'Parser.test.my'
18
10
 
19
- import 'BytecodeInstructions.test.my'
20
- import 'BytecodeParser.test.my'
11
+ import 'String/Parser.test.my'
12
+ import 'Stream/Parser.test.my'
13
+ import 'Stream/Patterns.test.my'
14
+ import 'Processor.test.my'
@@ -4,13 +4,9 @@
4
4
  declare_meme(:"BasicSpec.my", [[:import, []]], nil, ::Myco.cscope.dup) { |*| nil}
5
5
  declare_meme(:"../lib/pegleromyces.my", [[:import, []]], nil, ::Myco.cscope.dup) { |*| nil}
6
6
  declare_meme(:"Patterns.test.my", [[:import, []]], nil, ::Myco.cscope.dup) { |*| nil}
7
- declare_meme(:"Constructions.test.my", [[:import, []]], nil, ::Myco.cscope.dup) { |*| nil}
8
- declare_meme(:"Instructions.test.my", [[:import, []]], nil, ::Myco.cscope.dup) { |*| nil}
9
- declare_meme(:"Machine.test.my", [[:import, []]], nil, ::Myco.cscope.dup) { |*| nil}
10
- declare_meme(:"Processor.test.my", [[:import, []]], nil, ::Myco.cscope.dup) { |*| nil}
11
- declare_meme(:"Builder.test.my", [[:import, []]], nil, ::Myco.cscope.dup) { |*| nil}
12
7
  declare_meme(:"Grammar.test.my", [[:import, []]], nil, ::Myco.cscope.dup) { |*| nil}
13
- declare_meme(:"Parser.test.my", [[:import, []]], nil, ::Myco.cscope.dup) { |*| nil}
14
- declare_meme(:"BytecodeInstructions.test.my", [[:import, []]], nil, ::Myco.cscope.dup) { |*| nil}
15
- declare_meme(:"BytecodeParser.test.my", [[:import, []]], nil, ::Myco.cscope.dup) { |*| nil}
8
+ declare_meme(:"String/Parser.test.my", [[:import, []]], nil, ::Myco.cscope.dup) { |*| nil}
9
+ declare_meme(:"Stream/Parser.test.my", [[:import, []]], nil, ::Myco.cscope.dup) { |*| nil}
10
+ declare_meme(:"Stream/Patterns.test.my", [[:import, []]], nil, ::Myco.cscope.dup) { |*| nil}
11
+ declare_meme(:"Processor.test.my", [[:import, []]], nil, ::Myco.cscope.dup) { |*| nil}
16
12
  )}}.instance
@@ -2,3 +2,4 @@
2
2
  import "core/Object.my"
3
3
  import "core/Switch.my"
4
4
  import "core/Ruby.my"
5
+ import "core/Loop.my"
@@ -4,4 +4,5 @@
4
4
  declare_meme(:"core/Object.my", [[:import, []]], nil, ::Myco.cscope.dup) { |*| nil}
5
5
  declare_meme(:"core/Switch.my", [[:import, []]], nil, ::Myco.cscope.dup) { |*| nil}
6
6
  declare_meme(:"core/Ruby.my", [[:import, []]], nil, ::Myco.cscope.dup) { |*| nil}
7
+ declare_meme(:"core/Loop.my", [[:import, []]], nil, ::Myco.cscope.dup) { |*| nil}
7
8
  )}}.instance
@@ -41,8 +41,10 @@
41
41
  # alias(::Ruby::Kernel, :raise) raise
42
42
  # alias(::Ruby::Kernel, :loop) loop
43
43
  raise: |*args| ::Ruby.__send__(:raise, *args)
44
- loop: |&block| ::Ruby.__send__(:loop, &block)
45
- break: raise(::Ruby::StopIteration)
44
+
45
+ # TODO remove deprecated aliases after 0.1.9 is released
46
+ loop: |&block| Loop.run(&block)
47
+ break: Loop.break
46
48
 
47
49
  send: |*args, &block| __send__(*args, &block)
48
50
 
@@ -30,11 +30,8 @@
30
30
  :raise,
31
31
  *args
32
32
  ))}
33
- declare_meme(:loop, [], nil, ::Myco.cscope.dup) { |&block| (::Object.__send__(
34
- :loop,
35
- &block
36
- ))}
37
- declare_meme(:break, [], nil, ::Myco.cscope.dup) { |*| (self.raise(::Object::StopIteration))}
33
+ declare_meme(:loop, [], nil, ::Myco.cscope.dup) { |&block| (::Myco.find_constant(:Loop).run(&block))}
34
+ declare_meme(:break, [], nil, ::Myco.cscope.dup) { |*| (::Myco.find_constant(:Loop).__send__(:break))}
38
35
  declare_meme(:send, [], nil, ::Myco.cscope.dup) { |*args, &block| (self.__send__(
39
36
  *args,
40
37
  &block
@@ -0,0 +1,5 @@
1
+
2
+ ::Myco::Loop: ::Myco::BasicObject {
3
+ run: |&block| ::Ruby.__send__(:loop, &block)
4
+ break: ::Ruby.__send__(:raise, ::Ruby::StopIteration)
5
+ }
@@ -0,0 +1,13 @@
1
+
2
+ ::Myco::Component.new([::Myco::FileToplevel], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
3
+ .tap { |__c__| __c__.__last__ = __c__.component_eval {(::Myco::Loop = (::Myco::Component.new([::Myco::BasicObject], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
4
+ .tap { |__c__| __c__.__last__ = __c__.component_eval {(
5
+ declare_meme(:run, [], nil, ::Myco.cscope.dup) { |&block| (::Object.__send__(
6
+ :loop,
7
+ &block
8
+ ))}
9
+ declare_meme(:break, [], nil, ::Myco.cscope.dup) { |*| (::Object.__send__(
10
+ :raise,
11
+ ::Object::StopIteration
12
+ ))}
13
+ )}}.instance))}}.instance
@@ -1,3 +1,4 @@
1
1
 
2
+ require_relative 'dev/profile'
2
3
  require_relative 'dev/counter'
3
4
  require_relative 'dev/call_sites'
@@ -0,0 +1,12 @@
1
+
2
+ module Myco
3
+ module DEV
4
+ def self.profile(show=true, &block)
5
+ require 'rubinius/profiler'
6
+ prof = Rubinius::Profiler::Instrumenter.new
7
+ prof.profile &block
8
+ prof.show if show
9
+ prof
10
+ end
11
+ end
12
+ end
@@ -1,10 +1,10 @@
1
1
 
2
2
  module Myco
3
- MYCO_VERSION = '0.1.8'
3
+ MYCO_VERSION = '0.1.9'
4
4
 
5
5
  MYCO_REQUIRED_GEMS = [
6
- ['rubinius-toolset', '~> 2.3'],
7
- ['rubinius-compiler', '~> 2.2'],
6
+ ['rubinius-toolset', '~> 2.3'],
7
+ ['rubinius-compiler', '~> 2.2'],
8
8
  ]
9
9
 
10
10
  # TODO: move elsewhere?
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: myco
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.8
4
+ version: 0.1.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Joe McIlvain
@@ -11,117 +11,117 @@ cert_chain: []
11
11
  date: 2015-05-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
- version_requirements: !ruby/object:Gem::Requirement
15
- requirements:
16
- - - "~>"
17
- - !ruby/object:Gem::Version
18
- version: '2.3'
19
- name: rubinius-toolset
20
14
  type: :runtime
15
+ name: rubinius-toolset
21
16
  prerelease: false
22
17
  requirement: !ruby/object:Gem::Requirement
23
18
  requirements:
24
19
  - - "~>"
25
20
  - !ruby/object:Gem::Version
26
21
  version: '2.3'
27
- - !ruby/object:Gem::Dependency
28
22
  version_requirements: !ruby/object:Gem::Requirement
29
23
  requirements:
30
24
  - - "~>"
31
25
  - !ruby/object:Gem::Version
32
- version: '2.2'
33
- name: rubinius-compiler
26
+ version: '2.3'
27
+ - !ruby/object:Gem::Dependency
34
28
  type: :runtime
29
+ name: rubinius-compiler
35
30
  prerelease: false
36
31
  requirement: !ruby/object:Gem::Requirement
37
32
  requirements:
38
33
  - - "~>"
39
34
  - !ruby/object:Gem::Version
40
35
  version: '2.2'
41
- - !ruby/object:Gem::Dependency
42
36
  version_requirements: !ruby/object:Gem::Requirement
43
37
  requirements:
44
38
  - - "~>"
45
39
  - !ruby/object:Gem::Version
46
- version: '1.6'
47
- name: bundler
40
+ version: '2.2'
41
+ - !ruby/object:Gem::Dependency
48
42
  type: :development
43
+ name: bundler
49
44
  prerelease: false
50
45
  requirement: !ruby/object:Gem::Requirement
51
46
  requirements:
52
47
  - - "~>"
53
48
  - !ruby/object:Gem::Version
54
49
  version: '1.6'
55
- - !ruby/object:Gem::Dependency
56
50
  version_requirements: !ruby/object:Gem::Requirement
57
51
  requirements:
58
52
  - - "~>"
59
53
  - !ruby/object:Gem::Version
60
- version: '10.3'
61
- name: rake
54
+ version: '1.6'
55
+ - !ruby/object:Gem::Dependency
62
56
  type: :development
57
+ name: rake
63
58
  prerelease: false
64
59
  requirement: !ruby/object:Gem::Requirement
65
60
  requirements:
66
61
  - - "~>"
67
62
  - !ruby/object:Gem::Version
68
63
  version: '10.3'
69
- - !ruby/object:Gem::Dependency
70
64
  version_requirements: !ruby/object:Gem::Requirement
71
65
  requirements:
72
66
  - - "~>"
73
67
  - !ruby/object:Gem::Version
74
- version: '0.9'
75
- name: pry
68
+ version: '10.3'
69
+ - !ruby/object:Gem::Dependency
76
70
  type: :development
71
+ name: pry
77
72
  prerelease: false
78
73
  requirement: !ruby/object:Gem::Requirement
79
74
  requirements:
80
75
  - - "~>"
81
76
  - !ruby/object:Gem::Version
82
77
  version: '0.9'
83
- - !ruby/object:Gem::Dependency
84
78
  version_requirements: !ruby/object:Gem::Requirement
85
79
  requirements:
86
80
  - - "~>"
87
81
  - !ruby/object:Gem::Version
88
- version: '1.4'
89
- name: pry-rescue
82
+ version: '0.9'
83
+ - !ruby/object:Gem::Dependency
90
84
  type: :development
85
+ name: pry-rescue
91
86
  prerelease: false
92
87
  requirement: !ruby/object:Gem::Requirement
93
88
  requirements:
94
89
  - - "~>"
95
90
  - !ruby/object:Gem::Version
96
91
  version: '1.4'
97
- - !ruby/object:Gem::Dependency
98
92
  version_requirements: !ruby/object:Gem::Requirement
99
93
  requirements:
100
94
  - - "~>"
101
95
  - !ruby/object:Gem::Version
102
- version: '3.0'
103
- name: rspec
96
+ version: '1.4'
97
+ - !ruby/object:Gem::Dependency
104
98
  type: :development
99
+ name: rspec
105
100
  prerelease: false
106
101
  requirement: !ruby/object:Gem::Requirement
107
102
  requirements:
108
103
  - - "~>"
109
104
  - !ruby/object:Gem::Version
110
105
  version: '3.0'
111
- - !ruby/object:Gem::Dependency
112
106
  version_requirements: !ruby/object:Gem::Requirement
113
107
  requirements:
114
108
  - - "~>"
115
109
  - !ruby/object:Gem::Version
116
- version: '1.3'
117
- name: fivemat
110
+ version: '3.0'
111
+ - !ruby/object:Gem::Dependency
118
112
  type: :development
113
+ name: fivemat
119
114
  prerelease: false
120
115
  requirement: !ruby/object:Gem::Requirement
121
116
  requirements:
122
117
  - - "~>"
123
118
  - !ruby/object:Gem::Version
124
119
  version: '1.3'
120
+ version_requirements: !ruby/object:Gem::Requirement
121
+ requirements:
122
+ - - "~>"
123
+ - !ruby/object:Gem::Version
124
+ version: '1.3'
125
125
  description: An experimental language on the Rubinius VM
126
126
  email: joe.eli.mac@gmail.com
127
127
  executables:
@@ -173,8 +173,6 @@ files:
173
173
  - lib/myco/code_tools/AST/ConstantDefine.my.rb
174
174
  - lib/myco/code_tools/AST/DeclareCategory.my
175
175
  - lib/myco/code_tools/AST/DeclareCategory.my.rb
176
- - lib/myco/code_tools/AST/DeclareDecorator.my
177
- - lib/myco/code_tools/AST/DeclareDecorator.my.rb
178
176
  - lib/myco/code_tools/AST/DeclareExtension.my
179
177
  - lib/myco/code_tools/AST/DeclareExtension.my.rb
180
178
  - lib/myco/code_tools/AST/DeclareFile.my
@@ -249,50 +247,44 @@ files:
249
247
  - lib/myco/code_tools/parser/MycoTokens.my.rb
250
248
  - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces.my
251
249
  - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces.my.rb
252
- - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Builder.my
253
- - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Builder.my.rb
254
250
  - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/BytecodeHelpers.my
255
251
  - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/BytecodeHelpers.my.rb
256
- - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/BytecodeInstructions.my
257
- - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/BytecodeInstructions.my.rb
258
- - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/BytecodeParser.my
259
- - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/BytecodeParser.my.rb
260
- - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Constructions.my
261
- - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Constructions.my.rb
252
+ - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Capture.my
253
+ - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Capture.my.rb
254
+ - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Common.my
255
+ - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Common.my.rb
256
+ - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Common/Parser.my
257
+ - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Common/Parser.my.rb
258
+ - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Composite.my
259
+ - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Composite.my.rb
262
260
  - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Grammar.my
263
261
  - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Grammar.my.rb
264
- - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Instructions.my
265
- - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Instructions.my.rb
266
- - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Machine.my
267
- - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Machine.my.rb
268
262
  - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Parser.my
269
263
  - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Parser.my.rb
270
- - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Patterns.my
271
- - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Patterns.my.rb
272
264
  - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Processor.my
273
265
  - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Processor.my.rb
266
+ - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Stream.my
267
+ - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Stream.my.rb
268
+ - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Stream/Parser.my
269
+ - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/Stream/Parser.my.rb
270
+ - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/String.my
271
+ - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/String.my.rb
272
+ - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/String/Parser.my
273
+ - lib/myco/code_tools/parser/pegleromyces/lib/pegleromyces/String/Parser.my.rb
274
274
  - lib/myco/code_tools/parser/pegleromyces/spec/BasicSpec.my
275
275
  - lib/myco/code_tools/parser/pegleromyces/spec/BasicSpec.my.rb
276
- - lib/myco/code_tools/parser/pegleromyces/spec/Builder.test.my
277
- - lib/myco/code_tools/parser/pegleromyces/spec/Builder.test.my.rb
278
- - lib/myco/code_tools/parser/pegleromyces/spec/BytecodeInstructions.test.my
279
- - lib/myco/code_tools/parser/pegleromyces/spec/BytecodeInstructions.test.my.rb
280
- - lib/myco/code_tools/parser/pegleromyces/spec/BytecodeParser.test.my
281
- - lib/myco/code_tools/parser/pegleromyces/spec/BytecodeParser.test.my.rb
282
- - lib/myco/code_tools/parser/pegleromyces/spec/Constructions.test.my
283
- - lib/myco/code_tools/parser/pegleromyces/spec/Constructions.test.my.rb
284
276
  - lib/myco/code_tools/parser/pegleromyces/spec/Grammar.test.my
285
277
  - lib/myco/code_tools/parser/pegleromyces/spec/Grammar.test.my.rb
286
- - lib/myco/code_tools/parser/pegleromyces/spec/Instructions.test.my
287
- - lib/myco/code_tools/parser/pegleromyces/spec/Instructions.test.my.rb
288
- - lib/myco/code_tools/parser/pegleromyces/spec/Machine.test.my
289
- - lib/myco/code_tools/parser/pegleromyces/spec/Machine.test.my.rb
290
- - lib/myco/code_tools/parser/pegleromyces/spec/Parser.test.my
291
- - lib/myco/code_tools/parser/pegleromyces/spec/Parser.test.my.rb
292
278
  - lib/myco/code_tools/parser/pegleromyces/spec/Patterns.test.my
293
279
  - lib/myco/code_tools/parser/pegleromyces/spec/Patterns.test.my.rb
294
280
  - lib/myco/code_tools/parser/pegleromyces/spec/Processor.test.my
295
281
  - lib/myco/code_tools/parser/pegleromyces/spec/Processor.test.my.rb
282
+ - lib/myco/code_tools/parser/pegleromyces/spec/Stream/Parser.test.my
283
+ - lib/myco/code_tools/parser/pegleromyces/spec/Stream/Parser.test.my.rb
284
+ - lib/myco/code_tools/parser/pegleromyces/spec/Stream/Patterns.test.my
285
+ - lib/myco/code_tools/parser/pegleromyces/spec/Stream/Patterns.test.my.rb
286
+ - lib/myco/code_tools/parser/pegleromyces/spec/String/Parser.test.my
287
+ - lib/myco/code_tools/parser/pegleromyces/spec/String/Parser.test.my.rb
296
288
  - lib/myco/code_tools/parser/pegleromyces/spec/run.my
297
289
  - lib/myco/code_tools/parser/pegleromyces/spec/run.my.rb
298
290
  - lib/myco/command.my
@@ -311,6 +303,8 @@ files:
311
303
  - lib/myco/core/Decorator.my.rb
312
304
  - lib/myco/core/FileToplevel.my
313
305
  - lib/myco/core/FileToplevel.my.rb
306
+ - lib/myco/core/Loop.my
307
+ - lib/myco/core/Loop.my.rb
314
308
  - lib/myco/core/Object.my
315
309
  - lib/myco/core/Object.my.rb
316
310
  - lib/myco/core/Ruby.my
@@ -320,6 +314,7 @@ files:
320
314
  - lib/myco/dev.rb
321
315
  - lib/myco/dev/call_sites.rb
322
316
  - lib/myco/dev/counter.rb
317
+ - lib/myco/dev/profile.rb
323
318
  - lib/myco/eval.rb
324
319
  - lib/myco/misc.rb
325
320
  - lib/myco/tools/BasicCommand.my
@@ -347,7 +342,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
347
342
  version: '0'
348
343
  requirements: []
349
344
  rubyforge_project:
350
- rubygems_version: 2.4.6
345
+ rubygems_version: 2.4.8
351
346
  signing_key:
352
347
  specification_version: 4
353
348
  summary: An experimental language on the Rubinius VM