CALLOUTS.BUILTIN               2018/03/16


* FAIL

  (*FAIL)

  Always fail.


* MISMATCH

  (*MISMATCH)

  Terminate Match process.
  Continue Search process.


* ERROR

  (*ERROR{n::LONG})

  Terminate Search/Match process.

  Return value is the argument 'n'. (The value must be less than -1)
  'n' is an optional argument. (default value is ONIG_ABORT)


* MAX

  (*MAX{n::LONG})

  Restrict the maximum count of success.

  [callout data]
  slot 0: current success count.


* COUNT

  (*COUNT{c::CHAR})

  Counter.
  Depends on 'c' argument, the slot 0 value changes.
  'c' is an optional argument, deefault value is '>'.

  [callout data]
  slot 0: '>': progress count, '<': retraction count, 'X': success count
  slot 1: progress count
  slot 2: retraction count

  (* success count = progress count - retraction count)

  ** If option ONIG_OPTION_FIND_LONGEST or ONIG_OPTION_FIND_NOT_EMPTY is used,
     counts are not accurate.


* TOTAL_COUNT

  (*TOTAL_COUNT{c::CHAR})

  It's the almost same as COUNT.
  But the counts are integrated in a search process.
  'c' is an optional argument, deefault value is '>'.

  [callout data]
  slot 0: '>': progress count, '<': retraction count, 'X': success count
  slot 1: progress count
  slot 2: retraction count

  ** If option ONIG_OPTION_FIND_LONGEST or ONIG_OPTION_FIND_NOT_EMPTY is used,
     counts are not accurate.


* CMP

  (*CMP{x::TAG/LONG, op::STRING, y::TAG/LONG})

  Compare x value and y value with op operator.

  op: '==', '!=', '>', '<', '>=', '<='

  ex. "(?:(*MAX[TA]{7})a|(*MAX[TB]{5})b)*(*CMP{TA,>=,4})"

  [callout data]
  slot 0: op value (enum OP_CMP in src/regexec.c)

//END
