ruby-internal 0.7.3 → 0.8.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (254) hide show
  1. data/bin/ruby-internal-node-dump +1 -1
  2. data/bin/ruby-internal-obfuscate +1 -1
  3. data/ext/cached/ruby-1.8.4/internal/method/{method.h → internal_method.h} +12 -0
  4. data/ext/cached/ruby-1.8.4/internal/module/getcfp.h +13 -0
  5. data/ext/cached/ruby-1.8.4/internal/node/global_entry.h +94 -0
  6. data/ext/cached/ruby-1.8.4/internal/node/node_type_descrip.c +41 -41
  7. data/ext/cached/ruby-1.8.4/internal/node/nodeinfo.c +288 -273
  8. data/ext/cached/ruby-1.8.4/internal/vm/instruction/insns_info.c +3 -0
  9. data/ext/cached/ruby-1.8.4/internal/vm/iseq/iseq_load.inc +21 -2
  10. data/ext/cached/{ruby-1.8.3/internal/method/method.h → ruby-1.8.5/internal/method/internal_method.h} +12 -0
  11. data/ext/cached/ruby-1.8.5/internal/module/getcfp.h +13 -0
  12. data/ext/cached/ruby-1.8.5/internal/node/global_entry.h +94 -0
  13. data/ext/cached/ruby-1.8.5/internal/node/node_type_descrip.c +45 -45
  14. data/ext/cached/ruby-1.8.5/internal/node/nodeinfo.c +310 -295
  15. data/ext/cached/ruby-1.8.5/internal/vm/instruction/insns_info.c +3 -0
  16. data/ext/cached/ruby-1.8.5/internal/vm/iseq/iseq_load.inc +21 -2
  17. data/ext/cached/{ruby-1.8.5/internal/method/method.h → ruby-1.8.6/internal/method/internal_method.h} +12 -0
  18. data/ext/cached/ruby-1.8.6/internal/module/getcfp.h +13 -0
  19. data/ext/cached/ruby-1.8.6/internal/node/global_entry.h +94 -0
  20. data/ext/cached/ruby-1.8.6/internal/node/node_type_descrip.c +48 -48
  21. data/ext/cached/ruby-1.8.6/internal/node/nodeinfo.c +323 -308
  22. data/ext/cached/ruby-1.8.6/internal/vm/instruction/insns_info.c +3 -0
  23. data/ext/cached/ruby-1.8.6/internal/vm/iseq/iseq_load.inc +21 -2
  24. data/ext/cached/{ruby-1.8.6/internal/method/method.h → ruby-1.8.7/internal/method/internal_method.h} +12 -0
  25. data/ext/cached/ruby-1.8.7/internal/module/getcfp.h +13 -0
  26. data/ext/cached/ruby-1.8.7/internal/node/global_entry.h +98 -0
  27. data/ext/cached/ruby-1.8.7/internal/node/node_type_descrip.c +42 -42
  28. data/ext/cached/ruby-1.8.7/internal/node/nodeinfo.c +276 -261
  29. data/ext/cached/ruby-1.8.7/internal/vm/instruction/insns_info.c +3 -0
  30. data/ext/cached/ruby-1.8.7/internal/vm/iseq/iseq_load.inc +21 -2
  31. data/ext/cached/{ruby-1.9.0/internal/method/method.h → ruby-1.9.1/internal/method/internal_method.h} +12 -0
  32. data/ext/cached/ruby-1.9.1/internal/module/classpath.c +12 -14
  33. data/ext/cached/ruby-1.9.1/internal/module/getcfp.h +25 -0
  34. data/ext/cached/ruby-1.9.1/internal/node/global_entry.h +86 -0
  35. data/ext/cached/ruby-1.9.1/internal/node/node_type_descrip.c +46 -48
  36. data/ext/cached/ruby-1.9.1/internal/node/nodeinfo.c +311 -412
  37. data/ext/cached/ruby-1.9.1/internal/vm/instruction/insns_info.c +3 -0
  38. data/ext/cached/ruby-1.9.1/internal/vm/iseq/iseq_load.inc +28 -6
  39. data/ext/cached/ruby-1.9.1/internal/yarv-headers/iseq.h +1 -0
  40. data/ext/cached/ruby-1.9.1/internal/yarv-headers/parse.h +6 -6
  41. data/ext/cached/ruby-1.9.1/internal/yarv-headers/revision.h +1 -1
  42. data/ext/cached/ruby-1.9.1/internal/yarv-headers/version.h +6 -5
  43. data/ext/cached/ruby-1.9.1/internal/yarv-headers/vm_core.h +3 -2
  44. data/ext/cached/ruby-1.9.1/internal/yarv-headers/vm_insnhelper.h +1 -0
  45. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/binding/block.h +0 -0
  46. data/ext/cached/{ruby-1.9.1/internal/method/method.h → ruby-1.9.2/internal/method/internal_method.h} +16 -5
  47. data/ext/cached/ruby-1.9.2/internal/module/classpath.c +40 -0
  48. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/module/classpath.h +0 -0
  49. data/ext/cached/ruby-1.9.2/internal/module/getcfp.h +25 -0
  50. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/node/block.h +0 -0
  51. data/ext/cached/ruby-1.9.2/internal/node/global_entry.h +93 -0
  52. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/node/node_type_descrip.c +44 -48
  53. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/node/nodeinfo.c +291 -439
  54. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/node/nodeinfo.h +0 -0
  55. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/proc/block.h +0 -0
  56. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/tag/tag.h +0 -0
  57. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/vm/instruction/insns_info.c +141 -64
  58. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/vm/instruction/insns_info.h +88 -80
  59. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/vm/iseq/insns_info.inc +77 -70
  60. data/ext/cached/ruby-1.9.2/internal/vm/iseq/iseq_load.inc +426 -0
  61. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/yarv-headers/debug.h +1 -1
  62. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/yarv-headers/dln.h +3 -3
  63. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/yarv-headers/encdb.h +18 -2
  64. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/yarv-headers/eval_intern.h +39 -28
  65. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/yarv-headers/gc.h +7 -5
  66. data/ext/cached/ruby-1.9.2/internal/yarv-headers/id.h +170 -0
  67. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/yarv-headers/iseq.h +20 -10
  68. data/ext/cached/ruby-1.9.2/internal/yarv-headers/method.h +103 -0
  69. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/yarv-headers/node.h +14 -47
  70. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/yarv-headers/parse.h +31 -148
  71. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/yarv-headers/regenc.h +7 -3
  72. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/yarv-headers/regint.h +16 -17
  73. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/yarv-headers/regparse.h +4 -1
  74. data/ext/cached/ruby-1.9.2/internal/yarv-headers/revision.h +1 -0
  75. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/yarv-headers/thread_pthread.h +4 -1
  76. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/yarv-headers/thread_win32.h +1 -1
  77. data/ext/cached/ruby-1.9.2/internal/yarv-headers/timev.h +21 -0
  78. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/yarv-headers/transcode_data.h +20 -10
  79. data/ext/cached/ruby-1.9.2/internal/yarv-headers/transdb.h +179 -0
  80. data/ext/cached/ruby-1.9.2/internal/yarv-headers/version.h +55 -0
  81. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/yarv-headers/vm_core.h +127 -84
  82. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/yarv-headers/vm_exec.h +4 -7
  83. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/yarv-headers/vm_insnhelper.h +53 -36
  84. data/ext/cached/{ruby-1.9.0 → ruby-1.9.2}/internal/yarv-headers/vm_opts.h +1 -1
  85. data/ext/cached/ruby-1.9.3/internal/binding/block.h +12 -0
  86. data/ext/cached/ruby-1.9.3/internal/method/internal_method.h +32 -0
  87. data/ext/cached/ruby-1.9.3/internal/module/classpath.c +40 -0
  88. data/ext/cached/{ruby-1.8.0 → ruby-1.9.3}/internal/module/classpath.h +5 -2
  89. data/ext/cached/ruby-1.9.3/internal/module/getcfp.h +25 -0
  90. data/ext/cached/ruby-1.9.3/internal/node/block.h +12 -0
  91. data/ext/cached/ruby-1.9.3/internal/node/global_entry.h +93 -0
  92. data/ext/cached/{ruby-1.8.3 → ruby-1.9.3}/internal/node/node_type_descrip.c +48 -57
  93. data/ext/cached/{ruby-1.6.8 → ruby-1.9.3}/internal/node/nodeinfo.c +589 -740
  94. data/ext/cached/{ruby-1.8.0 → ruby-1.9.3}/internal/node/nodeinfo.h +4 -3
  95. data/ext/cached/ruby-1.9.3/internal/proc/block.h +12 -0
  96. data/ext/cached/ruby-1.9.3/internal/tag/tag.h +6 -0
  97. data/ext/cached/ruby-1.9.3/internal/vm/instruction/insns_info.c +6013 -0
  98. data/ext/cached/ruby-1.9.3/internal/vm/instruction/insns_info.h +899 -0
  99. data/ext/cached/ruby-1.9.3/internal/vm/iseq/insns_info.inc +707 -0
  100. data/ext/cached/ruby-1.9.3/internal/vm/iseq/iseq_load.inc +423 -0
  101. data/ext/cached/ruby-1.9.3/internal/yarv-headers/addr2line.h +21 -0
  102. data/ext/cached/ruby-1.9.3/internal/yarv-headers/atomic.h +56 -0
  103. data/ext/cached/ruby-1.9.3/internal/yarv-headers/constant.h +34 -0
  104. data/ext/cached/ruby-1.9.3/internal/yarv-headers/debug.h +41 -0
  105. data/ext/cached/ruby-1.9.3/internal/yarv-headers/dln.h +50 -0
  106. data/ext/cached/ruby-1.9.3/internal/yarv-headers/encdb.h +167 -0
  107. data/ext/cached/ruby-1.9.3/internal/yarv-headers/eval_intern.h +234 -0
  108. data/ext/cached/ruby-1.9.3/internal/yarv-headers/gc.h +98 -0
  109. data/ext/cached/ruby-1.9.3/internal/yarv-headers/id.h +175 -0
  110. data/ext/cached/ruby-1.9.3/internal/yarv-headers/internal.h +232 -0
  111. data/ext/cached/ruby-1.9.3/internal/yarv-headers/iseq.h +125 -0
  112. data/ext/cached/ruby-1.9.3/internal/yarv-headers/method.h +105 -0
  113. data/ext/cached/ruby-1.9.3/internal/yarv-headers/node.h +503 -0
  114. data/ext/cached/ruby-1.9.3/internal/yarv-headers/parse.h +186 -0
  115. data/ext/cached/ruby-1.9.3/internal/yarv-headers/regenc.h +219 -0
  116. data/ext/cached/ruby-1.9.3/internal/yarv-headers/regint.h +850 -0
  117. data/ext/cached/ruby-1.9.3/internal/yarv-headers/regparse.h +362 -0
  118. data/ext/cached/ruby-1.9.3/internal/yarv-headers/revision.h +1 -0
  119. data/ext/cached/ruby-1.9.3/internal/yarv-headers/thread_pthread.h +51 -0
  120. data/ext/cached/ruby-1.9.3/internal/yarv-headers/thread_win32.h +40 -0
  121. data/ext/cached/ruby-1.9.3/internal/yarv-headers/timev.h +21 -0
  122. data/ext/cached/ruby-1.9.3/internal/yarv-headers/transcode_data.h +117 -0
  123. data/ext/cached/ruby-1.9.3/internal/yarv-headers/transdb.h +189 -0
  124. data/ext/cached/ruby-1.9.3/internal/yarv-headers/version.h +52 -0
  125. data/ext/cached/ruby-1.9.3/internal/yarv-headers/vm_core.h +756 -0
  126. data/ext/cached/ruby-1.9.3/internal/yarv-headers/vm_exec.h +184 -0
  127. data/ext/cached/ruby-1.9.3/internal/yarv-headers/vm_insnhelper.h +220 -0
  128. data/ext/cached/ruby-1.9.3/internal/yarv-headers/vm_opts.h +51 -0
  129. data/ext/internal/binding/block.h +20 -0
  130. data/ext/internal/method/internal_method.h +5 -38
  131. data/ext/internal/method/internal_method.h.rpp +0 -7
  132. data/ext/internal/method/method.c +52 -32
  133. data/ext/internal/module/classpath.c +18 -13
  134. data/ext/internal/module/classpath.h +3 -3
  135. data/ext/internal/module/extconf.rb +3 -2
  136. data/ext/internal/module/getcfp.h +13 -0
  137. data/ext/internal/module/getcfp.h.rpp +44 -0
  138. data/ext/internal/module/module.c +58 -21
  139. data/ext/internal/node/block.h +20 -0
  140. data/ext/internal/node/extconf.rb +2 -0
  141. data/ext/internal/node/global_entry.h +69 -13
  142. data/ext/internal/node/global_entry.h.rpp +11 -2
  143. data/ext/internal/node/node.c +30 -3
  144. data/ext/internal/node/node_type_descrip.c +47 -38
  145. data/ext/internal/node/nodeinfo.c +622 -306
  146. data/ext/internal/node/nodeinfo.h +1 -4
  147. data/ext/internal/proc/block.h +20 -0
  148. data/ext/internal/tag/tag.h +10 -0
  149. data/ext/internal/thread/thread.c +9 -3
  150. data/ext/internal/vm/extconf.rb +1 -0
  151. data/ext/internal/vm/instruction/insns_info.c +3 -5974
  152. data/ext/internal/vm/instruction/insns_info.h +0 -878
  153. data/ext/internal/vm/iseq/extconf.rb +1 -0
  154. data/ext/internal/vm/iseq/iseq.c +38 -4
  155. data/ext/internal/vm/iseq/iseq_load.inc.rpp +23 -5
  156. data/ext/internal/vm/vm.c +28 -0
  157. data/lib/internal/classtree.rb +28 -0
  158. data/lib/internal/debug.rb +10 -2
  159. data/lib/internal/method/as_code.rb +25 -0
  160. data/lib/internal/method/as_expression.rb +2 -3
  161. data/lib/internal/method/origin.rb +29 -0
  162. data/lib/internal/method/signature.rb +5 -300
  163. data/lib/internal/method/signature/argument.rb +102 -0
  164. data/lib/internal/method/signature/iseq.rb +52 -0
  165. data/lib/internal/method/signature/node.rb +160 -0
  166. data/lib/internal/method/signature/signature.rb +23 -0
  167. data/lib/internal/proc/as_code.rb +2 -0
  168. data/lib/internal/proc/as_expression.rb +2 -0
  169. data/lib/internal/vm/bytedecoder.rb +5 -5
  170. data/lib/internal/vm/iseq/as_code.rb +2 -2
  171. data/lib/internal/vm/iseq/as_expression.rb +2 -2
  172. data/test/test_dump_method.rb +1 -1
  173. data/test/test_method.rb +21 -3
  174. data/test/test_node.rb +20 -4
  175. metadata +152 -155
  176. data/ext/cached/ruby-1.6.8/internal/binding/block.h +0 -35
  177. data/ext/cached/ruby-1.6.8/internal/method/method.h +0 -19
  178. data/ext/cached/ruby-1.6.8/internal/module/classpath.c +0 -3
  179. data/ext/cached/ruby-1.6.8/internal/module/classpath.h +0 -8
  180. data/ext/cached/ruby-1.6.8/internal/node/block.h +0 -35
  181. data/ext/cached/ruby-1.6.8/internal/node/global_entry.h +0 -15
  182. data/ext/cached/ruby-1.6.8/internal/node/node_type_descrip.c +0 -149
  183. data/ext/cached/ruby-1.6.8/internal/node/nodeinfo.h +0 -69
  184. data/ext/cached/ruby-1.6.8/internal/proc/block.h +0 -35
  185. data/ext/cached/ruby-1.6.8/internal/tag/tag.h +0 -15
  186. data/ext/cached/ruby-1.6.8/internal/vm/instruction/insns_info.c +0 -39
  187. data/ext/cached/ruby-1.6.8/internal/vm/instruction/insns_info.h +0 -21
  188. data/ext/cached/ruby-1.6.8/internal/vm/iseq/insns_info.inc +0 -12
  189. data/ext/cached/ruby-1.6.8/internal/vm/iseq/iseq_load.inc +0 -9
  190. data/ext/cached/ruby-1.8.0/internal/binding/block.h +0 -37
  191. data/ext/cached/ruby-1.8.0/internal/method/method.h +0 -19
  192. data/ext/cached/ruby-1.8.0/internal/module/classpath.c +0 -27
  193. data/ext/cached/ruby-1.8.0/internal/node/block.h +0 -37
  194. data/ext/cached/ruby-1.8.0/internal/node/global_entry.h +0 -10
  195. data/ext/cached/ruby-1.8.0/internal/node/node_type_descrip.c +0 -155
  196. data/ext/cached/ruby-1.8.0/internal/node/nodeinfo.c +0 -5744
  197. data/ext/cached/ruby-1.8.0/internal/proc/block.h +0 -37
  198. data/ext/cached/ruby-1.8.0/internal/tag/tag.h +0 -15
  199. data/ext/cached/ruby-1.8.0/internal/vm/instruction/insns_info.c +0 -39
  200. data/ext/cached/ruby-1.8.0/internal/vm/instruction/insns_info.h +0 -21
  201. data/ext/cached/ruby-1.8.0/internal/vm/iseq/insns_info.inc +0 -12
  202. data/ext/cached/ruby-1.8.0/internal/vm/iseq/iseq_load.inc +0 -9
  203. data/ext/cached/ruby-1.8.1/internal/binding/block.h +0 -31
  204. data/ext/cached/ruby-1.8.1/internal/method/method.h +0 -19
  205. data/ext/cached/ruby-1.8.1/internal/module/classpath.c +0 -27
  206. data/ext/cached/ruby-1.8.1/internal/module/classpath.h +0 -14
  207. data/ext/cached/ruby-1.8.1/internal/node/block.h +0 -31
  208. data/ext/cached/ruby-1.8.1/internal/node/global_entry.h +0 -10
  209. data/ext/cached/ruby-1.8.1/internal/node/node_type_descrip.c +0 -154
  210. data/ext/cached/ruby-1.8.1/internal/node/nodeinfo.c +0 -5736
  211. data/ext/cached/ruby-1.8.1/internal/node/nodeinfo.h +0 -69
  212. data/ext/cached/ruby-1.8.1/internal/proc/block.h +0 -31
  213. data/ext/cached/ruby-1.8.1/internal/tag/tag.h +0 -16
  214. data/ext/cached/ruby-1.8.1/internal/vm/instruction/insns_info.c +0 -39
  215. data/ext/cached/ruby-1.8.1/internal/vm/instruction/insns_info.h +0 -21
  216. data/ext/cached/ruby-1.8.1/internal/vm/iseq/insns_info.inc +0 -12
  217. data/ext/cached/ruby-1.8.1/internal/vm/iseq/iseq_load.inc +0 -9
  218. data/ext/cached/ruby-1.8.2/internal/binding/block.h +0 -32
  219. data/ext/cached/ruby-1.8.2/internal/method/method.h +0 -19
  220. data/ext/cached/ruby-1.8.2/internal/module/classpath.c +0 -45
  221. data/ext/cached/ruby-1.8.2/internal/module/classpath.h +0 -17
  222. data/ext/cached/ruby-1.8.2/internal/node/block.h +0 -32
  223. data/ext/cached/ruby-1.8.2/internal/node/global_entry.h +0 -10
  224. data/ext/cached/ruby-1.8.2/internal/node/node_type_descrip.c +0 -154
  225. data/ext/cached/ruby-1.8.2/internal/node/nodeinfo.c +0 -5736
  226. data/ext/cached/ruby-1.8.2/internal/node/nodeinfo.h +0 -69
  227. data/ext/cached/ruby-1.8.2/internal/proc/block.h +0 -32
  228. data/ext/cached/ruby-1.8.2/internal/tag/tag.h +0 -16
  229. data/ext/cached/ruby-1.8.2/internal/vm/instruction/insns_info.c +0 -39
  230. data/ext/cached/ruby-1.8.2/internal/vm/instruction/insns_info.h +0 -21
  231. data/ext/cached/ruby-1.8.2/internal/vm/iseq/insns_info.inc +0 -12
  232. data/ext/cached/ruby-1.8.2/internal/vm/iseq/iseq_load.inc +0 -9
  233. data/ext/cached/ruby-1.8.3/internal/binding/block.h +0 -32
  234. data/ext/cached/ruby-1.8.3/internal/module/classpath.c +0 -45
  235. data/ext/cached/ruby-1.8.3/internal/module/classpath.h +0 -17
  236. data/ext/cached/ruby-1.8.3/internal/node/block.h +0 -32
  237. data/ext/cached/ruby-1.8.3/internal/node/global_entry.h +0 -10
  238. data/ext/cached/ruby-1.8.3/internal/node/nodeinfo.c +0 -5736
  239. data/ext/cached/ruby-1.8.3/internal/node/nodeinfo.h +0 -69
  240. data/ext/cached/ruby-1.8.3/internal/proc/block.h +0 -32
  241. data/ext/cached/ruby-1.8.3/internal/tag/tag.h +0 -16
  242. data/ext/cached/ruby-1.8.3/internal/vm/instruction/insns_info.c +0 -39
  243. data/ext/cached/ruby-1.8.3/internal/vm/instruction/insns_info.h +0 -21
  244. data/ext/cached/ruby-1.8.3/internal/vm/iseq/insns_info.inc +0 -12
  245. data/ext/cached/ruby-1.8.3/internal/vm/iseq/iseq_load.inc +0 -9
  246. data/ext/cached/ruby-1.8.7/internal/method/method.h +0 -20
  247. data/ext/cached/ruby-1.9.0/internal/module/classpath.c +0 -42
  248. data/ext/cached/ruby-1.9.0/internal/node/global_entry.h +0 -10
  249. data/ext/cached/ruby-1.9.0/internal/vm/iseq/iseq_load.inc +0 -13
  250. data/ext/cached/ruby-1.9.0/internal/yarv-headers/id.h +0 -83
  251. data/ext/cached/ruby-1.9.0/internal/yarv-headers/revision.h +0 -1
  252. data/ext/cached/ruby-1.9.0/internal/yarv-headers/transdb.h +0 -67
  253. data/ext/cached/ruby-1.9.0/internal/yarv-headers/version.h +0 -57
  254. data/ext/internal/module/cfp.h +0 -13
@@ -228,7 +228,7 @@ VALUE dump_node_elem(enum Node_Elem_Name nen, NODE * n, VALUE node_hash)
228
228
  else
229
229
  {
230
230
  path = rb_class_path(klass);
231
- if(STR2CSTR(path)[0] == '#')
231
+ if(StringValuePtr(path)[0] == '#')
232
232
  {
233
233
  rb_raise(rb_eArgError, "cannot dump anonymous class");
234
234
  }
@@ -322,7 +322,7 @@ VALUE dump_node_elem(enum Node_Elem_Name nen, NODE * n, VALUE node_hash)
322
322
  else
323
323
  {
324
324
  path = rb_class_path(klass);
325
- if(STR2CSTR(path)[0] == '#')
325
+ if(StringValuePtr(path)[0] == '#')
326
326
  {
327
327
  rb_raise(rb_eArgError, "cannot dump anonymous class");
328
328
  }
@@ -521,7 +521,7 @@ VALUE dump_node_elem(enum Node_Elem_Name nen, NODE * n, VALUE node_hash)
521
521
  else
522
522
  {
523
523
  path = rb_class_path(klass);
524
- if(STR2CSTR(path)[0] == '#')
524
+ if(StringValuePtr(path)[0] == '#')
525
525
  {
526
526
  rb_raise(rb_eArgError, "cannot dump anonymous class");
527
527
  }
@@ -658,7 +658,7 @@ VALUE dump_node_elem(enum Node_Elem_Name nen, NODE * n, VALUE node_hash)
658
658
  else
659
659
  {
660
660
  path = rb_class_path(klass);
661
- if(STR2CSTR(path)[0] == '#')
661
+ if(StringValuePtr(path)[0] == '#')
662
662
  {
663
663
  rb_raise(rb_eArgError, "cannot dump anonymous class");
664
664
  }
@@ -872,7 +872,7 @@ VALUE dump_node_elem(enum Node_Elem_Name nen, NODE * n, VALUE node_hash)
872
872
  else
873
873
  {
874
874
  path = rb_class_path(klass);
875
- if(STR2CSTR(path)[0] == '#')
875
+ if(StringValuePtr(path)[0] == '#')
876
876
  {
877
877
  rb_raise(rb_eArgError, "cannot dump anonymous class");
878
878
  }
@@ -1131,20 +1131,23 @@ void load_node_elem(enum Node_Elem_Name nen, VALUE v, NODE * n, VALUE node_hash,
1131
1131
  }
1132
1132
  case NEN_CLSS:
1133
1133
  {
1134
+ int flags;
1134
1135
  Check_Type(v, T_ARRAY);
1135
1136
  if(RARRAY_LEN(v) != 2)
1136
1137
  {
1137
1138
  rb_raise(rb_eArgError, "wrong size for array");
1138
1139
  }
1139
- int flags = NUM2INT(RARRAY_PTR(v)[0]);
1140
+ flags = NUM2INT(RARRAY_PTR(v)[0]);
1140
1141
  switch(flags & T_MASK)
1141
1142
  {
1142
1143
  case T_CLASS:
1143
1144
  case T_MODULE:
1144
1145
  {
1145
- VALUE str = RARRAY_PTR(v)[1];
1146
+ VALUE str, klass;
1147
+
1148
+ str = RARRAY_PTR(v)[1];
1146
1149
  Check_Type(str, T_STRING);
1147
- VALUE klass = rb_path2class(STR2CSTR(str));
1150
+ klass = rb_path2class(StringValuePtr(str));
1148
1151
  if(flags & FL_SINGLETON)
1149
1152
  {
1150
1153
  *(VALUE *)(&n->nd_clss) =
@@ -1220,20 +1223,23 @@ void load_node_elem(enum Node_Elem_Name nen, VALUE v, NODE * n, VALUE node_hash,
1220
1223
  }
1221
1224
  case NEN_CVAL:
1222
1225
  {
1226
+ int flags;
1223
1227
  Check_Type(v, T_ARRAY);
1224
1228
  if(RARRAY_LEN(v) != 2)
1225
1229
  {
1226
1230
  rb_raise(rb_eArgError, "wrong size for array");
1227
1231
  }
1228
- int flags = NUM2INT(RARRAY_PTR(v)[0]);
1232
+ flags = NUM2INT(RARRAY_PTR(v)[0]);
1229
1233
  switch(flags & T_MASK)
1230
1234
  {
1231
1235
  case T_CLASS:
1232
1236
  case T_MODULE:
1233
1237
  {
1234
- VALUE str = RARRAY_PTR(v)[1];
1238
+ VALUE str, klass;
1239
+
1240
+ str = RARRAY_PTR(v)[1];
1235
1241
  Check_Type(str, T_STRING);
1236
- VALUE klass = rb_path2class(STR2CSTR(str));
1242
+ klass = rb_path2class(StringValuePtr(str));
1237
1243
  if(flags & FL_SINGLETON)
1238
1244
  {
1239
1245
  *(VALUE *)(&n->nd_cval) =
@@ -1414,20 +1420,23 @@ void load_node_elem(enum Node_Elem_Name nen, VALUE v, NODE * n, VALUE node_hash,
1414
1420
  }
1415
1421
  case NEN_LIT:
1416
1422
  {
1423
+ int flags;
1417
1424
  Check_Type(v, T_ARRAY);
1418
1425
  if(RARRAY_LEN(v) != 2)
1419
1426
  {
1420
1427
  rb_raise(rb_eArgError, "wrong size for array");
1421
1428
  }
1422
- int flags = NUM2INT(RARRAY_PTR(v)[0]);
1429
+ flags = NUM2INT(RARRAY_PTR(v)[0]);
1423
1430
  switch(flags & T_MASK)
1424
1431
  {
1425
1432
  case T_CLASS:
1426
1433
  case T_MODULE:
1427
1434
  {
1428
- VALUE str = RARRAY_PTR(v)[1];
1435
+ VALUE str, klass;
1436
+
1437
+ str = RARRAY_PTR(v)[1];
1429
1438
  Check_Type(str, T_STRING);
1430
- VALUE klass = rb_path2class(STR2CSTR(str));
1439
+ klass = rb_path2class(StringValuePtr(str));
1431
1440
  if(flags & FL_SINGLETON)
1432
1441
  {
1433
1442
  *(VALUE *)(&n->nd_lit) =
@@ -1556,20 +1565,23 @@ void load_node_elem(enum Node_Elem_Name nen, VALUE v, NODE * n, VALUE node_hash,
1556
1565
  }
1557
1566
  case NEN_ORIG:
1558
1567
  {
1568
+ int flags;
1559
1569
  Check_Type(v, T_ARRAY);
1560
1570
  if(RARRAY_LEN(v) != 2)
1561
1571
  {
1562
1572
  rb_raise(rb_eArgError, "wrong size for array");
1563
1573
  }
1564
- int flags = NUM2INT(RARRAY_PTR(v)[0]);
1574
+ flags = NUM2INT(RARRAY_PTR(v)[0]);
1565
1575
  switch(flags & T_MASK)
1566
1576
  {
1567
1577
  case T_CLASS:
1568
1578
  case T_MODULE:
1569
1579
  {
1570
- VALUE str = RARRAY_PTR(v)[1];
1580
+ VALUE str, klass;
1581
+
1582
+ str = RARRAY_PTR(v)[1];
1571
1583
  Check_Type(str, T_STRING);
1572
- VALUE klass = rb_path2class(STR2CSTR(str));
1584
+ klass = rb_path2class(StringValuePtr(str));
1573
1585
  if(flags & FL_SINGLETON)
1574
1586
  {
1575
1587
  *(VALUE *)(&n->nd_orig) =
@@ -1808,20 +1820,23 @@ void load_node_elem(enum Node_Elem_Name nen, VALUE v, NODE * n, VALUE node_hash,
1808
1820
  }
1809
1821
  case NEN_TVAL:
1810
1822
  {
1823
+ int flags;
1811
1824
  Check_Type(v, T_ARRAY);
1812
1825
  if(RARRAY_LEN(v) != 2)
1813
1826
  {
1814
1827
  rb_raise(rb_eArgError, "wrong size for array");
1815
1828
  }
1816
- int flags = NUM2INT(RARRAY_PTR(v)[0]);
1829
+ flags = NUM2INT(RARRAY_PTR(v)[0]);
1817
1830
  switch(flags & T_MASK)
1818
1831
  {
1819
1832
  case T_CLASS:
1820
1833
  case T_MODULE:
1821
1834
  {
1822
- VALUE str = RARRAY_PTR(v)[1];
1835
+ VALUE str, klass;
1836
+
1837
+ str = RARRAY_PTR(v)[1];
1823
1838
  Check_Type(str, T_STRING);
1824
- VALUE klass = rb_path2class(STR2CSTR(str));
1839
+ klass = rb_path2class(StringValuePtr(str));
1825
1840
  if(flags & FL_SINGLETON)
1826
1841
  {
1827
1842
  *(VALUE *)(&n->nd_tval) =
@@ -2000,16 +2015,6 @@ static VALUE node_alen(VALUE self)
2000
2015
  Data_Get_Struct(self, NODE, n);
2001
2016
  return LONG2NUM(n->nd_alen);
2002
2017
  }
2003
- /*
2004
- * Return the Node's _argc_ member. The return type is an
2005
- * Integer.
2006
- */
2007
- static VALUE node_argc(VALUE self)
2008
- {
2009
- NODE * n;
2010
- Data_Get_Struct(self, NODE, n);
2011
- return LONG2NUM(n->nd_argc);
2012
- }
2013
2018
  /*
2014
2019
  * Return the Node's _args_ member. The return type is
2015
2020
  * either a Node or an Object.
@@ -2107,33 +2112,6 @@ static VALUE node_cfnc(VALUE self)
2107
2112
  Data_Get_Struct(self, NODE, n);
2108
2113
  return LONG2NUM((long)(n->nd_cfnc));
2109
2114
  }
2110
- /*
2111
- * Return the Node's _clss_ member. The return type is
2112
- * either a Node or an Object.
2113
- */
2114
- static VALUE node_clss(VALUE self)
2115
- {
2116
- NODE * n;
2117
- Data_Get_Struct(self, NODE, n);
2118
-
2119
- if(TYPE(n->nd_clss) == T_NODE)
2120
- {
2121
- if(0 && nd_type(n) == NODE_OP_ASGN2)
2122
- {
2123
- return wrap_node_as(
2124
- (NODE *)n->nd_clss,
2125
- rb_cNodeSubclass[NODE_OP_ASGN2_ARG]);
2126
- }
2127
- else
2128
- {
2129
- return wrap_node((NODE *)n->nd_clss);
2130
- }
2131
- }
2132
- else
2133
- {
2134
- return (VALUE)n->nd_clss;
2135
- }
2136
- }
2137
2115
  /*
2138
2116
  * Return the Node's _cnt_ member. The return type is an
2139
2117
  * Integer.
@@ -2499,27 +2477,6 @@ static VALUE node_nth(VALUE self)
2499
2477
  Data_Get_Struct(self, NODE, n);
2500
2478
  return LONG2NUM(n->nd_nth);
2501
2479
  }
2502
- /*
2503
- * Return the Node's _oid_ member. The return type is a
2504
- * Symbol.
2505
- */
2506
- static VALUE node_oid(VALUE self)
2507
- {
2508
- NODE * n;
2509
- Data_Get_Struct(self, NODE, n);
2510
- if(n->nd_oid == 0)
2511
- {
2512
- return Qfalse;
2513
- }
2514
- else if(n->nd_oid == 1)
2515
- {
2516
- return Qtrue;
2517
- }
2518
- else
2519
- {
2520
- return ID2SYM(n->nd_oid);
2521
- }
2522
- }
2523
2480
  /*
2524
2481
  * Return the Node's _opt_ member. The return type is
2525
2482
  * either a Node or an Object.
@@ -2865,10 +2822,10 @@ void define_node_subclass_methods()
2865
2822
  rb_iv_set(rb_cALIAS, "__member__", members);
2866
2823
  rb_iv_set(rb_cALIAS, "__type__", INT2NUM(NODE_ALIAS));
2867
2824
  rb_define_singleton_method(rb_cALIAS, "members", node_s_members, 0);
2868
- rb_define_method(rb_cALIAS, "first", node_1st, 0);
2869
- rb_ary_push(members, rb_str_new2("first"));
2870
2825
  rb_define_method(rb_cALIAS, "second", node_2nd, 0);
2871
2826
  rb_ary_push(members, rb_str_new2("second"));
2827
+ rb_define_method(rb_cALIAS, "first", node_1st, 0);
2828
+ rb_ary_push(members, rb_str_new2("first"));
2872
2829
  }
2873
2830
 
2874
2831
  /* Document-class: Node::ALLOCA
@@ -2892,17 +2849,17 @@ void define_node_subclass_methods()
2892
2849
  rb_define_method(rb_cALLOCA, "cfnc", node_cfnc, 0);
2893
2850
  rb_ary_push(members, rb_str_new2("cfnc"));
2894
2851
 
2895
- /* Document-method: value
2896
- * a pointer to the previously allocated temporary node
2897
- */
2898
- rb_define_method(rb_cALLOCA, "value", node_value, 0);
2899
- rb_ary_push(members, rb_str_new2("value"));
2900
-
2901
2852
  /* Document-method: cnt
2902
2853
  * the number of bytes allocated
2903
2854
  */
2904
2855
  rb_define_method(rb_cALLOCA, "cnt", node_cnt, 0);
2905
2856
  rb_ary_push(members, rb_str_new2("cnt"));
2857
+
2858
+ /* Document-method: value
2859
+ * a pointer to the previously allocated temporary node
2860
+ */
2861
+ rb_define_method(rb_cALLOCA, "value", node_value, 0);
2862
+ rb_ary_push(members, rb_str_new2("value"));
2906
2863
  }
2907
2864
  #endif
2908
2865
 
@@ -2921,17 +2878,17 @@ void define_node_subclass_methods()
2921
2878
  rb_iv_set(rb_cAND, "__type__", INT2NUM(NODE_AND));
2922
2879
  rb_define_singleton_method(rb_cAND, "members", node_s_members, 0);
2923
2880
 
2924
- /* Document-method: first
2925
- * the expression on the left hand side
2926
- */
2927
- rb_define_method(rb_cAND, "first", node_1st, 0);
2928
- rb_ary_push(members, rb_str_new2("first"));
2929
-
2930
2881
  /* Document-method: second
2931
2882
  * the expression on the right hand side
2932
2883
  */
2933
2884
  rb_define_method(rb_cAND, "second", node_2nd, 0);
2934
2885
  rb_ary_push(members, rb_str_new2("second"));
2886
+
2887
+ /* Document-method: first
2888
+ * the expression on the left hand side
2889
+ */
2890
+ rb_define_method(rb_cAND, "first", node_1st, 0);
2891
+ rb_ary_push(members, rb_str_new2("first"));
2935
2892
  }
2936
2893
 
2937
2894
  /* Document-class: Node::ARGS
@@ -2945,6 +2902,12 @@ void define_node_subclass_methods()
2945
2902
  rb_iv_set(rb_cARGS, "__type__", INT2NUM(NODE_ARGS));
2946
2903
  rb_define_singleton_method(rb_cARGS, "members", node_s_members, 0);
2947
2904
 
2905
+ /* Document-method: cnt
2906
+ * the number of required arguments
2907
+ */
2908
+ rb_define_method(rb_cARGS, "cnt", node_cnt, 0);
2909
+ rb_ary_push(members, rb_str_new2("cnt"));
2910
+
2948
2911
  /* Document-method: rest
2949
2912
  * an assignment node to assign the rest arg, if it is present
2950
2913
  */
@@ -2957,12 +2920,6 @@ void define_node_subclass_methods()
2957
2920
  */
2958
2921
  rb_define_method(rb_cARGS, "opt", node_opt, 0);
2959
2922
  rb_ary_push(members, rb_str_new2("opt"));
2960
-
2961
- /* Document-method: cnt
2962
- * the number of required arguments
2963
- */
2964
- rb_define_method(rb_cARGS, "cnt", node_cnt, 0);
2965
- rb_ary_push(members, rb_str_new2("cnt"));
2966
2923
  }
2967
2924
 
2968
2925
  /* Document-class: Node::ARGSCAT
@@ -2982,18 +2939,18 @@ void define_node_subclass_methods()
2982
2939
  rb_iv_set(rb_cARGSCAT, "__type__", INT2NUM(NODE_ARGSCAT));
2983
2940
  rb_define_singleton_method(rb_cARGSCAT, "members", node_s_members, 0);
2984
2941
 
2985
- /* Document-method: head
2986
- * a list of fixed arguments
2987
- */
2988
- rb_define_method(rb_cARGSCAT, "head", node_head, 0);
2989
- rb_ary_push(members, rb_str_new2("head"));
2990
-
2991
2942
  /* Document-method: body
2992
2943
  * the last argument, which will be splatted onto the end of the
2993
2944
  * fixed arguments
2994
2945
  */
2995
2946
  rb_define_method(rb_cARGSCAT, "body", node_body, 0);
2996
2947
  rb_ary_push(members, rb_str_new2("body"));
2948
+
2949
+ /* Document-method: head
2950
+ * a list of fixed arguments
2951
+ */
2952
+ rb_define_method(rb_cARGSCAT, "head", node_head, 0);
2953
+ rb_ary_push(members, rb_str_new2("head"));
2997
2954
  }
2998
2955
 
2999
2956
  /* Document-class: Node::ARGSPUSH
@@ -3010,10 +2967,10 @@ void define_node_subclass_methods()
3010
2967
  rb_iv_set(rb_cARGSPUSH, "__member__", members);
3011
2968
  rb_iv_set(rb_cARGSPUSH, "__type__", INT2NUM(NODE_ARGSPUSH));
3012
2969
  rb_define_singleton_method(rb_cARGSPUSH, "members", node_s_members, 0);
3013
- rb_define_method(rb_cARGSPUSH, "head", node_head, 0);
3014
- rb_ary_push(members, rb_str_new2("head"));
3015
2970
  rb_define_method(rb_cARGSPUSH, "body", node_body, 0);
3016
2971
  rb_ary_push(members, rb_str_new2("body"));
2972
+ rb_define_method(rb_cARGSPUSH, "head", node_head, 0);
2973
+ rb_ary_push(members, rb_str_new2("head"));
3017
2974
  }
3018
2975
 
3019
2976
  /* Document-class: Node::ARRAY
@@ -3028,12 +2985,6 @@ void define_node_subclass_methods()
3028
2985
  rb_iv_set(rb_cARRAY, "__member__", members);
3029
2986
  rb_iv_set(rb_cARRAY, "__type__", INT2NUM(NODE_ARRAY));
3030
2987
  rb_define_singleton_method(rb_cARRAY, "members", node_s_members, 0);
3031
-
3032
- /* Document-method: head
3033
- * the first element of the array
3034
- */
3035
- rb_define_method(rb_cARRAY, "head", node_head, 0);
3036
- rb_ary_push(members, rb_str_new2("head"));
3037
2988
  rb_define_method(rb_cARRAY, "alen", node_alen, 0);
3038
2989
  rb_ary_push(members, rb_str_new2("alen"));
3039
2990
 
@@ -3042,6 +2993,12 @@ void define_node_subclass_methods()
3042
2993
  */
3043
2994
  rb_define_method(rb_cARRAY, "next", node_next, 0);
3044
2995
  rb_ary_push(members, rb_str_new2("next"));
2996
+
2997
+ /* Document-method: head
2998
+ * the first element of the array
2999
+ */
3000
+ rb_define_method(rb_cARRAY, "head", node_head, 0);
3001
+ rb_ary_push(members, rb_str_new2("head"));
3045
3002
  }
3046
3003
 
3047
3004
  /* Document-class: Node::ATTRASGN
@@ -3058,11 +3015,11 @@ void define_node_subclass_methods()
3058
3015
  rb_iv_set(rb_cATTRASGN, "__type__", INT2NUM(NODE_ATTRASGN));
3059
3016
  rb_define_singleton_method(rb_cATTRASGN, "members", node_s_members, 0);
3060
3017
 
3061
- /* Document-method: args
3062
- * the arguments to the method
3018
+ /* Document-method: recv
3019
+ * the receiver of the method
3063
3020
  */
3064
- rb_define_method(rb_cATTRASGN, "args", node_args, 0);
3065
- rb_ary_push(members, rb_str_new2("args"));
3021
+ rb_define_method(rb_cATTRASGN, "recv", node_recv, 0);
3022
+ rb_ary_push(members, rb_str_new2("recv"));
3066
3023
 
3067
3024
  /* Document-method: mid
3068
3025
  * the id of the attribute, with a trailing '=' sign
@@ -3070,32 +3027,11 @@ void define_node_subclass_methods()
3070
3027
  rb_define_method(rb_cATTRASGN, "mid", node_mid, 0);
3071
3028
  rb_ary_push(members, rb_str_new2("mid"));
3072
3029
 
3073
- /* Document-method: recv
3074
- * the receiver of the method
3075
- */
3076
- rb_define_method(rb_cATTRASGN, "recv", node_recv, 0);
3077
- rb_ary_push(members, rb_str_new2("recv"));
3078
- }
3079
-
3080
- /* Document-class: Node::ATTRSET
3081
- * A placeholder for an attribute writer method, which can added to a
3082
- * class by using attr_writer:
3083
- * attr_writer :attribute
3084
- * Its reader counterpart is IVAR.
3085
- */
3086
- {
3087
- VALUE rb_cATTRSET = rb_define_class_under(rb_cNode, "ATTRSET", rb_cNode);
3088
- members = rb_ary_new();
3089
- rb_cNodeSubclass[NODE_ATTRSET] = rb_cATTRSET;
3090
- rb_iv_set(rb_cATTRSET, "__member__", members);
3091
- rb_iv_set(rb_cATTRSET, "__type__", INT2NUM(NODE_ATTRSET));
3092
- rb_define_singleton_method(rb_cATTRSET, "members", node_s_members, 0);
3093
-
3094
- /* Document-method: vid
3095
- * the name of the attribute, with a leading '@' sign
3030
+ /* Document-method: args
3031
+ * the arguments to the method
3096
3032
  */
3097
- rb_define_method(rb_cATTRSET, "vid", node_vid, 0);
3098
- rb_ary_push(members, rb_str_new2("vid"));
3033
+ rb_define_method(rb_cATTRASGN, "args", node_args, 0);
3034
+ rb_ary_push(members, rb_str_new2("args"));
3099
3035
  }
3100
3036
 
3101
3037
  /* Document-class: Node::BACK_REF
@@ -3162,17 +3098,17 @@ void define_node_subclass_methods()
3162
3098
  rb_iv_set(rb_cBLOCK, "__type__", INT2NUM(NODE_BLOCK));
3163
3099
  rb_define_singleton_method(rb_cBLOCK, "members", node_s_members, 0);
3164
3100
 
3165
- /* Document-method: head
3166
- * the first expression in the block of code
3167
- */
3168
- rb_define_method(rb_cBLOCK, "head", node_head, 0);
3169
- rb_ary_push(members, rb_str_new2("head"));
3170
-
3171
3101
  /* Document-method: next
3172
3102
  * the second expression in the block of code
3173
3103
  */
3174
3104
  rb_define_method(rb_cBLOCK, "next", node_next, 0);
3175
3105
  rb_ary_push(members, rb_str_new2("next"));
3106
+
3107
+ /* Document-method: head
3108
+ * the first expression in the block of code
3109
+ */
3110
+ rb_define_method(rb_cBLOCK, "head", node_head, 0);
3111
+ rb_ary_push(members, rb_str_new2("head"));
3176
3112
  }
3177
3113
 
3178
3114
  /* Document-class: Node::BLOCK_ARG
@@ -3280,11 +3216,11 @@ void define_node_subclass_methods()
3280
3216
  rb_iv_set(rb_cCALL, "__type__", INT2NUM(NODE_CALL));
3281
3217
  rb_define_singleton_method(rb_cCALL, "members", node_s_members, 0);
3282
3218
 
3283
- /* Document-method: args
3284
- * the arguments to the method
3219
+ /* Document-method: recv
3220
+ * the receiver of the method
3285
3221
  */
3286
- rb_define_method(rb_cCALL, "args", node_args, 0);
3287
- rb_ary_push(members, rb_str_new2("args"));
3222
+ rb_define_method(rb_cCALL, "recv", node_recv, 0);
3223
+ rb_ary_push(members, rb_str_new2("recv"));
3288
3224
 
3289
3225
  /* Document-method: mid
3290
3226
  * the method id
@@ -3292,11 +3228,11 @@ void define_node_subclass_methods()
3292
3228
  rb_define_method(rb_cCALL, "mid", node_mid, 0);
3293
3229
  rb_ary_push(members, rb_str_new2("mid"));
3294
3230
 
3295
- /* Document-method: recv
3296
- * the receiver of the method
3231
+ /* Document-method: args
3232
+ * the arguments to the method
3297
3233
  */
3298
- rb_define_method(rb_cCALL, "recv", node_recv, 0);
3299
- rb_ary_push(members, rb_str_new2("recv"));
3234
+ rb_define_method(rb_cCALL, "args", node_args, 0);
3235
+ rb_ary_push(members, rb_str_new2("args"));
3300
3236
  }
3301
3237
 
3302
3238
  /* Document-class: Node::CASE
@@ -3314,12 +3250,6 @@ void define_node_subclass_methods()
3314
3250
  rb_iv_set(rb_cCASE, "__type__", INT2NUM(NODE_CASE));
3315
3251
  rb_define_singleton_method(rb_cCASE, "members", node_s_members, 0);
3316
3252
 
3317
- /* Document-method: head
3318
- * the value to select on
3319
- */
3320
- rb_define_method(rb_cCASE, "head", node_head, 0);
3321
- rb_ary_push(members, rb_str_new2("head"));
3322
-
3323
3253
  /* Document-method: body
3324
3254
  * a linked list of nodes, each node representing a when
3325
3255
  * conditional
@@ -3328,6 +3258,12 @@ void define_node_subclass_methods()
3328
3258
  rb_ary_push(members, rb_str_new2("body"));
3329
3259
  rb_define_method(rb_cCASE, "next", node_next, 0);
3330
3260
  rb_ary_push(members, rb_str_new2("next"));
3261
+
3262
+ /* Document-method: head
3263
+ * the value to select on
3264
+ */
3265
+ rb_define_method(rb_cCASE, "head", node_head, 0);
3266
+ rb_ary_push(members, rb_str_new2("head"));
3331
3267
  }
3332
3268
 
3333
3269
  /* Document-class: Node::CDECL
@@ -3355,22 +3291,6 @@ void define_node_subclass_methods()
3355
3291
  rb_ary_push(members, rb_str_new2("vid"));
3356
3292
  }
3357
3293
 
3358
- /* Document-class: Node::CFUNC
3359
- * A placeholder for a function implemented in C.
3360
- */
3361
- {
3362
- VALUE rb_cCFUNC = rb_define_class_under(rb_cNode, "CFUNC", rb_cNode);
3363
- members = rb_ary_new();
3364
- rb_cNodeSubclass[NODE_CFUNC] = rb_cCFUNC;
3365
- rb_iv_set(rb_cCFUNC, "__member__", members);
3366
- rb_iv_set(rb_cCFUNC, "__type__", INT2NUM(NODE_CFUNC));
3367
- rb_define_singleton_method(rb_cCFUNC, "members", node_s_members, 0);
3368
- rb_define_method(rb_cCFUNC, "cfnc", node_cfnc, 0);
3369
- rb_ary_push(members, rb_str_new2("cfnc"));
3370
- rb_define_method(rb_cCFUNC, "argc", node_argc, 0);
3371
- rb_ary_push(members, rb_str_new2("argc"));
3372
- }
3373
-
3374
3294
  /* Document-class: Node::CLASS
3375
3295
  * Represents a class definition, e.g.:
3376
3296
  * class cpath
@@ -3395,12 +3315,6 @@ void define_node_subclass_methods()
3395
3315
  rb_iv_set(rb_cCLASS, "__type__", INT2NUM(NODE_CLASS));
3396
3316
  rb_define_singleton_method(rb_cCLASS, "members", node_s_members, 0);
3397
3317
 
3398
- /* Document-method: cpath
3399
- * the name of the class to define
3400
- */
3401
- rb_define_method(rb_cCLASS, "cpath", node_cpath, 0);
3402
- rb_ary_push(members, rb_str_new2("cpath"));
3403
-
3404
3318
  /* Document-method: body
3405
3319
  * the body of the class definition
3406
3320
  */
@@ -3413,6 +3327,12 @@ void define_node_subclass_methods()
3413
3327
  */
3414
3328
  rb_define_method(rb_cCLASS, "super", node_super, 0);
3415
3329
  rb_ary_push(members, rb_str_new2("super"));
3330
+
3331
+ /* Document-method: cpath
3332
+ * the name of the class to define
3333
+ */
3334
+ rb_define_method(rb_cCLASS, "cpath", node_cpath, 0);
3335
+ rb_ary_push(members, rb_str_new2("cpath"));
3416
3336
  }
3417
3337
 
3418
3338
  /* Document-class: Node::COLON2
@@ -3431,17 +3351,17 @@ void define_node_subclass_methods()
3431
3351
  rb_iv_set(rb_cCOLON2, "__type__", INT2NUM(NODE_COLON2));
3432
3352
  rb_define_singleton_method(rb_cCOLON2, "members", node_s_members, 0);
3433
3353
 
3434
- /* Document-method: head
3435
- * an expression specifying the class in which to do the lookup
3436
- */
3437
- rb_define_method(rb_cCOLON2, "head", node_head, 0);
3438
- rb_ary_push(members, rb_str_new2("head"));
3439
-
3440
3354
  /* Document-method: mid
3441
3355
  * the name of the method or constant to call/look up
3442
3356
  */
3443
3357
  rb_define_method(rb_cCOLON2, "mid", node_mid, 0);
3444
3358
  rb_ary_push(members, rb_str_new2("mid"));
3359
+
3360
+ /* Document-method: head
3361
+ * an expression specifying the class in which to do the lookup
3362
+ */
3363
+ rb_define_method(rb_cCOLON2, "head", node_head, 0);
3364
+ rb_ary_push(members, rb_str_new2("head"));
3445
3365
  }
3446
3366
 
3447
3367
  /* Document-class: Node::COLON3
@@ -3652,17 +3572,17 @@ void define_node_subclass_methods()
3652
3572
  rb_define_method(rb_cDEFN, "defn", node_defn, 0);
3653
3573
  rb_ary_push(members, rb_str_new2("defn"));
3654
3574
 
3655
- /* Document-method: mid
3656
- * the name of the method* defn the body of the method
3657
- */
3658
- rb_define_method(rb_cDEFN, "mid", node_mid, 0);
3659
- rb_ary_push(members, rb_str_new2("mid"));
3660
-
3661
3575
  /* Document-method: noex
3662
3576
  * the flags which should be used to define the method
3663
3577
  */
3664
3578
  rb_define_method(rb_cDEFN, "noex", node_noex, 0);
3665
3579
  rb_ary_push(members, rb_str_new2("noex"));
3580
+
3581
+ /* Document-method: mid
3582
+ * the name of the method* defn the body of the method
3583
+ */
3584
+ rb_define_method(rb_cDEFN, "mid", node_mid, 0);
3585
+ rb_ary_push(members, rb_str_new2("mid"));
3666
3586
  }
3667
3587
 
3668
3588
  /* Document-class: Node::DEFS
@@ -3681,17 +3601,17 @@ void define_node_subclass_methods()
3681
3601
  rb_define_method(rb_cDEFS, "defn", node_defn, 0);
3682
3602
  rb_ary_push(members, rb_str_new2("defn"));
3683
3603
 
3684
- /* Document-method: mid
3685
- * the name of the method* defn the body of the method
3686
- */
3687
- rb_define_method(rb_cDEFS, "mid", node_mid, 0);
3688
- rb_ary_push(members, rb_str_new2("mid"));
3689
-
3690
3604
  /* Document-method: recv
3691
3605
  * the object to whose singleton class the new method is to be added
3692
3606
  */
3693
3607
  rb_define_method(rb_cDEFS, "recv", node_recv, 0);
3694
3608
  rb_ary_push(members, rb_str_new2("recv"));
3609
+
3610
+ /* Document-method: mid
3611
+ * the name of the method* defn the body of the method
3612
+ */
3613
+ rb_define_method(rb_cDEFS, "mid", node_mid, 0);
3614
+ rb_ary_push(members, rb_str_new2("mid"));
3695
3615
  }
3696
3616
 
3697
3617
  /* Document-class: Node::DOT2
@@ -3707,12 +3627,6 @@ void define_node_subclass_methods()
3707
3627
  rb_iv_set(rb_cDOT2, "__type__", INT2NUM(NODE_DOT2));
3708
3628
  rb_define_singleton_method(rb_cDOT2, "members", node_s_members, 0);
3709
3629
 
3710
- /* Document-method: beg
3711
- * the beginning of the range
3712
- */
3713
- rb_define_method(rb_cDOT2, "beg", node_beg, 0);
3714
- rb_ary_push(members, rb_str_new2("beg"));
3715
-
3716
3630
  /* Document-method: end
3717
3631
  * the end of the range
3718
3632
  */
@@ -3720,6 +3634,12 @@ void define_node_subclass_methods()
3720
3634
  rb_ary_push(members, rb_str_new2("end"));
3721
3635
  rb_define_method(rb_cDOT2, "state", node_state, 0);
3722
3636
  rb_ary_push(members, rb_str_new2("state"));
3637
+
3638
+ /* Document-method: beg
3639
+ * the beginning of the range
3640
+ */
3641
+ rb_define_method(rb_cDOT2, "beg", node_beg, 0);
3642
+ rb_ary_push(members, rb_str_new2("beg"));
3723
3643
  }
3724
3644
 
3725
3645
  /* Document-class: Node::DOT3
@@ -3735,12 +3655,6 @@ void define_node_subclass_methods()
3735
3655
  rb_iv_set(rb_cDOT3, "__type__", INT2NUM(NODE_DOT3));
3736
3656
  rb_define_singleton_method(rb_cDOT3, "members", node_s_members, 0);
3737
3657
 
3738
- /* Document-method: beg
3739
- * the beginning of the range
3740
- */
3741
- rb_define_method(rb_cDOT3, "beg", node_beg, 0);
3742
- rb_ary_push(members, rb_str_new2("beg"));
3743
-
3744
3658
  /* Document-method: end
3745
3659
  * the end of the range
3746
3660
  */
@@ -3748,7 +3662,13 @@ void define_node_subclass_methods()
3748
3662
  rb_ary_push(members, rb_str_new2("end"));
3749
3663
  rb_define_method(rb_cDOT3, "state", node_state, 0);
3750
3664
  rb_ary_push(members, rb_str_new2("state"));
3751
- }
3665
+
3666
+ /* Document-method: beg
3667
+ * the beginning of the range
3668
+ */
3669
+ rb_define_method(rb_cDOT3, "beg", node_beg, 0);
3670
+ rb_ary_push(members, rb_str_new2("beg"));
3671
+ }
3752
3672
 
3753
3673
  /* Document-class: Node::DREGX
3754
3674
  * Represents a regular expresion with interpolation. The node is
@@ -3766,12 +3686,6 @@ void define_node_subclass_methods()
3766
3686
  rb_iv_set(rb_cDREGX, "__type__", INT2NUM(NODE_DREGX));
3767
3687
  rb_define_singleton_method(rb_cDREGX, "members", node_s_members, 0);
3768
3688
 
3769
- /* Document-method: lit
3770
- * a string
3771
- */
3772
- rb_define_method(rb_cDREGX, "lit", node_lit, 0);
3773
- rb_ary_push(members, rb_str_new2("lit"));
3774
-
3775
3689
  /* Document-method: cflag
3776
3690
  * a bitfield containing the options used in the regular
3777
3691
  * expression. Valid values include:
@@ -3789,6 +3703,12 @@ void define_node_subclass_methods()
3789
3703
  rb_define_method(rb_cDREGX, "cflag", node_cflag, 0);
3790
3704
  rb_ary_push(members, rb_str_new2("cflag"));
3791
3705
 
3706
+ /* Document-method: lit
3707
+ * a string
3708
+ */
3709
+ rb_define_method(rb_cDREGX, "lit", node_lit, 0);
3710
+ rb_ary_push(members, rb_str_new2("lit"));
3711
+
3792
3712
  /* Document-method: next
3793
3713
  * a list of expressions to be appended onto the string
3794
3714
  */
@@ -3809,12 +3729,6 @@ void define_node_subclass_methods()
3809
3729
  rb_iv_set(rb_cDREGX_ONCE, "__type__", INT2NUM(NODE_DREGX_ONCE));
3810
3730
  rb_define_singleton_method(rb_cDREGX_ONCE, "members", node_s_members, 0);
3811
3731
 
3812
- /* Document-method: lit
3813
- * a string
3814
- */
3815
- rb_define_method(rb_cDREGX_ONCE, "lit", node_lit, 0);
3816
- rb_ary_push(members, rb_str_new2("lit"));
3817
-
3818
3732
  /* Document-method: cflag
3819
3733
  * a bitfield containing the options used in the regular
3820
3734
  * expression. See DREGX for a list of valid values.
@@ -3822,6 +3736,12 @@ void define_node_subclass_methods()
3822
3736
  rb_define_method(rb_cDREGX_ONCE, "cflag", node_cflag, 0);
3823
3737
  rb_ary_push(members, rb_str_new2("cflag"));
3824
3738
 
3739
+ /* Document-method: lit
3740
+ * a string
3741
+ */
3742
+ rb_define_method(rb_cDREGX_ONCE, "lit", node_lit, 0);
3743
+ rb_ary_push(members, rb_str_new2("lit"));
3744
+
3825
3745
  /* Document-method: next
3826
3746
  * a list of expressions to be appended onto the string
3827
3747
  */
@@ -3957,17 +3877,17 @@ void define_node_subclass_methods()
3957
3877
  rb_iv_set(rb_cENSURE, "__type__", INT2NUM(NODE_ENSURE));
3958
3878
  rb_define_singleton_method(rb_cENSURE, "members", node_s_members, 0);
3959
3879
 
3960
- /* Document-method: head
3961
- * the expression to protect
3962
- */
3963
- rb_define_method(rb_cENSURE, "head", node_head, 0);
3964
- rb_ary_push(members, rb_str_new2("head"));
3965
-
3966
3880
  /* Document-method: ensr
3967
3881
  * the expression to evaluate after the head is evaluated
3968
3882
  */
3969
3883
  rb_define_method(rb_cENSURE, "ensr", node_ensr, 0);
3970
3884
  rb_ary_push(members, rb_str_new2("ensr"));
3885
+
3886
+ /* Document-method: head
3887
+ * the expression to protect
3888
+ */
3889
+ rb_define_method(rb_cENSURE, "head", node_head, 0);
3890
+ rb_ary_push(members, rb_str_new2("head"));
3971
3891
  }
3972
3892
 
3973
3893
  /* Document-class: Node::EVSTR
@@ -4003,38 +3923,6 @@ void define_node_subclass_methods()
4003
3923
  rb_define_singleton_method(rb_cFALSE, "members", node_s_members, 0);
4004
3924
  }
4005
3925
 
4006
- /* Document-class: Node::FBODY
4007
- * A placeholder for a method alias, which can be added to a class by
4008
- * using alias or alias_method:
4009
- * alias old new
4010
- */
4011
- {
4012
- VALUE rb_cFBODY = rb_define_class_under(rb_cNode, "FBODY", rb_cNode);
4013
- members = rb_ary_new();
4014
- rb_cNodeSubclass[NODE_FBODY] = rb_cFBODY;
4015
- rb_iv_set(rb_cFBODY, "__member__", members);
4016
- rb_iv_set(rb_cFBODY, "__type__", INT2NUM(NODE_FBODY));
4017
- rb_define_singleton_method(rb_cFBODY, "members", node_s_members, 0);
4018
-
4019
- /* Document-method: body
4020
- * the method body
4021
- */
4022
- rb_define_method(rb_cFBODY, "body", node_body, 0);
4023
- rb_ary_push(members, rb_str_new2("body"));
4024
-
4025
- /* Document-method: cnt
4026
- * the method's flags
4027
- */
4028
- rb_define_method(rb_cFBODY, "cnt", node_cnt, 0);
4029
- rb_ary_push(members, rb_str_new2("cnt"));
4030
-
4031
- /* Document-method: oid
4032
- * the original name of the method
4033
- */
4034
- rb_define_method(rb_cFBODY, "oid", node_oid, 0);
4035
- rb_ary_push(members, rb_str_new2("oid"));
4036
- }
4037
-
4038
3926
  /* Document-class: Node::FCALL
4039
3927
  * Represents a method call in the form:
4040
3928
  * mid(args).
@@ -4050,17 +3938,17 @@ void define_node_subclass_methods()
4050
3938
  rb_iv_set(rb_cFCALL, "__type__", INT2NUM(NODE_FCALL));
4051
3939
  rb_define_singleton_method(rb_cFCALL, "members", node_s_members, 0);
4052
3940
 
4053
- /* Document-method: args
4054
- * the arguments to the method
4055
- */
4056
- rb_define_method(rb_cFCALL, "args", node_args, 0);
4057
- rb_ary_push(members, rb_str_new2("args"));
4058
-
4059
3941
  /* Document-method: mid
4060
3942
  * the method id
4061
3943
  */
4062
3944
  rb_define_method(rb_cFCALL, "mid", node_mid, 0);
4063
3945
  rb_ary_push(members, rb_str_new2("mid"));
3946
+
3947
+ /* Document-method: args
3948
+ * the arguments to the method
3949
+ */
3950
+ rb_define_method(rb_cFCALL, "args", node_args, 0);
3951
+ rb_ary_push(members, rb_str_new2("args"));
4064
3952
  }
4065
3953
 
4066
3954
  /* Document-class: Node::FLIP2
@@ -4077,11 +3965,12 @@ void define_node_subclass_methods()
4077
3965
  rb_iv_set(rb_cFLIP2, "__type__", INT2NUM(NODE_FLIP2));
4078
3966
  rb_define_singleton_method(rb_cFLIP2, "members", node_s_members, 0);
4079
3967
 
4080
- /* Document-method: beg
4081
- * the beginning of the range
3968
+ /* Document-method: cnt
3969
+ * the index into the local variable table of the special variable
3970
+ * to use in the flip-flop expression (usually 2 for $_)
4082
3971
  */
4083
- rb_define_method(rb_cFLIP2, "beg", node_beg, 0);
4084
- rb_ary_push(members, rb_str_new2("beg"));
3972
+ rb_define_method(rb_cFLIP2, "cnt", node_cnt, 0);
3973
+ rb_ary_push(members, rb_str_new2("cnt"));
4085
3974
 
4086
3975
  /* Document-method: end
4087
3976
  * the end of the range
@@ -4089,12 +3978,11 @@ void define_node_subclass_methods()
4089
3978
  rb_define_method(rb_cFLIP2, "end", node_end, 0);
4090
3979
  rb_ary_push(members, rb_str_new2("end"));
4091
3980
 
4092
- /* Document-method: cnt
4093
- * the index into the local variable table of the special variable
4094
- * to use in the flip-flop expression (usually 2 for $_)
3981
+ /* Document-method: beg
3982
+ * the beginning of the range
4095
3983
  */
4096
- rb_define_method(rb_cFLIP2, "cnt", node_cnt, 0);
4097
- rb_ary_push(members, rb_str_new2("cnt"));
3984
+ rb_define_method(rb_cFLIP2, "beg", node_beg, 0);
3985
+ rb_ary_push(members, rb_str_new2("beg"));
4098
3986
  }
4099
3987
 
4100
3988
  /* Document-class: Node::FLIP3
@@ -4111,11 +3999,12 @@ void define_node_subclass_methods()
4111
3999
  rb_iv_set(rb_cFLIP3, "__type__", INT2NUM(NODE_FLIP3));
4112
4000
  rb_define_singleton_method(rb_cFLIP3, "members", node_s_members, 0);
4113
4001
 
4114
- /* Document-method: beg
4115
- * the beginning of the range
4002
+ /* Document-method: cnt
4003
+ * the index into the local variable table of the special variable
4004
+ * to use in the flip-flop expression (usually 2 for $_)
4116
4005
  */
4117
- rb_define_method(rb_cFLIP3, "beg", node_beg, 0);
4118
- rb_ary_push(members, rb_str_new2("beg"));
4006
+ rb_define_method(rb_cFLIP3, "cnt", node_cnt, 0);
4007
+ rb_ary_push(members, rb_str_new2("cnt"));
4119
4008
 
4120
4009
  /* Document-method: end
4121
4010
  * the end of the range
@@ -4123,12 +4012,11 @@ void define_node_subclass_methods()
4123
4012
  rb_define_method(rb_cFLIP3, "end", node_end, 0);
4124
4013
  rb_ary_push(members, rb_str_new2("end"));
4125
4014
 
4126
- /* Document-method: cnt
4127
- * the index into the local variable table of the special variable
4128
- * to use in the flip-flop expression (usually 2 for $_)
4015
+ /* Document-method: beg
4016
+ * the beginning of the range
4129
4017
  */
4130
- rb_define_method(rb_cFLIP3, "cnt", node_cnt, 0);
4131
- rb_ary_push(members, rb_str_new2("cnt"));
4018
+ rb_define_method(rb_cFLIP3, "beg", node_beg, 0);
4019
+ rb_ary_push(members, rb_str_new2("beg"));
4132
4020
  }
4133
4021
 
4134
4022
  /* Document-class: Node::FOR
@@ -4184,6 +4072,8 @@ void define_node_subclass_methods()
4184
4072
  rb_iv_set(rb_cGASGN, "__member__", members);
4185
4073
  rb_iv_set(rb_cGASGN, "__type__", INT2NUM(NODE_GASGN));
4186
4074
  rb_define_singleton_method(rb_cGASGN, "members", node_s_members, 0);
4075
+ rb_define_method(rb_cGASGN, "entry", node_entry, 0);
4076
+ rb_ary_push(members, rb_str_new2("entry"));
4187
4077
 
4188
4078
  /* Document-method: value
4189
4079
  * an expression whose result is the new value of the global variable
@@ -4196,8 +4086,6 @@ void define_node_subclass_methods()
4196
4086
  */
4197
4087
  rb_define_method(rb_cGASGN, "vid", node_vid, 0);
4198
4088
  rb_ary_push(members, rb_str_new2("vid"));
4199
- rb_define_method(rb_cGASGN, "entry", node_entry, 0);
4200
- rb_ary_push(members, rb_str_new2("entry"));
4201
4089
  }
4202
4090
 
4203
4091
  /* Document-class: Node::GVAR
@@ -4210,14 +4098,14 @@ void define_node_subclass_methods()
4210
4098
  rb_iv_set(rb_cGVAR, "__member__", members);
4211
4099
  rb_iv_set(rb_cGVAR, "__type__", INT2NUM(NODE_GVAR));
4212
4100
  rb_define_singleton_method(rb_cGVAR, "members", node_s_members, 0);
4101
+ rb_define_method(rb_cGVAR, "entry", node_entry, 0);
4102
+ rb_ary_push(members, rb_str_new2("entry"));
4213
4103
 
4214
4104
  /* Document-method: vid
4215
4105
  * the name of the global variable to retrieve, with a leading '$'
4216
4106
  */
4217
4107
  rb_define_method(rb_cGVAR, "vid", node_vid, 0);
4218
4108
  rb_ary_push(members, rb_str_new2("vid"));
4219
- rb_define_method(rb_cGVAR, "entry", node_entry, 0);
4220
- rb_ary_push(members, rb_str_new2("entry"));
4221
4109
  }
4222
4110
 
4223
4111
  /* Document-class: Node::HASH
@@ -4292,12 +4180,6 @@ void define_node_subclass_methods()
4292
4180
  rb_iv_set(rb_cIF, "__type__", INT2NUM(NODE_IF));
4293
4181
  rb_define_singleton_method(rb_cIF, "members", node_s_members, 0);
4294
4182
 
4295
- /* Document-method: cond
4296
- * the condition to evaluate
4297
- */
4298
- rb_define_method(rb_cIF, "cond", node_cond, 0);
4299
- rb_ary_push(members, rb_str_new2("cond"));
4300
-
4301
4183
  /* Document-method: body
4302
4184
  * the expression to evaluate if the expression is true, or false
4303
4185
  * if the expression is empty
@@ -4305,6 +4187,12 @@ void define_node_subclass_methods()
4305
4187
  rb_define_method(rb_cIF, "body", node_body, 0);
4306
4188
  rb_ary_push(members, rb_str_new2("body"));
4307
4189
 
4190
+ /* Document-method: cond
4191
+ * the condition to evaluate
4192
+ */
4193
+ rb_define_method(rb_cIF, "cond", node_cond, 0);
4194
+ rb_ary_push(members, rb_str_new2("cond"));
4195
+
4308
4196
  /* Document-method: else
4309
4197
  * the expression to evaluate if the expression is false, or false
4310
4198
  * if the expression is empty
@@ -4330,18 +4218,18 @@ void define_node_subclass_methods()
4330
4218
  rb_define_method(rb_cIFUNC, "cfnc", node_cfnc, 0);
4331
4219
  rb_ary_push(members, rb_str_new2("cfnc"));
4332
4220
 
4221
+ /* Document-method: state
4222
+ * always 0
4223
+ */
4224
+ rb_define_method(rb_cIFUNC, "state", node_state, 0);
4225
+ rb_ary_push(members, rb_str_new2("state"));
4226
+
4333
4227
  /* Document-method: tval
4334
4228
  * the user-specified data to be passed as the second argument to
4335
4229
  * cfnc
4336
4230
  */
4337
4231
  rb_define_method(rb_cIFUNC, "tval", node_tval, 0);
4338
4232
  rb_ary_push(members, rb_str_new2("tval"));
4339
-
4340
- /* Document-method: state
4341
- * always 0
4342
- */
4343
- rb_define_method(rb_cIFUNC, "state", node_state, 0);
4344
- rb_ary_push(members, rb_str_new2("state"));
4345
4233
  }
4346
4234
 
4347
4235
  /* Document-class: Node::ITER
@@ -4418,6 +4306,8 @@ void define_node_subclass_methods()
4418
4306
  rb_iv_set(rb_cLASGN, "__member__", members);
4419
4307
  rb_iv_set(rb_cLASGN, "__type__", INT2NUM(NODE_LASGN));
4420
4308
  rb_define_singleton_method(rb_cLASGN, "members", node_s_members, 0);
4309
+ rb_define_method(rb_cLASGN, "cnt", node_cnt, 0);
4310
+ rb_ary_push(members, rb_str_new2("cnt"));
4421
4311
 
4422
4312
  /* Document-method: value
4423
4313
  * the value to assign to the local variable
@@ -4430,8 +4320,6 @@ void define_node_subclass_methods()
4430
4320
  */
4431
4321
  rb_define_method(rb_cLASGN, "vid", node_vid, 0);
4432
4322
  rb_ary_push(members, rb_str_new2("vid"));
4433
- rb_define_method(rb_cLASGN, "cnt", node_cnt, 0);
4434
- rb_ary_push(members, rb_str_new2("cnt"));
4435
4323
  }
4436
4324
 
4437
4325
  /* Document-class: Node::LIT
@@ -4463,14 +4351,14 @@ void define_node_subclass_methods()
4463
4351
  rb_iv_set(rb_cLVAR, "__member__", members);
4464
4352
  rb_iv_set(rb_cLVAR, "__type__", INT2NUM(NODE_LVAR));
4465
4353
  rb_define_singleton_method(rb_cLVAR, "members", node_s_members, 0);
4354
+ rb_define_method(rb_cLVAR, "cnt", node_cnt, 0);
4355
+ rb_ary_push(members, rb_str_new2("cnt"));
4466
4356
 
4467
4357
  /* Document-method: vid
4468
4358
  * the name of the local variable to retrieve.
4469
4359
  */
4470
4360
  rb_define_method(rb_cLVAR, "vid", node_vid, 0);
4471
4361
  rb_ary_push(members, rb_str_new2("vid"));
4472
- rb_define_method(rb_cLVAR, "cnt", node_cnt, 0);
4473
- rb_ary_push(members, rb_str_new2("cnt"));
4474
4362
  }
4475
4363
 
4476
4364
  /* Document-class: Node::MASGN
@@ -4484,6 +4372,12 @@ void define_node_subclass_methods()
4484
4372
  rb_iv_set(rb_cMASGN, "__type__", INT2NUM(NODE_MASGN));
4485
4373
  rb_define_singleton_method(rb_cMASGN, "members", node_s_members, 0);
4486
4374
 
4375
+ /* Document-method: value
4376
+ * TODO
4377
+ */
4378
+ rb_define_method(rb_cMASGN, "value", node_value, 0);
4379
+ rb_ary_push(members, rb_str_new2("value"));
4380
+
4487
4381
  /* Document-method: args
4488
4382
  * TODO
4489
4383
  */
@@ -4495,12 +4389,6 @@ void define_node_subclass_methods()
4495
4389
  */
4496
4390
  rb_define_method(rb_cMASGN, "head", node_head, 0);
4497
4391
  rb_ary_push(members, rb_str_new2("head"));
4498
-
4499
- /* Document-method: value
4500
- * TODO
4501
- */
4502
- rb_define_method(rb_cMASGN, "value", node_value, 0);
4503
- rb_ary_push(members, rb_str_new2("value"));
4504
4392
  }
4505
4393
 
4506
4394
  /* Document-class: Node::MATCH
@@ -4563,6 +4451,13 @@ void define_node_subclass_methods()
4563
4451
  rb_iv_set(rb_cMATCH2, "__type__", INT2NUM(NODE_MATCH2));
4564
4452
  rb_define_singleton_method(rb_cMATCH2, "members", node_s_members, 0);
4565
4453
 
4454
+ /* Document-method: recv
4455
+ * the regular expression on the left hand side of the match
4456
+ * operator
4457
+ */
4458
+ rb_define_method(rb_cMATCH2, "recv", node_recv, 0);
4459
+ rb_ary_push(members, rb_str_new2("recv"));
4460
+
4566
4461
  /* Document-method: value
4567
4462
  * the expression on the right hand side of the match operator, or
4568
4463
  * an expression returning $_ if there is nothing on the right hand
@@ -4570,13 +4465,6 @@ void define_node_subclass_methods()
4570
4465
  */
4571
4466
  rb_define_method(rb_cMATCH2, "value", node_value, 0);
4572
4467
  rb_ary_push(members, rb_str_new2("value"));
4573
-
4574
- /* Document-method: recv
4575
- * the regular expression on the left hand side of the match
4576
- * operator
4577
- */
4578
- rb_define_method(rb_cMATCH2, "recv", node_recv, 0);
4579
- rb_ary_push(members, rb_str_new2("recv"));
4580
4468
  }
4581
4469
 
4582
4470
  /* Document-class: Node::MATCH3
@@ -4594,17 +4482,17 @@ void define_node_subclass_methods()
4594
4482
  rb_iv_set(rb_cMATCH3, "__type__", INT2NUM(NODE_MATCH3));
4595
4483
  rb_define_singleton_method(rb_cMATCH3, "members", node_s_members, 0);
4596
4484
 
4597
- /* Document-method: value
4598
- * the right hand side of the match
4599
- */
4600
- rb_define_method(rb_cMATCH3, "value", node_value, 0);
4601
- rb_ary_push(members, rb_str_new2("value"));
4602
-
4603
4485
  /* Document-method: recv
4604
4486
  * the left hand side of the match
4605
4487
  */
4606
4488
  rb_define_method(rb_cMATCH3, "recv", node_recv, 0);
4607
4489
  rb_ary_push(members, rb_str_new2("recv"));
4490
+
4491
+ /* Document-method: value
4492
+ * the right hand side of the match
4493
+ */
4494
+ rb_define_method(rb_cMATCH3, "value", node_value, 0);
4495
+ rb_ary_push(members, rb_str_new2("value"));
4608
4496
  }
4609
4497
 
4610
4498
  /* Document-class: Node::MEMO
@@ -4630,42 +4518,6 @@ void define_node_subclass_methods()
4630
4518
  rb_define_singleton_method(rb_cMEMO, "members", node_s_members, 0);
4631
4519
  }
4632
4520
 
4633
- /* Document-class: Node::METHOD
4634
- * A placeholder for a method entry in a class's method table.
4635
- *
4636
- * On ruby 1.9 this node type is also known as RUBY_VM_METHOD_NODE.
4637
- * Its use differs from that of NODE_METHOD in that it is used as the
4638
- * body of another METHOD node and is used to store the method's
4639
- * instruction sequence.
4640
- */
4641
- {
4642
- VALUE rb_cMETHOD = rb_define_class_under(rb_cNode, "METHOD", rb_cNode);
4643
- members = rb_ary_new();
4644
- rb_cNodeSubclass[NODE_METHOD] = rb_cMETHOD;
4645
- rb_iv_set(rb_cMETHOD, "__member__", members);
4646
- rb_iv_set(rb_cMETHOD, "__type__", INT2NUM(NODE_METHOD));
4647
- rb_define_singleton_method(rb_cMETHOD, "members", node_s_members, 0);
4648
-
4649
- /* Document-method: body
4650
- * the body of the method
4651
- */
4652
- rb_define_method(rb_cMETHOD, "body", node_body, 0);
4653
- rb_ary_push(members, rb_str_new2("body"));
4654
-
4655
- /* Document-method: clss
4656
- * the class to which the method was added or the instruction
4657
- * sequence used to implement this method
4658
- */
4659
- rb_define_method(rb_cMETHOD, "clss", node_clss, 0);
4660
- rb_ary_push(members, rb_str_new2("clss"));
4661
-
4662
- /* Document-method: noex
4663
- * the method's flags
4664
- */
4665
- rb_define_method(rb_cMETHOD, "noex", node_noex, 0);
4666
- rb_ary_push(members, rb_str_new2("noex"));
4667
- }
4668
-
4669
4521
  /* Document-class: Node::MODULE
4670
4522
  * Represents a module definition, e.g.:
4671
4523
  * module cpath
@@ -4685,17 +4537,17 @@ void define_node_subclass_methods()
4685
4537
  rb_iv_set(rb_cMODULE, "__type__", INT2NUM(NODE_MODULE));
4686
4538
  rb_define_singleton_method(rb_cMODULE, "members", node_s_members, 0);
4687
4539
 
4688
- /* Document-method: cpath
4689
- * the name of the module to define
4690
- */
4691
- rb_define_method(rb_cMODULE, "cpath", node_cpath, 0);
4692
- rb_ary_push(members, rb_str_new2("cpath"));
4693
-
4694
4540
  /* Document-method: body
4695
4541
  * the body of the module definition
4696
4542
  */
4697
4543
  rb_define_method(rb_cMODULE, "body", node_body, 0);
4698
4544
  rb_ary_push(members, rb_str_new2("body"));
4545
+
4546
+ /* Document-method: cpath
4547
+ * the name of the module to define
4548
+ */
4549
+ rb_define_method(rb_cMODULE, "cpath", node_cpath, 0);
4550
+ rb_ary_push(members, rb_str_new2("cpath"));
4699
4551
  }
4700
4552
 
4701
4553
  /* Document-class: Node::NEXT
@@ -4800,11 +4652,11 @@ void define_node_subclass_methods()
4800
4652
  rb_iv_set(rb_cOP_ASGN1, "__type__", INT2NUM(NODE_OP_ASGN1));
4801
4653
  rb_define_singleton_method(rb_cOP_ASGN1, "members", node_s_members, 0);
4802
4654
 
4803
- /* Document-method: args
4804
- * the arguments to the assigment
4655
+ /* Document-method: recv
4656
+ * the receiver of the assignment
4805
4657
  */
4806
- rb_define_method(rb_cOP_ASGN1, "args", node_args, 0);
4807
- rb_ary_push(members, rb_str_new2("args"));
4658
+ rb_define_method(rb_cOP_ASGN1, "recv", node_recv, 0);
4659
+ rb_ary_push(members, rb_str_new2("recv"));
4808
4660
 
4809
4661
  /* Document-method: mid
4810
4662
  * 0, 1, or the name a method to call to calculate the value of the
@@ -4813,11 +4665,11 @@ void define_node_subclass_methods()
4813
4665
  rb_define_method(rb_cOP_ASGN1, "mid", node_mid, 0);
4814
4666
  rb_ary_push(members, rb_str_new2("mid"));
4815
4667
 
4816
- /* Document-method: recv
4817
- * the receiver of the assignment
4668
+ /* Document-method: args
4669
+ * the arguments to the assigment
4818
4670
  */
4819
- rb_define_method(rb_cOP_ASGN1, "recv", node_recv, 0);
4820
- rb_ary_push(members, rb_str_new2("recv"));
4671
+ rb_define_method(rb_cOP_ASGN1, "args", node_args, 0);
4672
+ rb_ary_push(members, rb_str_new2("args"));
4821
4673
  }
4822
4674
 
4823
4675
  /* Document-class: Node::OP_ASGN2
@@ -4840,11 +4692,11 @@ void define_node_subclass_methods()
4840
4692
  rb_iv_set(rb_cOP_ASGN2, "__type__", INT2NUM(NODE_OP_ASGN2));
4841
4693
  rb_define_singleton_method(rb_cOP_ASGN2, "members", node_s_members, 0);
4842
4694
 
4843
- /* Document-method: value
4844
- * the value to assign to the attribute
4695
+ /* Document-method: recv
4696
+ * the receiver of the attribute
4845
4697
  */
4846
- rb_define_method(rb_cOP_ASGN2, "value", node_value, 0);
4847
- rb_ary_push(members, rb_str_new2("value"));
4698
+ rb_define_method(rb_cOP_ASGN2, "recv", node_recv, 0);
4699
+ rb_ary_push(members, rb_str_new2("recv"));
4848
4700
 
4849
4701
  /* Document-method: next
4850
4702
  * another node of type OP_ASGN2 which contains more information
@@ -4853,11 +4705,11 @@ void define_node_subclass_methods()
4853
4705
  rb_define_method(rb_cOP_ASGN2, "next", node_next, 0);
4854
4706
  rb_ary_push(members, rb_str_new2("next"));
4855
4707
 
4856
- /* Document-method: recv
4857
- * the receiver of the attribute
4708
+ /* Document-method: value
4709
+ * the value to assign to the attribute
4858
4710
  */
4859
- rb_define_method(rb_cOP_ASGN2, "recv", node_recv, 0);
4860
- rb_ary_push(members, rb_str_new2("recv"));
4711
+ rb_define_method(rb_cOP_ASGN2, "value", node_value, 0);
4712
+ rb_ary_push(members, rb_str_new2("value"));
4861
4713
  }
4862
4714
 
4863
4715
  /* Document-class: Node::OP_ASGN2_ARG
@@ -4873,12 +4725,6 @@ void define_node_subclass_methods()
4873
4725
  rb_iv_set(rb_cOP_ASGN2_ARG, "__type__", INT2NUM(NODE_OP_ASGN2_ARG));
4874
4726
  rb_define_singleton_method(rb_cOP_ASGN2_ARG, "members", node_s_members, 0);
4875
4727
 
4876
- /* Document-method: vid
4877
- * The method to call on the receiver to retrieve the attribute
4878
- */
4879
- rb_define_method(rb_cOP_ASGN2_ARG, "vid", node_vid, 0);
4880
- rb_ary_push(members, rb_str_new2("vid"));
4881
-
4882
4728
  /* Document-method: aid
4883
4729
  * The method to call on the receiver to set the attribute
4884
4730
  */
@@ -4892,6 +4738,12 @@ void define_node_subclass_methods()
4892
4738
  */
4893
4739
  rb_define_method(rb_cOP_ASGN2_ARG, "mid", node_mid, 0);
4894
4740
  rb_ary_push(members, rb_str_new2("mid"));
4741
+
4742
+ /* Document-method: vid
4743
+ * The method to call on the receiver to retrieve the attribute
4744
+ */
4745
+ rb_define_method(rb_cOP_ASGN2_ARG, "vid", node_vid, 0);
4746
+ rb_ary_push(members, rb_str_new2("vid"));
4895
4747
  }
4896
4748
 
4897
4749
  /* Document-class: Node::OP_ASGN_AND
@@ -4910,18 +4762,18 @@ void define_node_subclass_methods()
4910
4762
  rb_iv_set(rb_cOP_ASGN_AND, "__type__", INT2NUM(NODE_OP_ASGN_AND));
4911
4763
  rb_define_singleton_method(rb_cOP_ASGN_AND, "members", node_s_members, 0);
4912
4764
 
4765
+ /* Document-method: recv
4766
+ * an expression representing the left hand side of the assignment
4767
+ */
4768
+ rb_define_method(rb_cOP_ASGN_AND, "recv", node_recv, 0);
4769
+ rb_ary_push(members, rb_str_new2("recv"));
4770
+
4913
4771
  /* Document-method: value
4914
4772
  * an expression representing the assignment that should be
4915
4773
  * performed if the left hand side is true
4916
4774
  */
4917
4775
  rb_define_method(rb_cOP_ASGN_AND, "value", node_value, 0);
4918
4776
  rb_ary_push(members, rb_str_new2("value"));
4919
-
4920
- /* Document-method: recv
4921
- * an expression representing the left hand side of the assignment
4922
- */
4923
- rb_define_method(rb_cOP_ASGN_AND, "recv", node_recv, 0);
4924
- rb_ary_push(members, rb_str_new2("recv"));
4925
4777
  }
4926
4778
 
4927
4779
  /* Document-class: Node::OP_ASGN_OR
@@ -4940,6 +4792,12 @@ void define_node_subclass_methods()
4940
4792
  rb_iv_set(rb_cOP_ASGN_OR, "__type__", INT2NUM(NODE_OP_ASGN_OR));
4941
4793
  rb_define_singleton_method(rb_cOP_ASGN_OR, "members", node_s_members, 0);
4942
4794
 
4795
+ /* Document-method: recv
4796
+ * the receiver of the assignment
4797
+ */
4798
+ rb_define_method(rb_cOP_ASGN_OR, "recv", node_recv, 0);
4799
+ rb_ary_push(members, rb_str_new2("recv"));
4800
+
4943
4801
  /* Document-method: aid
4944
4802
  * if this indicator is nonzero, ruby will check to see if the
4945
4803
  * provided expression is defined, otherwise it will assume that
@@ -4953,12 +4811,6 @@ void define_node_subclass_methods()
4953
4811
  */
4954
4812
  rb_define_method(rb_cOP_ASGN_OR, "value", node_value, 0);
4955
4813
  rb_ary_push(members, rb_str_new2("value"));
4956
-
4957
- /* Document-method: recv
4958
- * the receiver of the assignment
4959
- */
4960
- rb_define_method(rb_cOP_ASGN_OR, "recv", node_recv, 0);
4961
- rb_ary_push(members, rb_str_new2("recv"));
4962
4814
  }
4963
4815
 
4964
4816
  /* Document-class: Node::OR
@@ -4976,17 +4828,17 @@ void define_node_subclass_methods()
4976
4828
  rb_iv_set(rb_cOR, "__type__", INT2NUM(NODE_OR));
4977
4829
  rb_define_singleton_method(rb_cOR, "members", node_s_members, 0);
4978
4830
 
4979
- /* Document-method: first
4980
- * the expression on the left hand side
4981
- */
4982
- rb_define_method(rb_cOR, "first", node_1st, 0);
4983
- rb_ary_push(members, rb_str_new2("first"));
4984
-
4985
4831
  /* Document-method: second
4986
4832
  * the expression on the right hand side
4987
4833
  */
4988
4834
  rb_define_method(rb_cOR, "second", node_2nd, 0);
4989
4835
  rb_ary_push(members, rb_str_new2("second"));
4836
+
4837
+ /* Document-method: first
4838
+ * the expression on the left hand side
4839
+ */
4840
+ rb_define_method(rb_cOR, "first", node_1st, 0);
4841
+ rb_ary_push(members, rb_str_new2("first"));
4990
4842
  }
4991
4843
 
4992
4844
  /* Document-class: Node::POSTEXE
@@ -5038,11 +4890,11 @@ void define_node_subclass_methods()
5038
4890
  rb_iv_set(rb_cRESBODY, "__type__", INT2NUM(NODE_RESBODY));
5039
4891
  rb_define_singleton_method(rb_cRESBODY, "members", node_s_members, 0);
5040
4892
 
5041
- /* Document-method: head
5042
- * the next rescue
4893
+ /* Document-method: body
4894
+ * the expresion to evaluate if the exception type matches
5043
4895
  */
5044
- rb_define_method(rb_cRESBODY, "head", node_head, 0);
5045
- rb_ary_push(members, rb_str_new2("head"));
4896
+ rb_define_method(rb_cRESBODY, "body", node_body, 0);
4897
+ rb_ary_push(members, rb_str_new2("body"));
5046
4898
 
5047
4899
  /* Document-method: args
5048
4900
  * the expression type to match against
@@ -5050,11 +4902,11 @@ void define_node_subclass_methods()
5050
4902
  rb_define_method(rb_cRESBODY, "args", node_args, 0);
5051
4903
  rb_ary_push(members, rb_str_new2("args"));
5052
4904
 
5053
- /* Document-method: body
5054
- * the expresion to evaluate if the exception type matches
4905
+ /* Document-method: head
4906
+ * the next rescue
5055
4907
  */
5056
- rb_define_method(rb_cRESBODY, "body", node_body, 0);
5057
- rb_ary_push(members, rb_str_new2("body"));
4908
+ rb_define_method(rb_cRESBODY, "head", node_head, 0);
4909
+ rb_ary_push(members, rb_str_new2("head"));
5058
4910
  }
5059
4911
 
5060
4912
  /* Document-class: Node::RESCUE
@@ -5094,11 +4946,11 @@ void define_node_subclass_methods()
5094
4946
  rb_iv_set(rb_cRESCUE, "__type__", INT2NUM(NODE_RESCUE));
5095
4947
  rb_define_singleton_method(rb_cRESCUE, "members", node_s_members, 0);
5096
4948
 
5097
- /* Document-method: head
5098
- * the body of the block to evaluate
4949
+ /* Document-method: resq
4950
+ * the expression to be evaluated if an exception is raised
5099
4951
  */
5100
- rb_define_method(rb_cRESCUE, "head", node_head, 0);
5101
- rb_ary_push(members, rb_str_new2("head"));
4952
+ rb_define_method(rb_cRESCUE, "resq", node_resq, 0);
4953
+ rb_ary_push(members, rb_str_new2("resq"));
5102
4954
 
5103
4955
  /* Document-method: else
5104
4956
  * the expression to be evaluated if no exception is raised
@@ -5106,11 +4958,11 @@ void define_node_subclass_methods()
5106
4958
  rb_define_method(rb_cRESCUE, "else", node_else, 0);
5107
4959
  rb_ary_push(members, rb_str_new2("else"));
5108
4960
 
5109
- /* Document-method: resq
5110
- * the expression to be evaluated if an exception is raised
4961
+ /* Document-method: head
4962
+ * the body of the block to evaluate
5111
4963
  */
5112
- rb_define_method(rb_cRESCUE, "resq", node_resq, 0);
5113
- rb_ary_push(members, rb_str_new2("resq"));
4964
+ rb_define_method(rb_cRESCUE, "head", node_head, 0);
4965
+ rb_ary_push(members, rb_str_new2("head"));
5114
4966
  }
5115
4967
 
5116
4968
  /* Document-class: Node::RETRY
@@ -5389,10 +5241,10 @@ void define_node_subclass_methods()
5389
5241
  rb_iv_set(rb_cVALIAS, "__member__", members);
5390
5242
  rb_iv_set(rb_cVALIAS, "__type__", INT2NUM(NODE_VALIAS));
5391
5243
  rb_define_singleton_method(rb_cVALIAS, "members", node_s_members, 0);
5392
- rb_define_method(rb_cVALIAS, "first", node_1st, 0);
5393
- rb_ary_push(members, rb_str_new2("first"));
5394
5244
  rb_define_method(rb_cVALIAS, "second", node_2nd, 0);
5395
5245
  rb_ary_push(members, rb_str_new2("second"));
5246
+ rb_define_method(rb_cVALIAS, "first", node_1st, 0);
5247
+ rb_ary_push(members, rb_str_new2("first"));
5396
5248
  }
5397
5249
 
5398
5250
  /* Document-class: Node::VCALL
@@ -5452,12 +5304,6 @@ void define_node_subclass_methods()
5452
5304
  rb_iv_set(rb_cWHEN, "__type__", INT2NUM(NODE_WHEN));
5453
5305
  rb_define_singleton_method(rb_cWHEN, "members", node_s_members, 0);
5454
5306
 
5455
- /* Document-method: head
5456
- * a value to compare against, or a condition to be tested
5457
- */
5458
- rb_define_method(rb_cWHEN, "head", node_head, 0);
5459
- rb_ary_push(members, rb_str_new2("head"));
5460
-
5461
5307
  /* Document-method: body
5462
5308
  * an expression to evaluate if the condition evaluates to true
5463
5309
  */
@@ -5469,6 +5315,12 @@ void define_node_subclass_methods()
5469
5315
  */
5470
5316
  rb_define_method(rb_cWHEN, "next", node_next, 0);
5471
5317
  rb_ary_push(members, rb_str_new2("next"));
5318
+
5319
+ /* Document-method: head
5320
+ * a value to compare against, or a condition to be tested
5321
+ */
5322
+ rb_define_method(rb_cWHEN, "head", node_head, 0);
5323
+ rb_ary_push(members, rb_str_new2("head"));
5472
5324
  }
5473
5325
 
5474
5326
  /* Document-class: Node::WHILE
@@ -5534,17 +5386,17 @@ void define_node_subclass_methods()
5534
5386
  rb_iv_set(rb_cYIELD, "__type__", INT2NUM(NODE_YIELD));
5535
5387
  rb_define_singleton_method(rb_cYIELD, "members", node_s_members, 0);
5536
5388
 
5537
- /* Document-method: head
5538
- * the value to yield
5539
- */
5540
- rb_define_method(rb_cYIELD, "head", node_head, 0);
5541
- rb_ary_push(members, rb_str_new2("head"));
5542
-
5543
5389
  /* Document-method: state
5544
5390
  * if nonzero, splats the value before yielding
5545
5391
  */
5546
5392
  rb_define_method(rb_cYIELD, "state", node_state, 0);
5547
5393
  rb_ary_push(members, rb_str_new2("state"));
5394
+
5395
+ /* Document-method: head
5396
+ * the value to yield
5397
+ */
5398
+ rb_define_method(rb_cYIELD, "head", node_head, 0);
5399
+ rb_ary_push(members, rb_str_new2("head"));
5548
5400
  }
5549
5401
 
5550
5402
  /* Document-class: Node::ZARRAY