puppet 0.16.0 → 0.18.4

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of puppet might be problematic. Click here for more details.

Files changed (185) hide show
  1. data/CHANGELOG +98 -0
  2. data/Rakefile +5 -1
  3. data/bin/puppet +1 -1
  4. data/bin/puppetca +25 -11
  5. data/bin/puppetd +189 -66
  6. data/bin/puppetdoc +79 -62
  7. data/bin/puppetmasterd +93 -49
  8. data/bin/puppetrun +385 -0
  9. data/conf/redhat/client.init +5 -2
  10. data/conf/redhat/fileserver.conf +1 -1
  11. data/conf/redhat/lsb-config.patch +51 -0
  12. data/conf/redhat/puppet.spec +45 -18
  13. data/conf/redhat/puppetd.conf +32 -4
  14. data/conf/redhat/server.init +5 -2
  15. data/conf/solaris/pkginfo +7 -0
  16. data/conf/solaris/smf/puppetd.xml +77 -0
  17. data/conf/solaris/smf/puppetmasterd.xml +77 -0
  18. data/conf/solaris/smf/svc-puppetd +66 -0
  19. data/conf/solaris/smf/svc-puppetmasterd +62 -0
  20. data/examples/code/failers/noobjectrvalue +1 -0
  21. data/examples/code/snippets/deepclassheirarchy.pp +23 -0
  22. data/examples/code/snippets/defineoverrides.pp +17 -0
  23. data/examples/code/snippets/emptyexec.pp +3 -0
  24. data/examples/code/snippets/selectorvalues.pp +6 -1
  25. data/examples/code/snippets/tagged.pp +35 -0
  26. data/ext/ldap/puppet.schema +2 -2
  27. data/install.rb +4 -2
  28. data/lib/puppet.rb +206 -15
  29. data/lib/puppet/client.rb +30 -20
  30. data/lib/puppet/client/ca.rb +2 -2
  31. data/lib/puppet/client/dipper.rb +5 -9
  32. data/lib/puppet/client/master.rb +224 -44
  33. data/lib/puppet/client/pelement.rb +54 -9
  34. data/lib/puppet/client/proxy.rb +3 -2
  35. data/lib/puppet/client/reporter.rb +34 -0
  36. data/lib/puppet/client/runner.rb +17 -0
  37. data/lib/puppet/config.rb +136 -55
  38. data/lib/puppet/daemon.rb +59 -37
  39. data/lib/puppet/element.rb +2 -1
  40. data/lib/puppet/event.rb +14 -3
  41. data/lib/puppet/filetype.rb +28 -19
  42. data/lib/puppet/log.rb +297 -132
  43. data/lib/puppet/metric.rb +31 -131
  44. data/lib/puppet/networkclient.rb +73 -46
  45. data/lib/puppet/parameter.rb +49 -1
  46. data/lib/puppet/parsedfile.rb +32 -12
  47. data/lib/puppet/parser/ast.rb +6 -1
  48. data/lib/puppet/parser/ast/astarray.rb +32 -6
  49. data/lib/puppet/parser/ast/collection.rb +91 -0
  50. data/lib/puppet/parser/ast/compdef.rb +2 -2
  51. data/lib/puppet/parser/ast/component.rb +24 -11
  52. data/lib/puppet/parser/ast/function.rb +50 -0
  53. data/lib/puppet/parser/ast/hostclass.rb +70 -22
  54. data/lib/puppet/parser/ast/node.rb +17 -8
  55. data/lib/puppet/parser/ast/nodedef.rb +1 -1
  56. data/lib/puppet/parser/ast/objectdef.rb +28 -10
  57. data/lib/puppet/parser/ast/selector.rb +4 -1
  58. data/lib/puppet/parser/functions.rb +145 -0
  59. data/lib/puppet/parser/interpreter.rb +243 -86
  60. data/lib/puppet/parser/lexer.rb +5 -4
  61. data/lib/puppet/parser/parser.rb +586 -505
  62. data/lib/puppet/parser/scope.rb +337 -187
  63. data/lib/puppet/rails.rb +115 -0
  64. data/lib/puppet/rails/database.rb +40 -0
  65. data/lib/puppet/rails/host.rb +83 -0
  66. data/lib/puppet/rails/rails_object.rb +42 -0
  67. data/lib/puppet/rails/rails_parameter.rb +5 -0
  68. data/lib/puppet/reports/rrdgraph.rb +20 -0
  69. data/lib/puppet/reports/tagmail.rb +94 -0
  70. data/lib/puppet/server.rb +20 -4
  71. data/lib/puppet/server/authconfig.rb +14 -3
  72. data/lib/puppet/server/authstore.rb +2 -2
  73. data/lib/puppet/server/ca.rb +23 -11
  74. data/lib/puppet/server/filebucket.rb +10 -10
  75. data/lib/puppet/server/fileserver.rb +4 -8
  76. data/lib/puppet/server/master.rb +19 -22
  77. data/lib/puppet/server/pelement.rb +28 -16
  78. data/lib/puppet/server/report.rb +184 -0
  79. data/lib/puppet/server/runner.rb +62 -0
  80. data/lib/puppet/server/servlet.rb +23 -9
  81. data/lib/puppet/sslcertificates/ca.rb +25 -1
  82. data/lib/puppet/statechange.rb +34 -53
  83. data/lib/puppet/storage.rb +1 -2
  84. data/lib/puppet/transaction.rb +305 -133
  85. data/lib/puppet/transaction/report.rb +42 -0
  86. data/lib/puppet/transportable.rb +57 -33
  87. data/lib/puppet/type.rb +260 -127
  88. data/lib/puppet/type/component.rb +9 -21
  89. data/lib/puppet/type/cron.rb +367 -116
  90. data/lib/puppet/type/exec.rb +15 -16
  91. data/lib/puppet/type/group.rb +9 -1
  92. data/lib/puppet/type/nameservice.rb +2 -5
  93. data/lib/puppet/type/nameservice/netinfo.rb +3 -0
  94. data/lib/puppet/type/nameservice/objectadd.rb +23 -10
  95. data/lib/puppet/type/nameservice/pw.rb +16 -3
  96. data/lib/puppet/type/package.rb +25 -75
  97. data/lib/puppet/type/package/apple.rb +15 -1
  98. data/lib/puppet/type/package/apt.rb +37 -2
  99. data/lib/puppet/type/package/blastwave.rb +136 -0
  100. data/lib/puppet/type/package/dpkg.rb +4 -4
  101. data/lib/puppet/type/package/gem.rb +119 -0
  102. data/lib/puppet/type/package/openbsd.rb +7 -6
  103. data/lib/puppet/type/package/ports.rb +7 -2
  104. data/lib/puppet/type/package/rpm.rb +1 -1
  105. data/lib/puppet/type/package/sun.rb +23 -9
  106. data/lib/puppet/type/package/sunfreeware.rb +7 -0
  107. data/lib/puppet/type/package/yum.rb +16 -9
  108. data/lib/puppet/type/parsedtype.rb +7 -5
  109. data/lib/puppet/type/parsedtype/mount.rb +55 -34
  110. data/lib/puppet/type/parsedtype/port.rb +7 -1
  111. data/lib/puppet/type/parsedtype/sshkey.rb +6 -16
  112. data/lib/puppet/type/pfile.rb +115 -23
  113. data/lib/puppet/type/pfile/checksum.rb +18 -5
  114. data/lib/puppet/type/pfile/content.rb +2 -2
  115. data/lib/puppet/type/pfile/ensure.rb +3 -3
  116. data/lib/puppet/type/pfile/group.rb +2 -2
  117. data/lib/puppet/type/pfile/source.rb +28 -17
  118. data/lib/puppet/type/pfile/target.rb +25 -17
  119. data/lib/puppet/type/pfilebucket.rb +25 -6
  120. data/lib/puppet/type/schedule.rb +6 -6
  121. data/lib/puppet/type/service.rb +24 -14
  122. data/lib/puppet/type/service/debian.rb +1 -1
  123. data/lib/puppet/type/service/redhat.rb +13 -10
  124. data/lib/puppet/type/service/smf.rb +3 -3
  125. data/lib/puppet/type/state.rb +1 -2
  126. data/lib/puppet/type/symlink.rb +3 -4
  127. data/lib/puppet/type/user.rb +22 -10
  128. data/lib/puppet/type/yumrepo.rb +6 -1
  129. data/lib/puppet/type/zone.rb +595 -0
  130. data/lib/puppet/util.rb +58 -12
  131. data/test/client/client.rb +2 -2
  132. data/test/client/master.rb +92 -3
  133. data/test/client/pelement.rb +99 -0
  134. data/test/executables/puppetbin.rb +3 -4
  135. data/test/executables/puppetca.rb +3 -3
  136. data/test/executables/puppetd.rb +3 -3
  137. data/test/executables/puppetmasterd.rb +1 -5
  138. data/test/executables/puppetmodule.rb +2 -2
  139. data/test/language/ast.rb +200 -11
  140. data/test/language/functions.rb +245 -0
  141. data/test/language/interpreter.rb +155 -6
  142. data/test/language/lexer.rb +35 -2
  143. data/test/language/node.rb +48 -1
  144. data/test/language/parser.rb +250 -1
  145. data/test/language/rails.rb +105 -0
  146. data/test/language/scope.rb +304 -10
  147. data/test/language/snippets.rb +54 -5
  148. data/test/language/transportable.rb +60 -28
  149. data/test/other/config.rb +214 -1
  150. data/test/other/events.rb +67 -9
  151. data/test/other/log.rb +31 -5
  152. data/test/other/metrics.rb +23 -21
  153. data/test/other/parsedfile.rb +29 -2
  154. data/test/other/puppet.rb +79 -0
  155. data/test/other/report.rb +106 -0
  156. data/test/other/storage.rb +2 -2
  157. data/test/other/transactions.rb +128 -2
  158. data/test/puppet/utiltest.rb +10 -5
  159. data/test/puppettest.rb +193 -21
  160. data/test/server/authstore.rb +13 -4
  161. data/test/server/bucket.rb +33 -8
  162. data/test/server/ca.rb +44 -6
  163. data/test/server/master.rb +6 -7
  164. data/test/server/pelement.rb +15 -5
  165. data/test/server/report.rb +93 -0
  166. data/test/server/runner.rb +107 -0
  167. data/test/server/server.rb +28 -1
  168. data/test/types/cron.rb +339 -31
  169. data/test/types/file.rb +256 -24
  170. data/test/types/filebucket.rb +6 -2
  171. data/test/types/filesources.rb +41 -92
  172. data/test/types/group.rb +31 -1
  173. data/test/types/host.rb +2 -1
  174. data/test/types/mount.rb +18 -1
  175. data/test/types/package.rb +200 -18
  176. data/test/types/service.rb +5 -1
  177. data/test/types/sshkey.rb +2 -1
  178. data/test/types/symlink.rb +3 -2
  179. data/test/types/type.rb +180 -1
  180. data/test/types/user.rb +65 -27
  181. data/test/types/yumrepo.rb +15 -0
  182. data/test/types/zone.rb +437 -0
  183. metadata +43 -4
  184. data/bin/cf2puppet +0 -186
  185. data/conf/redhat/puppetmasterd.conf +0 -5
@@ -34,6 +34,9 @@ module Puppet
34
34
  %r{,} => :COMMA,
35
35
  %r{\.} => :DOT,
36
36
  %r{:} => :COLON,
37
+ %r{@} => :AT,
38
+ %r{<\|} => :LCOLLECT,
39
+ %r{\|>} => :RCOLLECT,
37
40
  %r{;} => :SEMIC,
38
41
  %r{\?} => :QMARK,
39
42
  %r{\\} => :BACKSLASH,
@@ -51,10 +54,8 @@ module Puppet
51
54
  "define" => :DEFINE,
52
55
  "false" => :BOOLEAN,
53
56
  "import" => :IMPORT,
54
- "include" => :INCLUDE,
55
57
  "inherits" => :INHERITS,
56
58
  "node" => :NODE,
57
- "tag" => :TAG,
58
59
  "true" => :BOOLEAN
59
60
  }
60
61
 
@@ -193,9 +194,9 @@ module Puppet
193
194
  #stoken = :DQTEXT
194
195
  #Puppet.debug("got string '%s' => '%s'" % [:DQTEXT,value])
195
196
  else
197
+ #Puppet.debug("got token '%s' => '%s'" % [stoken,value])
196
198
  yield [stoken,value]
197
199
  @last = value
198
- #Puppet.debug("got token '%s' => '%s'" % [stoken,value])
199
200
  end
200
201
  @scanner.skip(@skip)
201
202
  end
@@ -229,4 +230,4 @@ module Puppet
229
230
  end
230
231
  end
231
232
 
232
- # $Id: lexer.rb 1106 2006-04-11 22:32:51Z luke $
233
+ # $Id: lexer.rb 1245 2006-06-08 20:06:41Z luke $
@@ -1,6 +1,6 @@
1
1
  #
2
2
  # DO NOT MODIFY!!!!
3
- # This file is automatically generated by racc 1.4.4
3
+ # This file is automatically generated by racc 1.4.5
4
4
  # from racc grammer file "grammar.ra".
5
5
  #
6
6
 
@@ -29,7 +29,9 @@ module Puppet
29
29
 
30
30
  class Parser < Racc::Parser
31
31
 
32
- module_eval <<'..end grammar.ra modeval..idb478f6db18', 'grammar.ra', 745
32
+ module_eval <<'..end grammar.ra modeval..id99c9ad765d', 'grammar.ra', 787
33
+ require 'puppet/parser/functions'
34
+
33
35
  attr_reader :file
34
36
  attr_accessor :files
35
37
 
@@ -51,7 +53,12 @@ end
51
53
 
52
54
  def file=(file)
53
55
  unless FileTest.exists?(file)
54
- raise Puppet::Error, "Could not find file %s" % file
56
+ unless file =~ /\.pp$/
57
+ file = file + ".pp"
58
+ end
59
+ unless FileTest.exists?(file)
60
+ raise Puppet::Error, "Could not find file %s" % file
61
+ end
55
62
  end
56
63
  if @files.detect { |f| f.file == file }
57
64
  raise Puppet::ImportError.new("Import loop detected")
@@ -148,298 +155,325 @@ end
148
155
  # mode: ruby
149
156
  # End:
150
157
 
151
- # $Id: parser.rb 1106 2006-04-11 22:32:51Z luke $
158
+ # $Id: parser.rb 1418 2006-07-21 19:38:29Z luke $
152
159
 
153
- ..end grammar.ra modeval..idb478f6db18
160
+ ..end grammar.ra modeval..id99c9ad765d
154
161
 
155
- ##### racc 1.4.4 generates ###
162
+ ##### racc 1.4.5 generates ###
156
163
 
157
164
  racc_reduce_table = [
158
165
  0, 0, :racc_error,
159
- 1, 43, :_reduce_1,
166
+ 1, 44, :_reduce_1,
160
167
  1, 44, :_reduce_none,
161
- 2, 44, :_reduce_3,
162
- 1, 45, :_reduce_none,
163
- 1, 45, :_reduce_none,
164
- 1, 45, :_reduce_none,
165
- 1, 45, :_reduce_none,
166
168
  1, 45, :_reduce_none,
167
- 1, 45, :_reduce_none,
168
- 1, 45, :_reduce_none,
169
- 1, 45, :_reduce_none,
170
- 1, 45, :_reduce_none,
171
- 2, 50, :_reduce_13,
172
- 2, 51, :_reduce_14,
173
- 1, 55, :_reduce_none,
174
- 3, 55, :_reduce_16,
175
- 1, 56, :_reduce_none,
176
- 1, 56, :_reduce_none,
177
- 5, 46, :_reduce_19,
178
- 5, 46, :_reduce_20,
179
- 5, 46, :_reduce_21,
180
- 4, 64, :_reduce_22,
169
+ 2, 45, :_reduce_4,
170
+ 1, 47, :_reduce_none,
171
+ 1, 47, :_reduce_none,
172
+ 1, 47, :_reduce_none,
173
+ 1, 47, :_reduce_none,
174
+ 1, 47, :_reduce_none,
175
+ 1, 47, :_reduce_none,
176
+ 1, 47, :_reduce_none,
177
+ 1, 47, :_reduce_none,
178
+ 1, 47, :_reduce_none,
179
+ 1, 47, :_reduce_none,
180
+ 4, 54, :_reduce_15,
181
+ 2, 54, :_reduce_16,
182
+ 1, 58, :_reduce_none,
183
+ 3, 58, :_reduce_18,
181
184
  1, 59, :_reduce_none,
182
- 3, 59, :_reduce_24,
183
- 0, 60, :_reduce_none,
184
- 1, 60, :_reduce_none,
185
- 1, 57, :_reduce_27,
186
- 1, 63, :_reduce_28,
187
- 1, 65, :_reduce_none,
188
- 1, 65, :_reduce_none,
189
- 1, 65, :_reduce_none,
190
- 1, 65, :_reduce_none,
191
- 1, 65, :_reduce_none,
192
- 1, 65, :_reduce_none,
193
- 3, 47, :_reduce_35,
194
- 0, 61, :_reduce_36,
195
- 1, 61, :_reduce_37,
196
- 3, 61, :_reduce_38,
197
- 3, 70, :_reduce_39,
198
- 1, 71, :_reduce_none,
199
- 3, 71, :_reduce_41,
200
- 1, 69, :_reduce_none,
201
- 1, 69, :_reduce_none,
202
- 1, 69, :_reduce_none,
185
+ 1, 59, :_reduce_none,
186
+ 1, 59, :_reduce_none,
187
+ 5, 48, :_reduce_22,
188
+ 5, 48, :_reduce_23,
189
+ 5, 48, :_reduce_24,
190
+ 2, 49, :_reduce_25,
191
+ 3, 50, :_reduce_26,
192
+ 4, 68, :_reduce_27,
193
+ 1, 63, :_reduce_none,
194
+ 3, 63, :_reduce_29,
195
+ 0, 64, :_reduce_none,
196
+ 1, 64, :_reduce_none,
197
+ 1, 60, :_reduce_32,
198
+ 1, 67, :_reduce_33,
203
199
  1, 69, :_reduce_none,
204
200
  1, 69, :_reduce_none,
205
201
  1, 69, :_reduce_none,
206
202
  1, 69, :_reduce_none,
207
203
  1, 69, :_reduce_none,
208
204
  1, 69, :_reduce_none,
209
- 1, 66, :_reduce_51,
210
- 1, 66, :_reduce_52,
211
- 1, 73, :_reduce_53,
212
- 4, 74, :_reduce_54,
213
- 5, 48, :_reduce_55,
214
- 1, 75, :_reduce_none,
215
- 2, 75, :_reduce_57,
216
- 5, 76, :_reduce_58,
217
- 4, 76, :_reduce_59,
218
- 1, 77, :_reduce_none,
219
- 3, 77, :_reduce_61,
220
- 3, 67, :_reduce_62,
205
+ 3, 51, :_reduce_40,
206
+ 0, 65, :_reduce_41,
207
+ 1, 65, :_reduce_42,
208
+ 3, 65, :_reduce_43,
209
+ 3, 73, :_reduce_44,
210
+ 1, 74, :_reduce_none,
211
+ 3, 74, :_reduce_46,
212
+ 1, 72, :_reduce_none,
213
+ 1, 72, :_reduce_none,
214
+ 1, 72, :_reduce_none,
215
+ 1, 72, :_reduce_none,
216
+ 1, 72, :_reduce_none,
217
+ 1, 72, :_reduce_none,
218
+ 1, 72, :_reduce_none,
219
+ 1, 72, :_reduce_none,
220
+ 1, 72, :_reduce_none,
221
+ 4, 78, :_reduce_56,
222
+ 1, 62, :_reduce_57,
223
+ 1, 62, :_reduce_58,
224
+ 1, 76, :_reduce_59,
225
+ 4, 77, :_reduce_60,
226
+ 5, 52, :_reduce_61,
221
227
  1, 79, :_reduce_none,
222
- 3, 79, :_reduce_64,
228
+ 2, 79, :_reduce_63,
229
+ 5, 80, :_reduce_64,
230
+ 4, 80, :_reduce_65,
223
231
  1, 81, :_reduce_none,
224
- 3, 81, :_reduce_66,
225
- 3, 80, :_reduce_67,
226
- 1, 78, :_reduce_68,
227
- 1, 78, :_reduce_69,
228
- 1, 78, :_reduce_none,
229
- 1, 78, :_reduce_none,
230
- 1, 78, :_reduce_72,
231
- 1, 78, :_reduce_none,
232
- 2, 49, :_reduce_74,
233
- 6, 52, :_reduce_75,
234
- 5, 52, :_reduce_76,
235
- 6, 53, :_reduce_77,
236
- 5, 53, :_reduce_78,
237
- 6, 54, :_reduce_79,
238
- 5, 54, :_reduce_80,
239
- 1, 84, :_reduce_none,
240
- 2, 84, :_reduce_82,
241
- 1, 85, :_reduce_83,
242
- 1, 85, :_reduce_84,
243
- 0, 86, :_reduce_85,
232
+ 3, 81, :_reduce_67,
233
+ 3, 70, :_reduce_68,
234
+ 1, 83, :_reduce_none,
235
+ 3, 83, :_reduce_70,
236
+ 1, 85, :_reduce_none,
237
+ 3, 85, :_reduce_72,
238
+ 3, 84, :_reduce_73,
244
239
  1, 82, :_reduce_none,
245
- 3, 82, :_reduce_87,
246
- 3, 82, :_reduce_88,
240
+ 1, 82, :_reduce_none,
241
+ 1, 82, :_reduce_none,
242
+ 1, 82, :_reduce_none,
243
+ 1, 82, :_reduce_none,
244
+ 1, 82, :_reduce_none,
245
+ 1, 82, :_reduce_80,
246
+ 2, 53, :_reduce_81,
247
+ 6, 55, :_reduce_82,
248
+ 5, 55, :_reduce_83,
249
+ 6, 56, :_reduce_84,
250
+ 5, 56, :_reduce_85,
251
+ 6, 57, :_reduce_86,
252
+ 5, 57, :_reduce_87,
253
+ 1, 88, :_reduce_none,
254
+ 3, 88, :_reduce_89,
255
+ 1, 89, :_reduce_90,
256
+ 1, 89, :_reduce_91,
257
+ 1, 89, :_reduce_92,
258
+ 0, 46, :_reduce_93,
259
+ 1, 86, :_reduce_none,
260
+ 3, 86, :_reduce_95,
261
+ 3, 86, :_reduce_96,
262
+ 1, 90, :_reduce_none,
263
+ 3, 90, :_reduce_98,
264
+ 3, 91, :_reduce_99,
265
+ 1, 91, :_reduce_100,
247
266
  1, 87, :_reduce_none,
248
- 3, 87, :_reduce_90,
249
- 3, 88, :_reduce_91,
250
- 1, 88, :_reduce_92,
251
- 1, 83, :_reduce_none,
252
- 2, 83, :_reduce_94,
253
- 1, 58, :_reduce_95,
254
- 3, 68, :_reduce_96,
255
- 1, 72, :_reduce_none,
256
- 1, 72, :_reduce_none,
257
- 0, 62, :_reduce_none,
258
- 1, 62, :_reduce_100 ]
267
+ 2, 87, :_reduce_102,
268
+ 1, 61, :_reduce_103,
269
+ 3, 71, :_reduce_104,
270
+ 2, 71, :_reduce_105,
271
+ 1, 75, :_reduce_none,
272
+ 1, 75, :_reduce_none,
273
+ 0, 66, :_reduce_none,
274
+ 1, 66, :_reduce_109 ]
259
275
 
260
- racc_reduce_n = 101
276
+ racc_reduce_n = 110
261
277
 
262
- racc_shift_n = 166
278
+ racc_shift_n = 181
263
279
 
264
280
  racc_action_table = [
265
- 34, 28, 29, 143, 92, 34, 28, 29, 134, -68,
266
- 34, 28, 29, 87, 133, 34, 28, 29, 102, 57,
267
- 34, 28, 29, 86, 42, 84, 42, 142, 54, 57,
268
- 47, 42, 7, 37, 41, 47, 42, 43, 37, 41,
269
- 47, 42, 43, 37, 41, 47, 42, 43, 37, 41,
270
- 47, 56, 43, 37, 66, 84, -73, 43, 34, 28,
271
- 29, 56, 111, 34, 28, 29, 113, 114, 34, 28,
272
- 29, 120, 80, 34, 28, 29, 26, 42, 34, 28,
273
- 29, 121, 42, 97, 42, 7, 28, 29, 47, 42,
274
- 7, 37, 41, 47, 42, 43, 37, 41, 47, 42,
275
- 43, 37, 41, 47, 42, 43, 37, 41, 47, 92,
276
- 43, 37, 41, 28, 29, 43, 110, 96, 28, 29,
277
- 124, -68, -71, 28, 29, 127, 128, 87, 28, 29,
278
- 7, 131, 132, 28, 29, 96, 81, 157, 42, 113,
279
- 114, 137, 47, 42, 93, 105, 108, 47, 42, 43,
280
- 105, 108, 47, 42, 43, 105, 108, 47, 42, 43,
281
- 105, 108, 47, -69, 43, 105, 108, 28, 29, 43,
282
- 141, 144, 77, -70, 6, 9, 74, 13, 15, 148,
283
- 21, 60, 96, 147, 3, 7, -71, 11, 7, 16,
284
- 19, 54, 42, -70, 91, 158, 47, 49, 48, 105,
285
- 108, 6, 9, 43, 13, 15, 165, 21, 30, 87,
286
- 26, 3, 7, 86, 11, nil, 16, 19, nil, nil,
287
- nil, nil, nil, 150, 6, 9, nil, 13, 15, nil,
288
- 21, nil, nil, nil, 3, 7, nil, 11, nil, 16,
289
- 19, 6, 9, 164, 13, 15, nil, 21, nil, nil,
290
- nil, 3, 7, nil, 11, nil, 16, 19, nil, nil,
291
- 136, 6, 9, nil, 13, 15, nil, 21, nil, nil,
292
- nil, 3, 7, nil, 11, nil, 16, 19, 6, 9,
293
- 154, 13, 15, nil, 21, nil, nil, nil, 3, 7,
294
- nil, 11, nil, 16, 19, nil, nil, 161, 6, 9,
295
- nil, 13, 15, nil, 21, nil, nil, nil, 3, 7,
296
- nil, 11, nil, 16, 19, 6, 9, 160, 13, 15,
297
- nil, 21, nil, nil, nil, 3, 7, nil, 11, nil,
298
- 16, 19, nil, nil, nil, 6, 9, nil, 13, 15,
299
- nil, 21, nil, nil, nil, 3, 7, nil, 11, nil,
300
- 16, 19, 6, 9, nil, 13, 15, nil, 21, nil,
301
- nil, nil, 3, 7, nil, 11, nil, 16, 19 ]
281
+ 47, 34, 37, 153, 149, 18, 47, 34, 37, 59,
282
+ 152, -76, 47, 34, 37, 77, 18, 34, 37, 70,
283
+ 34, 37, 18, 35, -75, 59, 34, 37, 18, 42,
284
+ 82, 129, -74, 48, 49, 42, 30, 54, 30, 48,
285
+ 49, 42, 68, 54, 60, 48, 49, -74, 42, 54,
286
+ 47, 34, 37, 35, 42, -77, 47, 34, 37, 35,
287
+ -76, 130, 47, 34, 37, 75, 18, 108, 29, 158,
288
+ 29, 31, 18, 31, 35, 75, 110, 106, 18, 42,
289
+ 159, 137, 138, 48, 49, 42, 145, 54, 80, 48,
290
+ 87, 42, -77, 54, 83, 48, 49, 34, 37, 54,
291
+ 47, 34, 37, 34, 37, 111, 47, 34, 37, 112,
292
+ 114, 142, 47, 34, 37, 168, 18, 112, 114, 72,
293
+ 43, 108, 18, 106, 146, 42, 81, -79, 18, 42,
294
+ 35, 42, 80, 48, 49, 42, 35, 54, -75, 48,
295
+ 49, 42, 72, 54, -78, 48, 49, 156, 157, 54,
296
+ 47, 34, 37, 34, 37, 105, 160, 161, 75, 72,
297
+ 34, 37, 34, 37, 67, 120, 18, 66, 18, 97,
298
+ 170, 65, 108, 35, 68, 18, 62, 18, 99, 42,
299
+ 32, 42, 26, 48, 49, 48, 49, 54, 42, 54,
300
+ 42, 103, 48, 49, 48, 49, 54, nil, 54, 34,
301
+ 37, 34, 37, nil, nil, 151, nil, nil, 34, 37,
302
+ nil, nil, nil, nil, 18, nil, 18, nil, nil, nil,
303
+ nil, nil, nil, 18, nil, nil, nil, 42, 163, 42,
304
+ nil, 48, 49, 48, 49, 54, 42, 54, nil, 18,
305
+ 48, 49, nil, 165, 54, nil, nil, nil, nil, 15,
306
+ 17, nil, 22, 24, 18, 3, nil, 9, 180, 12,
307
+ nil, 19, nil, nil, 15, 17, nil, 22, 24, 18,
308
+ 3, nil, 9, 166, 12, nil, 19, nil, nil, 15,
309
+ 17, nil, 22, 24, 18, 3, nil, 9, 175, 12,
310
+ nil, 19, nil, nil, 15, 17, nil, 22, 24, 18,
311
+ 3, nil, 9, 140, 12, nil, 19, nil, nil, 15,
312
+ 17, nil, 22, 24, 18, 3, nil, 9, 179, 12,
313
+ nil, 19, nil, nil, 15, 17, nil, 22, 24, 18,
314
+ 3, nil, 9, 176, 12, nil, 19, nil, nil, 15,
315
+ 17, nil, 22, 24, 18, 3, nil, 9, nil, 12,
316
+ nil, 19, nil, nil, 15, 17, nil, 22, 24, 18,
317
+ 3, nil, 9, nil, 12, nil, 19, nil, nil, 15,
318
+ 17, nil, 22, 24, 18, 3, nil, 9, nil, 12,
319
+ nil, 19, nil, nil, 15, 17, nil, 22, 24, nil,
320
+ 3, nil, 9, nil, 12, nil, 19 ]
302
321
 
303
322
  racc_action_check = [
304
- 137, 137, 137, 116, 66, 48, 48, 48, 101, 66,
305
- 80, 80, 80, 97, 101, 34, 34, 34, 75, 21,
306
- 26, 26, 26, 50, 86, 49, 137, 116, 46, 58,
307
- 137, 48, 86, 137, 137, 48, 80, 137, 48, 48,
308
- 80, 34, 48, 80, 80, 34, 26, 80, 34, 34,
309
- 26, 21, 34, 26, 26, 58, 44, 26, 11, 11,
310
- 11, 58, 79, 92, 92, 92, 79, 79, 112, 112,
311
- 112, 83, 38, 131, 131, 131, 38, 16, 93, 93,
312
- 93, 84, 19, 73, 11, 16, 6, 6, 11, 92,
313
- 19, 11, 11, 92, 112, 11, 92, 92, 112, 131,
314
- 92, 112, 112, 131, 93, 112, 131, 131, 93, 87,
315
- 131, 93, 93, 77, 77, 93, 77, 88, 110, 110,
316
- 89, 41, 40, 143, 143, 94, 95, 96, 81, 81,
317
- 74, 99, 100, 156, 156, 69, 39, 139, 77, 139,
318
- 139, 104, 77, 110, 68, 77, 77, 110, 143, 77,
319
- 110, 110, 143, 81, 110, 143, 143, 81, 156, 143,
320
- 81, 81, 156, 37, 81, 156, 156, 118, 118, 156,
321
- 115, 118, 32, 31, 1, 1, 30, 1, 1, 123,
322
- 1, 24, 130, 120, 1, 1, 65, 1, 134, 1,
323
- 1, 18, 118, 61, 60, 142, 118, 15, 13, 118,
324
- 118, 120, 120, 118, 120, 120, 163, 120, 9, 54,
325
- 4, 120, 120, 55, 120, nil, 120, 120, nil, nil,
326
- nil, nil, nil, 124, 163, 163, nil, 163, 163, nil,
327
- 163, nil, nil, nil, 163, 163, nil, 163, nil, 163,
328
- 163, 124, 124, 158, 124, 124, nil, 124, nil, nil,
329
- nil, 124, 124, nil, 124, nil, 124, 124, nil, nil,
330
- 102, 158, 158, nil, 158, 158, nil, 158, nil, nil,
331
- nil, 158, 158, nil, 158, nil, 158, 158, 102, 102,
332
- 135, 102, 102, nil, 102, nil, nil, nil, 102, 102,
333
- nil, 102, nil, 102, 102, nil, nil, 149, 135, 135,
334
- nil, 135, 135, nil, 135, nil, nil, nil, 135, 135,
335
- nil, 135, nil, 135, 135, 149, 149, 146, 149, 149,
336
- nil, 149, nil, nil, nil, 149, 149, nil, 149, nil,
337
- 149, 149, nil, nil, nil, 146, 146, nil, 146, 146,
338
- nil, 146, nil, nil, nil, 146, 146, nil, 146, nil,
339
- 146, 146, 0, 0, nil, 0, 0, nil, 0, nil,
340
- nil, nil, 0, 0, nil, 0, nil, 0, 0 ]
323
+ 65, 65, 65, 127, 124, 19, 130, 130, 130, 13,
324
+ 127, 57, 47, 47, 47, 47, 65, 15, 15, 27,
325
+ 43, 43, 130, 19, 85, 64, 80, 80, 47, 65,
326
+ 53, 88, 91, 65, 65, 130, 3, 65, 70, 130,
327
+ 130, 47, 27, 130, 13, 47, 47, 53, 43, 47,
328
+ 113, 113, 113, 43, 80, 92, 59, 59, 59, 80,
329
+ 93, 94, 82, 82, 82, 76, 113, 96, 3, 133,
330
+ 70, 3, 59, 70, 99, 115, 76, 87, 82, 113,
331
+ 133, 100, 102, 113, 113, 59, 115, 113, 87, 59,
332
+ 59, 82, 56, 59, 55, 82, 82, 75, 75, 82,
333
+ 12, 12, 12, 9, 9, 79, 146, 146, 146, 79,
334
+ 79, 107, 161, 161, 161, 148, 12, 148, 148, 108,
335
+ 9, 74, 146, 72, 118, 75, 51, 58, 161, 12,
336
+ 75, 9, 49, 12, 12, 146, 9, 12, 46, 146,
337
+ 146, 161, 129, 146, 45, 161, 161, 131, 132, 161,
338
+ 106, 106, 106, 83, 83, 71, 134, 136, 36, 32,
339
+ 153, 153, 81, 81, 26, 81, 106, 24, 83, 60,
340
+ 152, 22, 154, 158, 66, 153, 17, 81, 62, 106,
341
+ 4, 83, 2, 106, 106, 83, 83, 106, 153, 83,
342
+ 81, 68, 153, 153, 81, 81, 153, nil, 81, 169,
343
+ 169, 125, 125, nil, nil, 125, nil, nil, 120, 120,
344
+ nil, nil, nil, nil, 169, nil, 125, nil, nil, nil,
345
+ nil, nil, nil, 120, nil, nil, nil, 169, 137, 125,
346
+ nil, 169, 169, 125, 125, 169, 120, 125, nil, 137,
347
+ 120, 120, nil, 138, 120, nil, nil, nil, nil, 137,
348
+ 137, nil, 137, 137, 138, 137, nil, 137, 178, 137,
349
+ nil, 137, nil, nil, 138, 138, nil, 138, 138, 178,
350
+ 138, nil, 138, 139, 138, nil, 138, nil, nil, 178,
351
+ 178, nil, 178, 178, 139, 178, nil, 178, 162, 178,
352
+ nil, 178, nil, nil, 139, 139, nil, 139, 139, 162,
353
+ 139, nil, 139, 105, 139, nil, 139, nil, nil, 162,
354
+ 162, nil, 162, 162, 105, 162, nil, 162, 170, 162,
355
+ nil, 162, nil, nil, 105, 105, nil, 105, 105, 170,
356
+ 105, nil, 105, 164, 105, nil, 105, nil, nil, 170,
357
+ 170, nil, 170, 170, 164, 170, nil, 170, nil, 170,
358
+ nil, 170, nil, nil, 164, 164, nil, 164, 164, 6,
359
+ 164, nil, 164, nil, 164, nil, 164, nil, nil, 6,
360
+ 6, nil, 6, 6, 0, 6, nil, 6, nil, 6,
361
+ nil, 6, nil, nil, 0, 0, nil, 0, 0, nil,
362
+ 0, nil, 0, nil, 0, nil, 0 ]
341
363
 
342
364
  racc_action_pointer = [
343
- 327, 149, nil, nil, 204, nil, 83, nil, nil, 172,
344
- nil, 56, nil, 185, nil, 161, 49, nil, 185, 54,
345
- nil, 15, nil, nil, 181, nil, 18, nil, nil, nil,
346
- 161, 159, 158, nil, 13, nil, nil, 149, 70, 130,
347
- 108, 107, nil, nil, 42, nil, 22, nil, 3, -5,
348
- 13, nil, nil, nil, 173, 203, nil, nil, 25, nil,
349
- 194, 179, nil, nil, nil, 172, -5, nil, 107, 125,
350
- nil, nil, nil, 49, 94, 12, nil, 110, nil, 57,
351
- 8, 125, nil, 65, 45, nil, -4, 100, 107, 114,
352
- nil, nil, 61, 76, 118, 119, 91, -23, nil, 118,
353
- 116, -2, 253, nil, 132, nil, nil, nil, nil, nil,
354
- 115, nil, 66, nil, nil, 165, -7, nil, 164, nil,
355
- 176, nil, nil, 172, 216, nil, nil, nil, nil, nil,
356
- 172, 71, nil, nil, 152, 273, nil, -2, nil, 130,
357
- nil, nil, 189, 120, nil, nil, 310, nil, nil, 290,
358
- nil, nil, nil, nil, nil, nil, 130, nil, 236, nil,
359
- nil, nil, nil, 199, nil, nil ]
365
+ 356, nil, 182, 32, 174, nil, 341, nil, nil, 100,
366
+ nil, nil, 98, 3, nil, 14, nil, 140, nil, -13,
367
+ nil, nil, 158, nil, 131, nil, 164, 9, nil, nil,
368
+ nil, nil, 123, nil, nil, nil, 148, nil, nil, nil,
369
+ nil, nil, nil, 17, nil, 125, 119, 10, nil, 112,
370
+ nil, 107, nil, 28, nil, 88, 73, -8, 108, 54,
371
+ 127, nil, 158, nil, 19, -2, 141, nil, 155, nil,
372
+ 34, 149, 114, nil, 111, 94, 55, nil, nil, 100,
373
+ 23, 159, 60, 150, nil, 5, nil, 68, 14, nil,
374
+ nil, 13, 36, 41, 24, nil, 57, nil, nil, 38,
375
+ 75, nil, 76, nil, nil, 296, 148, 104, 83, nil,
376
+ nil, nil, nil, 48, nil, 65, nil, nil, 115, nil,
377
+ 205, nil, nil, nil, -1, 198, nil, -7, nil, 106,
378
+ 4, 140, 141, 59, 135, nil, 144, 221, 236, 266,
379
+ nil, nil, nil, nil, nil, nil, 104, nil, 108, nil,
380
+ nil, nil, 164, 157, 162, nil, nil, nil, 137, nil,
381
+ nil, 110, 281, nil, 326, nil, nil, nil, nil, 196,
382
+ 311, nil, nil, nil, nil, nil, nil, nil, 251, nil,
383
+ nil ]
360
384
 
361
385
  racc_action_default = [
362
- -101, -1, -2, -28, -101, -4, -101, -27, -5, -101,
363
- -6, -101, -7, -101, -8, -101, -101, -9, -101, -101,
364
- -10, -101, -11, -12, -101, -3, -36, -74, -51, -52,
365
- -85, -42, -101, -46, -101, -49, -47, -28, -43, -101,
366
- -48, -27, -95, -72, -45, -50, -44, -53, -101, -85,
367
- -13, -15, -17, -18, -36, -14, -83, -84, -85, -81,
368
- -101, -29, -32, -34, -30, -33, -27, -37, -25, -99,
369
- -73, -31, -23, -101, -85, -101, -86, -101, -40, -101,
370
- -101, -101, -35, -101, -101, -93, -101, -101, -99, -101,
371
- -82, 166, -101, -26, -101, -101, -100, -36, -89, -92,
372
- -101, -101, -101, -70, -101, -69, -62, -71, -68, -63,
373
- -101, -96, -101, -97, -98, -101, -101, -60, -101, -56,
374
- -101, -94, -16, -101, -101, -39, -24, -19, -20, -38,
375
- -99, -101, -87, -88, -101, -101, -76, -101, -65, -101,
376
- -41, -54, -101, -101, -55, -57, -101, -78, -21, -101,
377
- -80, -22, -91, -90, -75, -67, -101, -64, -101, -61,
378
- -77, -79, -66, -101, -59, -58 ]
386
+ -93, -12, -110, -110, -110, -13, -1, -14, -2, -32,
387
+ -3, -5, -110, -110, -6, -110, -7, -110, -33, -110,
388
+ -8, -9, -110, -10, -110, -11, -110, -93, -88, -90,
389
+ -91, -92, -41, -4, -57, -32, -16, -58, -17, -19,
390
+ -20, -21, -103, -110, -54, -55, -49, -110, -59, -32,
391
+ -51, -110, -53, -48, -80, -110, -52, -47, -50, -41,
392
+ -110, -81, -93, -25, -110, -110, -93, 181, -110, -101,
393
+ -110, -110, -110, -42, -108, -110, -110, -105, -45, -110,
394
+ -110, -110, -110, -110, -78, -36, -28, -32, -110, -37,
395
+ -39, -35, -38, -34, -30, -79, -108, -26, -94, -93,
396
+ -110, -40, -110, -102, -89, -110, -110, -110, -109, -18,
397
+ -15, -104, -106, -110, -107, -110, -75, -74, -110, -77,
398
+ -110, -68, -76, -69, -110, -110, -62, -110, -66, -41,
399
+ -31, -110, -110, -110, -110, -97, -100, -110, -110, -110,
400
+ -87, -44, -24, -43, -46, -56, -110, -71, -110, -60,
401
+ -63, -61, -110, -110, -108, -29, -22, -23, -110, -96,
402
+ -95, -110, -110, -83, -110, -85, -86, -73, -70, -110,
403
+ -110, -67, -27, -98, -99, -82, -84, -72, -110, -65,
404
+ -64 ]
379
405
 
380
406
  racc_goto_table = [
381
- 25, 1, 27, 39, 95, 119, 53, 70, 69, 53,
382
- 112, 62, 38, 109, 59, 129, 65, 52, 72, 63,
383
- 52, 83, 61, 123, 76, 122, 78, 64, 98, 46,
384
- 89, 50, 106, 118, 55, 38, 88, 139, 75, 68,
385
- 82, 58, 145, 94, 71, 79, 138, 101, 24, 38,
386
- nil, 90, 46, nil, nil, nil, nil, nil, 70, 36,
387
- nil, nil, 70, nil, nil, 151, 46, 107, 100, nil,
388
- 156, 107, 115, 103, 70, 99, 53, 103, 62, 130,
389
- nil, 38, 36, 65, 125, 126, 63, 52, 153, 61,
390
- nil, 70, 162, 38, 64, nil, 36, nil, 46, 70,
391
- 107, nil, nil, 135, 140, nil, 103, nil, 107, nil,
392
- 46, 71, nil, 38, 103, nil, nil, nil, nil, nil,
393
- nil, 146, nil, 152, 70, 149, nil, nil, 36, 155,
394
- 46, nil, 38, 107, 25, 99, nil, 70, 38, 103,
395
- 36, nil, nil, 104, nil, 25, 107, 117, 25, 46,
396
- nil, nil, 103, nil, nil, 46, nil, nil, nil, 163,
397
- 36, nil, 25, nil, nil, nil, nil, nil, nil, nil,
398
- nil, nil, nil, nil, nil, nil, 104, nil, nil, 36,
399
- nil, nil, nil, nil, 117, 36, nil, nil, nil, nil,
400
- nil, nil, nil, nil, nil, nil, nil, nil, nil, nil,
401
- nil, nil, nil, nil, nil, nil, nil, nil, nil, 159,
402
- nil, nil, nil, nil, nil, nil, nil, nil, nil, nil,
403
- nil, nil, 104 ]
407
+ 33, 6, 74, 39, 8, 107, 53, 89, 135, 123,
408
+ 126, 86, 36, 64, 109, 40, 71, 90, 125, 79,
409
+ 94, 121, 113, 131, 148, 28, 100, 132, 143, 96,
410
+ 41, 27, 63, 133, 2, nil, 61, 39, nil, nil,
411
+ 118, 53, 128, nil, nil, nil, 76, nil, 147, 40,
412
+ nil, nil, 150, 91, nil, 102, nil, nil, nil, 53,
413
+ nil, nil, nil, nil, 41, 92, 98, 173, nil, 39,
414
+ nil, nil, nil, nil, 39, 117, 53, 117, 89, 118,
415
+ 93, 40, 155, 115, 128, 172, 40, 119, 90, 119,
416
+ 55, 169, 104, 136, nil, 46, 41, 177, nil, 154,
417
+ 53, 41, 122, 134, 122, nil, 139, 53, nil, nil,
418
+ nil, nil, 171, nil, 117, nil, nil, nil, nil, 117,
419
+ nil, nil, nil, nil, 91, 78, 119, nil, 118, nil,
420
+ 46, 119, nil, 33, nil, nil, 92, nil, 162, 164,
421
+ 53, 122, 85, 101, nil, nil, 122, 117, 46, nil,
422
+ nil, 93, 136, nil, 84, 53, 33, 95, 33, 119,
423
+ 124, nil, nil, 117, 116, 46, 116, nil, nil, nil,
424
+ nil, 178, 33, nil, 122, 119, 84, nil, 84, 95,
425
+ nil, 95, nil, nil, 141, nil, nil, nil, nil, 46,
426
+ 122, 144, nil, nil, nil, nil, 46, nil, nil, nil,
427
+ nil, nil, nil, 116, nil, nil, nil, nil, 116, nil,
428
+ nil, nil, nil, 85, nil, 84, nil, nil, 95, nil,
429
+ 84, nil, nil, 95, 167, 84, nil, nil, 95, 46,
430
+ nil, nil, nil, nil, nil, nil, 116, nil, nil, 174,
431
+ nil, nil, nil, nil, 46, nil, nil, nil, 84, nil,
432
+ nil, 95, 116, nil, nil, nil, nil, nil, nil, nil,
433
+ nil, nil, nil, nil, 84, nil, nil, 95 ]
404
434
 
405
435
  racc_goto_check = [
406
- 3, 2, 24, 27, 20, 34, 16, 31, 19, 16,
407
- 30, 25, 15, 38, 43, 28, 16, 15, 22, 26,
408
- 15, 41, 24, 20, 44, 14, 27, 15, 46, 21,
409
- 41, 13, 37, 33, 13, 15, 19, 39, 40, 17,
410
- 27, 42, 34, 18, 21, 29, 38, 45, 1, 15,
411
- nil, 43, 21, nil, nil, nil, nil, nil, 31, 4,
412
- nil, nil, 31, nil, nil, 20, 21, 16, 44, nil,
413
- 30, 16, 27, 24, 31, 15, 16, 24, 25, 19,
414
- nil, 15, 4, 16, 27, 22, 26, 15, 46, 24,
415
- nil, 31, 38, 15, 15, nil, 4, nil, 21, 31,
416
- 16, nil, nil, 2, 27, nil, 24, nil, 16, nil,
417
- 21, 21, nil, 15, 24, nil, nil, nil, nil, nil,
418
- nil, 2, nil, 27, 31, 2, nil, nil, 4, 27,
419
- 21, nil, 15, 16, 3, 15, nil, 31, 15, 24,
420
- 4, nil, nil, 36, nil, 3, 16, 36, 3, 21,
421
- nil, nil, 24, nil, nil, 21, nil, nil, nil, 2,
422
- 4, nil, 3, nil, nil, nil, nil, nil, nil, nil,
423
- nil, nil, nil, nil, nil, nil, 36, nil, nil, 4,
424
- nil, nil, nil, nil, 36, 4, nil, nil, nil, nil,
425
- nil, nil, nil, nil, nil, nil, nil, nil, nil, nil,
426
- nil, nil, nil, nil, nil, nil, nil, nil, nil, 36,
427
- nil, nil, nil, nil, nil, nil, nil, nil, nil, nil,
428
- nil, nil, 36 ]
436
+ 4, 2, 22, 17, 3, 23, 17, 27, 48, 41,
437
+ 37, 25, 15, 17, 16, 18, 44, 28, 36, 31,
438
+ 20, 40, 32, 21, 42, 46, 43, 23, 30, 22,
439
+ 19, 45, 5, 47, 1, nil, 19, 17, nil, nil,
440
+ 39, 17, 39, nil, nil, nil, 15, nil, 41, 18,
441
+ nil, nil, 37, 17, nil, 44, nil, nil, nil, 17,
442
+ nil, nil, nil, nil, 19, 18, 3, 48, nil, 17,
443
+ nil, nil, nil, nil, 17, 17, 17, 17, 27, 39,
444
+ 19, 18, 25, 15, 39, 23, 18, 18, 28, 18,
445
+ 29, 32, 46, 17, nil, 24, 19, 41, nil, 22,
446
+ 17, 19, 19, 3, 19, nil, 2, 17, nil, nil,
447
+ nil, nil, 39, nil, 17, nil, nil, nil, nil, 17,
448
+ nil, nil, nil, nil, 17, 29, 18, nil, 39, nil,
449
+ 24, 18, nil, 4, nil, nil, 18, nil, 2, 2,
450
+ 17, 19, 24, 29, nil, nil, 19, 17, 24, nil,
451
+ nil, 19, 17, nil, 35, 17, 4, 33, 4, 18,
452
+ 29, nil, nil, 17, 24, 24, 24, nil, nil, nil,
453
+ nil, 2, 4, nil, 19, 18, 35, nil, 35, 33,
454
+ nil, 33, nil, nil, 29, nil, nil, nil, nil, 24,
455
+ 19, 29, nil, nil, nil, nil, 24, nil, nil, nil,
456
+ nil, nil, nil, 24, nil, nil, nil, nil, 24, nil,
457
+ nil, nil, nil, 24, nil, 35, nil, nil, 33, nil,
458
+ 35, nil, nil, 33, 29, 35, nil, nil, 33, 24,
459
+ nil, nil, nil, nil, nil, nil, 24, nil, nil, 29,
460
+ nil, nil, nil, nil, 24, nil, nil, nil, 35, nil,
461
+ nil, 33, 24, nil, nil, nil, nil, nil, nil, nil,
462
+ nil, nil, nil, nil, 35, nil, nil, 33 ]
429
463
 
430
464
  racc_goto_pointer = [
431
- nil, 48, 1, -1, 48, nil, nil, nil, nil, nil,
432
- nil, nil, nil, 15, -61, 1, -10, 13, -25, -18,
433
- -65, 18, -8, nil, -4, -15, -7, -8, -81, 11,
434
- -69, -19, nil, -48, -76, nil, 66, -45, -64, -73,
435
- 8, -28, 20, -7, -6, -27, -46 ]
465
+ nil, 34, 1, 4, -6, 13, nil, nil, nil, nil,
466
+ nil, nil, nil, nil, nil, 3, -61, -6, 6, 21,
467
+ -39, -71, -30, -69, 83, -48, nil, -52, -42, 78,
468
+ -80, -28, -57, 98, nil, 95, -65, -73, nil, -41,
469
+ -60, -72, -96, -36, -11, 28, 22, -66, -91 ]
436
470
 
437
471
  racc_goto_default = [
438
- nil, nil, nil, 2, 5, 8, 10, 12, 14, 17,
439
- 20, 22, 23, nil, 51, 4, 40, nil, nil, nil,
440
- nil, 18, nil, 73, 31, 33, 35, nil, 67, nil,
441
- nil, 44, 45, nil, nil, 116, 32, nil, nil, nil,
442
- nil, nil, nil, nil, 85, nil, nil ]
472
+ nil, nil, nil, 69, 10, 11, 14, 16, 20, 21,
473
+ 23, 25, 1, 5, 7, nil, 38, 13, 56, 57,
474
+ nil, nil, nil, nil, 4, nil, 88, 50, 52, nil,
475
+ 73, nil, nil, 58, 44, 45, nil, nil, 127, 51,
476
+ nil, nil, nil, nil, nil, nil, nil, nil, nil ]
443
477
 
444
478
  racc_token_table = {
445
479
  false => 0,
@@ -456,38 +490,39 @@ racc_token_table = {
456
490
  :TRUE => 11,
457
491
  :FALSE => 12,
458
492
  :EQUALS => 13,
459
- :QMARK => 14,
460
- :LPAREN => 15,
461
- :RPAREN => 16,
462
- :ISEQUAL => 17,
463
- :GREATEREQUAL => 18,
464
- :GREATERTHAN => 19,
465
- :LESSTHAN => 20,
466
- :LESSEQUAL => 21,
467
- :NOTEQUAL => 22,
468
- :IF => 23,
469
- :ELSE => 24,
470
- :IMPORT => 25,
471
- :DEFINE => 26,
472
- :ELSIF => 27,
473
- :VARIABLE => 28,
474
- :CLASS => 29,
475
- :INHERITS => 30,
476
- :NODE => 31,
477
- :BOOLEAN => 32,
478
- :DOT => 33,
479
- :COLON => 34,
480
- :TYPE => 35,
493
+ :LESSEQUAL => 14,
494
+ :NOTEQUAL => 15,
495
+ :DOT => 16,
496
+ :COLON => 17,
497
+ :TYPE => 18,
498
+ :QMARK => 19,
499
+ :LPAREN => 20,
500
+ :RPAREN => 21,
501
+ :ISEQUAL => 22,
502
+ :GREATEREQUAL => 23,
503
+ :GREATERTHAN => 24,
504
+ :LESSTHAN => 25,
505
+ :IF => 26,
506
+ :ELSE => 27,
507
+ :IMPORT => 28,
508
+ :DEFINE => 29,
509
+ :ELSIF => 30,
510
+ :VARIABLE => 31,
511
+ :CLASS => 32,
512
+ :INHERITS => 33,
513
+ :NODE => 34,
514
+ :BOOLEAN => 35,
481
515
  :NAME => 36,
482
516
  :SEMIC => 37,
483
517
  :CASE => 38,
484
518
  :DEFAULT => 39,
485
- :INCLUDE => 40,
486
- :TAG => 41 }
519
+ :AT => 40,
520
+ :LCOLLECT => 41,
521
+ :RCOLLECT => 42 }
487
522
 
488
523
  racc_use_result_var = true
489
524
 
490
- racc_nt_base = 42
525
+ racc_nt_base = 43
491
526
 
492
527
  Racc_arg = [
493
528
  racc_action_table,
@@ -520,6 +555,11 @@ Racc_token_to_s_table = [
520
555
  'TRUE',
521
556
  'FALSE',
522
557
  'EQUALS',
558
+ 'LESSEQUAL',
559
+ 'NOTEQUAL',
560
+ 'DOT',
561
+ 'COLON',
562
+ 'TYPE',
523
563
  'QMARK',
524
564
  'LPAREN',
525
565
  'RPAREN',
@@ -527,8 +567,6 @@ Racc_token_to_s_table = [
527
567
  'GREATEREQUAL',
528
568
  'GREATERTHAN',
529
569
  'LESSTHAN',
530
- 'LESSEQUAL',
531
- 'NOTEQUAL',
532
570
  'IF',
533
571
  'ELSE',
534
572
  'IMPORT',
@@ -539,25 +577,25 @@ Racc_token_to_s_table = [
539
577
  'INHERITS',
540
578
  'NODE',
541
579
  'BOOLEAN',
542
- 'DOT',
543
- 'COLON',
544
- 'TYPE',
545
580
  'NAME',
546
581
  'SEMIC',
547
582
  'CASE',
548
583
  'DEFAULT',
549
- 'INCLUDE',
550
- 'TAG',
584
+ 'AT',
585
+ 'LCOLLECT',
586
+ 'RCOLLECT',
551
587
  '$start',
552
588
  'program',
553
589
  'statements',
590
+ 'nothing',
554
591
  'statement',
555
592
  'object',
593
+ 'collectable',
594
+ 'collection',
556
595
  'assignment',
557
596
  'casestatement',
558
597
  'import',
559
- 'include',
560
- 'tag',
598
+ 'fstatement',
561
599
  'definition',
562
600
  'hostclass',
563
601
  'nodedef',
@@ -565,6 +603,7 @@ Racc_token_to_s_table = [
565
603
  'classname',
566
604
  'name',
567
605
  'variable',
606
+ 'quotedtext',
568
607
  'objectinstances',
569
608
  'endsemi',
570
609
  'params',
@@ -572,7 +611,6 @@ Racc_token_to_s_table = [
572
611
  'type',
573
612
  'objectinst',
574
613
  'objectname',
575
- 'quotedtext',
576
614
  'selector',
577
615
  'array',
578
616
  'rvalue',
@@ -581,6 +619,7 @@ Racc_token_to_s_table = [
581
619
  'comma',
582
620
  'boolean',
583
621
  'objectref',
622
+ 'funcrvalue',
584
623
  'caseopts',
585
624
  'caseopt',
586
625
  'casevalues',
@@ -592,7 +631,6 @@ Racc_token_to_s_table = [
592
631
  'parent',
593
632
  'hostnames',
594
633
  'hostname',
595
- 'nothing',
596
634
  'arguments',
597
635
  'argument']
598
636
 
@@ -602,7 +640,7 @@ Racc_debug_parser = false
602
640
 
603
641
  # reduce 0 omitted
604
642
 
605
- module_eval <<'.,.,', 'grammar.ra', 40
643
+ module_eval <<'.,.,', 'grammar.ra', 26
606
644
  def _reduce_1( val, _values, result )
607
645
  if val[0].is_a?(AST::ASTArray)
608
646
  result = val[0]
@@ -612,29 +650,16 @@ module_eval <<'.,.,', 'grammar.ra', 40
612
650
  :children => [val[0]]
613
651
  )
614
652
  end
615
-
616
- # this is mainly so we can test the parser separately from the
617
- # interpreter
618
- # if Puppet[:parseonly]
619
- # begin
620
- # if Puppet[:debug]
621
- # puts result.tree(0)
622
- # end
623
- # rescue NoMethodError => detail
624
- # Puppet.err detail
625
- # #exit(78)
626
- # end
627
- # #require 'puppet/parser/interpreter'
628
- # #result = Puppet::Server.new(result)
629
- # end
630
653
  result
631
654
  end
632
655
  .,.,
633
656
 
634
657
  # reduce 2 omitted
635
658
 
636
- module_eval <<'.,.,', 'grammar.ra', 54
637
- def _reduce_3( val, _values, result )
659
+ # reduce 3 omitted
660
+
661
+ module_eval <<'.,.,', 'grammar.ra', 41
662
+ def _reduce_4( val, _values, result )
638
663
  if val[0].instance_of?(AST::ASTArray)
639
664
  val[0].push(val[1])
640
665
  result = val[0]
@@ -649,8 +674,6 @@ module_eval <<'.,.,', 'grammar.ra', 54
649
674
  end
650
675
  .,.,
651
676
 
652
- # reduce 4 omitted
653
-
654
677
  # reduce 5 omitted
655
678
 
656
679
  # reduce 6 omitted
@@ -667,51 +690,42 @@ module_eval <<'.,.,', 'grammar.ra', 54
667
690
 
668
691
  # reduce 12 omitted
669
692
 
670
- module_eval <<'.,.,', 'grammar.ra', 92
671
- def _reduce_13( val, _values, result )
672
- classnames = aryfy(val[1])
673
-
674
- klasses = []
675
-
676
- # Now just iterate over each of the class names and create a new
677
- # object instance. FIXME This should probably eventually include
678
- # some kind of checking that the asked-for class is a defined class.
679
- classnames.each { |classname|
680
- emptyary = AST::ASTArray.new(:children => [])
681
- klasses << AST::ObjectDef.new(
682
- :pin => "{}",
683
- :line => @lexer.line,
684
- :file => @lexer.file,
685
- :type => classname,
686
- :params => emptyary
687
- )
688
- }
689
- result = AST::ASTArray.new(
693
+ # reduce 13 omitted
694
+
695
+ # reduce 14 omitted
696
+
697
+ module_eval <<'.,.,', 'grammar.ra', 64
698
+ def _reduce_15( val, _values, result )
699
+ args = aryfy(val[2])
700
+ result = AST::Function.new(
690
701
  :line => @lexer.line,
691
702
  :file => @lexer.file,
692
- :children => klasses
703
+ :name => val[0],
704
+ :arguments => args,
705
+ :ftype => :statement
693
706
  )
694
707
  result
695
708
  end
696
709
  .,.,
697
710
 
698
- module_eval <<'.,.,', 'grammar.ra', 102
699
- def _reduce_14( val, _values, result )
700
- classnames = aryfy(val[1])
701
-
702
- result = AST::Tag.new(
711
+ module_eval <<'.,.,', 'grammar.ra', 74
712
+ def _reduce_16( val, _values, result )
713
+ args = aryfy(val[1])
714
+ result = AST::Function.new(
703
715
  :line => @lexer.line,
704
716
  :file => @lexer.file,
705
- :type => val[1]
717
+ :name => val[0],
718
+ :arguments => args,
719
+ :ftype => :statement
706
720
  )
707
721
  result
708
722
  end
709
723
  .,.,
710
724
 
711
- # reduce 15 omitted
725
+ # reduce 17 omitted
712
726
 
713
- module_eval <<'.,.,', 'grammar.ra', 109
714
- def _reduce_16( val, _values, result )
727
+ module_eval <<'.,.,', 'grammar.ra', 93
728
+ def _reduce_18( val, _values, result )
715
729
  result = aryfy(val[0], val[2])
716
730
  result.line = @lexer.line
717
731
  result.file = @lexer.file
@@ -719,12 +733,14 @@ module_eval <<'.,.,', 'grammar.ra', 109
719
733
  end
720
734
  .,.,
721
735
 
722
- # reduce 17 omitted
736
+ # reduce 19 omitted
737
+
738
+ # reduce 20 omitted
723
739
 
724
- # reduce 18 omitted
740
+ # reduce 21 omitted
725
741
 
726
- module_eval <<'.,.,', 'grammar.ra', 143
727
- def _reduce_19( val, _values, result )
742
+ module_eval <<'.,.,', 'grammar.ra', 128
743
+ def _reduce_22( val, _values, result )
728
744
  if val[0].instance_of?(AST::ASTArray)
729
745
  raise Puppet::ParseError, "Invalid name"
730
746
  end
@@ -756,8 +772,8 @@ module_eval <<'.,.,', 'grammar.ra', 143
756
772
  end
757
773
  .,.,
758
774
 
759
- module_eval <<'.,.,', 'grammar.ra', 157
760
- def _reduce_20( val, _values, result )
775
+ module_eval <<'.,.,', 'grammar.ra', 142
776
+ def _reduce_23( val, _values, result )
761
777
  if val[0].instance_of?(AST::ASTArray)
762
778
  Puppet.notice "invalid name"
763
779
  raise Puppet::ParseError, "Invalid name"
@@ -775,8 +791,8 @@ module_eval <<'.,.,', 'grammar.ra', 157
775
791
  end
776
792
  .,.,
777
793
 
778
- module_eval <<'.,.,', 'grammar.ra', 169
779
- def _reduce_21( val, _values, result )
794
+ module_eval <<'.,.,', 'grammar.ra', 154
795
+ def _reduce_24( val, _values, result )
780
796
  # a template setting for a type
781
797
  if val[0].instance_of?(AST::ASTArray)
782
798
  raise Puppet::ParseError, "Invalid type"
@@ -793,7 +809,45 @@ module_eval <<'.,.,', 'grammar.ra', 169
793
809
  .,.,
794
810
 
795
811
  module_eval <<'.,.,', 'grammar.ra', 177
796
- def _reduce_22( val, _values, result )
812
+ def _reduce_25( val, _values, result )
813
+ unless Puppet[:storeconfigs]
814
+ raise Puppet::ParseError, "You cannot collect without storeconfigs being set"
815
+ end
816
+
817
+ if val[1].is_a? AST::TypeDefaults
818
+ raise Puppet::ParseError, "Defaults are not collectable"
819
+ end
820
+
821
+ # Just mark our objects as collectable and pass them through.
822
+ if val[1].instance_of?(AST::ASTArray)
823
+ val[1].each do |obj|
824
+ obj.collectable = true
825
+ end
826
+ else
827
+ val[1].collectable = true
828
+ end
829
+
830
+ result = val[1]
831
+ result
832
+ end
833
+ .,.,
834
+
835
+ module_eval <<'.,.,', 'grammar.ra', 190
836
+ def _reduce_26( val, _values, result )
837
+ unless Puppet[:storeconfigs]
838
+ raise Puppet::ParseError, "You cannot collect without storeconfigs being set"
839
+ end
840
+ result = AST::Collection.new(
841
+ :line => @lexer.line,
842
+ :file => @lexer.file,
843
+ :type => val[0]
844
+ )
845
+ result
846
+ end
847
+ .,.,
848
+
849
+ module_eval <<'.,.,', 'grammar.ra', 198
850
+ def _reduce_27( val, _values, result )
797
851
  result = AST::ObjectInst.new(
798
852
  :line => @lexer.line,
799
853
  :file => @lexer.file,
@@ -803,10 +857,10 @@ module_eval <<'.,.,', 'grammar.ra', 177
803
857
  end
804
858
  .,.,
805
859
 
806
- # reduce 23 omitted
860
+ # reduce 28 omitted
807
861
 
808
- module_eval <<'.,.,', 'grammar.ra', 191
809
- def _reduce_24( val, _values, result )
862
+ module_eval <<'.,.,', 'grammar.ra', 212
863
+ def _reduce_29( val, _values, result )
810
864
  if val[0].instance_of?(AST::ObjectInst)
811
865
  result = AST::ASTArray.new(
812
866
  :line => @lexer.line,
@@ -821,12 +875,12 @@ module_eval <<'.,.,', 'grammar.ra', 191
821
875
  end
822
876
  .,.,
823
877
 
824
- # reduce 25 omitted
878
+ # reduce 30 omitted
825
879
 
826
- # reduce 26 omitted
880
+ # reduce 31 omitted
827
881
 
828
- module_eval <<'.,.,', 'grammar.ra', 202
829
- def _reduce_27( val, _values, result )
882
+ module_eval <<'.,.,', 'grammar.ra', 223
883
+ def _reduce_32( val, _values, result )
830
884
  result = AST::Name.new(
831
885
  :line => @lexer.line,
832
886
  :file => @lexer.file,
@@ -836,8 +890,8 @@ module_eval <<'.,.,', 'grammar.ra', 202
836
890
  end
837
891
  .,.,
838
892
 
839
- module_eval <<'.,.,', 'grammar.ra', 210
840
- def _reduce_28( val, _values, result )
893
+ module_eval <<'.,.,', 'grammar.ra', 231
894
+ def _reduce_33( val, _values, result )
841
895
  result = AST::Type.new(
842
896
  :line => @lexer.line,
843
897
  :file => @lexer.file,
@@ -847,20 +901,20 @@ module_eval <<'.,.,', 'grammar.ra', 210
847
901
  end
848
902
  .,.,
849
903
 
850
- # reduce 29 omitted
904
+ # reduce 34 omitted
851
905
 
852
- # reduce 30 omitted
906
+ # reduce 35 omitted
853
907
 
854
- # reduce 31 omitted
908
+ # reduce 36 omitted
855
909
 
856
- # reduce 32 omitted
910
+ # reduce 37 omitted
857
911
 
858
- # reduce 33 omitted
912
+ # reduce 38 omitted
859
913
 
860
- # reduce 34 omitted
914
+ # reduce 39 omitted
861
915
 
862
- module_eval <<'.,.,', 'grammar.ra', 233
863
- def _reduce_35( val, _values, result )
916
+ module_eval <<'.,.,', 'grammar.ra', 254
917
+ def _reduce_40( val, _values, result )
864
918
  # this is distinct from referencing a variable
865
919
  variable = AST::Name.new(
866
920
  :line => @lexer.line,
@@ -878,8 +932,8 @@ module_eval <<'.,.,', 'grammar.ra', 233
878
932
  end
879
933
  .,.,
880
934
 
881
- module_eval <<'.,.,', 'grammar.ra', 242
882
- def _reduce_36( val, _values, result )
935
+ module_eval <<'.,.,', 'grammar.ra', 263
936
+ def _reduce_41( val, _values, result )
883
937
  result = AST::ASTArray.new(
884
938
  :line => @lexer.line,
885
939
  :file => @lexer.file,
@@ -889,15 +943,15 @@ module_eval <<'.,.,', 'grammar.ra', 242
889
943
  end
890
944
  .,.,
891
945
 
892
- module_eval <<'.,.,', 'grammar.ra', 242
893
- def _reduce_37( val, _values, result )
946
+ module_eval <<'.,.,', 'grammar.ra', 263
947
+ def _reduce_42( val, _values, result )
894
948
  result = val[0]
895
949
  result
896
950
  end
897
951
  .,.,
898
952
 
899
- module_eval <<'.,.,', 'grammar.ra', 255
900
- def _reduce_38( val, _values, result )
953
+ module_eval <<'.,.,', 'grammar.ra', 276
954
+ def _reduce_43( val, _values, result )
901
955
  if val[0].instance_of?(AST::ASTArray)
902
956
  val[0].push(val[2])
903
957
  result = val[0]
@@ -912,8 +966,8 @@ module_eval <<'.,.,', 'grammar.ra', 255
912
966
  end
913
967
  .,.,
914
968
 
915
- module_eval <<'.,.,', 'grammar.ra', 270
916
- def _reduce_39( val, _values, result )
969
+ module_eval <<'.,.,', 'grammar.ra', 291
970
+ def _reduce_44( val, _values, result )
917
971
  leaf = AST::String.new(
918
972
  :line => @lexer.line,
919
973
  :file => @lexer.file,
@@ -930,10 +984,10 @@ module_eval <<'.,.,', 'grammar.ra', 270
930
984
  end
931
985
  .,.,
932
986
 
933
- # reduce 40 omitted
987
+ # reduce 45 omitted
934
988
 
935
- module_eval <<'.,.,', 'grammar.ra', 283
936
- def _reduce_41( val, _values, result )
989
+ module_eval <<'.,.,', 'grammar.ra', 304
990
+ def _reduce_46( val, _values, result )
937
991
  if val[0].instance_of?(AST::ASTArray)
938
992
  result = val[0].push(val[2])
939
993
  else
@@ -947,26 +1001,40 @@ module_eval <<'.,.,', 'grammar.ra', 283
947
1001
  end
948
1002
  .,.,
949
1003
 
950
- # reduce 42 omitted
1004
+ # reduce 47 omitted
951
1005
 
952
- # reduce 43 omitted
1006
+ # reduce 48 omitted
953
1007
 
954
- # reduce 44 omitted
1008
+ # reduce 49 omitted
955
1009
 
956
- # reduce 45 omitted
1010
+ # reduce 50 omitted
957
1011
 
958
- # reduce 46 omitted
1012
+ # reduce 51 omitted
959
1013
 
960
- # reduce 47 omitted
1014
+ # reduce 52 omitted
961
1015
 
962
- # reduce 48 omitted
1016
+ # reduce 53 omitted
963
1017
 
964
- # reduce 49 omitted
1018
+ # reduce 54 omitted
965
1019
 
966
- # reduce 50 omitted
1020
+ # reduce 55 omitted
1021
+
1022
+ module_eval <<'.,.,', 'grammar.ra', 326
1023
+ def _reduce_56( val, _values, result )
1024
+ args = aryfy(val[2])
1025
+ result = AST::Function.new(
1026
+ :line => @lexer.line,
1027
+ :file => @lexer.file,
1028
+ :name => val[0],
1029
+ :arguments => args,
1030
+ :ftype => :rvalue
1031
+ )
1032
+ result
1033
+ end
1034
+ .,.,
967
1035
 
968
- module_eval <<'.,.,', 'grammar.ra', 301
969
- def _reduce_51( val, _values, result )
1036
+ module_eval <<'.,.,', 'grammar.ra', 334
1037
+ def _reduce_57( val, _values, result )
970
1038
  result = AST::String.new(
971
1039
  :line => @lexer.line,
972
1040
  :file => @lexer.file,
@@ -976,8 +1044,8 @@ module_eval <<'.,.,', 'grammar.ra', 301
976
1044
  end
977
1045
  .,.,
978
1046
 
979
- module_eval <<'.,.,', 'grammar.ra', 307
980
- def _reduce_52( val, _values, result )
1047
+ module_eval <<'.,.,', 'grammar.ra', 340
1048
+ def _reduce_58( val, _values, result )
981
1049
  result = AST::FlatString.new(
982
1050
  :line => @lexer.line,
983
1051
  :file => @lexer.file,
@@ -987,8 +1055,8 @@ module_eval <<'.,.,', 'grammar.ra', 307
987
1055
  end
988
1056
  .,.,
989
1057
 
990
- module_eval <<'.,.,', 'grammar.ra', 315
991
- def _reduce_53( val, _values, result )
1058
+ module_eval <<'.,.,', 'grammar.ra', 348
1059
+ def _reduce_59( val, _values, result )
992
1060
  result = AST::Boolean.new(
993
1061
  :line => @lexer.line,
994
1062
  :file => @lexer.file,
@@ -998,8 +1066,8 @@ module_eval <<'.,.,', 'grammar.ra', 315
998
1066
  end
999
1067
  .,.,
1000
1068
 
1001
- module_eval <<'.,.,', 'grammar.ra', 325
1002
- def _reduce_54( val, _values, result )
1069
+ module_eval <<'.,.,', 'grammar.ra', 358
1070
+ def _reduce_60( val, _values, result )
1003
1071
  result = AST::ObjectRef.new(
1004
1072
  :pin => '[]',
1005
1073
  :line => @lexer.line,
@@ -1011,8 +1079,8 @@ module_eval <<'.,.,', 'grammar.ra', 325
1011
1079
  end
1012
1080
  .,.,
1013
1081
 
1014
- module_eval <<'.,.,', 'grammar.ra', 342
1015
- def _reduce_55( val, _values, result )
1082
+ module_eval <<'.,.,', 'grammar.ra', 375
1083
+ def _reduce_61( val, _values, result )
1016
1084
  options = val[3]
1017
1085
  unless options.instance_of?(AST::ASTArray)
1018
1086
  options = AST::ASTArray.new(
@@ -1031,10 +1099,10 @@ module_eval <<'.,.,', 'grammar.ra', 342
1031
1099
  end
1032
1100
  .,.,
1033
1101
 
1034
- # reduce 56 omitted
1102
+ # reduce 62 omitted
1035
1103
 
1036
- module_eval <<'.,.,', 'grammar.ra', 356
1037
- def _reduce_57( val, _values, result )
1104
+ module_eval <<'.,.,', 'grammar.ra', 389
1105
+ def _reduce_63( val, _values, result )
1038
1106
  if val[0].instance_of?(AST::ASTArray)
1039
1107
  val[0].push val[1]
1040
1108
  result = val[0]
@@ -1049,8 +1117,8 @@ module_eval <<'.,.,', 'grammar.ra', 356
1049
1117
  end
1050
1118
  .,.,
1051
1119
 
1052
- module_eval <<'.,.,', 'grammar.ra', 366
1053
- def _reduce_58( val, _values, result )
1120
+ module_eval <<'.,.,', 'grammar.ra', 399
1121
+ def _reduce_64( val, _values, result )
1054
1122
  result = AST::CaseOpt.new(
1055
1123
  :pin => ":",
1056
1124
  :value => val[0],
@@ -1062,8 +1130,8 @@ module_eval <<'.,.,', 'grammar.ra', 366
1062
1130
  end
1063
1131
  .,.,
1064
1132
 
1065
- module_eval <<'.,.,', 'grammar.ra', 378
1066
- def _reduce_59( val, _values, result )
1133
+ module_eval <<'.,.,', 'grammar.ra', 411
1134
+ def _reduce_65( val, _values, result )
1067
1135
  result = AST::CaseOpt.new(
1068
1136
  :pin => ":",
1069
1137
  :value => val[0],
@@ -1079,10 +1147,10 @@ module_eval <<'.,.,', 'grammar.ra', 378
1079
1147
  end
1080
1148
  .,.,
1081
1149
 
1082
- # reduce 60 omitted
1150
+ # reduce 66 omitted
1083
1151
 
1084
- module_eval <<'.,.,', 'grammar.ra', 392
1085
- def _reduce_61( val, _values, result )
1152
+ module_eval <<'.,.,', 'grammar.ra', 425
1153
+ def _reduce_67( val, _values, result )
1086
1154
  if val[0].instance_of?(AST::ASTArray)
1087
1155
  val[0].push(val[2])
1088
1156
  result = val[0]
@@ -1097,8 +1165,8 @@ module_eval <<'.,.,', 'grammar.ra', 392
1097
1165
  end
1098
1166
  .,.,
1099
1167
 
1100
- module_eval <<'.,.,', 'grammar.ra', 402
1101
- def _reduce_62( val, _values, result )
1168
+ module_eval <<'.,.,', 'grammar.ra', 435
1169
+ def _reduce_68( val, _values, result )
1102
1170
  result = AST::Selector.new(
1103
1171
  :pin => "?",
1104
1172
  :line => @lexer.line,
@@ -1110,19 +1178,19 @@ module_eval <<'.,.,', 'grammar.ra', 402
1110
1178
  end
1111
1179
  .,.,
1112
1180
 
1113
- # reduce 63 omitted
1181
+ # reduce 69 omitted
1114
1182
 
1115
- module_eval <<'.,.,', 'grammar.ra', 404
1116
- def _reduce_64( val, _values, result )
1183
+ module_eval <<'.,.,', 'grammar.ra', 437
1184
+ def _reduce_70( val, _values, result )
1117
1185
  result = val[1]
1118
1186
  result
1119
1187
  end
1120
1188
  .,.,
1121
1189
 
1122
- # reduce 65 omitted
1190
+ # reduce 71 omitted
1123
1191
 
1124
- module_eval <<'.,.,', 'grammar.ra', 419
1125
- def _reduce_66( val, _values, result )
1192
+ module_eval <<'.,.,', 'grammar.ra', 452
1193
+ def _reduce_72( val, _values, result )
1126
1194
  if val[0].instance_of?(AST::ASTArray)
1127
1195
  val[0].push(val[2])
1128
1196
  result = val[0]
@@ -1137,8 +1205,8 @@ module_eval <<'.,.,', 'grammar.ra', 419
1137
1205
  end
1138
1206
  .,.,
1139
1207
 
1140
- module_eval <<'.,.,', 'grammar.ra', 429
1141
- def _reduce_67( val, _values, result )
1208
+ module_eval <<'.,.,', 'grammar.ra', 462
1209
+ def _reduce_73( val, _values, result )
1142
1210
  result = AST::ObjectParam.new(
1143
1211
  :pin => "=>",
1144
1212
  :line => @lexer.line,
@@ -1150,34 +1218,20 @@ module_eval <<'.,.,', 'grammar.ra', 429
1150
1218
  end
1151
1219
  .,.,
1152
1220
 
1153
- module_eval <<'.,.,', 'grammar.ra', 437
1154
- def _reduce_68( val, _values, result )
1155
- result = AST::String.new(
1156
- :line => @lexer.line,
1157
- :file => @lexer.file,
1158
- :value => val[0]
1159
- )
1160
- result
1161
- end
1162
- .,.,
1221
+ # reduce 74 omitted
1163
1222
 
1164
- module_eval <<'.,.,', 'grammar.ra', 444
1165
- def _reduce_69( val, _values, result )
1166
- result = AST::String.new(
1167
- :line => @lexer.line,
1168
- :file => @lexer.file,
1169
- :value => val[0]
1170
- )
1171
- result
1172
- end
1173
- .,.,
1223
+ # reduce 75 omitted
1174
1224
 
1175
- # reduce 70 omitted
1225
+ # reduce 76 omitted
1176
1226
 
1177
- # reduce 71 omitted
1227
+ # reduce 77 omitted
1178
1228
 
1179
- module_eval <<'.,.,', 'grammar.ra', 453
1180
- def _reduce_72( val, _values, result )
1229
+ # reduce 78 omitted
1230
+
1231
+ # reduce 79 omitted
1232
+
1233
+ module_eval <<'.,.,', 'grammar.ra', 476
1234
+ def _reduce_80( val, _values, result )
1181
1235
  result = AST::Default.new(
1182
1236
  :line => @lexer.line,
1183
1237
  :file => @lexer.file,
@@ -1187,10 +1241,8 @@ module_eval <<'.,.,', 'grammar.ra', 453
1187
1241
  end
1188
1242
  .,.,
1189
1243
 
1190
- # reduce 73 omitted
1191
-
1192
- module_eval <<'.,.,', 'grammar.ra', 506
1193
- def _reduce_74( val, _values, result )
1244
+ module_eval <<'.,.,', 'grammar.ra', 535
1245
+ def _reduce_81( val, _values, result )
1194
1246
  # importing files
1195
1247
  # yuk, i hate keywords
1196
1248
  # we'll probably have to have some kind of search path eventually
@@ -1203,6 +1255,7 @@ module_eval <<'.,.,', 'grammar.ra', 506
1203
1255
  :file => @lexer.file,
1204
1256
  :line => @lexer.line
1205
1257
  )
1258
+
1206
1259
  Dir.chdir(dir) {
1207
1260
  # We can't interpolate at this point since we don't have any
1208
1261
  # scopes set up. Warn the user if they use a variable reference
@@ -1213,39 +1266,45 @@ module_eval <<'.,.,', 'grammar.ra', 506
1213
1266
  " variables are not interpolated for imports " +
1214
1267
  "in file #{@lexer.file} at line #{@lexer.line}"
1215
1268
  )
1216
- end
1269
+ end
1217
1270
  files = Dir.glob(pat)
1218
1271
  if files.size == 0
1219
- raise Puppet::ImportError.new("No file(s) found for import " +
1220
- "of '#{pat}'")
1272
+ files = Dir.glob(pat + ".pp")
1273
+ if files.size == 0
1274
+ raise Puppet::ImportError.new("No file(s) found for import " +
1275
+ "of '#{pat}'")
1276
+ end
1221
1277
  end
1278
+
1222
1279
  files.each { |file|
1223
1280
  parser = Puppet::Parser::Parser.new()
1224
1281
  parser.files = self.files
1225
1282
  Puppet.debug("importing '%s'" % file)
1283
+
1284
+ unless file =~ /^#{File::SEPARATOR}/
1285
+ file = File.join(dir, file)
1286
+ end
1226
1287
  begin
1227
- parser.file = File.join(dir, file)
1288
+ parser.file = file
1228
1289
  rescue Puppet::ImportError
1229
1290
  Puppet.warning(
1230
1291
  "Importing %s would result in an import loop" %
1231
1292
  File.join(dir, file)
1232
1293
  )
1233
- result = AST::ASTArray.new(
1234
- :file => @lexer.file,
1235
- :line => @lexer.line
1236
- )
1237
1294
  next
1238
1295
  end
1239
1296
  # push the results into the main result array
1240
- result.push parser.parse
1297
+ parser.parse.each do |child|
1298
+ result.push child
1299
+ end
1241
1300
  }
1242
1301
  }
1243
1302
  result
1244
1303
  end
1245
1304
  .,.,
1246
1305
 
1247
- module_eval <<'.,.,', 'grammar.ra', 517
1248
- def _reduce_75( val, _values, result )
1306
+ module_eval <<'.,.,', 'grammar.ra', 546
1307
+ def _reduce_82( val, _values, result )
1249
1308
  result = AST::CompDef.new(
1250
1309
  :type => AST::Name.new(:value => val[1], :line => @lexer.line),
1251
1310
  :args => val[2],
@@ -1258,8 +1317,8 @@ module_eval <<'.,.,', 'grammar.ra', 517
1258
1317
  end
1259
1318
  .,.,
1260
1319
 
1261
- module_eval <<'.,.,', 'grammar.ra', 530
1262
- def _reduce_76( val, _values, result )
1320
+ module_eval <<'.,.,', 'grammar.ra', 559
1321
+ def _reduce_83( val, _values, result )
1263
1322
  result = AST::CompDef.new(
1264
1323
  :type => AST::Name.new(:value => val[1], :line => @lexer.line),
1265
1324
  :args => val[2],
@@ -1276,8 +1335,8 @@ module_eval <<'.,.,', 'grammar.ra', 530
1276
1335
  end
1277
1336
  .,.,
1278
1337
 
1279
- module_eval <<'.,.,', 'grammar.ra', 547
1280
- def _reduce_77( val, _values, result )
1338
+ module_eval <<'.,.,', 'grammar.ra', 576
1339
+ def _reduce_84( val, _values, result )
1281
1340
  #:args => val[2],
1282
1341
  args = {
1283
1342
  :type => AST::Name.new(:value => val[1], :line => @lexer.line),
@@ -1295,8 +1354,8 @@ module_eval <<'.,.,', 'grammar.ra', 547
1295
1354
  end
1296
1355
  .,.,
1297
1356
 
1298
- module_eval <<'.,.,', 'grammar.ra', 564
1299
- def _reduce_78( val, _values, result )
1357
+ module_eval <<'.,.,', 'grammar.ra', 593
1358
+ def _reduce_85( val, _values, result )
1300
1359
  args = {
1301
1360
  :type => AST::Name.new(:value => val[1], :line => @lexer.line),
1302
1361
  :file => @lexer.file,
@@ -1317,8 +1376,8 @@ module_eval <<'.,.,', 'grammar.ra', 564
1317
1376
  end
1318
1377
  .,.,
1319
1378
 
1320
- module_eval <<'.,.,', 'grammar.ra', 585
1321
- def _reduce_79( val, _values, result )
1379
+ module_eval <<'.,.,', 'grammar.ra', 614
1380
+ def _reduce_86( val, _values, result )
1322
1381
  unless val[1].instance_of?(AST::ASTArray)
1323
1382
  val[1] = AST::ASTArray.new(
1324
1383
  :line => val[1].line,
@@ -1341,8 +1400,8 @@ module_eval <<'.,.,', 'grammar.ra', 585
1341
1400
  end
1342
1401
  .,.,
1343
1402
 
1344
- module_eval <<'.,.,', 'grammar.ra', 608
1345
- def _reduce_80( val, _values, result )
1403
+ module_eval <<'.,.,', 'grammar.ra', 637
1404
+ def _reduce_87( val, _values, result )
1346
1405
  unless val[1].instance_of?(AST::ASTArray)
1347
1406
  val[1] = AST::ASTArray.new(
1348
1407
  :line => val[1].line,
@@ -1369,26 +1428,26 @@ module_eval <<'.,.,', 'grammar.ra', 608
1369
1428
  end
1370
1429
  .,.,
1371
1430
 
1372
- # reduce 81 omitted
1431
+ # reduce 88 omitted
1373
1432
 
1374
- module_eval <<'.,.,', 'grammar.ra', 622
1375
- def _reduce_82( val, _values, result )
1433
+ module_eval <<'.,.,', 'grammar.ra', 652
1434
+ def _reduce_89( val, _values, result )
1376
1435
  if val[0].instance_of?(AST::ASTArray)
1377
1436
  result = val[0]
1378
- result.push val[1]
1437
+ result.push val[2]
1379
1438
  else
1380
1439
  result = AST::ASTArray.new(
1381
1440
  :line => @lexer.line,
1382
1441
  :file => @lexer.file,
1383
- :children => [val[0], val[1]]
1442
+ :children => [val[0], val[2]]
1384
1443
  )
1385
1444
  end
1386
1445
  result
1387
1446
  end
1388
1447
  .,.,
1389
1448
 
1390
- module_eval <<'.,.,', 'grammar.ra', 630
1391
- def _reduce_83( val, _values, result )
1449
+ module_eval <<'.,.,', 'grammar.ra', 660
1450
+ def _reduce_90( val, _values, result )
1392
1451
  result = AST::HostName.new(
1393
1452
  :line => @lexer.line,
1394
1453
  :file => @lexer.file,
@@ -1398,8 +1457,8 @@ module_eval <<'.,.,', 'grammar.ra', 630
1398
1457
  end
1399
1458
  .,.,
1400
1459
 
1401
- module_eval <<'.,.,', 'grammar.ra', 636
1402
- def _reduce_84( val, _values, result )
1460
+ module_eval <<'.,.,', 'grammar.ra', 666
1461
+ def _reduce_91( val, _values, result )
1403
1462
  result = AST::HostName.new(
1404
1463
  :line => @lexer.line,
1405
1464
  :file => @lexer.file,
@@ -1409,8 +1468,19 @@ module_eval <<'.,.,', 'grammar.ra', 636
1409
1468
  end
1410
1469
  .,.,
1411
1470
 
1412
- module_eval <<'.,.,', 'grammar.ra', 644
1413
- def _reduce_85( val, _values, result )
1471
+ module_eval <<'.,.,', 'grammar.ra', 672
1472
+ def _reduce_92( val, _values, result )
1473
+ result = AST::Default.new(
1474
+ :line => @lexer.line,
1475
+ :file => @lexer.file,
1476
+ :value => val[0]
1477
+ )
1478
+ result
1479
+ end
1480
+ .,.,
1481
+
1482
+ module_eval <<'.,.,', 'grammar.ra', 680
1483
+ def _reduce_93( val, _values, result )
1414
1484
  result = AST::ASTArray.new(
1415
1485
  :line => @lexer.line,
1416
1486
  :file => @lexer.file,
@@ -1420,17 +1490,17 @@ module_eval <<'.,.,', 'grammar.ra', 644
1420
1490
  end
1421
1491
  .,.,
1422
1492
 
1423
- # reduce 86 omitted
1493
+ # reduce 94 omitted
1424
1494
 
1425
- module_eval <<'.,.,', 'grammar.ra', 649
1426
- def _reduce_87( val, _values, result )
1495
+ module_eval <<'.,.,', 'grammar.ra', 685
1496
+ def _reduce_95( val, _values, result )
1427
1497
  result = val[1]
1428
1498
  result
1429
1499
  end
1430
1500
  .,.,
1431
1501
 
1432
- module_eval <<'.,.,', 'grammar.ra', 660
1433
- def _reduce_88( val, _values, result )
1502
+ module_eval <<'.,.,', 'grammar.ra', 696
1503
+ def _reduce_96( val, _values, result )
1434
1504
  if val[1].instance_of?(AST::ASTArray)
1435
1505
  result = val[1]
1436
1506
  else
@@ -1444,10 +1514,10 @@ module_eval <<'.,.,', 'grammar.ra', 660
1444
1514
  end
1445
1515
  .,.,
1446
1516
 
1447
- # reduce 89 omitted
1517
+ # reduce 97 omitted
1448
1518
 
1449
- module_eval <<'.,.,', 'grammar.ra', 674
1450
- def _reduce_90( val, _values, result )
1519
+ module_eval <<'.,.,', 'grammar.ra', 710
1520
+ def _reduce_98( val, _values, result )
1451
1521
  if val[0].instance_of?(AST::ASTArray)
1452
1522
  val[0].push(val[2])
1453
1523
  result = val[0]
@@ -1462,8 +1532,8 @@ module_eval <<'.,.,', 'grammar.ra', 674
1462
1532
  end
1463
1533
  .,.,
1464
1534
 
1465
- module_eval <<'.,.,', 'grammar.ra', 682
1466
- def _reduce_91( val, _values, result )
1535
+ module_eval <<'.,.,', 'grammar.ra', 718
1536
+ def _reduce_99( val, _values, result )
1467
1537
  result = AST::CompArgument.new(
1468
1538
  :line => @lexer.line,
1469
1539
  :file => @lexer.file,
@@ -1473,8 +1543,8 @@ module_eval <<'.,.,', 'grammar.ra', 682
1473
1543
  end
1474
1544
  .,.,
1475
1545
 
1476
- module_eval <<'.,.,', 'grammar.ra', 689
1477
- def _reduce_92( val, _values, result )
1546
+ module_eval <<'.,.,', 'grammar.ra', 725
1547
+ def _reduce_100( val, _values, result )
1478
1548
  result = AST::CompArgument.new(
1479
1549
  :line => @lexer.line,
1480
1550
  :file => @lexer.file,
@@ -1484,10 +1554,10 @@ module_eval <<'.,.,', 'grammar.ra', 689
1484
1554
  end
1485
1555
  .,.,
1486
1556
 
1487
- # reduce 93 omitted
1557
+ # reduce 101 omitted
1488
1558
 
1489
- module_eval <<'.,.,', 'grammar.ra', 698
1490
- def _reduce_94( val, _values, result )
1559
+ module_eval <<'.,.,', 'grammar.ra', 734
1560
+ def _reduce_102( val, _values, result )
1491
1561
  result = AST::Name.new(
1492
1562
  :value => val[1],
1493
1563
  :file => @lexer.file,
@@ -1497,8 +1567,8 @@ module_eval <<'.,.,', 'grammar.ra', 698
1497
1567
  end
1498
1568
  .,.,
1499
1569
 
1500
- module_eval <<'.,.,', 'grammar.ra', 707
1501
- def _reduce_95( val, _values, result )
1570
+ module_eval <<'.,.,', 'grammar.ra', 743
1571
+ def _reduce_103( val, _values, result )
1502
1572
  name = val[0].sub(/^\$/,'')
1503
1573
  result = AST::Variable.new(
1504
1574
  :line => @lexer.line,
@@ -1509,8 +1579,8 @@ module_eval <<'.,.,', 'grammar.ra', 707
1509
1579
  end
1510
1580
  .,.,
1511
1581
 
1512
- module_eval <<'.,.,', 'grammar.ra', 719
1513
- def _reduce_96( val, _values, result )
1582
+ module_eval <<'.,.,', 'grammar.ra', 755
1583
+ def _reduce_104( val, _values, result )
1514
1584
  if val[1].instance_of?(AST::ASTArray)
1515
1585
  result = val[1]
1516
1586
  else
@@ -1524,14 +1594,25 @@ module_eval <<'.,.,', 'grammar.ra', 719
1524
1594
  end
1525
1595
  .,.,
1526
1596
 
1527
- # reduce 97 omitted
1597
+ module_eval <<'.,.,', 'grammar.ra', 761
1598
+ def _reduce_105( val, _values, result )
1599
+ result = AST::ASTArray.new(
1600
+ :line => @lexer.line,
1601
+ :file => @lexer.file,
1602
+ :children => []
1603
+ )
1604
+ result
1605
+ end
1606
+ .,.,
1528
1607
 
1529
- # reduce 98 omitted
1608
+ # reduce 106 omitted
1530
1609
 
1531
- # reduce 99 omitted
1610
+ # reduce 107 omitted
1532
1611
 
1533
- module_eval <<'.,.,', 'grammar.ra', 724
1534
- def _reduce_100( val, _values, result )
1612
+ # reduce 108 omitted
1613
+
1614
+ module_eval <<'.,.,', 'grammar.ra', 766
1615
+ def _reduce_109( val, _values, result )
1535
1616
  result = nil
1536
1617
  result
1537
1618
  end