FAQ    2014/03/07

1. Longest match

   You can execute longest match by using ONIG_OPTION_FIND_LONGEST option
   in onig_new().


2. Thread safe

   In order to make thread safe, which of (A) or (B) must be done.

   (A) Onigmo Layer

       Uncomment the following macros in onigmo/regint.h.
       (It has the same effect that add --enable-multithread option
       when running ./configure.)

       /* #define USE_MULTI_THREAD_SYSTEM */
       /* #define USE_DEFAULT_MULTI_THREAD_SYSTEM */

       Or define the macro below in onigmo/regint.h.

       USE_MULTI_THREAD_SYSTEM
       THREAD_ATOMIC_START
       THREAD_ATOMIC_END
       THREAD_PASS

       THREAD_SYSTEM_INIT
       THREAD_SYSTEM_END


   (B) Application Layer

       The plural threads should not do simultaneously that making
       new regexp objects or re-compiling objects or freeing objects,
       even if these objects are differ.


3. CR + LF

   DOS newline (CR (0x0c) + LF (0x0a) sequence)

   Enable the following line in regenc.h, and use ONIG_OPTION_NEWLINE_CRLF
   option in onig_new().

     /* #define USE_CRNL_AS_LINE_TERMINATOR */


4. Mailing list

   There is no mailing list about Onigmo/Oniguruma.

// END
