myco 0.1.2 → 0.1.3

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: bc50c42ea202118c68b826111198d91b40615181
4
- data.tar.gz: 3a7b9505f106be896c06b78e8398bfa6bff9c89a
3
+ metadata.gz: df9a55b04c78564fb8a8f10e94d72c7136fc2bde
4
+ data.tar.gz: 6073c4691d0c8d869435b52fc9ccee1f78093bd7
5
5
  SHA512:
6
- metadata.gz: 13d8580696387328fbe7ff490a8005d5f6112bcd0854f9a2d887be015b7d436141f3c86f57ad3d51818e560000696adffc374f0c0aa48dd0d534105b47606d63
7
- data.tar.gz: 1b8a255e325b29af1be99af379ef2d7788576734a2521f1f9f1f5cea3ec972511a26506a41bcccf27cd41f95d6c04bea2ce44ff1dbae89b1c299665149bc1db8
6
+ metadata.gz: 2276b5f604d73476740c3a8357e3ac7a759bbaa71606da9d778a11274550233c59e8cb92a1d47ed362565e56e73a0daffafb053f3ad3320dd5a8b24c095989dc
7
+ data.tar.gz: 5c68645cf8199d1f6eb86d9f861ed6fb2812caafaceb1b8b3469cdefb3c91c7205c58eafb3d661a9049cf252034e2bf591e901a602d54b84e0e9977df029441f
@@ -1,18 +1,9 @@
1
- ::Myco::Component.new([
2
- ::Myco::FileToplevel
3
- ], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
1
+
2
+ ::Myco::Component.new([::Myco::FileToplevel], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
4
3
  .tap { |__c__| __c__.__last__ = __c__.component_eval {(
5
- ::Myco::RubyEval = ::Myco::Component.new([
6
- ::Myco.find_constant(:EmptyObject)
7
- ], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
8
- .tap { |__c__| __c__.__last__ = __c__.component_eval {(
9
- declare_meme(:from_string, [], nil, ::Myco.cscope.dup) { |string| (
10
- ::Kernel.instance_method(:eval).bind(self).call(string)
11
- )}
12
- )}}
4
+ ::Myco::RubyEval = ::Myco::Component.new([::Myco.find_constant(:EmptyObject)], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
5
+ .tap { |__c__| __c__.__last__ = __c__.component_eval {(declare_meme(:from_string, [], nil, ::Myco.cscope.dup) { |string| (::Kernel.instance_method(:eval).bind(self).call(string))})}}
13
6
  .tap { |__c__| __c__.__name__ = :RubyEval }
14
- ::Myco::Component.new([
15
- ::Myco.find_constant(:RubyEval)
16
- ], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
7
+ ::Myco::Component.new([::Myco.find_constant(:RubyEval)], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
17
8
  .tap { |__c__| __c__.__last__ = __c__.component_eval {nil}}.instance.from_string(" Myco.eval_file(\"core/Category.my\", [Myco::CoreLoadPath])\n Myco.eval_file(\"core/BasicDecorators.my\", [Myco::CoreLoadPath])\n Myco.eval_file(\"core/BasicObject.my\", [Myco::CoreLoadPath])\n Myco.eval_file(\"core/Decorator.my\", [Myco::CoreLoadPath])\n Myco.eval_file(\"core/Object.my\", [Myco::CoreLoadPath])\n Myco.eval_file(\"core/FileToplevel.my\", [Myco::CoreLoadPath])\n \n # Below are not necessary for bootstrapping; TODO: move out of RubyEval\n Myco.eval_file(\"core/Switch.my\", [Myco::CoreLoadPath])\n")
18
- )}}.instance
9
+ )}}.instance
@@ -1,23 +1,14 @@
1
- ::Myco::Component.new([
2
- ::Myco::FileToplevel
3
- ], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
1
+
2
+ ::Myco::Component.new([::Myco::FileToplevel], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
4
3
  .tap { |__c__| __c__.__last__ = __c__.component_eval {(
5
- declare_meme(:"../tools/BasicCommand.my", [
6
- [:import, []]
7
- ], nil, ::Myco.cscope.dup) { |*| nil}
8
- ::Myco::Component.new([
9
- ::Myco.find_constant(:BasicCommand)
10
- ], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
4
+ declare_meme(:"../tools/BasicCommand.my", [[:import, []]], nil, ::Myco.cscope.dup) { |*| nil}
5
+ ::Myco::Component.new([::Myco.find_constant(:BasicCommand)], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
11
6
  .tap { |__c__| __c__.__last__ = __c__.component_eval {(
12
- declare_meme(:banner, [], nil, ::Myco.cscope.dup) { |*| (
13
- "Usage: myco inoculate [options]"
14
- )}
15
- declare_meme(:shell, [], nil, ::Myco.cscope.dup) { |*a, &b| (
16
- ::Myco.find_constant(:Kernel).instance_method(:system).bind(self).call(
17
- *a,
18
- &b
19
- )
20
- )}
7
+ declare_meme(:banner, [], nil, ::Myco.cscope.dup) { |*| ("Usage: myco inoculate [options]")}
8
+ declare_meme(:shell, [], nil, ::Myco.cscope.dup) { |*a, &b| (::Myco.find_constant(:Kernel).instance_method(:system).bind(self).call(
9
+ *a,
10
+ &b
11
+ ))}
21
12
  declare_meme(:run, [], nil, ::Myco.cscope.dup) { |*argv| (
22
13
  destinations = self.options_parse(*argv)
23
14
  ::Myco.branch_op(:"??", ::Myco.branch_op(:"|?", destinations.size.__send__(
@@ -82,121 +73,79 @@
82
73
  )}
83
74
  )}}
84
75
  )}
85
- declare_meme(:run_operation, [], nil, ::Myco.cscope.dup) { |opcode, source_list| (
86
- source_list.each { |source| (
87
- dest = self.transforms.send(
88
- opcode,
89
- source
76
+ declare_meme(:run_operation, [], nil, ::Myco.cscope.dup) { |opcode, source_list| (source_list.each { |source| (
77
+ dest = self.transforms.send(
78
+ opcode,
79
+ source
80
+ )
81
+ self.__send__(
82
+ :unless,
83
+ self.operation_is_unnecessary(
84
+ source,
85
+ dest
90
86
  )
87
+ ) { || (
91
88
  self.__send__(
92
- :unless,
93
- self.operation_is_unnecessary(
94
- source,
95
- dest
96
- )
89
+ :if,
90
+ self.config.verbose
97
91
  ) { || (
98
- self.__send__(
99
- :if,
100
- self.config.verbose
101
- ) { || (
102
- self.puts("#{opcode.upcase} #{source}")
103
- self.puts(" => #{dest}")
104
- )}
105
- self.operations.send(
106
- opcode,
107
- source,
108
- dest
109
- )
92
+ self.puts("#{opcode.upcase} #{source}")
93
+ self.puts(" => #{dest}")
110
94
  )}
95
+ self.operations.send(
96
+ opcode,
97
+ source,
98
+ dest
99
+ )
111
100
  )}
112
- )}
113
- declare_meme(:operation_is_unnecessary, [], nil, ::Myco.cscope.dup) { |source, dest| (
114
- ::Myco.branch_op(:"&&", ::Myco.find_constant(:File).__send__(
115
- :file?,
116
- dest
117
- )) {::Myco.find_constant(:File).mtime(dest).__send__(
118
- :>=,
119
- ::Myco.find_constant(:File).mtime(source)
120
- )}
121
- )}
122
- declare_meme(:files, [], nil, ::Myco.cscope.dup) { |prefix, glob| (
123
- ::Myco.find_constant(:Dir).glob(::Myco.branch_op(:"??", ::Myco.branch_op(:"&?", prefix) {::Myco.find_constant(:File).join(
124
- prefix,
125
- glob
126
- )}) {glob})
127
- )}
101
+ )})}
102
+ declare_meme(:operation_is_unnecessary, [], nil, ::Myco.cscope.dup) { |source, dest| (::Myco.branch_op(:"&&", ::Myco.find_constant(:File).__send__(
103
+ :file?,
104
+ dest
105
+ )) {::Myco.find_constant(:File).mtime(dest).__send__(
106
+ :>=,
107
+ ::Myco.find_constant(:File).mtime(source)
108
+ )})}
109
+ declare_meme(:files, [], nil, ::Myco.cscope.dup) { |prefix, glob| (::Myco.find_constant(:Dir).glob(::Myco.branch_op(:"??", ::Myco.branch_op(:"&?", prefix) {::Myco.find_constant(:File).join(
110
+ prefix,
111
+ glob
112
+ )}) {glob}))}
128
113
  __category__(:operations).component_eval {(
129
- declare_meme(:copy, [], nil, ::Myco.cscope.dup) { |source, dest| (
130
- self.shell("mkdir -p #{::Myco.find_constant(:File).dirname(dest)} && cp #{source} #{dest}")
131
- )}
132
- declare_meme(:myrb, [], nil, ::Myco.cscope.dup) { |source, dest| (
133
- ::Myco.find_constant(:Myco)::CodeLoader::MycoLoader.new(source).__send__(:emit_rb!)
134
- )}
114
+ declare_meme(:copy, [], nil, ::Myco.cscope.dup) { |source, dest| (self.shell("mkdir -p #{::Myco.find_constant(:File).dirname(dest)} && cp #{source} #{dest}"))}
115
+ declare_meme(:myrb, [], nil, ::Myco.cscope.dup) { |source, dest| (::Myco.find_constant(:Myco)::CodeLoader::MycoLoader.new(source).__send__(:emit_rb!))}
135
116
  )}
136
117
  __category__(:transforms).component_eval {(
137
- declare_meme(:copy, [], nil, ::Myco.cscope.dup) { |filename| (
138
- ::Myco.find_constant(:File).join(
139
- self.config.dest,
140
- filename
141
- )
142
- )}
143
- declare_meme(:myrb, [], nil, ::Myco.cscope.dup) { |filename| (
144
- "#{filename}.rb"
145
- )}
118
+ declare_meme(:copy, [], nil, ::Myco.cscope.dup) { |filename| (::Myco.find_constant(:File).join(
119
+ self.config.dest,
120
+ filename
121
+ ))}
122
+ declare_meme(:myrb, [], nil, ::Myco.cscope.dup) { |filename| ("#{filename}.rb")}
146
123
  )}
147
124
  __category__(:config).component_eval {(
148
- declare_meme(:source, [
149
- [:var, []]
150
- ], nil, ::Myco.cscope.dup) { |*| nil}
151
- declare_meme(:dest, [
152
- [:var, []]
153
- ], nil, ::Myco.cscope.dup) { |*| nil}
154
- declare_meme(:verbose, [
155
- [:var, []]
156
- ], nil, ::Myco.cscope.dup) { |*| nil}
125
+ declare_meme(:source, [[:var, []]], nil, ::Myco.cscope.dup) { |*| nil}
126
+ declare_meme(:dest, [[:var, []]], nil, ::Myco.cscope.dup) { |*| nil}
127
+ declare_meme(:verbose, [[:var, []]], nil, ::Myco.cscope.dup) { |*| nil}
157
128
  )}
158
129
  __category__(:options).component_eval {(
159
- declare_meme(:"-d", [], nil, ::Myco.cscope.dup) { |*| (
160
- ::Myco::Component.new([
161
- ::Myco.find_constant(:Option)
162
- ], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
163
- .tap { |__c__| __c__.__last__ = __c__.component_eval {(
164
- declare_meme(:description, [], nil, ::Myco.cscope.dup) { |*| (
165
- "The destination directory to clone material into."
166
- )}
167
- declare_meme(:long_form, [], nil, ::Myco.cscope.dup) { |*| (
168
- "--dest"
169
- )}
170
- declare_meme(:argument, [], nil, ::Myco.cscope.dup) { |*| (
171
- "STRING"
172
- )}
173
- declare_meme(:do, [], nil, ::Myco.cscope.dup) { |arg| (
174
- self.parent.config.__send__(
175
- :dest=,
176
- arg
177
- )
178
- )}
179
- )}}.instance
180
- )}
181
- declare_meme(:"-v", [], nil, ::Myco.cscope.dup) { |*| (
182
- ::Myco::Component.new([
183
- ::Myco.find_constant(:Option)
184
- ], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
185
- .tap { |__c__| __c__.__last__ = __c__.component_eval {(
186
- declare_meme(:description, [], nil, ::Myco.cscope.dup) { |*| (
187
- "Show details about material cloning operations."
188
- )}
189
- declare_meme(:long_form, [], nil, ::Myco.cscope.dup) { |*| (
190
- "--verbose"
191
- )}
192
- declare_meme(:do, [], nil, ::Myco.cscope.dup) { |arg| (
193
- self.parent.config.__send__(
194
- :verbose=,
195
- true
196
- )
197
- )}
198
- )}}.instance
199
- )}
130
+ declare_meme(:"-d", [], nil, ::Myco.cscope.dup) { |*| (::Myco::Component.new([::Myco.find_constant(:Option)], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
131
+ .tap { |__c__| __c__.__last__ = __c__.component_eval {(
132
+ declare_meme(:description, [], nil, ::Myco.cscope.dup) { |*| ("The destination directory to clone material into.")}
133
+ declare_meme(:long_form, [], nil, ::Myco.cscope.dup) { |*| ("--dest")}
134
+ declare_meme(:argument, [], nil, ::Myco.cscope.dup) { |*| ("STRING")}
135
+ declare_meme(:do, [], nil, ::Myco.cscope.dup) { |arg| (self.parent.config.__send__(
136
+ :dest=,
137
+ arg
138
+ ))}
139
+ )}}.instance)}
140
+ declare_meme(:"-v", [], nil, ::Myco.cscope.dup) { |*| (::Myco::Component.new([::Myco.find_constant(:Option)], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
141
+ .tap { |__c__| __c__.__last__ = __c__.component_eval {(
142
+ declare_meme(:description, [], nil, ::Myco.cscope.dup) { |*| ("Show details about material cloning operations.")}
143
+ declare_meme(:long_form, [], nil, ::Myco.cscope.dup) { |*| ("--verbose")}
144
+ declare_meme(:do, [], nil, ::Myco.cscope.dup) { |arg| (self.parent.config.__send__(
145
+ :verbose=,
146
+ true
147
+ ))}
148
+ )}}.instance)}
200
149
  )}
201
150
  )}}.instance
202
- )}}.instance
151
+ )}}.instance
@@ -1,77 +1,34 @@
1
- ::Myco::Component.new([
2
- ::Myco::FileToplevel
3
- ], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
1
+
2
+ ::Myco::Component.new([::Myco::FileToplevel], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
4
3
  .tap { |__c__| __c__.__last__ = __c__.component_eval {(
5
- declare_meme(:"tools/BasicCommand.my", [
6
- [:import, []]
7
- ], nil, ::Myco.cscope.dup) { |*| nil}
8
- ::Myco::Component.new([
9
- ::Myco.find_constant(:BasicCommand)
10
- ], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
4
+ declare_meme(:"tools/BasicCommand.my", [[:import, []]], nil, ::Myco.cscope.dup) { |*| nil}
5
+ ::Myco::Component.new([::Myco.find_constant(:BasicCommand)], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
11
6
  .tap { |__c__| __c__.__last__ = __c__.component_eval {(
12
- declare_meme(:banner, [], nil, ::Myco.cscope.dup) { |*| (
13
- "Usage: myco [subcommand] [options] [files]"
14
- )}
15
- declare_meme(:creation, [
16
- [:on, []]
17
- ], nil, ::Myco.cscope.dup) { |*| (
18
- self.run(*::Myco.find_constant(:ARGV))
19
- )}
7
+ declare_meme(:banner, [], nil, ::Myco.cscope.dup) { |*| ("Usage: myco [subcommand] [options] [files]")}
8
+ declare_meme(:creation, [[:on, []]], nil, ::Myco.cscope.dup) { |*| (self.run(*::Myco.find_constant(:ARGV)))}
20
9
  declare_meme(:run, [], nil, ::Myco.cscope.dup) { |*argv| (
21
10
  files = self.options_parse(*argv)
22
- ::Myco.branch_op(:"&&", files) {files.uniq.each { |file| (
23
- ::Myco.find_constant(:Myco).eval_file(
24
- file,
25
- [
26
- ::Dir.pwd
27
- ]
28
- )
29
- )}}
11
+ ::Myco.branch_op(:"&&", files) {files.uniq.each { |file| (::Myco.find_constant(:Myco).eval_file(
12
+ file,
13
+ [::Dir.pwd]
14
+ ))}}
30
15
  )}
31
16
  __category__(:options).component_eval {(
32
- declare_meme(:"-E", [], nil, ::Myco.cscope.dup) { |*| (
33
- ::Myco::Component.new([
34
- ::Myco.find_constant(:Option)
35
- ], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
36
- .tap { |__c__| __c__.__last__ = __c__.component_eval {(
37
- declare_meme(:description, [], nil, ::Myco.cscope.dup) { |*| (
38
- "Evaluate a string of declarative Myco"
39
- )}
40
- declare_meme(:long_form, [], nil, ::Myco.cscope.dup) { |*| (
41
- "--eval"
42
- )}
43
- declare_meme(:argument, [], nil, ::Myco.cscope.dup) { |*| (
44
- "STRING"
45
- )}
46
- declare_meme(:do, [], nil, ::Myco.cscope.dup) { |arg| (
47
- ::Myco.find_constant(:Myco).eval(arg)
48
- )}
49
- )}}.instance
50
- )}
51
- declare_meme(:"-e", [], nil, ::Myco.cscope.dup) { |*| (
52
- ::Myco::Component.new([
53
- ::Myco.find_constant(:Option)
54
- ], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
55
- .tap { |__c__| __c__.__last__ = __c__.component_eval {(
56
- declare_meme(:description, [], nil, ::Myco.cscope.dup) { |*| (
57
- "Evaluate a string of procedural Myco inside an Object"
58
- )}
59
- declare_meme(:long_form, [], nil, ::Myco.cscope.dup) { |*| (
60
- "--eval-meme"
61
- )}
62
- declare_meme(:argument, [], nil, ::Myco.cscope.dup) { |*| (
63
- "STRING"
64
- )}
65
- declare_meme(:do, [], nil, ::Myco.cscope.dup) { |arg| (
66
- ::Myco.find_constant(:Myco).eval("Object { on creation: { #{arg} } }")
67
- )}
68
- )}}.instance
69
- )}
70
- )}
71
- __category__(:commands).component_eval {(
72
- declare_meme(:inoculate, [], nil, ::Myco.cscope.dup) { |*| (
73
- ::Myco.find_constant(:Myco).eval_file("command/inoculate.my")
74
- )}
17
+ declare_meme(:"-E", [], nil, ::Myco.cscope.dup) { |*| (::Myco::Component.new([::Myco.find_constant(:Option)], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
18
+ .tap { |__c__| __c__.__last__ = __c__.component_eval {(
19
+ declare_meme(:description, [], nil, ::Myco.cscope.dup) { |*| ("Evaluate a string of declarative Myco")}
20
+ declare_meme(:long_form, [], nil, ::Myco.cscope.dup) { |*| ("--eval")}
21
+ declare_meme(:argument, [], nil, ::Myco.cscope.dup) { |*| ("STRING")}
22
+ declare_meme(:do, [], nil, ::Myco.cscope.dup) { |arg| (::Myco.find_constant(:Myco).eval(arg))}
23
+ )}}.instance)}
24
+ declare_meme(:"-e", [], nil, ::Myco.cscope.dup) { |*| (::Myco::Component.new([::Myco.find_constant(:Option)], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
25
+ .tap { |__c__| __c__.__last__ = __c__.component_eval {(
26
+ declare_meme(:description, [], nil, ::Myco.cscope.dup) { |*| ("Evaluate a string of procedural Myco inside an Object")}
27
+ declare_meme(:long_form, [], nil, ::Myco.cscope.dup) { |*| ("--eval-meme")}
28
+ declare_meme(:argument, [], nil, ::Myco.cscope.dup) { |*| ("STRING")}
29
+ declare_meme(:do, [], nil, ::Myco.cscope.dup) { |arg| (::Myco.find_constant(:Myco).eval("Object { on creation: { #{arg} } }"))}
30
+ )}}.instance)}
75
31
  )}
32
+ __category__(:commands).component_eval {(declare_meme(:inoculate, [], nil, ::Myco.cscope.dup) { |*| (::Myco.find_constant(:Myco).eval_file("command/inoculate.my"))})}
76
33
  )}}.instance
77
- )}}.instance
34
+ )}}.instance
@@ -1,129 +1,68 @@
1
- ::Myco::Component.new([
2
- ::Myco::FileToplevel
3
- ], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
4
- .tap { |__c__| __c__.__last__ = __c__.component_eval {(
5
- ::Myco::BasicDecorators = ::Myco::Component.new([
6
- ::Myco::EmptyObject
7
- ], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
1
+
2
+ ::Myco::Component.new([::Myco::FileToplevel], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
3
+ .tap { |__c__| __c__.__last__ = __c__.component_eval {(::Myco::BasicDecorators = ::Myco::Component.new([::Myco::EmptyObject], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
4
+ .tap { |__c__| __c__.__last__ = __c__.component_eval {(__category__(:decorators).component_eval {(
5
+ declare_meme(:storage, [], nil, ::Myco.cscope.dup) { |*| (::Myco::Component.new([::Myco.find_constant(:Decorator)], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
8
6
  .tap { |__c__| __c__.__last__ = __c__.component_eval {(
9
- __category__(:decorators).component_eval {(
10
- declare_meme(:storage, [], nil, ::Myco.cscope.dup) { |*| (
11
- ::Myco::Component.new([
12
- ::Myco.find_constant(:Decorator)
13
- ], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
14
- .tap { |__c__| __c__.__last__ = __c__.component_eval {(
15
- declare_meme(:apply, [], nil, ::Myco.cscope.dup) { |meme| (
16
- meme.target.declare_meme(:"#{meme.name}=") { |new_value, *args| (
17
- meme.set_result_for(
18
- self,
19
- new_value,
20
- *args
21
- )
22
- )}
23
- )}
24
- __category__(:transforms).component_eval {(
25
- declare_meme(:cache, [], nil, ::Myco.cscope.dup) { |*| (
26
- true
27
- )}
28
- )}
29
- )}}.instance
7
+ declare_meme(:apply, [], nil, ::Myco.cscope.dup) { |meme| (meme.target.declare_meme(:"#{meme.name}=") { |new_value, *args| (meme.set_result_for(
8
+ self,
9
+ new_value,
10
+ *args
11
+ ))})}
12
+ __category__(:transforms).component_eval {(declare_meme(:cache, [], nil, ::Myco.cscope.dup) { |*| (true)})}
13
+ )}}.instance)}
14
+ declare_meme(:var, [], nil, ::Myco.cscope.dup) { |*| (::Myco::Component.new([::Myco.find_constant(:Decorator)], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
15
+ .tap { |__c__| __c__.__last__ = __c__.component_eval {(__category__(:transforms).component_eval {(declare_meme(:var, [], nil, ::Myco.cscope.dup) { |*| (true)})})}}.instance)}
16
+ declare_meme(:memoize, [], nil, ::Myco.cscope.dup) { |*| (::Myco::Component.new([::Myco.find_constant(:Decorator)], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
17
+ .tap { |__c__| __c__.__last__ = __c__.component_eval {(__category__(:transforms).component_eval {(declare_meme(:cache, [], nil, ::Myco.cscope.dup) { |*| (true)})})}}.instance)}
18
+ declare_meme(:sclass, [], nil, ::Myco.cscope.dup) { |*| (::Myco::Component.new([::Myco.find_constant(:Decorator)], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
19
+ .tap { |__c__| __c__.__last__ = __c__.component_eval {(__category__(:transforms).component_eval {(declare_meme(:target, [], nil, ::Myco.cscope.dup) { |meme| (meme.target.singleton_class)})})}}.instance)}
20
+ declare_meme(:before, [], nil, ::Myco.cscope.dup) { |*| (::Myco::Component.new([::Myco.find_constant(:Decorator)], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
21
+ .tap { |__c__| __c__.__last__ = __c__.component_eval {(declare_meme(:apply, [], nil, ::Myco.cscope.dup) { |meme| (
22
+ orig_meme = meme.target.memes.__send__(
23
+ :[],
24
+ meme.name
25
+ )
26
+ wrap_meme = meme.dup
27
+ meme.__send__(
28
+ :body=,
29
+ ::Myco.find_constant(:Proc).new { |*a, &b| (
30
+ wrap_meme.result_for(
31
+ self,
32
+ *a,
33
+ &b
34
+ )
35
+ orig_meme.result_for(
36
+ self,
37
+ *a,
38
+ &b
39
+ )
30
40
  )}
31
- declare_meme(:var, [], nil, ::Myco.cscope.dup) { |*| (
32
- ::Myco::Component.new([
33
- ::Myco.find_constant(:Decorator)
34
- ], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
35
- .tap { |__c__| __c__.__last__ = __c__.component_eval {(
36
- __category__(:transforms).component_eval {(
37
- declare_meme(:var, [], nil, ::Myco.cscope.dup) { |*| (
38
- true
39
- )}
40
- )}
41
- )}}.instance
41
+ )
42
+ )})}}.instance)}
43
+ declare_meme(:after, [], nil, ::Myco.cscope.dup) { |*| (::Myco::Component.new([::Myco.find_constant(:Decorator)], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
44
+ .tap { |__c__| __c__.__last__ = __c__.component_eval {(declare_meme(:apply, [], nil, ::Myco.cscope.dup) { |meme| (
45
+ orig_meme = meme.target.memes.__send__(
46
+ :[],
47
+ meme.name
48
+ )
49
+ wrap_meme = meme.dup
50
+ meme.__send__(
51
+ :body=,
52
+ ::Myco.find_constant(:Proc).new { |*a, &b| (
53
+ result = orig_meme.result_for(
54
+ self,
55
+ *a,
56
+ &b
57
+ )
58
+ wrap_meme.result_for(
59
+ self,
60
+ *a,
61
+ &b
62
+ )
63
+ result
42
64
  )}
43
- declare_meme(:memoize, [], nil, ::Myco.cscope.dup) { |*| (
44
- ::Myco::Component.new([
45
- ::Myco.find_constant(:Decorator)
46
- ], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
47
- .tap { |__c__| __c__.__last__ = __c__.component_eval {(
48
- __category__(:transforms).component_eval {(
49
- declare_meme(:cache, [], nil, ::Myco.cscope.dup) { |*| (
50
- true
51
- )}
52
- )}
53
- )}}.instance
54
- )}
55
- declare_meme(:sclass, [], nil, ::Myco.cscope.dup) { |*| (
56
- ::Myco::Component.new([
57
- ::Myco.find_constant(:Decorator)
58
- ], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
59
- .tap { |__c__| __c__.__last__ = __c__.component_eval {(
60
- __category__(:transforms).component_eval {(
61
- declare_meme(:target, [], nil, ::Myco.cscope.dup) { |meme| (
62
- meme.target.singleton_class
63
- )}
64
- )}
65
- )}}.instance
66
- )}
67
- declare_meme(:before, [], nil, ::Myco.cscope.dup) { |*| (
68
- ::Myco::Component.new([
69
- ::Myco.find_constant(:Decorator)
70
- ], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
71
- .tap { |__c__| __c__.__last__ = __c__.component_eval {(
72
- declare_meme(:apply, [], nil, ::Myco.cscope.dup) { |meme| (
73
- orig_meme = meme.target.memes.__send__(
74
- :[],
75
- meme.name
76
- )
77
- wrap_meme = meme.dup
78
- meme.__send__(
79
- :body=,
80
- ::Myco.find_constant(:Proc).new { |*a, &b| (
81
- wrap_meme.result_for(
82
- self,
83
- *a,
84
- &b
85
- )
86
- orig_meme.result_for(
87
- self,
88
- *a,
89
- &b
90
- )
91
- )}
92
- )
93
- )}
94
- )}}.instance
95
- )}
96
- declare_meme(:after, [], nil, ::Myco.cscope.dup) { |*| (
97
- ::Myco::Component.new([
98
- ::Myco.find_constant(:Decorator)
99
- ], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
100
- .tap { |__c__| __c__.__last__ = __c__.component_eval {(
101
- declare_meme(:apply, [], nil, ::Myco.cscope.dup) { |meme| (
102
- orig_meme = meme.target.memes.__send__(
103
- :[],
104
- meme.name
105
- )
106
- wrap_meme = meme.dup
107
- meme.__send__(
108
- :body=,
109
- ::Myco.find_constant(:Proc).new { |*a, &b| (
110
- result = orig_meme.result_for(
111
- self,
112
- *a,
113
- &b
114
- )
115
- wrap_meme.result_for(
116
- self,
117
- *a,
118
- &b
119
- )
120
- result
121
- )}
122
- )
123
- )}
124
- )}}.instance
125
- )}
126
- )}
127
- )}}
128
- .tap { |__c__| __c__.__name__ = :BasicDecorators }
129
- )}}.instance
65
+ )
66
+ )})}}.instance)}
67
+ )})}}
68
+ .tap { |__c__| __c__.__name__ = :BasicDecorators })}}.instance
@@ -1,50 +1,27 @@
1
- ::Myco::Component.new([
2
- ::Myco::FileToplevel
3
- ], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
1
+
2
+ ::Myco::Component.new([::Myco::FileToplevel], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
4
3
  .tap { |__c__| __c__.__last__ = __c__.component_eval {(
5
4
  ::Myco::BasicObject = ::Myco::Component.new([
6
5
  ::Myco::EmptyObject,
7
6
  ::Myco::BasicDecorators
8
7
  ], ::Myco.cscope.for_method_definition, __FILE__, __LINE__)
9
8
  .tap { |__c__| __c__.__last__ = __c__.component_eval {(
10
- declare_meme(:if, [], nil, ::Myco.cscope.dup) { |cond, &blk| (
11
- ::Myco.branch_op(:"&&", cond) {blk.call}
12
- )}
13
- declare_meme(:unless, [], nil, ::Myco.cscope.dup) { |cond, &blk| (
14
- ::Myco.branch_op(:"||", cond) {blk.call}
15
- )}
16
- declare_meme(:switch, [], nil, ::Myco.cscope.dup) { |input, comparator=:==| (
17
- ::Myco.find_constant(:Switch).new({
18
- :input => input,
19
- :comparator => comparator
20
- })
21
- )}
22
- declare_meme(:raise, [], nil, ::Myco.cscope.dup) { |*args| (
23
- ::Kernel.instance_method(:raise).bind(self).call(*args)
24
- )}
25
- declare_meme(:loop, [], nil, ::Myco.cscope.dup) { |&block| (
26
- ::Kernel.instance_method(:loop).bind(self).call(&block)
27
- )}
28
- declare_meme(:break, [], nil, ::Myco.cscope.dup) { |*| (
29
- self.raise(::StopIteration)
30
- )}
31
- declare_meme(:puts, [], nil, ::Myco.cscope.dup) { |*args| (
32
- ::Myco.find_constant(:STDOUT).puts(*args)
33
- )}
34
- declare_meme(:p, [], nil, ::Myco.cscope.dup) { |*args| (
35
- ::Myco.find_constant(:STDOUT).puts(args.map { |a| (
36
- a.inspect
37
- )}.join(", "))
38
- )}
39
- declare_meme(:ruby_require, [], nil, ::Myco.cscope.dup) { |arg| (
40
- ::Myco.find_constant(:Object).send(
41
- :require,
42
- arg
43
- )
44
- )}
9
+ declare_meme(:if, [], nil, ::Myco.cscope.dup) { |cond, &blk| (::Myco.branch_op(:"&&", cond) {blk.call})}
10
+ declare_meme(:unless, [], nil, ::Myco.cscope.dup) { |cond, &blk| (::Myco.branch_op(:"||", cond) {blk.call})}
11
+ declare_meme(:switch, [], nil, ::Myco.cscope.dup) { |input, comparator=:==| (::Myco.find_constant(:Switch).new({
12
+ :input => input,
13
+ :comparator => comparator
14
+ }))}
15
+ declare_meme(:raise, [], nil, ::Myco.cscope.dup) { |*args| (::Kernel.instance_method(:raise).bind(self).call(*args))}
16
+ declare_meme(:loop, [], nil, ::Myco.cscope.dup) { |&block| (::Kernel.instance_method(:loop).bind(self).call(&block))}
17
+ declare_meme(:break, [], nil, ::Myco.cscope.dup) { |*| (self.raise(::StopIteration))}
18
+ declare_meme(:puts, [], nil, ::Myco.cscope.dup) { |*args| (::Myco.find_constant(:STDOUT).puts(*args))}
19
+ declare_meme(:p, [], nil, ::Myco.cscope.dup) { |*args| (::Myco.find_constant(:STDOUT).puts(args.map { |a| (a.inspect)}.join(", ")))}
20
+ declare_meme(:ruby_require, [], nil, ::Myco.cscope.dup) { |arg| (::Myco.find_constant(:Object).send(
21
+ :require,
22
+ arg
23
+ ))}
45
24
  )}}
46
25
  .tap { |__c__| __c__.__name__ = :BasicObject }
47
- ::Myco::Instance::BasicObject = (
48
- ::Myco::BasicObject
49
- )
50
- )}}.instance
26
+ ::Myco::Instance::BasicObject = (::Myco::BasicObject)
27
+ )}}.instance