ruby-dcl 1.6.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (319) hide show
  1. data/ChangeLog +321 -0
  2. data/GenWrapper/Makefile +14 -0
  3. data/GenWrapper/cproto2init.rb +41 -0
  4. data/GenWrapper/dcl_narrayed_funcs.rb +181 -0
  5. data/GenWrapper/dcl_rb_footing +29 -0
  6. data/GenWrapper/dcl_rb_heading +129 -0
  7. data/GenWrapper/def.rb +20 -0
  8. data/GenWrapper/elim_ary_size.rb +398 -0
  9. data/GenWrapper/etc/Mk_proto +375 -0
  10. data/GenWrapper/etc/dcl_gen +13 -0
  11. data/GenWrapper/etc/p_header +63 -0
  12. data/GenWrapper/etc/p_init +410 -0
  13. data/GenWrapper/pparse.rb +137 -0
  14. data/GenWrapper/proto/Makefile +35 -0
  15. data/GenWrapper/proto/grph1_00 +17 -0
  16. data/GenWrapper/proto/grph1_csgi.fp +27 -0
  17. data/GenWrapper/proto/grph1_scpack.fp +442 -0
  18. data/GenWrapper/proto/grph1_sgpack.fp +1406 -0
  19. data/GenWrapper/proto/grph1_slpack.fp +316 -0
  20. data/GenWrapper/proto/grph1_stpack.fp +411 -0
  21. data/GenWrapper/proto/grph1_swpack.fp +746 -0
  22. data/GenWrapper/proto/grph2_00 +16 -0
  23. data/GenWrapper/proto/grph2_grpack.fp +139 -0
  24. data/GenWrapper/proto/grph2_ucpack.fp +522 -0
  25. data/GenWrapper/proto/grph2_udpack.fp +692 -0
  26. data/GenWrapper/proto/grph2_uepack.fp +601 -0
  27. data/GenWrapper/proto/grph2_ugpack.fp +436 -0
  28. data/GenWrapper/proto/grph2_uhpack.fp +246 -0
  29. data/GenWrapper/proto/grph2_ulpack.fp +516 -0
  30. data/GenWrapper/proto/grph2_umpack.fp +676 -0
  31. data/GenWrapper/proto/grph2_uspack.fp +989 -0
  32. data/GenWrapper/proto/grph2_uupack.fp +663 -0
  33. data/GenWrapper/proto/grph2_uvpack.fp +246 -0
  34. data/GenWrapper/proto/grph2_uwpack.fp +203 -0
  35. data/GenWrapper/proto/grph2_uxpack.fp +295 -0
  36. data/GenWrapper/proto/grph2_uypack.fp +295 -0
  37. data/GenWrapper/proto/grph2_uzpack.fp +574 -0
  38. data/GenWrapper/proto/math1_00 +12 -0
  39. data/GenWrapper/proto/math1_blklib.fp +58 -0
  40. data/GenWrapper/proto/math1_chrlib.fp +83 -0
  41. data/GenWrapper/proto/math1_fnclib.fp +79 -0
  42. data/GenWrapper/proto/math1_gnmlib.fp +118 -0
  43. data/GenWrapper/proto/math1_gt2dlib.fp +144 -0
  44. data/GenWrapper/proto/math1_ifalib.fp +123 -0
  45. data/GenWrapper/proto/math1_indxlib.fp +222 -0
  46. data/GenWrapper/proto/math1_intlib.fp +46 -0
  47. data/GenWrapper/proto/math1_lrllib.fp +276 -0
  48. data/GenWrapper/proto/math1_maplib.fp +24 -0
  49. data/GenWrapper/proto/math1_oslib.fp +28 -0
  50. data/GenWrapper/proto/math1_rfalib.fp +420 -0
  51. data/GenWrapper/proto/math1_rfblib.fp +51 -0
  52. data/GenWrapper/proto/math1_sublib.fp +60 -0
  53. data/GenWrapper/proto/math1_syslib.fp +767 -0
  54. data/GenWrapper/proto/math1_vialib.fp +339 -0
  55. data/GenWrapper/proto/math1_viblib.fp +264 -0
  56. data/GenWrapper/proto/math1_vralib.fp +339 -0
  57. data/GenWrapper/proto/math1_vrblib.fp +264 -0
  58. data/GenWrapper/proto/math1_xfclib.fp +68 -0
  59. data/GenWrapper/proto/math2_00 +12 -0
  60. data/GenWrapper/proto/math2_fftlib.fp +803 -0
  61. data/GenWrapper/proto/math2_intrlib.fp +32 -0
  62. data/GenWrapper/proto/math2_odelib.fp_notused +568 -0
  63. data/GenWrapper/proto/math2_rnmlib.fp +54 -0
  64. data/GenWrapper/proto/math2_shtlib.fp +1292 -0
  65. data/GenWrapper/proto/math2_shtlib.fp_old +1294 -0
  66. data/GenWrapper/proto/math2_vstlib.fp +84 -0
  67. data/GenWrapper/proto/misc1_00 +17 -0
  68. data/GenWrapper/proto/misc1_chnlib.fp +47 -0
  69. data/GenWrapper/proto/misc1_datelib.fp +352 -0
  70. data/GenWrapper/proto/misc1_fmtlib.fp +19 -0
  71. data/GenWrapper/proto/misc1_misclib.fp +26 -0
  72. data/GenWrapper/proto/misc1_randlib.fp +36 -0
  73. data/GenWrapper/proto/misc1_timelib.fp +151 -0
  74. data/GenWrapper/proto2c.rb +13 -0
  75. data/GenWrapper/prototype.rb +209 -0
  76. data/GenWrapper/util.rb +9 -0
  77. data/GenWrapper/variable.rb +671 -0
  78. data/README +29 -0
  79. data/Rakefile +44 -0
  80. data/ToDo +2 -0
  81. data/dcl_cary2obj.c +354 -0
  82. data/dcl_narrayed_funcs.c +518 -0
  83. data/dcl_obj2cary.c +512 -0
  84. data/dcl_rubydcloriginal.c +129 -0
  85. data/demo/gokuraku/hop/hop.rb +26 -0
  86. data/demo/gokuraku/jump/jump1.rb +64 -0
  87. data/demo/gokuraku/jump/jump2.rb +50 -0
  88. data/demo/gokuraku/layout/lay1.rb +46 -0
  89. data/demo/gokuraku/layout/lay2.rb +44 -0
  90. data/demo/gokuraku/step/step0.rb +34 -0
  91. data/demo/gokuraku/step/step1.rb +84 -0
  92. data/demo/gokuraku/step/step2.rb +62 -0
  93. data/demo/gokuraku/u1d/u1d1.rb +37 -0
  94. data/demo/gokuraku/u1d/u1d2.rb +50 -0
  95. data/demo/gokuraku/u2d/u2d1.rb +46 -0
  96. data/demo/gokuraku/u2d/u2d2.rb +49 -0
  97. data/demo/gokuraku/u2d/u2d3.rb +45 -0
  98. data/demo/gokuraku/u2d/u2d4.rb +61 -0
  99. data/demo/grph1/scpack/scpkt2.rb +40 -0
  100. data/demo/grph1/scpack/scpkt3.rb +102 -0
  101. data/demo/grph1/scpack/scpkt6.rb +84 -0
  102. data/demo/grph1/scpack/scpkt7.rb +59 -0
  103. data/demo/grph1/scpack/scpkt8.rb +60 -0
  104. data/demo/grph1/scpack/t810630.dat +296 -0
  105. data/demo/grph1/scpack/t811231.dat +296 -0
  106. data/demo/grph1/sgpack/sgfont.rb +52 -0
  107. data/demo/grph1/sgpack/sgfonz.rb +53 -0
  108. data/demo/grph1/sgpack/sgksx1.rb +44 -0
  109. data/demo/grph1/sgpack/sgksx2.rb +90 -0
  110. data/demo/grph1/sgpack/sgksx3.rb +75 -0
  111. data/demo/grph1/sgpack/sglidx.rb +40 -0
  112. data/demo/grph1/sgpack/sgltyp.rb +48 -0
  113. data/demo/grph1/sgpack/sgpk01.rb +39 -0
  114. data/demo/grph1/sgpack/sgpk02.rb +79 -0
  115. data/demo/grph1/sgpack/sgpk03.rb +107 -0
  116. data/demo/grph1/sgpack/sgpk04.rb +86 -0
  117. data/demo/grph1/sgpack/sgpk05.rb +66 -0
  118. data/demo/grph1/sgpack/sgpk06.rb +91 -0
  119. data/demo/grph1/sgpack/sgpk07.rb +66 -0
  120. data/demo/grph1/sgpack/sgpk08.rb +67 -0
  121. data/demo/grph1/sgpack/sgpk09.rb +61 -0
  122. data/demo/grph1/sgpack/sgpk10.rb +58 -0
  123. data/demo/grph1/sgpack/sgtclr.rb +59 -0
  124. data/demo/grph1/sgpack/sgtone.rb +70 -0
  125. data/demo/grph1/sgpack/sgtonz.rb +66 -0
  126. data/demo/grph1/slpack/slpk01.rb +37 -0
  127. data/demo/grph1/slpack/slpk02.rb +29 -0
  128. data/demo/grph1/slpack/slpk03.rb +36 -0
  129. data/demo/grph1/slpack/slpk04.rb +36 -0
  130. data/demo/grph2/g2pack/g2pk01.rb +78 -0
  131. data/demo/grph2/g2pack/g2pk02.rb +75 -0
  132. data/demo/grph2/grpack/grpk01.rb +65 -0
  133. data/demo/grph2/ucpack/ucpk01.rb +95 -0
  134. data/demo/grph2/ucpack/ucpk02.rb +95 -0
  135. data/demo/grph2/udegpk/u2df01.rb +50 -0
  136. data/demo/grph2/udegpk/u2df02.rb +76 -0
  137. data/demo/grph2/udegpk/u2df03.rb +80 -0
  138. data/demo/grph2/udegpk/u2df04.rb +52 -0
  139. data/demo/grph2/udegpk/u2df05.rb +70 -0
  140. data/demo/grph2/udegpk/u2df06.rb +59 -0
  141. data/demo/grph2/udegpk/u2df07.rb +68 -0
  142. data/demo/grph2/udegpk/u2df08.rb +91 -0
  143. data/demo/grph2/udegpk/u2df09b.rb +88 -0
  144. data/demo/grph2/udegpk/u2df09c.rb +89 -0
  145. data/demo/grph2/udegpk/u2df09e.rb +88 -0
  146. data/demo/grph2/udegpk/u2df09f.rb +89 -0
  147. data/demo/grph2/ulpack/ulpk01.rb +111 -0
  148. data/demo/grph2/ulpack/ulpk01n.rb +111 -0
  149. data/demo/grph2/ulpack/ulpk02.rb +111 -0
  150. data/demo/grph2/ulpack/ulpk02n.rb +111 -0
  151. data/demo/grph2/umpack/t811231.dat +296 -0
  152. data/demo/grph2/umpack/test01.rb +69 -0
  153. data/demo/grph2/umpack/test02.rb +64 -0
  154. data/demo/grph2/umpack/test03.rb +84 -0
  155. data/demo/grph2/umpack/test04.rb +54 -0
  156. data/demo/grph2/umpack/test05.rb +85 -0
  157. data/demo/grph2/umpack/test06.rb +44 -0
  158. data/demo/grph2/umpack/test07.rb +43 -0
  159. data/demo/grph2/umpack/test08.rb +37 -0
  160. data/demo/grph2/umpack/test09.rb +86 -0
  161. data/demo/grph2/umpack/test10.rb +52 -0
  162. data/demo/grph2/umpack/umpk01.rb +65 -0
  163. data/demo/grph2/umpack/umpk02.rb +54 -0
  164. data/demo/grph2/umpack/umpk03.rb +46 -0
  165. data/demo/grph2/umpack/umpk04.rb +65 -0
  166. data/demo/grph2/umpack/umpk05.rb +84 -0
  167. data/demo/grph2/uspack/uspk01.rb +39 -0
  168. data/demo/grph2/uspack/uspk02.rb +47 -0
  169. data/demo/grph2/uspack/uspk03.rb +38 -0
  170. data/demo/grph2/uspack/uspk04.rb +64 -0
  171. data/demo/grph2/uspack/uspk05.rb +68 -0
  172. data/demo/grph2/uspack/uspk06.rb +43 -0
  173. data/demo/grph2/uspack/uspk07.rb +62 -0
  174. data/demo/grph2/uspack/uspk08.rb +46 -0
  175. data/demo/grph2/uspack/uspk09.rb +89 -0
  176. data/demo/grph2/uspack/uspk10.rb +48 -0
  177. data/demo/grph2/uspack/uspk11.rb +71 -0
  178. data/demo/grph2/uspack/uspk12.rb +51 -0
  179. data/demo/grph2/uupack/uupk01.rb +50 -0
  180. data/demo/grph2/uupack/uupk02.rb +74 -0
  181. data/demo/grph2/uupack/uupk03.rb +56 -0
  182. data/demo/grph2/uupack/uupk04.rb +84 -0
  183. data/demo/grph2/uupack/uupk05.rb +74 -0
  184. data/demo/grph2/uupack/uupk06.rb +77 -0
  185. data/demo/grph2/uupack/uupk07.rb +88 -0
  186. data/demo/grph2/uxyzpk/uxyz01.rb +38 -0
  187. data/demo/grph2/uxyzpk/uxyz02.rb +36 -0
  188. data/demo/grph2/uxyzpk/uxyz03.rb +37 -0
  189. data/demo/grph2/uxyzpk/uxyz04.rb +54 -0
  190. data/demo/grph2/uxyzpk/uxyz05.rb +41 -0
  191. data/demo/grph2/uxyzpk/uxyz06.rb +42 -0
  192. data/demo/grph2/uxyzpk/uxyz07.rb +38 -0
  193. data/demo/grph2/uxyzpk/uxyz08.rb +60 -0
  194. data/demo/grph2/uxyzpk/uxyz09.rb +52 -0
  195. data/demo/grph2/uxyzpk/uxyz10.rb +57 -0
  196. data/demo/grph2/ximage/MEMO +23 -0
  197. data/demo/grph2/ximage/tomsclm.dat +1344 -0
  198. data/demo/grph2/ximage/ximg01.rb +145 -0
  199. data/demo/math1/gt2dlib/gt2d01.rb +33 -0
  200. data/demo/math2/fftlib/fftl01.rb +28 -0
  201. data/demo/math2/fftlib/fftl02.rb +224 -0
  202. data/demo/math2/intrlib/intr01.rb +22 -0
  203. data/demo/math2/rnmlib/rnml01.rb +21 -0
  204. data/demo/math2/vstlib/vstl01.rb +29 -0
  205. data/demo/math2/vstlib/vstl02.rb +38 -0
  206. data/demo/rakuraku/color/color1.rb +61 -0
  207. data/demo/rakuraku/color/color2.rb +57 -0
  208. data/demo/rakuraku/color/color3.rb +81 -0
  209. data/demo/rakuraku/kihon/kihon1.rb +39 -0
  210. data/demo/rakuraku/kihon/kihon2.rb +56 -0
  211. data/demo/rakuraku/kihon/kihon3.rb +57 -0
  212. data/demo/rakuraku/kihon/kihon4.rb +70 -0
  213. data/demo/rakuraku/kihon/kihon5.rb +56 -0
  214. data/demo/rakuraku/kihon/kihon6.rb +40 -0
  215. data/demo/rakuraku/kihon/kihon7.rb +98 -0
  216. data/demo/rakuraku/kihon/kihon8.rb +93 -0
  217. data/demo/rakuraku/kihon/kihon9.rb +77 -0
  218. data/demo/rakuraku/kihon/kihona.rb +123 -0
  219. data/demo/rakuraku/kihon/kihonb.rb +73 -0
  220. data/demo/rakuraku/kihon/kihonc.rb +110 -0
  221. data/demo/rakuraku/layout/lay1.rb +29 -0
  222. data/demo/rakuraku/layout/lay2.rb +28 -0
  223. data/demo/rakuraku/layout/lay3.rb +29 -0
  224. data/demo/rakuraku/map3d/map3d1.rb +68 -0
  225. data/demo/rakuraku/map3d/map3d2.rb +67 -0
  226. data/demo/rakuraku/map3d/map3d3.rb +66 -0
  227. data/demo/rakuraku/map3d/map3d4.rb +107 -0
  228. data/demo/rakuraku/map3d/map3d5.rb +118 -0
  229. data/demo/rakuraku/map3d/map3d6.rb +96 -0
  230. data/demo/rakuraku/map3d/map3d7.rb +98 -0
  231. data/demo/rakuraku/miss/miss1.rb +76 -0
  232. data/demo/rakuraku/miss/miss2.rb +60 -0
  233. data/demo/rakuraku/quick/quick1.rb +35 -0
  234. data/demo/rakuraku/quick/quick2.rb +33 -0
  235. data/demo/rakuraku/quick/quick3.rb +46 -0
  236. data/demo/rakuraku/quick/quick4.rb +47 -0
  237. data/demo/rakuraku/quick/quick5.rb +46 -0
  238. data/demo/rakuraku/u2d/u2d1.rb +50 -0
  239. data/demo/rakuraku/u2d/u2d2.rb +51 -0
  240. data/demo/rakuraku/u2d/u2d3.rb +70 -0
  241. data/demo/rakuraku/u2d/u2d4.rb +59 -0
  242. data/demo/rakuraku/u2d/u2d5.rb +61 -0
  243. data/demo/rakuraku/u2d/u2d6.rb +57 -0
  244. data/demo/rakuraku/u2d/u2d7.rb +103 -0
  245. data/demo/rakuraku/uspack/uspac1.rb +35 -0
  246. data/demo/rakuraku/uspack/uspac2.rb +66 -0
  247. data/demo/rakuraku/uspack/uspac3.rb +37 -0
  248. data/demo/rakuraku/uspack/uspac4.rb +49 -0
  249. data/demo/rakuraku/uxyz/uxyz1.rb +37 -0
  250. data/demo/rakuraku/uxyz/uxyz2.rb +35 -0
  251. data/demo/rakuraku/uxyz/uxyz3.rb +38 -0
  252. data/demo/rakuraku/uxyz/uxyz4.rb +36 -0
  253. data/demo/rakuraku/uxyz/uxyz5.rb +57 -0
  254. data/demo/rakuraku/uxyz/uxyz6.rb +43 -0
  255. data/demo/rakuraku/uxyz/uxyz7.rb +39 -0
  256. data/demo/rakuraku/uxyz/uxyz8.rb +56 -0
  257. data/demo/rubydcloriginal/uemrkz1.rb +37 -0
  258. data/dummy.c +9 -0
  259. data/extconf.rb +133 -0
  260. data/grph1_csgi.c +119 -0
  261. data/grph1_scpack.c +1388 -0
  262. data/grph1_sgpack.c +3876 -0
  263. data/grph1_slpack.c +432 -0
  264. data/grph1_stpack.c +1044 -0
  265. data/grph1_swpack.c +1922 -0
  266. data/grph1_zgpack.c.org +141 -0
  267. data/grph2_grpack.c +368 -0
  268. data/grph2_ucpack.c +1232 -0
  269. data/grph2_udpack.c +1404 -0
  270. data/grph2_uepack.c +1443 -0
  271. data/grph2_ugpack.c +1073 -0
  272. data/grph2_uhpack.c +943 -0
  273. data/grph2_ulpack.c +1304 -0
  274. data/grph2_umpack.c +1540 -0
  275. data/grph2_uspack.c +2481 -0
  276. data/grph2_uupack.c +1689 -0
  277. data/grph2_uvpack.c +943 -0
  278. data/grph2_uwpack.c +552 -0
  279. data/grph2_uxpack.c +555 -0
  280. data/grph2_uypack.c +555 -0
  281. data/grph2_uzpack.c +1455 -0
  282. data/init.c.default +187 -0
  283. data/init.c.gtk +189 -0
  284. data/lib/dcl.rb +5084 -0
  285. data/math1_blklib.c +227 -0
  286. data/math1_chrlib.c +239 -0
  287. data/math1_fnclib.c +254 -0
  288. data/math1_gnmlib.c +356 -0
  289. data/math1_gt2dlib.c +514 -0
  290. data/math1_ifalib.c +427 -0
  291. data/math1_indxlib.c +709 -0
  292. data/math1_intlib.c +167 -0
  293. data/math1_lrllib.c +817 -0
  294. data/math1_maplib.c +172 -0
  295. data/math1_oslib.c +111 -0
  296. data/math1_rfalib.c +1417 -0
  297. data/math1_rfblib.c +232 -0
  298. data/math1_sublib.c +221 -0
  299. data/math1_syslib.c +2025 -0
  300. data/math1_vialib.c +1156 -0
  301. data/math1_viblib.c +1027 -0
  302. data/math1_vralib.c +1156 -0
  303. data/math1_vrblib.c +1027 -0
  304. data/math1_xfclib.c +142 -0
  305. data/math2_fftlib.c +833 -0
  306. data/math2_intrlib.c +138 -0
  307. data/math2_rnmlib.c +226 -0
  308. data/math2_shtlib.c +1568 -0
  309. data/math2_vstlib.c +366 -0
  310. data/misc1_chnlib.c +179 -0
  311. data/misc1_datelib.c +953 -0
  312. data/misc1_fmtlib.c +99 -0
  313. data/misc1_misclib.c +118 -0
  314. data/misc1_randlib.c +142 -0
  315. data/misc1_timelib.c +380 -0
  316. data/obsolete/README +2 -0
  317. data/obsolete/dcl_ext.html +112 -0
  318. data/obsolete/dcl_ext.rb +313 -0
  319. metadata +433 -0
@@ -0,0 +1,410 @@
1
+ /*
2
+ * $Id: p_init,v 1.1.1.1 2011-02-23 07:21:28 horinout Exp $
3
+ */
4
+
5
+ void
6
+ Init_dcl()
7
+ {
8
+ /* for Num::DCl **
9
+ mNum = rb_define_module("Num");
10
+ mDCL = rb_define_module_under(mNum, "DCL");
11
+ */
12
+ mDCL = rb_define_module("DCL");
13
+
14
+ /*** grph2 ***/
15
+ /* grpack */
16
+ rb_define_module_function(mDCL, "gropn", dcl_gropn, 1);
17
+ rb_define_module_function(mDCL, "grcls", dcl_grcls, 0);
18
+ rb_define_module_function(mDCL, "grfrm", dcl_grfrm, 0);
19
+ rb_define_module_function(mDCL, "grswnd", dcl_grswnd, 4);
20
+ rb_define_module_function(mDCL, "grsvpt", dcl_grsvpt, 4);
21
+ rb_define_module_function(mDCL, "grstrn", dcl_grstrn, 1);
22
+ rb_define_module_function(mDCL, "grstrf", dcl_grstrf, 0);
23
+ rb_define_module_function(mDCL, "grfig", dcl_grfig, 0);
24
+ rb_define_module_function(mDCL, "grsmpl", dcl_grsmpl, 3);
25
+ rb_define_module_function(mDCL, "grssim", dcl_grssim, 3);
26
+ rb_define_module_function(mDCL, "grstxy", dcl_grstxy, 4);
27
+ /* ucpack */
28
+ rb_define_module_function(mDCL, "ucxacl", dcl_ucxacl, 3);
29
+ rb_define_module_function(mDCL, "ucxady", dcl_ucxady, 3);
30
+ rb_define_module_function(mDCL, "ucxamn", dcl_ucxamn, 3);
31
+ rb_define_module_function(mDCL, "ucxayr", dcl_ucxayr, 3);
32
+ rb_define_module_function(mDCL, "ucyacl", dcl_ucyacl, 3);
33
+ rb_define_module_function(mDCL, "ucyady", dcl_ucyady, 3);
34
+ rb_define_module_function(mDCL, "ucyamn", dcl_ucyamn, 3);
35
+ rb_define_module_function(mDCL, "ucyayr", dcl_ucyayr, 3);
36
+ /* udpack */
37
+ rb_define_module_function(mDCL, "udcntr", dcl_udcntr, 4);
38
+ rb_define_module_function(mDCL, "udsfmt", dcl_udsfmt, 1);
39
+ rb_define_module_function(mDCL, "uddclv", dcl_uddclv, 1);
40
+ rb_define_module_function(mDCL, "udgcla", dcl_udgcla, 3);
41
+ rb_define_module_function(mDCL, "udgclb", dcl_udgclb, 5);
42
+ rb_define_module_function(mDCL, "udsclv", dcl_udsclv, 5);
43
+ rb_define_module_function(mDCL, "udiset", dcl_udiset, 2);
44
+ rb_define_module_function(mDCL, "udlset", dcl_udlset, 2);
45
+ rb_define_module_function(mDCL, "udrset", dcl_udrset, 2);
46
+ /* uepack */
47
+ rb_define_module_function(mDCL, "ueitlv", dcl_ueitlv, 0);
48
+ rb_define_module_function(mDCL, "uestlv", dcl_uestlv, 3);
49
+ rb_define_module_function(mDCL, "uestln", dcl_uestln, 3);
50
+ rb_define_module_function(mDCL, "uetone", dcl_uetone, 4);
51
+ rb_define_module_function(mDCL, "uetonf", dcl_uetonf, 4);
52
+ /* ugpack */
53
+ rb_define_module_function(mDCL, "ugvect", dcl_ugvect, 6);
54
+ rb_define_module_function(mDCL, "uglset", dcl_uglset, 2);
55
+ rb_define_module_function(mDCL, "ugrset", dcl_ugrset, 2);
56
+ rb_define_module_function(mDCL, "ugsut", dcl_ugsut, 2);
57
+ /* uhpack */
58
+ rb_define_module_function(mDCL, "uhbra", dcl_uhbra, 4);
59
+ rb_define_module_function(mDCL, "uhbrf", dcl_uhbrf, 4);
60
+ rb_define_module_function(mDCL, "uhbrl", dcl_uhbrl, 3);
61
+ rb_define_module_function(mDCL, "uhbxa", dcl_uhbxa, 4);
62
+ rb_define_module_function(mDCL, "uhbxf", dcl_uhbxf, 4);
63
+ rb_define_module_function(mDCL, "uhbxl", dcl_uhbxl, 3);
64
+ rb_define_module_function(mDCL, "uhdif", dcl_uhdif, 4);
65
+ rb_define_module_function(mDCL, "uherb", dcl_uherb, 4);
66
+ /* ulpack */
67
+ rb_define_module_function(mDCL, "uliset", dcl_uliset, 2);
68
+ rb_define_module_function(mDCL, "ulsxbl", dcl_ulsxbl, 2);
69
+ rb_define_module_function(mDCL, "ulsybl", dcl_ulsybl, 2);
70
+ rb_define_module_function(mDCL, "ulxlog", dcl_ulxlog, 3);
71
+ rb_define_module_function(mDCL, "ulxsfm", dcl_ulxsfm, 1);
72
+ rb_define_module_function(mDCL, "ulylog", dcl_ulylog, 3);
73
+ rb_define_module_function(mDCL, "ulysfm", dcl_ulysfm, 1);
74
+ /* umpack */
75
+ rb_define_module_function(mDCL, "umpmap", dcl_umpmap, 1);
76
+ rb_define_module_function(mDCL, "umpgrd", dcl_umpgrd, 0);
77
+ rb_define_module_function(mDCL, "umpglb", dcl_umpglb, 0);
78
+ rb_define_module_function(mDCL, "umpfit", dcl_umpfit, 0);
79
+ rb_define_module_function(mDCL, "umplim", dcl_umplim, 0);
80
+ rb_define_module_function(mDCL, "umiset", dcl_umiset, 2);
81
+ rb_define_module_function(mDCL, "umlset", dcl_umlset, 2);
82
+ rb_define_module_function(mDCL, "umrset", dcl_umrset, 2);
83
+ /* uspack */
84
+ rb_define_module_function(mDCL, "ussttl", dcl_ussttl, 4);
85
+ rb_define_module_function(mDCL, "usgrph", dcl_usgrph, 3);
86
+ rb_define_module_function(mDCL, "usspnt", dcl_usspnt, 3);
87
+ rb_define_module_function(mDCL, "uspfit", dcl_uspfit, 0);
88
+ rb_define_module_function(mDCL, "usdaxs", dcl_usdaxs, 0);
89
+ rb_define_module_function(mDCL, "uscset", dcl_uscset, 2);
90
+ rb_define_module_function(mDCL, "uslset", dcl_uslset, 2);
91
+ rb_define_module_function(mDCL, "usrset", dcl_usrset, 2);
92
+ rb_define_module_function(mDCL, "usyaxs", dcl_usyaxs, 1);
93
+ /* uupack */
94
+ rb_define_module_function(mDCL, "uulin", dcl_uulin, 3);
95
+ rb_define_module_function(mDCL, "uulinz", dcl_uulinz, 5);
96
+ rb_define_module_function(mDCL, "uuslni", dcl_uuslni, 1);
97
+ rb_define_module_function(mDCL, "uuslnt", dcl_uuslnt, 1);
98
+ rb_define_module_function(mDCL, "uumrk", dcl_uumrk, 3);
99
+ rb_define_module_function(mDCL, "uumrkz", dcl_uumrkz, 6);
100
+ rb_define_module_function(mDCL, "uusmki", dcl_uusmki, 1);
101
+ rb_define_module_function(mDCL, "uusmks", dcl_uusmks, 1);
102
+ rb_define_module_function(mDCL, "uusmkt", dcl_uusmkt, 1);
103
+ rb_define_module_function(mDCL, "uusebi", dcl_uusebi, 1);
104
+ rb_define_module_function(mDCL, "uusebt", dcl_uusebt, 1);
105
+ rb_define_module_function(mDCL, "uusarp", dcl_uusarp, 2);
106
+ rb_define_module_function(mDCL, "uusbrs", dcl_uusbrs, 1);
107
+ rb_define_module_function(mDCL, "uusidv", dcl_uusidv, 2);
108
+ /* uvpack */
109
+ rb_define_module_function(mDCL, "uvbra", dcl_uvbra, 4);
110
+ rb_define_module_function(mDCL, "uvbrf", dcl_uvbrf, 4);
111
+ rb_define_module_function(mDCL, "uvbrl", dcl_uvbrl, 3);
112
+ rb_define_module_function(mDCL, "uvbxa", dcl_uvbxa, 4);
113
+ rb_define_module_function(mDCL, "uvbxf", dcl_uvbxf, 4);
114
+ rb_define_module_function(mDCL, "uvbxl", dcl_uvbxl, 3);
115
+ rb_define_module_function(mDCL, "uvdif", dcl_uvdif, 4);
116
+ rb_define_module_function(mDCL, "uverb", dcl_uverb, 4);
117
+ /* uwpack */
118
+ rb_define_module_function(mDCL, "uwsgxb", dcl_uwsgxb, 3);
119
+ rb_define_module_function(mDCL, "uwsgya", dcl_uwsgya, 2);
120
+ /* uxpack */
121
+ rb_define_module_function(mDCL, "uxaxdv", dcl_uxaxdv, 3);
122
+ rb_define_module_function(mDCL, "uxaxlb", dcl_uxaxlb, 7);
123
+ rb_define_module_function(mDCL, "uxsaxs", dcl_uxsaxs, 1);
124
+ rb_define_module_function(mDCL, "uxmttl", dcl_uxmttl, 3);
125
+ rb_define_module_function(mDCL, "uxsttl", dcl_uxsttl, 3);
126
+ rb_define_module_function(mDCL, "uxsfmt", dcl_uxsfmt, 1);
127
+ /* uypack */
128
+ rb_define_module_function(mDCL, "uyaxdv", dcl_uyaxdv, 3);
129
+ rb_define_module_function(mDCL, "uyaxlb", dcl_uyaxlb, 7);
130
+ rb_define_module_function(mDCL, "uysaxs", dcl_uysaxs, 1);
131
+ rb_define_module_function(mDCL, "uysttl", dcl_uysttl, 3);
132
+ rb_define_module_function(mDCL, "uysfmt", dcl_uysfmt, 1);
133
+ /* uzpack */
134
+ rb_define_module_function(mDCL, "uzfact", dcl_uzfact, 1);
135
+ rb_define_module_function(mDCL, "uzinit", dcl_uzinit, 0);
136
+ rb_define_module_function(mDCL, "uziset", dcl_uziset, 2);
137
+ rb_define_module_function(mDCL, "uzlset", dcl_uzlset, 2);
138
+ rb_define_module_function(mDCL, "uzrset", dcl_uzrset, 2);
139
+ /*** grph1 ***/
140
+ /* csgi */
141
+ rb_define_module_function(mDCL, "csgi", dcl_csgi, 1);
142
+ /* scpack */
143
+ rb_define_module_function(mDCL, "scsvpt", dcl_scsvpt, 6);
144
+ rb_define_module_function(mDCL, "scswnd", dcl_scswnd, 6);
145
+ rb_define_module_function(mDCL, "scstrn", dcl_scstrn, 1);
146
+ rb_define_module_function(mDCL, "scstrf", dcl_scstrf, 0);
147
+ rb_define_module_function(mDCL, "scseye", dcl_scseye, 3);
148
+ rb_define_module_function(mDCL, "scslog", dcl_scslog, 3);
149
+ rb_define_module_function(mDCL, "scsorg", dcl_scsorg, 4);
150
+ rb_define_module_function(mDCL, "scsobj", dcl_scsobj, 3);
151
+ rb_define_module_function(mDCL, "scsprj", dcl_scsprj, 0);
152
+ rb_define_module_function(mDCL, "scplu", dcl_scplu, 4);
153
+ rb_define_module_function(mDCL, "scspli", dcl_scspli, 1);
154
+ rb_define_module_function(mDCL, "scspln", dcl_scspln, 3);
155
+ rb_define_module_function(mDCL, "scpmu", dcl_scpmu, 4);
156
+ rb_define_module_function(mDCL, "scspmi", dcl_scspmi, 1);
157
+ rb_define_module_function(mDCL, "scspms", dcl_scspms, 1);
158
+ rb_define_module_function(mDCL, "scspmt", dcl_scspmt, 1);
159
+ rb_define_module_function(mDCL, "sctnu", dcl_sctnu, 3);
160
+ rb_define_module_function(mDCL, "scstnp", dcl_scstnp, 2);
161
+ /* sgpack */
162
+ rb_define_module_function(mDCL, "sgopn", dcl_sgopn, 1);
163
+ rb_define_module_function(mDCL, "sgcls", dcl_sgcls, 0);
164
+ rb_define_module_function(mDCL, "sgfrm", dcl_sgfrm, 0);
165
+ rb_define_module_function(mDCL, "sgpwsn", dcl_sgpwsn, 0);
166
+ rb_define_module_function(mDCL, "sgiset", dcl_sgiset, 2);
167
+ rb_define_module_function(mDCL, "sglset", dcl_sglset, 2);
168
+ rb_define_module_function(mDCL, "sgrset", dcl_sgrset, 2);
169
+ rb_define_module_function(mDCL, "sgqwnd", dcl_sgqwnd, 0);
170
+ rb_define_module_function(mDCL, "sgswnd", dcl_sgswnd, 4);
171
+ rb_define_module_function(mDCL, "sgsvpt", dcl_sgsvpt, 4);
172
+ rb_define_module_function(mDCL, "sgstrn", dcl_sgstrn, 1);
173
+ rb_define_module_function(mDCL, "sgstrf", dcl_sgstrf, 0);
174
+ rb_define_module_function(mDCL, "sglau", dcl_sglau, 4);
175
+ rb_define_module_function(mDCL, "sglav", dcl_sglav, 4);
176
+ rb_define_module_function(mDCL, "sglazu", dcl_sglazu, 6);
177
+ rb_define_module_function(mDCL, "sgslai", dcl_sgslai, 1);
178
+ rb_define_module_function(mDCL, "sgslat", dcl_sgslat, 1);
179
+ rb_define_module_function(mDCL, "sglnu", dcl_sglnu, 4);
180
+ rb_define_module_function(mDCL, "sglnv", dcl_sglnv, 4);
181
+ rb_define_module_function(mDCL, "sglnzu", dcl_sglnzu, 5);
182
+ rb_define_module_function(mDCL, "sglnzv", dcl_sglnzv, 5);
183
+ rb_define_module_function(mDCL, "sgslni", dcl_sgslni, 1);
184
+ rb_define_module_function(mDCL, "sgplu", dcl_sgplu, 3);
185
+ rb_define_module_function(mDCL, "sgplv", dcl_sgplv, 3);
186
+ rb_define_module_function(mDCL, "sgplzu", dcl_sgplzu, 5);
187
+ rb_define_module_function(mDCL, "sgplzv", dcl_sgplzv, 5);
188
+ rb_define_module_function(mDCL, "sgnplc", dcl_sgnplc, 0);
189
+ rb_define_module_function(mDCL, "sgsplc", dcl_sgsplc, 1);
190
+ rb_define_module_function(mDCL, "sgspli", dcl_sgspli, 1);
191
+ rb_define_module_function(mDCL, "sgspls", dcl_sgspls, 1);
192
+ rb_define_module_function(mDCL, "sgsplt", dcl_sgsplt, 1);
193
+ rb_define_module_function(mDCL, "sgpmu", dcl_sgpmu, 3);
194
+ rb_define_module_function(mDCL, "sgpmv", dcl_sgpmv, 3);
195
+ rb_define_module_function(mDCL, "sgpmzu", dcl_sgpmzu, 6);
196
+ rb_define_module_function(mDCL, "sgpmzv", dcl_sgpmzv, 6);
197
+ rb_define_module_function(mDCL, "sgspmi", dcl_sgspmi, 1);
198
+ rb_define_module_function(mDCL, "sgspmt", dcl_sgspmt, 1);
199
+ rb_define_module_function(mDCL, "sgspms", dcl_sgspms, 1);
200
+ rb_define_module_function(mDCL, "sgtnu", dcl_sgtnu, 3);
201
+ rb_define_module_function(mDCL, "sgtnv", dcl_sgtnv, 3);
202
+ rb_define_module_function(mDCL, "sgtnzu", dcl_sgtnzu, 4);
203
+ rb_define_module_function(mDCL, "sgstnp", dcl_sgstnp, 1);
204
+ rb_define_module_function(mDCL, "sgtxr", dcl_sgtxr, 3);
205
+ rb_define_module_function(mDCL, "sgtxu", dcl_sgtxu, 3);
206
+ rb_define_module_function(mDCL, "sgtxv", dcl_sgtxv, 3);
207
+ rb_define_module_function(mDCL, "sgtxzr", dcl_sgtxzr, 7);
208
+ rb_define_module_function(mDCL, "sgtxzu", dcl_sgtxzu, 7);
209
+ rb_define_module_function(mDCL, "sgtxzv", dcl_sgtxzv, 7);
210
+ rb_define_module_function(mDCL, "sgstxc", dcl_sgstxc, 1);
211
+ rb_define_module_function(mDCL, "sgstxi", dcl_sgstxi, 1);
212
+ rb_define_module_function(mDCL, "sgstxr", dcl_sgstxr, 1);
213
+ rb_define_module_function(mDCL, "sgstxs", dcl_sgstxs, 1);
214
+ rb_define_module_function(mDCL, "sgstxy", dcl_sgstxy, 4);
215
+ rb_define_module_function(mDCL, "sgssim", dcl_sgssim, 3);
216
+ rb_define_module_function(mDCL, "sgsmpl", dcl_sgsmpl, 3);
217
+ rb_define_module_function(mDCL, "sgtrnl", dcl_sgtrnl, 1);
218
+ rb_define_module_function(mDCL, "isgtrc", dcl_isgtrc, 1);
219
+ /* slpack */
220
+ rb_define_module_function(mDCL, "sldiv", dcl_sldiv, 3);
221
+ rb_define_module_function(mDCL, "slmgn", dcl_slmgn, 4);
222
+ rb_define_module_function(mDCL, "slform", dcl_slform, 2);
223
+ rb_define_module_function(mDCL, "slrat", dcl_slrat, 2);
224
+ rb_define_module_function(mDCL, "slsttl", dcl_slsttl, 6);
225
+ rb_define_module_function(mDCL, "slpvpr", dcl_slpvpr, 1);
226
+ rb_define_module_function(mDCL, "slpwwr", dcl_slpwwr, 1);
227
+ /* stpack */
228
+ rb_define_module_function(mDCL, "stftrf", dcl_stftrf, 2);
229
+ /* swpack */
230
+ rb_define_module_function(mDCL, "swistx", dcl_swistx, 2);
231
+ rb_define_module_function(mDCL, "swlstx", dcl_swlstx, 2);
232
+ /* szpack */
233
+ /* kuro for test **
234
+ rb_define_module_function(mDCL, "szl3op", dcl_szl3op, 1);
235
+ rb_define_module_function(mDCL, "szl3cl", dcl_szl3cl, 0);
236
+ rb_define_module_function(mDCL, "szl3zu", dcl_szl3zu, 4);
237
+ rb_define_module_function(mDCL, "szl3zv", dcl_szl3zv, 4);
238
+ rb_define_module_function(mDCL, "szt3op", dcl_szt3op, 2);
239
+ rb_define_module_function(mDCL, "szt3cl", dcl_szt3cl, 0);
240
+ rb_define_module_function(mDCL, "szt3zu", dcl_szt3zu, 3);
241
+ rb_define_module_function(mDCL, "szt3zv", dcl_szt3zv, 3);
242
+ rb_define_module_function(mDCL, "szopl3", dcl_szopl3, 0);
243
+ rb_define_module_function(mDCL, "szcll3", dcl_szcll3, 0);
244
+ rb_define_module_function(mDCL, "szmvl3", dcl_szmvl3, 3);
245
+ rb_define_module_function(mDCL, "szpll3", dcl_szpll3, 3);
246
+ ** kuro for test */
247
+ /*** math2 ***/
248
+ /* fftlib */
249
+ rb_define_module_function(mDCL, "ezffti", dcl_ezffti, 1);
250
+ rb_define_module_function(mDCL, "ezfftf", dcl_ezfftf, 3);
251
+ rb_define_module_function(mDCL, "ezfftb", dcl_ezfftb, 5);
252
+ rb_define_module_function(mDCL, "rffti", dcl_rffti, 1);
253
+ rb_define_module_function(mDCL, "rfftf", dcl_rfftf, 3);
254
+ rb_define_module_function(mDCL, "rfftb", dcl_rfftb, 3);
255
+ /* intrlib */
256
+ rb_define_module_function(mDCL, "vrintr", dcl_vrintr, 3);
257
+ /* rnmlib */
258
+ rb_define_module_function(mDCL, "vrrnm", dcl_vrrnm, 5);
259
+ /* vstlib */
260
+ rb_define_module_function(mDCL, "vs1int", dcl_vs1int, 1);
261
+ rb_define_module_function(mDCL, "vs1din", dcl_vs1din, 4);
262
+ rb_define_module_function(mDCL, "vs1out", dcl_vs1out, 3);
263
+ rb_define_module_function(mDCL, "vs2int", dcl_vs2int, 2);
264
+ rb_define_module_function(mDCL, "vs2din", dcl_vs2din, 6);
265
+ rb_define_module_function(mDCL, "vs2out", dcl_vs2out, 4);
266
+ /*** math1 ***/
267
+ /* blklib */
268
+ rb_define_module_function(mDCL, "iblkgt", dcl_iblkgt, 3);
269
+ rb_define_module_function(mDCL, "iblkge", dcl_iblkge, 3);
270
+ rb_define_module_function(mDCL, "iblklt", dcl_iblklt, 3);
271
+ rb_define_module_function(mDCL, "iblkle", dcl_iblkle, 3);
272
+ /* chrlib */
273
+ rb_define_module_function(mDCL, "cladj", dcl_cladj, 1);
274
+ rb_define_module_function(mDCL, "cradj", dcl_cradj, 1);
275
+ rb_define_module_function(mDCL, "crvrs", dcl_crvrs, 1);
276
+ rb_define_module_function(mDCL, "lenb", dcl_lenb, 1);
277
+ rb_define_module_function(mDCL, "lenc", dcl_lenc, 1);
278
+ rb_define_module_function(mDCL, "leny", dcl_leny, 1);
279
+ rb_define_module_function(mDCL, "lenz", dcl_lenz, 1);
280
+ /* fnclib */
281
+ rb_define_module_function(mDCL, "igus", dcl_igus, 1);
282
+ rb_define_module_function(mDCL, "imod", dcl_imod, 2);
283
+ rb_define_module_function(mDCL, "rd2r", dcl_rd2r, 1);
284
+ rb_define_module_function(mDCL, "rr2d", dcl_rr2d, 1);
285
+ rb_define_module_function(mDCL, "rexp", dcl_rexp, 3);
286
+ rb_define_module_function(mDCL, "rfpi", dcl_rfpi, 0);
287
+ rb_define_module_function(mDCL, "rmod", dcl_rmod, 2);
288
+ /* gnmlib */
289
+ rb_define_module_function(mDCL, "gnlt", dcl_gnlt, 1);
290
+ rb_define_module_function(mDCL, "gnle", dcl_gnle, 1);
291
+ rb_define_module_function(mDCL, "gngt", dcl_gngt, 1);
292
+ rb_define_module_function(mDCL, "gnge", dcl_gnge, 1);
293
+ rb_define_module_function(mDCL, "rgnlt", dcl_rgnlt, 1);
294
+ rb_define_module_function(mDCL, "rgnle", dcl_rgnle, 1);
295
+ rb_define_module_function(mDCL, "rgngt", dcl_rgngt, 1);
296
+ rb_define_module_function(mDCL, "rgnge", dcl_rgnge, 1);
297
+ /* ifalib */
298
+ rb_define_module_function(mDCL, "imax", dcl_imax, 3);
299
+ rb_define_module_function(mDCL, "imin", dcl_imin, 3);
300
+ rb_define_module_function(mDCL, "isum", dcl_isum, 3);
301
+ /* indxlib */
302
+ rb_define_module_function(mDCL, "indxif", dcl_indxif, 4);
303
+ rb_define_module_function(mDCL, "indxil", dcl_indxil, 4);
304
+ rb_define_module_function(mDCL, "nindxi", dcl_nindxi, 4);
305
+ rb_define_module_function(mDCL, "indxrf", dcl_indxrf, 4);
306
+ rb_define_module_function(mDCL, "indxrl", dcl_indxrl, 4);
307
+ rb_define_module_function(mDCL, "nindxr", dcl_nindxr, 4);
308
+ rb_define_module_function(mDCL, "indxcf", dcl_indxcf, 4);
309
+ rb_define_module_function(mDCL, "indxcl", dcl_indxcl, 4);
310
+ rb_define_module_function(mDCL, "nindxc", dcl_nindxc, 4);
311
+ rb_define_module_function(mDCL, "indxmf", dcl_indxmf, 4);
312
+ rb_define_module_function(mDCL, "indxml", dcl_indxml, 4);
313
+ rb_define_module_function(mDCL, "nindxm", dcl_nindxm, 4);
314
+ /* intlib */
315
+ rb_define_module_function(mDCL, "irlt", dcl_irlt, 1);
316
+ rb_define_module_function(mDCL, "irle", dcl_irle, 1);
317
+ rb_define_module_function(mDCL, "irgt", dcl_irgt, 1);
318
+ rb_define_module_function(mDCL, "irge", dcl_irge, 1);
319
+ /* lrllib */
320
+ rb_define_module_function(mDCL, "lreq", dcl_lreq, 2);
321
+ rb_define_module_function(mDCL, "lrne", dcl_lrne, 2);
322
+ rb_define_module_function(mDCL, "lrlt", dcl_lrlt, 2);
323
+ rb_define_module_function(mDCL, "lrle", dcl_lrle, 2);
324
+ rb_define_module_function(mDCL, "lrgt", dcl_lrgt, 2);
325
+ rb_define_module_function(mDCL, "lrge", dcl_lrge, 2);
326
+ rb_define_module_function(mDCL, "lreqa", dcl_lreqa, 3);
327
+ rb_define_module_function(mDCL, "lrnea", dcl_lrnea, 3);
328
+ rb_define_module_function(mDCL, "lrlta", dcl_lrlta, 3);
329
+ rb_define_module_function(mDCL, "lrlea", dcl_lrlea, 3);
330
+ rb_define_module_function(mDCL, "lrgta", dcl_lrgta, 3);
331
+ rb_define_module_function(mDCL, "lrgea", dcl_lrgea, 3);
332
+ /* rfalib */
333
+ rb_define_module_function(mDCL, "rmax", dcl_rmax, 3);
334
+ rb_define_module_function(mDCL, "rmin", dcl_rmin, 3);
335
+ rb_define_module_function(mDCL, "rsum", dcl_rsum, 3);
336
+ rb_define_module_function(mDCL, "rave", dcl_rave, 3);
337
+ rb_define_module_function(mDCL, "rvar", dcl_rvar, 3);
338
+ rb_define_module_function(mDCL, "rstd", dcl_rstd, 3);
339
+ rb_define_module_function(mDCL, "rrms", dcl_rrms, 3);
340
+ rb_define_module_function(mDCL, "ramp", dcl_ramp, 3);
341
+ rb_define_module_function(mDCL, "rmlt0", dcl_rmlt0, 4);
342
+ /* rfblib */
343
+ rb_define_module_function(mDCL, "rprd", dcl_rprd, 5);
344
+ rb_define_module_function(mDCL, "rcov", dcl_rcov, 5);
345
+ rb_define_module_function(mDCL, "rcor", dcl_rcor, 5);
346
+ /* sublib */
347
+ rb_define_module_function(mDCL, "vignn", dcl_vignn, 2);
348
+ rb_define_module_function(mDCL, "vrgnn", dcl_vrgnn, 2);
349
+ /* syslib */
350
+ rb_define_module_function(mDCL, "gliget", dcl_gliget, 1);
351
+ rb_define_module_function(mDCL, "gliset", dcl_gliset, 2);
352
+ rb_define_module_function(mDCL, "glistx", dcl_glistx, 2);
353
+ rb_define_module_function(mDCL, "gllget", dcl_gllget, 1);
354
+ rb_define_module_function(mDCL, "gllset", dcl_gllset, 2);
355
+ rb_define_module_function(mDCL, "gllstx", dcl_gllstx, 2);
356
+ rb_define_module_function(mDCL, "glrget", dcl_glrget, 1);
357
+ rb_define_module_function(mDCL, "glrset", dcl_glrset, 2);
358
+ rb_define_module_function(mDCL, "glrstx", dcl_glrstx, 2);
359
+ rb_define_module_function(mDCL, "msgdmp", dcl_msgdmp, 3);
360
+ /* vialib */
361
+ rb_define_module_function(mDCL, "viset", dcl_viset, 4);
362
+ rb_define_module_function(mDCL, "viinc", dcl_viinc, 5);
363
+ rb_define_module_function(mDCL, "vifct", dcl_vifct, 5);
364
+ rb_define_module_function(mDCL, "vicon", dcl_vicon, 5);
365
+ rb_define_module_function(mDCL, "iadd", dcl_iadd, 4);
366
+ rb_define_module_function(mDCL, "imlt", dcl_imlt, 4);
367
+ rb_define_module_function(mDCL, "iset", dcl_iset, 4);
368
+ /* viblib */
369
+ rb_define_module_function(mDCL, "viadd", dcl_viadd, 6);
370
+ rb_define_module_function(mDCL, "visub", dcl_visub, 6);
371
+ rb_define_module_function(mDCL, "vimlt", dcl_vimlt, 6);
372
+ rb_define_module_function(mDCL, "vidiv", dcl_vidiv, 6);
373
+ /* vralib */
374
+ rb_define_module_function(mDCL, "vrset", dcl_vrset, 4);
375
+ rb_define_module_function(mDCL, "vrinc", dcl_vrinc, 5);
376
+ rb_define_module_function(mDCL, "vrfct", dcl_vrfct, 5);
377
+ rb_define_module_function(mDCL, "vrcon", dcl_vrcon, 5);
378
+ rb_define_module_function(mDCL, "radd", dcl_radd, 4);
379
+ rb_define_module_function(mDCL, "rmlt", dcl_rmlt, 4);
380
+ rb_define_module_function(mDCL, "rset", dcl_rset, 4);
381
+ /* vrblib */
382
+ rb_define_module_function(mDCL, "vradd", dcl_vradd, 6);
383
+ rb_define_module_function(mDCL, "vrsub", dcl_vrsub, 6);
384
+ rb_define_module_function(mDCL, "vrmlt", dcl_vrmlt, 6);
385
+ rb_define_module_function(mDCL, "vrdiv", dcl_vrdiv, 6);
386
+ /*** misc1 ***/
387
+ /* datelib */
388
+ rb_define_module_function(mDCL, "date12", dcl_date12, 1);
389
+ rb_define_module_function(mDCL, "date21", dcl_date21, 2);
390
+ rb_define_module_function(mDCL, "date13", dcl_date13, 1);
391
+ rb_define_module_function(mDCL, "date31", dcl_date31, 3);
392
+ rb_define_module_function(mDCL, "date32", dcl_date32, 3);
393
+ rb_define_module_function(mDCL, "datef1", dcl_datef1, 2);
394
+ rb_define_module_function(mDCL, "dateg1", dcl_dateg1, 2);
395
+ rb_define_module_function(mDCL, "datef2", dcl_datef2, 3);
396
+ rb_define_module_function(mDCL, "dateg2", dcl_dateg2, 4);
397
+ rb_define_module_function(mDCL, "datef3", dcl_datef3, 4);
398
+ rb_define_module_function(mDCL, "dateg3", dcl_dateg3, 6);
399
+ rb_define_module_function(mDCL, "dateq1", dcl_dateq1, 0);
400
+ rb_define_module_function(mDCL, "datec1", dcl_datec1, 2);
401
+ rb_define_module_function(mDCL, "dateq2", dcl_dateq2, 0);
402
+ rb_define_module_function(mDCL, "datec2", dcl_datec2, 3);
403
+ rb_define_module_function(mDCL, "datec3", dcl_datec3, 4);
404
+ rb_define_module_function(mDCL, "cweek", dcl_cweek, 1);
405
+ rb_define_module_function(mDCL, "iweek1", dcl_iweek1, 1);
406
+ rb_define_module_function(mDCL, "iweek2", dcl_iweek2, 2);
407
+ rb_define_module_function(mDCL, "iweek3", dcl_iweek3, 3);
408
+
409
+ }
410
+
@@ -0,0 +1,137 @@
1
+ # pparse.rb
2
+ # $Id: pparse.rb,v 1.1.1.1 2011-02-23 07:21:28 horinout Exp $
3
+
4
+
5
+ require "./prototype"
6
+
7
+ class PrototypeParser
8
+ def parse(&block)
9
+ @cpp.each_line do |line|
10
+ case line
11
+ when /^\s*$/
12
+ next
13
+ when /^#/
14
+ macro(line, &block) # retain as macros
15
+ when /(\S+)\s+FUNCTION\s+(\w+)\s*\(/
16
+ func($1, $2)
17
+ when /SUBROUTINE\s+(\w+)\s*\(/
18
+ subr($1)
19
+ when /^\s*\)\s*$/
20
+ close(&block)
21
+ else
22
+ line.gsub!(/(^\s+)|(\s+$)/, "")
23
+ line.chomp!
24
+ var(line)
25
+ end
26
+ end
27
+ end
28
+
29
+ private
30
+
31
+ def delete_comment(src) # [ruby-list:32030] [ruby-list:32049]
32
+ src.gsub(%r@ ([\'\"])(\\.|.)*?\1
33
+ | (/\*.*?\*/)
34
+ | (//)[^\n]*$
35
+ @mx) {
36
+ if $3
37
+ s = $3.delete("^\n")
38
+ s = ' ' if s.empty?
39
+ s
40
+ elsif $4
41
+ ''
42
+ else
43
+ $&
44
+ end
45
+ }
46
+ end
47
+
48
+ def initialize(file)
49
+ input = if file.is_a? IO
50
+ file
51
+ else
52
+ File::open(file)
53
+ end
54
+
55
+ @cpp = delete_comment(input.read)
56
+ end
57
+
58
+ def func(type, name)
59
+ @type, @name = type, name.downcase
60
+ @var = []
61
+ @rtn = []
62
+
63
+ if (/(\d+)|\*\((.*)\)/ =~ type)
64
+ charlen = ($1||$2).downcase # may be charcter length
65
+ @type = type.scan(/\w+/)[0]
66
+ else
67
+ charlen = nil
68
+ end
69
+ @rtn.push Variable("rtn_val", @type, "o", false, charlen)
70
+
71
+ p [:func, type, name] if $DEBUG
72
+ end
73
+
74
+ def subr(name)
75
+ @type, @name = nil, name.downcase
76
+ @var = []
77
+ @rtn = []
78
+
79
+ p [:subr, name] if $DEBUG
80
+ end
81
+
82
+ def var(decl)
83
+ name, *tmp = decl.split.reverse
84
+ tmp.reverse!
85
+ attr = (tmp[-1] =~ /^[a-z]+$/ ? tmp.pop : "i")
86
+ ary = (tmp[-1] =~ /^\((.*)\)/ ? (tmp.pop; $1.downcase) : false)
87
+ vtype = tmp.pop
88
+ if (/(\d+)|\*\((.*)\)/ =~ vtype)
89
+ charlen = ($1||$2).downcase # may be charcter length
90
+ vtype = vtype.scan(/\w+/)[0]
91
+ else
92
+ charlen = nil
93
+ end
94
+ attr0 = attr.scan(/./).sort.uniq.join
95
+ r = (attr =~ /i/ ? (attr.delete!("i"); true) : false)
96
+ w = (attr =~ /o/ ? (attr.delete!("o"); true) : false)
97
+ t = (attr =~ /t/ ? (attr.delete!("t"); true) : false)
98
+ raise "unexpected decl `#{decl.inspect}'" unless tmp.empty?
99
+ raise "unexpected read/write attr `#{decl.inspect}'" unless attr.empty?
100
+ v = Variable(name.downcase, vtype, attr0, ary, charlen)
101
+ @var.push v
102
+ @rtn.push v if (!@type && w)
103
+
104
+ p decl if $DEBUG
105
+ p v if $DEBUG
106
+
107
+ end
108
+
109
+ def close
110
+ val = Prototype.new(@type, @name, @var, @rtn)
111
+ p val if $DEBUG
112
+ @var = nil
113
+ @rtn = nil
114
+ # puts if $DEBUG
115
+ if block_given?
116
+ yield(val)
117
+ else
118
+ val
119
+ end
120
+ end
121
+
122
+ def macro(line)
123
+ if block_given?
124
+ yield(line)
125
+ else
126
+ line
127
+ end
128
+ end
129
+
130
+ def method_missing(m, *a, &b)
131
+ p [m, a.join(" ")]
132
+ end
133
+
134
+ # Var = Struct.new("Var",
135
+ # "vtype", "ary?", "attr", "r?", "w?", "t?", "name",
136
+ # "ignore?").freeze
137
+ end