esruby 0.0.0 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (385) hide show
  1. checksums.yaml +4 -4
  2. data/LICENSE +6 -6
  3. data/bin/esruby +9 -0
  4. data/lib/esruby.rb +8 -0
  5. data/resources/mruby/build_config.rb +0 -1
  6. data/resources/mruby/mrbgems/mruby-print/mrblib/print.rb +1 -1
  7. data/resources/project_template/app/app.rb +2 -0
  8. data/resources/project_template/config.rb +35 -0
  9. data/resources/project_template/www/index.html +17 -0
  10. metadata +6 -377
  11. data/resources/mruby/bin/mirb +0 -0
  12. data/resources/mruby/bin/mrbc +0 -0
  13. data/resources/mruby/bin/mruby +0 -0
  14. data/resources/mruby/bin/mruby-strip +0 -0
  15. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/README.md +0 -82
  16. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/mrbgem.rake +0 -63
  17. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/mrblib/regexp_pcre.rb +0 -232
  18. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/mrblib/string_pcre.rb +0 -333
  19. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/132html +0 -313
  20. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/AUTHORS +0 -45
  21. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/CMakeLists.txt +0 -959
  22. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/COPYING +0 -5
  23. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/ChangeLog +0 -4981
  24. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/CheckMan +0 -67
  25. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/CleanTxt +0 -113
  26. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/Detrail +0 -35
  27. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/HACKING +0 -473
  28. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/INSTALL +0 -370
  29. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/LICENCE +0 -92
  30. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/Makefile.am +0 -877
  31. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/Makefile.in +0 -2917
  32. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/NEWS +0 -611
  33. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/NON-AUTOTOOLS-BUILD +0 -639
  34. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/NON-UNIX-USE +0 -7
  35. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/PrepareRelease +0 -253
  36. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/README +0 -935
  37. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/RunGrepTest +0 -551
  38. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/RunTest +0 -1015
  39. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/RunTest.bat +0 -616
  40. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/aclocal.m4 +0 -1230
  41. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/autom4te.cache/output.0 +0 -21280
  42. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/autom4te.cache/output.1 +0 -21280
  43. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/autom4te.cache/requests +0 -273
  44. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/autom4te.cache/traces.0 +0 -2421
  45. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/autom4te.cache/traces.1 +0 -1144
  46. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/cmake/COPYING-CMAKE-SCRIPTS +0 -22
  47. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/cmake/FindEditline.cmake +0 -17
  48. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/cmake/FindPackageHandleStandardArgs.cmake +0 -58
  49. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/cmake/FindReadline.cmake +0 -29
  50. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/compile +0 -343
  51. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/config-cmake.h.in +0 -54
  52. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/config.guess +0 -1552
  53. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/config.h +0 -392
  54. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/config.h.generic +0 -392
  55. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/config.h.in +0 -343
  56. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/config.sub +0 -1804
  57. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/configure +0 -21280
  58. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/configure.ac +0 -1082
  59. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/depcomp +0 -708
  60. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/dftables.c +0 -212
  61. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/index.html +0 -180
  62. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre-config.html +0 -109
  63. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre.html +0 -204
  64. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre16.html +0 -383
  65. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_assign_jit_stack.html +0 -76
  66. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_compile.html +0 -108
  67. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_compile2.html +0 -112
  68. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_config.html +0 -91
  69. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_copy_named_substring.html +0 -65
  70. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_copy_substring.html +0 -61
  71. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_dfa_exec.html +0 -128
  72. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_exec.html +0 -110
  73. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_free_study.html +0 -46
  74. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_free_substring.html +0 -46
  75. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_free_substring_list.html +0 -46
  76. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_fullinfo.html +0 -108
  77. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_get_named_substring.html +0 -68
  78. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_get_stringnumber.html +0 -57
  79. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_get_stringtable_entries.html +0 -60
  80. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_get_substring.html +0 -64
  81. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_get_substring_list.html +0 -61
  82. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_jit_exec.html +0 -108
  83. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_jit_stack_alloc.html +0 -55
  84. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_jit_stack_free.html +0 -48
  85. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_maketables.html +0 -48
  86. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_pattern_to_host_byte_order.html +0 -58
  87. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_refcount.html +0 -51
  88. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_study.html +0 -68
  89. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_utf16_to_host_byte_order.html +0 -57
  90. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcre_version.html +0 -46
  91. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcreapi.html +0 -2786
  92. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcrebuild.html +0 -517
  93. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcrecallout.html +0 -243
  94. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcrecompat.html +0 -216
  95. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcrecpp.html +0 -368
  96. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcredemo.html +0 -426
  97. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcregrep.html +0 -757
  98. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcrejit.html +0 -458
  99. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcrelimits.html +0 -86
  100. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcrematching.html +0 -233
  101. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcrepartial.html +0 -474
  102. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcrepattern.html +0 -2953
  103. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcreperform.html +0 -195
  104. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcreposix.html +0 -292
  105. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcreprecompile.html +0 -158
  106. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcresample.html +0 -110
  107. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcrestack.html +0 -225
  108. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcresyntax.html +0 -521
  109. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcretest.html +0 -1082
  110. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/html/pcreunicode.html +0 -270
  111. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/index.html.src +0 -180
  112. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre-config.1 +0 -92
  113. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre-config.txt +0 -86
  114. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre.3 +0 -202
  115. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre.txt +0 -9909
  116. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre16.3 +0 -390
  117. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre32.3 +0 -389
  118. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_assign_jit_stack.3 +0 -61
  119. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_compile.3 +0 -98
  120. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_compile2.3 +0 -106
  121. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_config.3 +0 -76
  122. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_copy_named_substring.3 +0 -59
  123. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_copy_substring.3 +0 -52
  124. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_dfa_exec.3 +0 -125
  125. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_exec.3 +0 -103
  126. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_free_study.3 +0 -31
  127. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_free_substring.3 +0 -31
  128. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_free_substring_list.3 +0 -31
  129. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_fullinfo.3 +0 -95
  130. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_get_named_substring.3 +0 -62
  131. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_get_stringnumber.3 +0 -45
  132. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_get_stringtable_entries.3 +0 -48
  133. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_get_substring.3 +0 -55
  134. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_get_substring_list.3 +0 -49
  135. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_jit_exec.3 +0 -104
  136. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_jit_stack_alloc.3 +0 -45
  137. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_jit_stack_free.3 +0 -35
  138. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_maketables.3 +0 -33
  139. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_pattern_to_host_byte_order.3 +0 -46
  140. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_refcount.3 +0 -36
  141. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_study.3 +0 -56
  142. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_utf16_to_host_byte_order.3 +0 -46
  143. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_utf32_to_host_byte_order.3 +0 -46
  144. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcre_version.3 +0 -31
  145. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcreapi.3 +0 -2823
  146. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcrebuild.3 +0 -520
  147. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcrecallout.3 +0 -214
  148. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcrecompat.3 +0 -185
  149. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcrecpp.3 +0 -348
  150. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcregrep.1 +0 -679
  151. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcregrep.txt +0 -740
  152. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcrejit.3 +0 -437
  153. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcrelimits.3 +0 -67
  154. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcrematching.3 +0 -206
  155. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcrepartial.3 +0 -445
  156. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcrepattern.3 +0 -2983
  157. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcreperform.3 +0 -177
  158. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcreposix.3 +0 -270
  159. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcreprecompile.3 +0 -151
  160. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcresample.3 +0 -99
  161. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcrestack.3 +0 -215
  162. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcresyntax.3 +0 -496
  163. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcretest.1 +0 -1079
  164. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcretest.txt +0 -1012
  165. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/pcreunicode.3 +0 -255
  166. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/doc/perltest.txt +0 -42
  167. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/install-sh +0 -527
  168. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/libpcre.pc.in +0 -12
  169. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/libpcre16.pc.in +0 -12
  170. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/libpcre32.pc.in +0 -12
  171. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/libpcrecpp.pc.in +0 -12
  172. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/libpcreposix.pc.in +0 -13
  173. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/ltmain.sh +0 -9636
  174. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/m4/ax_pthread.m4 +0 -309
  175. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/m4/libtool.m4 +0 -7844
  176. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/m4/ltoptions.m4 +0 -369
  177. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/m4/ltsugar.m4 +0 -123
  178. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/m4/ltversion.m4 +0 -23
  179. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/m4/lt~obsolete.m4 +0 -98
  180. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/m4/pcre_visibility.m4 +0 -89
  181. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/makevp.bat +0 -66
  182. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/makevp_c.txt +0 -20
  183. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/makevp_l.txt +0 -20
  184. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/missing +0 -331
  185. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre-config.in +0 -133
  186. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre.h +0 -653
  187. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre.h.generic +0 -653
  188. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre.h.in +0 -653
  189. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre16_byte_order.c +0 -45
  190. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre16_chartables.c +0 -45
  191. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre16_compile.c +0 -45
  192. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre16_config.c +0 -45
  193. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre16_dfa_exec.c +0 -45
  194. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre16_exec.c +0 -45
  195. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre16_fullinfo.c +0 -45
  196. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre16_get.c +0 -45
  197. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre16_globals.c +0 -45
  198. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre16_jit_compile.c +0 -45
  199. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre16_maketables.c +0 -45
  200. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre16_newline.c +0 -45
  201. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre16_ord2utf16.c +0 -90
  202. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre16_printint.c +0 -45
  203. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre16_refcount.c +0 -45
  204. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre16_string_utils.c +0 -45
  205. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre16_study.c +0 -45
  206. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre16_tables.c +0 -45
  207. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre16_ucd.c +0 -45
  208. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre16_utf16_utils.c +0 -130
  209. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre16_valid_utf16.c +0 -156
  210. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre16_version.c +0 -45
  211. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre16_xclass.c +0 -45
  212. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre32_byte_order.c +0 -45
  213. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre32_chartables.c +0 -45
  214. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre32_compile.c +0 -45
  215. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre32_config.c +0 -45
  216. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre32_dfa_exec.c +0 -45
  217. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre32_exec.c +0 -45
  218. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre32_fullinfo.c +0 -45
  219. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre32_get.c +0 -45
  220. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre32_globals.c +0 -45
  221. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre32_jit_compile.c +0 -45
  222. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre32_maketables.c +0 -45
  223. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre32_newline.c +0 -45
  224. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre32_ord2utf32.c +0 -82
  225. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre32_printint.c +0 -45
  226. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre32_refcount.c +0 -45
  227. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre32_string_utils.c +0 -45
  228. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre32_study.c +0 -45
  229. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre32_tables.c +0 -45
  230. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre32_ucd.c +0 -45
  231. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre32_utf32_utils.c +0 -141
  232. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre32_valid_utf32.c +0 -131
  233. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre32_version.c +0 -45
  234. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre32_xclass.c +0 -45
  235. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_byte_order.c +0 -318
  236. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_chartables.c +0 -198
  237. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_chartables.c.dist +0 -198
  238. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_compile.c +0 -8386
  239. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_config.c +0 -186
  240. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_dfa_exec.c +0 -3582
  241. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_exec.c +0 -7049
  242. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_fullinfo.c +0 -231
  243. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_get.c +0 -662
  244. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_globals.c +0 -84
  245. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_internal.h +0 -2744
  246. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_jit_compile.c +0 -8560
  247. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_jit_test.c +0 -1614
  248. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_maketables.c +0 -151
  249. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_newline.c +0 -210
  250. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_ord2utf8.c +0 -94
  251. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_printint.c +0 -766
  252. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_refcount.c +0 -92
  253. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_scanner.cc +0 -199
  254. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_scanner.h +0 -172
  255. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_scanner_unittest.cc +0 -159
  256. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_string_utils.c +0 -211
  257. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_stringpiece.cc +0 -43
  258. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_stringpiece.h.in +0 -179
  259. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_stringpiece_unittest.cc +0 -150
  260. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_study.c +0 -1562
  261. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_tables.c +0 -655
  262. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_ucd.c +0 -3298
  263. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_valid_utf8.c +0 -312
  264. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_version.c +0 -98
  265. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcre_xclass.c +0 -198
  266. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcrecpp.cc +0 -922
  267. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcrecpp.h +0 -710
  268. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcrecpp_internal.h +0 -71
  269. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcrecpp_unittest.cc +0 -1291
  270. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcrecpparg.h.in +0 -174
  271. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcredemo.c +0 -406
  272. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcregexp.pas +0 -845
  273. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcregrep.c +0 -3180
  274. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcreposix.c +0 -419
  275. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcreposix.h +0 -146
  276. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/pcretest.c +0 -5488
  277. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/perltest.pl +0 -237
  278. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/sljit/sljitConfig.h +0 -110
  279. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/sljit/sljitConfigInternal.h +0 -484
  280. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/sljit/sljitExecAllocator.c +0 -289
  281. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/sljit/sljitLir.c +0 -1766
  282. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/sljit/sljitLir.h +0 -985
  283. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/sljit/sljitNativeARM_Thumb2.c +0 -2008
  284. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/sljit/sljitNativeARM_v5.c +0 -2515
  285. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/sljit/sljitNativeMIPS_32.c +0 -404
  286. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/sljit/sljitNativeMIPS_common.c +0 -1881
  287. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/sljit/sljitNativePPC_32.c +0 -269
  288. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/sljit/sljitNativePPC_64.c +0 -421
  289. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/sljit/sljitNativePPC_common.c +0 -2014
  290. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/sljit/sljitNativeSPARC_32.c +0 -164
  291. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/sljit/sljitNativeSPARC_common.c +0 -1348
  292. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/sljit/sljitNativeX86_32.c +0 -547
  293. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/sljit/sljitNativeX86_64.c +0 -810
  294. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/sljit/sljitNativeX86_common.c +0 -2836
  295. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/sljit/sljitUtils.c +0 -332
  296. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/grepbinary +0 -0
  297. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/grepfilelist +0 -3
  298. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/grepinput +0 -611
  299. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/grepinput3 +0 -15
  300. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/grepinput8 +0 -11
  301. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/grepinputv +0 -4
  302. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/grepinputx +0 -43
  303. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/greplist +0 -7
  304. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/grepoutput +0 -707
  305. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/grepoutput8 +0 -12
  306. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/grepoutputN +0 -17
  307. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/greppatN4 +0 -2
  308. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/saved16 +0 -0
  309. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/saved16BE-1 +0 -0
  310. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/saved16BE-2 +0 -0
  311. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/saved16LE-1 +0 -0
  312. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/saved16LE-2 +0 -0
  313. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/saved32 +0 -0
  314. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/saved32BE-1 +0 -0
  315. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/saved32BE-2 +0 -0
  316. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/saved32LE-1 +0 -0
  317. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/saved32LE-2 +0 -0
  318. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/saved8 +0 -0
  319. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput1 +0 -5306
  320. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput10 +0 -1337
  321. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput11 +0 -135
  322. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput12 +0 -89
  323. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput13 +0 -9
  324. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput14 +0 -329
  325. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput15 +0 -430
  326. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput16 +0 -35
  327. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput17 +0 -296
  328. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput18 +0 -296
  329. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput19 +0 -22
  330. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput2 +0 -3813
  331. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput20 +0 -19
  332. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput21 +0 -16
  333. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput22 +0 -13
  334. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput23 +0 -16
  335. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput24 +0 -77
  336. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput25 +0 -32
  337. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput26 +0 -80
  338. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput3 +0 -95
  339. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput4 +0 -624
  340. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput5 +0 -772
  341. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput6 +0 -1319
  342. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput7 +0 -672
  343. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput8 +0 -4801
  344. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinput9 +0 -717
  345. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testinputEBC +0 -121
  346. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput1 +0 -8798
  347. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput10 +0 -2726
  348. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput11-16 +0 -713
  349. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput11-32 +0 -713
  350. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput11-8 +0 -713
  351. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput12 +0 -181
  352. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput13 +0 -21
  353. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput14 +0 -476
  354. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput15 +0 -1269
  355. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput16 +0 -121
  356. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput17 +0 -505
  357. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput18-16 +0 -1022
  358. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput18-32 +0 -1019
  359. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput19 +0 -88
  360. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput2 +0 -12484
  361. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput20 +0 -27
  362. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput21-16 +0 -90
  363. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput21-32 +0 -90
  364. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput22-16 +0 -71
  365. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput22-32 +0 -71
  366. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput23 +0 -42
  367. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput24 +0 -145
  368. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput25 +0 -79
  369. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput26 +0 -148
  370. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput3 +0 -169
  371. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput4 +0 -1094
  372. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput5 +0 -1849
  373. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput6 +0 -2137
  374. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput7 +0 -1473
  375. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput8 +0 -8019
  376. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutput9 +0 -1371
  377. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/testoutputEBC +0 -182
  378. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/wintestinput3 +0 -91
  379. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/testdata/wintestoutput3 +0 -166
  380. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/pcre/ucp.h +0 -197
  381. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/run_test.rb +0 -23
  382. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/src/mruby_regexp_pcre.c +0 -364
  383. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/test/matchdata.rb +0 -94
  384. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/test/regexp.rb +0 -264
  385. data/resources/mruby/build/mrbgems/mruby-regexp-pcre/test/string.rb +0 -201
@@ -1,368 +0,0 @@
1
- <html>
2
- <head>
3
- <title>pcrecpp specification</title>
4
- </head>
5
- <body bgcolor="#FFFFFF" text="#00005A" link="#0066FF" alink="#3399FF" vlink="#2222BB">
6
- <h1>pcrecpp man page</h1>
7
- <p>
8
- Return to the <a href="index.html">PCRE index page</a>.
9
- </p>
10
- <p>
11
- This page is part of the PCRE HTML documentation. It was generated automatically
12
- from the original man page. If there is any nonsense in it, please consult the
13
- man page, in case the conversion went wrong.
14
- <br>
15
- <ul>
16
- <li><a name="TOC1" href="#SEC1">SYNOPSIS OF C++ WRAPPER</a>
17
- <li><a name="TOC2" href="#SEC2">DESCRIPTION</a>
18
- <li><a name="TOC3" href="#SEC3">MATCHING INTERFACE</a>
19
- <li><a name="TOC4" href="#SEC4">QUOTING METACHARACTERS</a>
20
- <li><a name="TOC5" href="#SEC5">PARTIAL MATCHES</a>
21
- <li><a name="TOC6" href="#SEC6">UTF-8 AND THE MATCHING INTERFACE</a>
22
- <li><a name="TOC7" href="#SEC7">PASSING MODIFIERS TO THE REGULAR EXPRESSION ENGINE</a>
23
- <li><a name="TOC8" href="#SEC8">SCANNING TEXT INCREMENTALLY</a>
24
- <li><a name="TOC9" href="#SEC9">PARSING HEX/OCTAL/C-RADIX NUMBERS</a>
25
- <li><a name="TOC10" href="#SEC10">REPLACING PARTS OF STRINGS</a>
26
- <li><a name="TOC11" href="#SEC11">AUTHOR</a>
27
- <li><a name="TOC12" href="#SEC12">REVISION</a>
28
- </ul>
29
- <br><a name="SEC1" href="#TOC1">SYNOPSIS OF C++ WRAPPER</a><br>
30
- <P>
31
- <b>#include &#60;pcrecpp.h&#62;</b>
32
- </P>
33
- <br><a name="SEC2" href="#TOC1">DESCRIPTION</a><br>
34
- <P>
35
- The C++ wrapper for PCRE was provided by Google Inc. Some additional
36
- functionality was added by Giuseppe Maxia. This brief man page was constructed
37
- from the notes in the <i>pcrecpp.h</i> file, which should be consulted for
38
- further details. Note that the C++ wrapper supports only the original 8-bit
39
- PCRE library. There is no 16-bit or 32-bit support at present.
40
- </P>
41
- <br><a name="SEC3" href="#TOC1">MATCHING INTERFACE</a><br>
42
- <P>
43
- The "FullMatch" operation checks that supplied text matches a supplied pattern
44
- exactly. If pointer arguments are supplied, it copies matched sub-strings that
45
- match sub-patterns into them.
46
- <pre>
47
- Example: successful match
48
- pcrecpp::RE re("h.*o");
49
- re.FullMatch("hello");
50
-
51
- Example: unsuccessful match (requires full match):
52
- pcrecpp::RE re("e");
53
- !re.FullMatch("hello");
54
-
55
- Example: creating a temporary RE object:
56
- pcrecpp::RE("h.*o").FullMatch("hello");
57
- </pre>
58
- You can pass in a "const char*" or a "string" for "text". The examples below
59
- tend to use a const char*. You can, as in the different examples above, store
60
- the RE object explicitly in a variable or use a temporary RE object. The
61
- examples below use one mode or the other arbitrarily. Either could correctly be
62
- used for any of these examples.
63
- </P>
64
- <P>
65
- You must supply extra pointer arguments to extract matched subpieces.
66
- <pre>
67
- Example: extracts "ruby" into "s" and 1234 into "i"
68
- int i;
69
- string s;
70
- pcrecpp::RE re("(\\w+):(\\d+)");
71
- re.FullMatch("ruby:1234", &s, &i);
72
-
73
- Example: does not try to extract any extra sub-patterns
74
- re.FullMatch("ruby:1234", &s);
75
-
76
- Example: does not try to extract into NULL
77
- re.FullMatch("ruby:1234", NULL, &i);
78
-
79
- Example: integer overflow causes failure
80
- !re.FullMatch("ruby:1234567891234", NULL, &i);
81
-
82
- Example: fails because there aren't enough sub-patterns:
83
- !pcrecpp::RE("\\w+:\\d+").FullMatch("ruby:1234", &s);
84
-
85
- Example: fails because string cannot be stored in integer
86
- !pcrecpp::RE("(.*)").FullMatch("ruby", &i);
87
- </pre>
88
- The provided pointer arguments can be pointers to any scalar numeric
89
- type, or one of:
90
- <pre>
91
- string (matched piece is copied to string)
92
- StringPiece (StringPiece is mutated to point to matched piece)
93
- T (where "bool T::ParseFrom(const char*, int)" exists)
94
- NULL (the corresponding matched sub-pattern is not copied)
95
- </pre>
96
- The function returns true iff all of the following conditions are satisfied:
97
- <pre>
98
- a. "text" matches "pattern" exactly;
99
-
100
- b. The number of matched sub-patterns is &#62;= number of supplied
101
- pointers;
102
-
103
- c. The "i"th argument has a suitable type for holding the
104
- string captured as the "i"th sub-pattern. If you pass in
105
- void * NULL for the "i"th argument, or a non-void * NULL
106
- of the correct type, or pass fewer arguments than the
107
- number of sub-patterns, "i"th captured sub-pattern is
108
- ignored.
109
- </pre>
110
- CAVEAT: An optional sub-pattern that does not exist in the matched
111
- string is assigned the empty string. Therefore, the following will
112
- return false (because the empty string is not a valid number):
113
- <pre>
114
- int number;
115
- pcrecpp::RE::FullMatch("abc", "[a-z]+(\\d+)?", &number);
116
- </pre>
117
- The matching interface supports at most 16 arguments per call.
118
- If you need more, consider using the more general interface
119
- <b>pcrecpp::RE::DoMatch</b>. See <b>pcrecpp.h</b> for the signature for
120
- <b>DoMatch</b>.
121
- </P>
122
- <P>
123
- NOTE: Do not use <b>no_arg</b>, which is used internally to mark the end of a
124
- list of optional arguments, as a placeholder for missing arguments, as this can
125
- lead to segfaults.
126
- </P>
127
- <br><a name="SEC4" href="#TOC1">QUOTING METACHARACTERS</a><br>
128
- <P>
129
- You can use the "QuoteMeta" operation to insert backslashes before all
130
- potentially meaningful characters in a string. The returned string, used as a
131
- regular expression, will exactly match the original string.
132
- <pre>
133
- Example:
134
- string quoted = RE::QuoteMeta(unquoted);
135
- </pre>
136
- Note that it's legal to escape a character even if it has no special meaning in
137
- a regular expression -- so this function does that. (This also makes it
138
- identical to the perl function of the same name; see "perldoc -f quotemeta".)
139
- For example, "1.5-2.0?" becomes "1\.5\-2\.0\?".
140
- </P>
141
- <br><a name="SEC5" href="#TOC1">PARTIAL MATCHES</a><br>
142
- <P>
143
- You can use the "PartialMatch" operation when you want the pattern
144
- to match any substring of the text.
145
- <pre>
146
- Example: simple search for a string:
147
- pcrecpp::RE("ell").PartialMatch("hello");
148
-
149
- Example: find first number in a string:
150
- int number;
151
- pcrecpp::RE re("(\\d+)");
152
- re.PartialMatch("x*100 + 20", &number);
153
- assert(number == 100);
154
- </PRE>
155
- </P>
156
- <br><a name="SEC6" href="#TOC1">UTF-8 AND THE MATCHING INTERFACE</a><br>
157
- <P>
158
- By default, pattern and text are plain text, one byte per character. The UTF8
159
- flag, passed to the constructor, causes both pattern and string to be treated
160
- as UTF-8 text, still a byte stream but potentially multiple bytes per
161
- character. In practice, the text is likelier to be UTF-8 than the pattern, but
162
- the match returned may depend on the UTF8 flag, so always use it when matching
163
- UTF8 text. For example, "." will match one byte normally but with UTF8 set may
164
- match up to three bytes of a multi-byte character.
165
- <pre>
166
- Example:
167
- pcrecpp::RE_Options options;
168
- options.set_utf8();
169
- pcrecpp::RE re(utf8_pattern, options);
170
- re.FullMatch(utf8_string);
171
-
172
- Example: using the convenience function UTF8():
173
- pcrecpp::RE re(utf8_pattern, pcrecpp::UTF8());
174
- re.FullMatch(utf8_string);
175
- </pre>
176
- NOTE: The UTF8 flag is ignored if pcre was not configured with the
177
- <pre>
178
- --enable-utf8 flag.
179
- </PRE>
180
- </P>
181
- <br><a name="SEC7" href="#TOC1">PASSING MODIFIERS TO THE REGULAR EXPRESSION ENGINE</a><br>
182
- <P>
183
- PCRE defines some modifiers to change the behavior of the regular expression
184
- engine. The C++ wrapper defines an auxiliary class, RE_Options, as a vehicle to
185
- pass such modifiers to a RE class. Currently, the following modifiers are
186
- supported:
187
- <pre>
188
- modifier description Perl corresponding
189
-
190
- PCRE_CASELESS case insensitive match /i
191
- PCRE_MULTILINE multiple lines match /m
192
- PCRE_DOTALL dot matches newlines /s
193
- PCRE_DOLLAR_ENDONLY $ matches only at end N/A
194
- PCRE_EXTRA strict escape parsing N/A
195
- PCRE_EXTENDED ignore white spaces /x
196
- PCRE_UTF8 handles UTF8 chars built-in
197
- PCRE_UNGREEDY reverses * and *? N/A
198
- PCRE_NO_AUTO_CAPTURE disables capturing parens N/A (*)
199
- </pre>
200
- (*) Both Perl and PCRE allow non capturing parentheses by means of the
201
- "?:" modifier within the pattern itself. e.g. (?:ab|cd) does not
202
- capture, while (ab|cd) does.
203
- </P>
204
- <P>
205
- For a full account on how each modifier works, please check the
206
- PCRE API reference page.
207
- </P>
208
- <P>
209
- For each modifier, there are two member functions whose name is made
210
- out of the modifier in lowercase, without the "PCRE_" prefix. For
211
- instance, PCRE_CASELESS is handled by
212
- <pre>
213
- bool caseless()
214
- </pre>
215
- which returns true if the modifier is set, and
216
- <pre>
217
- RE_Options & set_caseless(bool)
218
- </pre>
219
- which sets or unsets the modifier. Moreover, PCRE_EXTRA_MATCH_LIMIT can be
220
- accessed through the <b>set_match_limit()</b> and <b>match_limit()</b> member
221
- functions. Setting <i>match_limit</i> to a non-zero value will limit the
222
- execution of pcre to keep it from doing bad things like blowing the stack or
223
- taking an eternity to return a result. A value of 5000 is good enough to stop
224
- stack blowup in a 2MB thread stack. Setting <i>match_limit</i> to zero disables
225
- match limiting. Alternatively, you can call <b>match_limit_recursion()</b>
226
- which uses PCRE_EXTRA_MATCH_LIMIT_RECURSION to limit how much PCRE
227
- recurses. <b>match_limit()</b> limits the number of matches PCRE does;
228
- <b>match_limit_recursion()</b> limits the depth of internal recursion, and
229
- therefore the amount of stack that is used.
230
- </P>
231
- <P>
232
- Normally, to pass one or more modifiers to a RE class, you declare
233
- a <i>RE_Options</i> object, set the appropriate options, and pass this
234
- object to a RE constructor. Example:
235
- <pre>
236
- RE_Options opt;
237
- opt.set_caseless(true);
238
- if (RE("HELLO", opt).PartialMatch("hello world")) ...
239
- </pre>
240
- RE_options has two constructors. The default constructor takes no arguments and
241
- creates a set of flags that are off by default. The optional parameter
242
- <i>option_flags</i> is to facilitate transfer of legacy code from C programs.
243
- This lets you do
244
- <pre>
245
- RE(pattern,
246
- RE_Options(PCRE_CASELESS|PCRE_MULTILINE)).PartialMatch(str);
247
- </pre>
248
- However, new code is better off doing
249
- <pre>
250
- RE(pattern,
251
- RE_Options().set_caseless(true).set_multiline(true))
252
- .PartialMatch(str);
253
- </pre>
254
- If you are going to pass one of the most used modifiers, there are some
255
- convenience functions that return a RE_Options class with the
256
- appropriate modifier already set: <b>CASELESS()</b>, <b>UTF8()</b>,
257
- <b>MULTILINE()</b>, <b>DOTALL</b>(), and <b>EXTENDED()</b>.
258
- </P>
259
- <P>
260
- If you need to set several options at once, and you don't want to go through
261
- the pains of declaring a RE_Options object and setting several options, there
262
- is a parallel method that give you such ability on the fly. You can concatenate
263
- several <b>set_xxxxx()</b> member functions, since each of them returns a
264
- reference to its class object. For example, to pass PCRE_CASELESS,
265
- PCRE_EXTENDED, and PCRE_MULTILINE to a RE with one statement, you may write:
266
- <pre>
267
- RE(" ^ xyz \\s+ .* blah$",
268
- RE_Options()
269
- .set_caseless(true)
270
- .set_extended(true)
271
- .set_multiline(true)).PartialMatch(sometext);
272
-
273
- </PRE>
274
- </P>
275
- <br><a name="SEC8" href="#TOC1">SCANNING TEXT INCREMENTALLY</a><br>
276
- <P>
277
- The "Consume" operation may be useful if you want to repeatedly
278
- match regular expressions at the front of a string and skip over
279
- them as they match. This requires use of the "StringPiece" type,
280
- which represents a sub-range of a real string. Like RE, StringPiece
281
- is defined in the pcrecpp namespace.
282
- <pre>
283
- Example: read lines of the form "var = value" from a string.
284
- string contents = ...; // Fill string somehow
285
- pcrecpp::StringPiece input(contents); // Wrap in a StringPiece
286
-
287
- string var;
288
- int value;
289
- pcrecpp::RE re("(\\w+) = (\\d+)\n");
290
- while (re.Consume(&input, &var, &value)) {
291
- ...;
292
- }
293
- </pre>
294
- Each successful call to "Consume" will set "var/value", and also
295
- advance "input" so it points past the matched text.
296
- </P>
297
- <P>
298
- The "FindAndConsume" operation is similar to "Consume" but does not
299
- anchor your match at the beginning of the string. For example, you
300
- could extract all words from a string by repeatedly calling
301
- <pre>
302
- pcrecpp::RE("(\\w+)").FindAndConsume(&input, &word)
303
- </PRE>
304
- </P>
305
- <br><a name="SEC9" href="#TOC1">PARSING HEX/OCTAL/C-RADIX NUMBERS</a><br>
306
- <P>
307
- By default, if you pass a pointer to a numeric value, the
308
- corresponding text is interpreted as a base-10 number. You can
309
- instead wrap the pointer with a call to one of the operators Hex(),
310
- Octal(), or CRadix() to interpret the text in another base. The
311
- CRadix operator interprets C-style "0" (base-8) and "0x" (base-16)
312
- prefixes, but defaults to base-10.
313
- <pre>
314
- Example:
315
- int a, b, c, d;
316
- pcrecpp::RE re("(.*) (.*) (.*) (.*)");
317
- re.FullMatch("100 40 0100 0x40",
318
- pcrecpp::Octal(&a), pcrecpp::Hex(&b),
319
- pcrecpp::CRadix(&c), pcrecpp::CRadix(&d));
320
- </pre>
321
- will leave 64 in a, b, c, and d.
322
- </P>
323
- <br><a name="SEC10" href="#TOC1">REPLACING PARTS OF STRINGS</a><br>
324
- <P>
325
- You can replace the first match of "pattern" in "str" with "rewrite".
326
- Within "rewrite", backslash-escaped digits (\1 to \9) can be
327
- used to insert text matching corresponding parenthesized group
328
- from the pattern. \0 in "rewrite" refers to the entire matching
329
- text. For example:
330
- <pre>
331
- string s = "yabba dabba doo";
332
- pcrecpp::RE("b+").Replace("d", &s);
333
- </pre>
334
- will leave "s" containing "yada dabba doo". The result is true if the pattern
335
- matches and a replacement occurs, false otherwise.
336
- </P>
337
- <P>
338
- <b>GlobalReplace</b> is like <b>Replace</b> except that it replaces all
339
- occurrences of the pattern in the string with the rewrite. Replacements are
340
- not subject to re-matching. For example:
341
- <pre>
342
- string s = "yabba dabba doo";
343
- pcrecpp::RE("b+").GlobalReplace("d", &s);
344
- </pre>
345
- will leave "s" containing "yada dada doo". It returns the number of
346
- replacements made.
347
- </P>
348
- <P>
349
- <b>Extract</b> is like <b>Replace</b>, except that if the pattern matches,
350
- "rewrite" is copied into "out" (an additional argument) with substitutions.
351
- The non-matching portions of "text" are ignored. Returns true iff a match
352
- occurred and the extraction happened successfully; if no match occurs, the
353
- string is left unaffected.
354
- </P>
355
- <br><a name="SEC11" href="#TOC1">AUTHOR</a><br>
356
- <P>
357
- The C++ wrapper was contributed by Google Inc.
358
- <br>
359
- Copyright &copy; 2007 Google Inc.
360
- <br>
361
- </P>
362
- <br><a name="SEC12" href="#TOC1">REVISION</a><br>
363
- <P>
364
- Last updated: 08 January 2012
365
- <br>
366
- <p>
367
- Return to the <a href="index.html">PCRE index page</a>.
368
- </p>
@@ -1,426 +0,0 @@
1
- <html>
2
- <head>
3
- <title>pcredemo specification</title>
4
- </head>
5
- <body bgcolor="#FFFFFF" text="#00005A" link="#0066FF" alink="#3399FF" vlink="#2222BB">
6
- <h1>pcredemo man page</h1>
7
- <p>
8
- Return to the <a href="index.html">PCRE index page</a>.
9
- </p>
10
- <p>
11
- This page is part of the PCRE HTML documentation. It was generated automatically
12
- from the original man page. If there is any nonsense in it, please consult the
13
- man page, in case the conversion went wrong.
14
- <br>
15
- <ul>
16
- </ul>
17
- <PRE>
18
- /*************************************************
19
- * PCRE DEMONSTRATION PROGRAM *
20
- *************************************************/
21
-
22
- /* This is a demonstration program to illustrate the most straightforward ways
23
- of calling the PCRE regular expression library from a C program. See the
24
- pcresample documentation for a short discussion ("man pcresample" if you have
25
- the PCRE man pages installed).
26
-
27
- In Unix-like environments, if PCRE is installed in your standard system
28
- libraries, you should be able to compile this program using this command:
29
-
30
- gcc -Wall pcredemo.c -lpcre -o pcredemo
31
-
32
- If PCRE is not installed in a standard place, it is likely to be installed with
33
- support for the pkg-config mechanism. If you have pkg-config, you can compile
34
- this program using this command:
35
-
36
- gcc -Wall pcredemo.c `pkg-config --cflags --libs libpcre` -o pcredemo
37
-
38
- If you do not have pkg-config, you may have to use this:
39
-
40
- gcc -Wall pcredemo.c -I/usr/local/include -L/usr/local/lib \
41
- -R/usr/local/lib -lpcre -o pcredemo
42
-
43
- Replace "/usr/local/include" and "/usr/local/lib" with wherever the include and
44
- library files for PCRE are installed on your system. Only some operating
45
- systems (e.g. Solaris) use the -R option.
46
-
47
- Building under Windows:
48
-
49
- If you want to statically link this program against a non-dll .a file, you must
50
- define PCRE_STATIC before including pcre.h, otherwise the pcre_malloc() and
51
- pcre_free() exported functions will be declared __declspec(dllimport), with
52
- unwanted results. So in this environment, uncomment the following line. */
53
-
54
- /* #define PCRE_STATIC */
55
-
56
- #include &lt;stdio.h&gt;
57
- #include &lt;string.h&gt;
58
- #include &lt;pcre.h&gt;
59
-
60
- #define OVECCOUNT 30 /* should be a multiple of 3 */
61
-
62
-
63
- int main(int argc, char **argv)
64
- {
65
- pcre *re;
66
- const char *error;
67
- char *pattern;
68
- char *subject;
69
- unsigned char *name_table;
70
- unsigned int option_bits;
71
- int erroffset;
72
- int find_all;
73
- int crlf_is_newline;
74
- int namecount;
75
- int name_entry_size;
76
- int ovector[OVECCOUNT];
77
- int subject_length;
78
- int rc, i;
79
- int utf8;
80
-
81
-
82
- /**************************************************************************
83
- * First, sort out the command line. There is only one possible option at *
84
- * the moment, "-g" to request repeated matching to find all occurrences, *
85
- * like Perl's /g option. We set the variable find_all to a non-zero value *
86
- * if the -g option is present. Apart from that, there must be exactly two *
87
- * arguments. *
88
- **************************************************************************/
89
-
90
- find_all = 0;
91
- for (i = 1; i &lt; argc; i++)
92
- {
93
- if (strcmp(argv[i], "-g") == 0) find_all = 1;
94
- else break;
95
- }
96
-
97
- /* After the options, we require exactly two arguments, which are the pattern,
98
- and the subject string. */
99
-
100
- if (argc - i != 2)
101
- {
102
- printf("Two arguments required: a regex and a subject string\n");
103
- return 1;
104
- }
105
-
106
- pattern = argv[i];
107
- subject = argv[i+1];
108
- subject_length = (int)strlen(subject);
109
-
110
-
111
- /*************************************************************************
112
- * Now we are going to compile the regular expression pattern, and handle *
113
- * and errors that are detected. *
114
- *************************************************************************/
115
-
116
- re = pcre_compile(
117
- pattern, /* the pattern */
118
- 0, /* default options */
119
- &amp;error, /* for error message */
120
- &amp;erroffset, /* for error offset */
121
- NULL); /* use default character tables */
122
-
123
- /* Compilation failed: print the error message and exit */
124
-
125
- if (re == NULL)
126
- {
127
- printf("PCRE compilation failed at offset %d: %s\n", erroffset, error);
128
- return 1;
129
- }
130
-
131
-
132
- /*************************************************************************
133
- * If the compilation succeeded, we call PCRE again, in order to do a *
134
- * pattern match against the subject string. This does just ONE match. If *
135
- * further matching is needed, it will be done below. *
136
- *************************************************************************/
137
-
138
- rc = pcre_exec(
139
- re, /* the compiled pattern */
140
- NULL, /* no extra data - we didn't study the pattern */
141
- subject, /* the subject string */
142
- subject_length, /* the length of the subject */
143
- 0, /* start at offset 0 in the subject */
144
- 0, /* default options */
145
- ovector, /* output vector for substring information */
146
- OVECCOUNT); /* number of elements in the output vector */
147
-
148
- /* Matching failed: handle error cases */
149
-
150
- if (rc &lt; 0)
151
- {
152
- switch(rc)
153
- {
154
- case PCRE_ERROR_NOMATCH: printf("No match\n"); break;
155
- /*
156
- Handle other special cases if you like
157
- */
158
- default: printf("Matching error %d\n", rc); break;
159
- }
160
- pcre_free(re); /* Release memory used for the compiled pattern */
161
- return 1;
162
- }
163
-
164
- /* Match succeded */
165
-
166
- printf("\nMatch succeeded at offset %d\n", ovector[0]);
167
-
168
-
169
- /*************************************************************************
170
- * We have found the first match within the subject string. If the output *
171
- * vector wasn't big enough, say so. Then output any substrings that were *
172
- * captured. *
173
- *************************************************************************/
174
-
175
- /* The output vector wasn't big enough */
176
-
177
- if (rc == 0)
178
- {
179
- rc = OVECCOUNT/3;
180
- printf("ovector only has room for %d captured substrings\n", rc - 1);
181
- }
182
-
183
- /* Show substrings stored in the output vector by number. Obviously, in a real
184
- application you might want to do things other than print them. */
185
-
186
- for (i = 0; i &lt; rc; i++)
187
- {
188
- char *substring_start = subject + ovector[2*i];
189
- int substring_length = ovector[2*i+1] - ovector[2*i];
190
- printf("%2d: %.*s\n", i, substring_length, substring_start);
191
- }
192
-
193
-
194
- /**************************************************************************
195
- * That concludes the basic part of this demonstration program. We have *
196
- * compiled a pattern, and performed a single match. The code that follows *
197
- * shows first how to access named substrings, and then how to code for *
198
- * repeated matches on the same subject. *
199
- **************************************************************************/
200
-
201
- /* See if there are any named substrings, and if so, show them by name. First
202
- we have to extract the count of named parentheses from the pattern. */
203
-
204
- (void)pcre_fullinfo(
205
- re, /* the compiled pattern */
206
- NULL, /* no extra data - we didn't study the pattern */
207
- PCRE_INFO_NAMECOUNT, /* number of named substrings */
208
- &amp;namecount); /* where to put the answer */
209
-
210
- if (namecount &lt;= 0) printf("No named substrings\n"); else
211
- {
212
- unsigned char *tabptr;
213
- printf("Named substrings\n");
214
-
215
- /* Before we can access the substrings, we must extract the table for
216
- translating names to numbers, and the size of each entry in the table. */
217
-
218
- (void)pcre_fullinfo(
219
- re, /* the compiled pattern */
220
- NULL, /* no extra data - we didn't study the pattern */
221
- PCRE_INFO_NAMETABLE, /* address of the table */
222
- &amp;name_table); /* where to put the answer */
223
-
224
- (void)pcre_fullinfo(
225
- re, /* the compiled pattern */
226
- NULL, /* no extra data - we didn't study the pattern */
227
- PCRE_INFO_NAMEENTRYSIZE, /* size of each entry in the table */
228
- &amp;name_entry_size); /* where to put the answer */
229
-
230
- /* Now we can scan the table and, for each entry, print the number, the name,
231
- and the substring itself. */
232
-
233
- tabptr = name_table;
234
- for (i = 0; i &lt; namecount; i++)
235
- {
236
- int n = (tabptr[0] &lt;&lt; 8) | tabptr[1];
237
- printf("(%d) %*s: %.*s\n", n, name_entry_size - 3, tabptr + 2,
238
- ovector[2*n+1] - ovector[2*n], subject + ovector[2*n]);
239
- tabptr += name_entry_size;
240
- }
241
- }
242
-
243
-
244
- /*************************************************************************
245
- * If the "-g" option was given on the command line, we want to continue *
246
- * to search for additional matches in the subject string, in a similar *
247
- * way to the /g option in Perl. This turns out to be trickier than you *
248
- * might think because of the possibility of matching an empty string. *
249
- * What happens is as follows: *
250
- * *
251
- * If the previous match was NOT for an empty string, we can just start *
252
- * the next match at the end of the previous one. *
253
- * *
254
- * If the previous match WAS for an empty string, we can't do that, as it *
255
- * would lead to an infinite loop. Instead, a special call of pcre_exec() *
256
- * is made with the PCRE_NOTEMPTY_ATSTART and PCRE_ANCHORED flags set. *
257
- * The first of these tells PCRE that an empty string at the start of the *
258
- * subject is not a valid match; other possibilities must be tried. The *
259
- * second flag restricts PCRE to one match attempt at the initial string *
260
- * position. If this match succeeds, an alternative to the empty string *
261
- * match has been found, and we can print it and proceed round the loop, *
262
- * advancing by the length of whatever was found. If this match does not *
263
- * succeed, we still stay in the loop, advancing by just one character. *
264
- * In UTF-8 mode, which can be set by (*UTF8) in the pattern, this may be *
265
- * more than one byte. *
266
- * *
267
- * However, there is a complication concerned with newlines. When the *
268
- * newline convention is such that CRLF is a valid newline, we must *
269
- * advance by two characters rather than one. The newline convention can *
270
- * be set in the regex by (*CR), etc.; if not, we must find the default. *
271
- *************************************************************************/
272
-
273
- if (!find_all) /* Check for -g */
274
- {
275
- pcre_free(re); /* Release the memory used for the compiled pattern */
276
- return 0; /* Finish unless -g was given */
277
- }
278
-
279
- /* Before running the loop, check for UTF-8 and whether CRLF is a valid newline
280
- sequence. First, find the options with which the regex was compiled; extract
281
- the UTF-8 state, and mask off all but the newline options. */
282
-
283
- (void)pcre_fullinfo(re, NULL, PCRE_INFO_OPTIONS, &amp;option_bits);
284
- utf8 = option_bits &amp; PCRE_UTF8;
285
- option_bits &amp;= PCRE_NEWLINE_CR|PCRE_NEWLINE_LF|PCRE_NEWLINE_CRLF|
286
- PCRE_NEWLINE_ANY|PCRE_NEWLINE_ANYCRLF;
287
-
288
- /* If no newline options were set, find the default newline convention from the
289
- build configuration. */
290
-
291
- if (option_bits == 0)
292
- {
293
- int d;
294
- (void)pcre_config(PCRE_CONFIG_NEWLINE, &amp;d);
295
- /* Note that these values are always the ASCII ones, even in
296
- EBCDIC environments. CR = 13, NL = 10. */
297
- option_bits = (d == 13)? PCRE_NEWLINE_CR :
298
- (d == 10)? PCRE_NEWLINE_LF :
299
- (d == (13&lt;&lt;8 | 10))? PCRE_NEWLINE_CRLF :
300
- (d == -2)? PCRE_NEWLINE_ANYCRLF :
301
- (d == -1)? PCRE_NEWLINE_ANY : 0;
302
- }
303
-
304
- /* See if CRLF is a valid newline sequence. */
305
-
306
- crlf_is_newline =
307
- option_bits == PCRE_NEWLINE_ANY ||
308
- option_bits == PCRE_NEWLINE_CRLF ||
309
- option_bits == PCRE_NEWLINE_ANYCRLF;
310
-
311
- /* Loop for second and subsequent matches */
312
-
313
- for (;;)
314
- {
315
- int options = 0; /* Normally no options */
316
- int start_offset = ovector[1]; /* Start at end of previous match */
317
-
318
- /* If the previous match was for an empty string, we are finished if we are
319
- at the end of the subject. Otherwise, arrange to run another match at the
320
- same point to see if a non-empty match can be found. */
321
-
322
- if (ovector[0] == ovector[1])
323
- {
324
- if (ovector[0] == subject_length) break;
325
- options = PCRE_NOTEMPTY_ATSTART | PCRE_ANCHORED;
326
- }
327
-
328
- /* Run the next matching operation */
329
-
330
- rc = pcre_exec(
331
- re, /* the compiled pattern */
332
- NULL, /* no extra data - we didn't study the pattern */
333
- subject, /* the subject string */
334
- subject_length, /* the length of the subject */
335
- start_offset, /* starting offset in the subject */
336
- options, /* options */
337
- ovector, /* output vector for substring information */
338
- OVECCOUNT); /* number of elements in the output vector */
339
-
340
- /* This time, a result of NOMATCH isn't an error. If the value in "options"
341
- is zero, it just means we have found all possible matches, so the loop ends.
342
- Otherwise, it means we have failed to find a non-empty-string match at a
343
- point where there was a previous empty-string match. In this case, we do what
344
- Perl does: advance the matching position by one character, and continue. We
345
- do this by setting the "end of previous match" offset, because that is picked
346
- up at the top of the loop as the point at which to start again.
347
-
348
- There are two complications: (a) When CRLF is a valid newline sequence, and
349
- the current position is just before it, advance by an extra byte. (b)
350
- Otherwise we must ensure that we skip an entire UTF-8 character if we are in
351
- UTF-8 mode. */
352
-
353
- if (rc == PCRE_ERROR_NOMATCH)
354
- {
355
- if (options == 0) break; /* All matches found */
356
- ovector[1] = start_offset + 1; /* Advance one byte */
357
- if (crlf_is_newline &amp;&amp; /* If CRLF is newline &amp; */
358
- start_offset &lt; subject_length - 1 &amp;&amp; /* we are at CRLF, */
359
- subject[start_offset] == '\r' &amp;&amp;
360
- subject[start_offset + 1] == '\n')
361
- ovector[1] += 1; /* Advance by one more. */
362
- else if (utf8) /* Otherwise, ensure we */
363
- { /* advance a whole UTF-8 */
364
- while (ovector[1] &lt; subject_length) /* character. */
365
- {
366
- if ((subject[ovector[1]] &amp; 0xc0) != 0x80) break;
367
- ovector[1] += 1;
368
- }
369
- }
370
- continue; /* Go round the loop again */
371
- }
372
-
373
- /* Other matching errors are not recoverable. */
374
-
375
- if (rc &lt; 0)
376
- {
377
- printf("Matching error %d\n", rc);
378
- pcre_free(re); /* Release memory used for the compiled pattern */
379
- return 1;
380
- }
381
-
382
- /* Match succeded */
383
-
384
- printf("\nMatch succeeded again at offset %d\n", ovector[0]);
385
-
386
- /* The match succeeded, but the output vector wasn't big enough. */
387
-
388
- if (rc == 0)
389
- {
390
- rc = OVECCOUNT/3;
391
- printf("ovector only has room for %d captured substrings\n", rc - 1);
392
- }
393
-
394
- /* As before, show substrings stored in the output vector by number, and then
395
- also any named substrings. */
396
-
397
- for (i = 0; i &lt; rc; i++)
398
- {
399
- char *substring_start = subject + ovector[2*i];
400
- int substring_length = ovector[2*i+1] - ovector[2*i];
401
- printf("%2d: %.*s\n", i, substring_length, substring_start);
402
- }
403
-
404
- if (namecount &lt;= 0) printf("No named substrings\n"); else
405
- {
406
- unsigned char *tabptr = name_table;
407
- printf("Named substrings\n");
408
- for (i = 0; i &lt; namecount; i++)
409
- {
410
- int n = (tabptr[0] &lt;&lt; 8) | tabptr[1];
411
- printf("(%d) %*s: %.*s\n", n, name_entry_size - 3, tabptr + 2,
412
- ovector[2*n+1] - ovector[2*n], subject + ovector[2*n]);
413
- tabptr += name_entry_size;
414
- }
415
- }
416
- } /* End of loop to find second and subsequent matches */
417
-
418
- printf("\n");
419
- pcre_free(re); /* Release memory used for the compiled pattern */
420
- return 0;
421
- }
422
-
423
- /* End of pcredemo.c */
424
- <p>
425
- Return to the <a href="index.html">PCRE index page</a>.
426
- </p>