std/pcre
Source Edit
Types
-
CalloutBlock = object
version*: cint ## Identifies version of block
callout_number*: cint ## Number compiled into pattern
offset_vector*: ptr cint ## The offset vector
subject*: cstring ## The subject being matched
subject_length*: cint ## The length of the subject
start_match*: cint ## Offset to start of this match attempt
current_position*: cint ## Where we currently are in the subject
capture_top*: cint ## Max current capture
capture_last*: cint ## Most recently closed capture
callout_data*: pointer ## Data passed in with the call
pattern_position*: cint ## Offset to next item in the pattern
next_item_length*: cint ## Length of next item in the pattern
mark*: pointer ## Pointer to current mark or NULL
- Source Edit
-
JitCallback = proc (a: pointer): ptr JitStack {.cdecl.}
- Source Edit
-
PJitStack {....deprecated.} = ptr JitStack
-
Deprecated
Source Edit
-
PPcre {....deprecated.} = ptr Pcre
-
Deprecated
Source Edit
Consts
-
ERROR_BADUTF8_OFFSET = -11
-
Same for 8/16 Source Edit
-
ERROR_BADUTF16_OFFSET = -11
-
Same for 8/16 Source Edit
-
ERROR_CALLOUT = -9
-
Never used by PCRE itself Source Edit
-
ERROR_NULLWSLIMIT = -22
-
No longer actually used Source Edit
-
ERROR_UNKNOWN_NODE = -5
-
For backward compatibility Source Edit
-
INFO_FIRSTCHAR = 4
-
For backwards compatibility Source Edit
-
INFO_NAMEENTRYSIZE = 7
- Source Edit
-
STUDY_JIT_PARTIAL_HARD_COMPILE = 0x00000004
- Source Edit
-
STUDY_JIT_PARTIAL_SOFT_COMPILE = 0x00000002
- Source Edit
Procs
-
proc compile(pattern: cstring; options: cint; errptr: ptr cstring;
erroffset: ptr cint; tableptr: pointer): ptr Pcre {.cdecl,
importc: "pcre_$1", ...raises: [], tags: [], forbids: [].}
- Source Edit
-
proc compile2(pattern: cstring; options: cint; errorcodeptr: ptr cint;
errptr: ptr cstring; erroffset: ptr cint; tableptr: pointer): ptr Pcre {.
cdecl, importc: "pcre_$1", ...raises: [], tags: [], forbids: [].}
- Source Edit
-
proc config(what: cint; where: pointer): cint {.cdecl, importc: "pcre_$1",
...raises: [], tags: [], forbids: [].}
- Source Edit
-
proc copy_named_substring(code: ptr Pcre; subject: cstring; ovector: ptr cint;
stringcount: cint; stringname: cstring;
buffer: cstring; buffersize: cint): cint {.cdecl,
importc: "pcre_$1", ...raises: [], tags: [], forbids: [].}
- Source Edit
-
proc copy_substring(subject: cstring; ovector: ptr cint; stringcount: cint;
stringnumber: cint; buffer: cstring; buffersize: cint): cint {.
cdecl, importc: "pcre_$1", ...raises: [], tags: [], forbids: [].}
- Source Edit
-
proc free_substring(stringptr: cstring) {.cdecl, importc: "pcre_$1", ...raises: [],
tags: [], forbids: [].}
- Source Edit
-
proc free_substring_list(stringptr: cstringArray) {.cdecl, importc: "pcre_$1",
...raises: [], tags: [], forbids: [].}
- Source Edit
-
proc get_named_substring(code: ptr Pcre; subject: cstring; ovector: ptr cint;
stringcount: cint; stringname: cstring;
stringptr: cstringArray): cint {.cdecl,
importc: "pcre_$1", ...raises: [], tags: [], forbids: [].}
- Source Edit
-
proc get_stringnumber(code: ptr Pcre; name: cstring): cint {.cdecl,
importc: "pcre_$1", ...raises: [], tags: [], forbids: [].}
- Source Edit
-
proc get_stringtable_entries(code: ptr Pcre; name: cstring; first: cstringArray;
last: cstringArray): cint {.cdecl,
importc: "pcre_$1", ...raises: [], tags: [], forbids: [].}
- Source Edit
-
proc get_substring(subject: cstring; ovector: ptr cint; stringcount: cint;
stringnumber: cint; stringptr: cstringArray): cint {.cdecl,
importc: "pcre_$1", ...raises: [], tags: [], forbids: [].}
- Source Edit
-
proc get_substring_list(subject: cstring; ovector: ptr cint; stringcount: cint;
listptr: ptr cstringArray): cint {.cdecl,
importc: "pcre_$1", ...raises: [], tags: [], forbids: [].}
- Source Edit
-
proc jit_free_unused_memory() {.cdecl, importc: "pcre_$1", ...raises: [], tags: [],
forbids: [].}
- Source Edit
-
proc jit_stack_alloc(startsize: cint; maxsize: cint): ptr JitStack {.cdecl,
importc: "pcre_$1", ...raises: [], tags: [], forbids: [].}
- Source Edit
-
proc jit_stack_free(stack: ptr JitStack) {.cdecl, importc: "pcre_$1",
...raises: [], tags: [], forbids: [].}
- Source Edit
-
proc maketables(): pointer {.cdecl, importc: "pcre_$1", ...raises: [], tags: [],
forbids: [].}
- Source Edit
-
proc refcount(code: ptr Pcre; adjust: cint): cint {.cdecl, importc: "pcre_$1",
...raises: [], tags: [], forbids: [].}
- Source Edit
-
proc study(code: ptr Pcre; options: cint; errptr: ptr cstring): ptr ExtraData {.
cdecl, importc: "pcre_$1", ...raises: [], tags: [], forbids: [].}
- Source Edit
-
proc study(code: ptr Pcre; options: cint; errptr: var cstring): ptr ExtraData {.
...deprecated, cdecl, importc: "pcre_$1", ...raises: [], tags: [], forbids: [].}
-
Deprecated
Source Edit
-
proc version(): cstring {.cdecl, importc: "pcre_$1", ...raises: [], tags: [],
forbids: [].}
- Source Edit