w32tex
About: TeX Live provides a comprehensive TeX system including all the major TeX-related programs, macro packages, and fonts that are free software. Windows sources.
  Fossies Dox: w32tex-src.tar.xz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

regex_internal.h File Reference
#include <assert.h>
#include <ctype.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
Include dependency graph for regex_internal.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  re_node_set
 
struct  re_token_t
 
struct  re_string_t
 
struct  bin_tree_t
 
struct  bin_tree_storage_t
 
struct  re_dfastate_t
 
struct  re_state_table_entry
 
struct  state_array_t
 
struct  re_sub_match_last_t
 
struct  re_sub_match_top_t
 
struct  re_backref_cache_entry
 
struct  re_match_context_t
 
struct  re_sift_context_t
 
struct  re_fail_stack_ent_t
 
struct  re_fail_stack_t
 
struct  re_dfa_t
 
struct  bracket_elem_t
 

Macros

#define __libc_lock_define(CLASS, NAME)
 
#define __libc_lock_init(NAME)   do { } while (0)
 
#define __libc_lock_lock(NAME)   do { } while (0)
 
#define __libc_lock_unlock(NAME)   do { } while (0)
 
#define isblank(ch)   ((ch) == ' ' || (ch) == '\t')
 
#define gettext(msgid)   (msgid)
 
#define gettext_noop(String)   String
 
#define SIZE_MAX   ((size_t) -1)
 
#define BE(expr, val)   (expr)
 
#define inline
 
#define SBC_MAX   256
 
#define COLL_ELEM_LEN_MAX   8
 
#define NEWLINE_CHAR   '\n'
 
#define WIDE_NEWLINE_CHAR   L'\n'
 
#define __wctype   wctype
 
#define __iswctype   iswctype
 
#define __btowc   btowc
 
#define __mempcpy   mempcpy
 
#define __wcrtomb   wcrtomb
 
#define __regfree   regfree
 
#define attribute_hidden
 
#define __attribute(arg)
 
#define BITSET_WORD_MAX   ULONG_MAX
 
#define BITSET_WORD_BITS   (sizeof (bitset_word_t) * CHAR_BIT)
 
#define BITSET_WORDS   (SBC_MAX / BITSET_WORD_BITS)
 
#define bitset_set(set, i)    (set[i / BITSET_WORD_BITS] |= (bitset_word_t) 1 << i % BITSET_WORD_BITS)
 
#define bitset_clear(set, i)    (set[i / BITSET_WORD_BITS] &= ~((bitset_word_t) 1 << i % BITSET_WORD_BITS))
 
#define bitset_contain(set, i)    (set[i / BITSET_WORD_BITS] & ((bitset_word_t) 1 << i % BITSET_WORD_BITS))
 
#define bitset_empty(set)   memset (set, '\0', sizeof (bitset_t))
 
#define bitset_set_all(set)   memset (set, '\xff', sizeof (bitset_t))
 
#define bitset_copy(dest, src)   memcpy (dest, src, sizeof (bitset_t))
 
#define PREV_WORD_CONSTRAINT   0x0001
 
#define PREV_NOTWORD_CONSTRAINT   0x0002
 
#define NEXT_WORD_CONSTRAINT   0x0004
 
#define NEXT_NOTWORD_CONSTRAINT   0x0008
 
#define PREV_NEWLINE_CONSTRAINT   0x0010
 
#define NEXT_NEWLINE_CONSTRAINT   0x0020
 
#define PREV_BEGBUF_CONSTRAINT   0x0040
 
#define NEXT_ENDBUF_CONSTRAINT   0x0080
 
#define WORD_DELIM_CONSTRAINT   0x0100
 
#define NOT_WORD_DELIM_CONSTRAINT   0x0200
 
#define EPSILON_BIT   8
 
#define IS_EPSILON_NODE(type)   ((type) & EPSILON_BIT)
 
#define internal_function
 
#define re_string_peek_byte(pstr, offset)    ((pstr)->mbs[(pstr)->cur_idx + offset])
 
#define re_string_fetch_byte(pstr)    ((pstr)->mbs[(pstr)->cur_idx++])
 
#define re_string_first_byte(pstr, idx)    ((idx) == (pstr)->valid_len || (pstr)->wcs[idx] != WEOF)
 
#define re_string_is_single_byte_char(pstr, idx)
 
#define re_string_eoi(pstr)   ((pstr)->stop <= (pstr)->cur_idx)
 
#define re_string_cur_idx(pstr)   ((pstr)->cur_idx)
 
#define re_string_get_buffer(pstr)   ((pstr)->mbs)
 
#define re_string_length(pstr)   ((pstr)->len)
 
#define re_string_byte_at(pstr, idx)   ((pstr)->mbs[idx])
 
#define re_string_skip_bytes(pstr, idx)   ((pstr)->cur_idx += (idx))
 
#define re_string_set_index(pstr, idx)   ((pstr)->cur_idx = (idx))
 
#define __libc_use_alloca(n)   0
 
#define re_malloc(t, n)   ((t *) malloc ((n) * sizeof (t)))
 
#define re_realloc(p, t, n)   ((t *) realloc (p, (n) * sizeof (t)))
 
#define re_free(p)   free (p)
 
#define BIN_TREE_STORAGE_SIZE    ((1024 - sizeof (void *)) / sizeof (bin_tree_t))
 
#define CONTEXT_WORD   1
 
#define CONTEXT_NEWLINE   (CONTEXT_WORD << 1)
 
#define CONTEXT_BEGBUF   (CONTEXT_NEWLINE << 1)
 
#define CONTEXT_ENDBUF   (CONTEXT_BEGBUF << 1)
 
#define IS_WORD_CONTEXT(c)   ((c) & CONTEXT_WORD)
 
#define IS_NEWLINE_CONTEXT(c)   ((c) & CONTEXT_NEWLINE)
 
#define IS_BEGBUF_CONTEXT(c)   ((c) & CONTEXT_BEGBUF)
 
#define IS_ENDBUF_CONTEXT(c)   ((c) & CONTEXT_ENDBUF)
 
#define IS_ORDINARY_CONTEXT(c)   ((c) == 0)
 
#define IS_WORD_CHAR(ch)   (isalnum (ch) || (ch) == '_')
 
#define IS_NEWLINE(ch)   ((ch) == NEWLINE_CHAR)
 
#define IS_WIDE_WORD_CHAR(ch)   (iswalnum (ch) || (ch) == L'_')
 
#define IS_WIDE_NEWLINE(ch)   ((ch) == WIDE_NEWLINE_CHAR)
 
#define NOT_SATISFY_PREV_CONSTRAINT(constraint, context)
 
#define NOT_SATISFY_NEXT_CONSTRAINT(constraint, context)
 
#define re_node_set_init_empty(set)   memset (set, '\0', sizeof (re_node_set))
 
#define re_node_set_remove(set, id)    (re_node_set_remove_at (set, re_node_set_contains (set, id) - 1))
 
#define re_node_set_empty(p)   ((p)->nelem = 0)
 
#define re_node_set_free(set)   re_free ((set)->elems)
 

Typedefs

typedef unsigned long int bitset_word_t
 
typedef bitset_word_t bitset_t[(256/(sizeof(bitset_word_t) *CHAR_BIT))]
 
typedef bitset_word_tre_bitset_ptr_t
 
typedef const bitset_word_tre_const_bitset_ptr_t
 
typedef struct re_string_t re_string_t
 
typedef struct re_dfa_t re_dfa_t
 
typedef struct bin_tree_t bin_tree_t
 
typedef struct bin_tree_storage_t bin_tree_storage_t
 
typedef struct re_dfastate_t re_dfastate_t
 

Enumerations

enum  bool { false , true }
 
enum  re_context_type {
  INSIDE_WORD = 0x0001 | 0x0004 , WORD_FIRST = 0x0002 | 0x0004 , WORD_LAST = 0x0001 | 0x0008 , INSIDE_NOTWORD = 0x0002 | 0x0008 ,
  LINE_FIRST = 0x0010 , LINE_LAST = 0x0020 , BUF_FIRST = 0x0040 , BUF_LAST = 0x0080 ,
  WORD_DELIM = 0x0100 , NOT_WORD_DELIM = 0x0200
}
 
enum  re_token_type_t {
  NON_TYPE = 0 , CHARACTER = 1 , END_OF_RE = 2 , SIMPLE_BRACKET = 3 ,
  OP_BACK_REF = 4 , OP_PERIOD = 5 , OP_OPEN_SUBEXP = 8 | 0 , OP_CLOSE_SUBEXP = 8 | 1 ,
  OP_ALT = 8 | 2 , OP_DUP_ASTERISK = 8 | 3 , ANCHOR = 8 | 4 , CONCAT = 16 ,
  SUBEXP = 17 , OP_DUP_PLUS = 18 , OP_DUP_QUESTION , OP_OPEN_BRACKET ,
  OP_CLOSE_BRACKET , OP_CHARSET_RANGE , OP_OPEN_DUP_NUM , OP_CLOSE_DUP_NUM ,
  OP_NON_MATCH_LIST , OP_OPEN_COLL_ELEM , OP_CLOSE_COLL_ELEM , OP_OPEN_EQUIV_CLASS ,
  OP_CLOSE_EQUIV_CLASS , OP_OPEN_CHAR_CLASS , OP_CLOSE_CHAR_CLASS , OP_WORD ,
  OP_NOTWORD , OP_SPACE , OP_NOTSPACE , BACK_SLASH
}
 
enum  bracket_elem_type {
  SB_CHAR , MB_CHAR , EQUIV_CLASS , COLL_SYM ,
  CHAR_CLASS
}
 

Functions

static reg_errcode_t re_string_realloc_buffers (re_string_t *pstr, int new_buf_len)
 
static void build_upper_buffer (re_string_t *pstr)
 
static void re_string_translate_buffer (re_string_t *pstr)
 
static unsigned int re_string_context_at (const re_string_t *input, int idx, int eflags)
 
static void bitset_not (bitset_t set)
 
static void bitset_merge (bitset_t dest, const bitset_t src)
 
static void bitset_mask (bitset_t dest, const bitset_t src)
 

Variables

const char __re_error_msgid []
 
const size_t __re_error_msgid_idx []
 

Macro Definition Documentation

◆ __attribute

#define __attribute (   arg)

Definition at line 135 of file regex_internal.h.

◆ __btowc

#define __btowc   btowc

Definition at line 125 of file regex_internal.h.

◆ __iswctype

#define __iswctype   iswctype

Definition at line 124 of file regex_internal.h.

◆ __libc_lock_define

#define __libc_lock_define (   CLASS,
  NAME 
)

Definition at line 58 of file regex_internal.h.

◆ __libc_lock_init

#define __libc_lock_init (   NAME)    do { } while (0)

Definition at line 59 of file regex_internal.h.

◆ __libc_lock_lock

#define __libc_lock_lock (   NAME)    do { } while (0)

Definition at line 60 of file regex_internal.h.

◆ __libc_lock_unlock

#define __libc_lock_unlock (   NAME)    do { } while (0)

Definition at line 61 of file regex_internal.h.

◆ __libc_use_alloca

#define __libc_use_alloca (   n)    0

Definition at line 446 of file regex_internal.h.

◆ __mempcpy

#define __mempcpy   mempcpy

Definition at line 126 of file regex_internal.h.

◆ __regfree

#define __regfree   regfree

Definition at line 128 of file regex_internal.h.

◆ __wcrtomb

#define __wcrtomb   wcrtomb

Definition at line 127 of file regex_internal.h.

◆ __wctype

#define __wctype   wctype

Definition at line 123 of file regex_internal.h.

◆ attribute_hidden

#define attribute_hidden

Definition at line 129 of file regex_internal.h.

◆ BE

#define BE (   expr,
  val 
)    (expr)

Definition at line 108 of file regex_internal.h.

◆ BIN_TREE_STORAGE_SIZE

#define BIN_TREE_STORAGE_SIZE    ((1024 - sizeof (void *)) / sizeof (bin_tree_t))

Definition at line 470 of file regex_internal.h.

◆ bitset_clear

#define bitset_clear (   set,
  i 
)     (set[i / BITSET_WORD_BITS] &= ~((bitset_word_t) 1 << i % BITSET_WORD_BITS))

Definition at line 156 of file regex_internal.h.

◆ bitset_contain

#define bitset_contain (   set,
  i 
)     (set[i / BITSET_WORD_BITS] & ((bitset_word_t) 1 << i % BITSET_WORD_BITS))

Definition at line 158 of file regex_internal.h.

◆ bitset_copy

#define bitset_copy (   dest,
  src 
)    memcpy (dest, src, sizeof (bitset_t))

Definition at line 162 of file regex_internal.h.

◆ bitset_empty

#define bitset_empty (   set)    memset (set, '\0', sizeof (bitset_t))

Definition at line 160 of file regex_internal.h.

◆ bitset_set

#define bitset_set (   set,
  i 
)     (set[i / BITSET_WORD_BITS] |= (bitset_word_t) 1 << i % BITSET_WORD_BITS)

Definition at line 154 of file regex_internal.h.

◆ bitset_set_all

#define bitset_set_all (   set)    memset (set, '\xff', sizeof (bitset_t))

Definition at line 161 of file regex_internal.h.

◆ BITSET_WORD_BITS

#define BITSET_WORD_BITS   (sizeof (bitset_word_t) * CHAR_BIT)

Definition at line 147 of file regex_internal.h.

◆ BITSET_WORD_MAX

#define BITSET_WORD_MAX   ULONG_MAX

Definition at line 145 of file regex_internal.h.

◆ BITSET_WORDS

#define BITSET_WORDS   (SBC_MAX / BITSET_WORD_BITS)

Definition at line 149 of file regex_internal.h.

◆ COLL_ELEM_LEN_MAX

#define COLL_ELEM_LEN_MAX   8

Definition at line 115 of file regex_internal.h.

◆ CONTEXT_BEGBUF

#define CONTEXT_BEGBUF   (CONTEXT_NEWLINE << 1)

Definition at line 482 of file regex_internal.h.

◆ CONTEXT_ENDBUF

#define CONTEXT_ENDBUF   (CONTEXT_BEGBUF << 1)

Definition at line 483 of file regex_internal.h.

◆ CONTEXT_NEWLINE

#define CONTEXT_NEWLINE   (CONTEXT_WORD << 1)

Definition at line 481 of file regex_internal.h.

◆ CONTEXT_WORD

#define CONTEXT_WORD   1

Definition at line 480 of file regex_internal.h.

◆ EPSILON_BIT

#define EPSILON_BIT   8

Definition at line 213 of file regex_internal.h.

◆ gettext

#define gettext (   msgid)    (msgid)

Definition at line 87 of file regex_internal.h.

◆ gettext_noop

#define gettext_noop (   String)    String

Definition at line 93 of file regex_internal.h.

◆ inline

#define inline

Definition at line 109 of file regex_internal.h.

◆ internal_function

#define internal_function

Definition at line 391 of file regex_internal.h.

◆ IS_BEGBUF_CONTEXT

#define IS_BEGBUF_CONTEXT (   c)    ((c) & CONTEXT_BEGBUF)

Definition at line 487 of file regex_internal.h.

◆ IS_ENDBUF_CONTEXT

#define IS_ENDBUF_CONTEXT (   c)    ((c) & CONTEXT_ENDBUF)

Definition at line 488 of file regex_internal.h.

◆ IS_EPSILON_NODE

#define IS_EPSILON_NODE (   type)    ((type) & EPSILON_BIT)

Definition at line 324 of file regex_internal.h.

◆ IS_NEWLINE

#define IS_NEWLINE (   ch)    ((ch) == NEWLINE_CHAR)

Definition at line 492 of file regex_internal.h.

◆ IS_NEWLINE_CONTEXT

#define IS_NEWLINE_CONTEXT (   c)    ((c) & CONTEXT_NEWLINE)

Definition at line 486 of file regex_internal.h.

◆ IS_ORDINARY_CONTEXT

#define IS_ORDINARY_CONTEXT (   c)    ((c) == 0)

Definition at line 489 of file regex_internal.h.

◆ IS_WIDE_NEWLINE

#define IS_WIDE_NEWLINE (   ch)    ((ch) == WIDE_NEWLINE_CHAR)

Definition at line 494 of file regex_internal.h.

◆ IS_WIDE_WORD_CHAR

#define IS_WIDE_WORD_CHAR (   ch)    (iswalnum (ch) || (ch) == L'_')

Definition at line 493 of file regex_internal.h.

◆ IS_WORD_CHAR

#define IS_WORD_CHAR (   ch)    (isalnum (ch) || (ch) == '_')

Definition at line 491 of file regex_internal.h.

◆ IS_WORD_CONTEXT

#define IS_WORD_CONTEXT (   c)    ((c) & CONTEXT_WORD)

Definition at line 485 of file regex_internal.h.

◆ isblank

#define isblank (   ch)    ((ch) == ' ' || (ch) == '\t')

Definition at line 66 of file regex_internal.h.

◆ NEWLINE_CHAR

#define NEWLINE_CHAR   '\n'

Definition at line 118 of file regex_internal.h.

◆ NEXT_ENDBUF_CONSTRAINT

#define NEXT_ENDBUF_CONSTRAINT   0x0080

Definition at line 171 of file regex_internal.h.

◆ NEXT_NEWLINE_CONSTRAINT

#define NEXT_NEWLINE_CONSTRAINT   0x0020

Definition at line 169 of file regex_internal.h.

◆ NEXT_NOTWORD_CONSTRAINT

#define NEXT_NOTWORD_CONSTRAINT   0x0008

Definition at line 167 of file regex_internal.h.

◆ NEXT_WORD_CONSTRAINT

#define NEXT_WORD_CONSTRAINT   0x0004

Definition at line 166 of file regex_internal.h.

◆ NOT_SATISFY_NEXT_CONSTRAINT

#define NOT_SATISFY_NEXT_CONSTRAINT (   constraint,
  context 
)
Value:
#define NEXT_WORD_CONSTRAINT
#define NEXT_NOTWORD_CONSTRAINT
#define IS_NEWLINE_CONTEXT(c)
#define NEXT_NEWLINE_CONSTRAINT
#define IS_WORD_CONTEXT(c)
#define IS_ENDBUF_CONTEXT(c)
#define NEXT_ENDBUF_CONSTRAINT

Definition at line 502 of file regex_internal.h.

◆ NOT_SATISFY_PREV_CONSTRAINT

#define NOT_SATISFY_PREV_CONSTRAINT (   constraint,
  context 
)
Value:
#define PREV_WORD_CONSTRAINT
#define PREV_NOTWORD_CONSTRAINT
#define PREV_BEGBUF_CONSTRAINT
#define IS_BEGBUF_CONTEXT(c)
#define PREV_NEWLINE_CONSTRAINT

Definition at line 496 of file regex_internal.h.

◆ NOT_WORD_DELIM_CONSTRAINT

#define NOT_WORD_DELIM_CONSTRAINT   0x0200

Definition at line 173 of file regex_internal.h.

◆ PREV_BEGBUF_CONSTRAINT

#define PREV_BEGBUF_CONSTRAINT   0x0040

Definition at line 170 of file regex_internal.h.

◆ PREV_NEWLINE_CONSTRAINT

#define PREV_NEWLINE_CONSTRAINT   0x0010

Definition at line 168 of file regex_internal.h.

◆ PREV_NOTWORD_CONSTRAINT

#define PREV_NOTWORD_CONSTRAINT   0x0002

Definition at line 165 of file regex_internal.h.

◆ PREV_WORD_CONSTRAINT

#define PREV_WORD_CONSTRAINT   0x0001

Definition at line 164 of file regex_internal.h.

◆ re_free

#define re_free (   p)    free (p)

Definition at line 452 of file regex_internal.h.

◆ re_malloc

#define re_malloc (   t,
  n 
)    ((t *) malloc ((n) * sizeof (t)))

Definition at line 450 of file regex_internal.h.

◆ re_node_set_empty

#define re_node_set_empty (   p)    ((p)->nelem = 0)

Definition at line 679 of file regex_internal.h.

◆ re_node_set_free

#define re_node_set_free (   set)    re_free ((set)->elems)

Definition at line 680 of file regex_internal.h.

◆ re_node_set_init_empty

#define re_node_set_init_empty (   set)    memset (set, '\0', sizeof (re_node_set))

Definition at line 676 of file regex_internal.h.

◆ re_node_set_remove

#define re_node_set_remove (   set,
  id 
)     (re_node_set_remove_at (set, re_node_set_contains (set, id) - 1))

Definition at line 677 of file regex_internal.h.

◆ re_realloc

#define re_realloc (   p,
  t,
  n 
)    ((t *) realloc (p, (n) * sizeof (t)))

Definition at line 451 of file regex_internal.h.

◆ re_string_byte_at

#define re_string_byte_at (   pstr,
  idx 
)    ((pstr)->mbs[idx])

Definition at line 420 of file regex_internal.h.

◆ re_string_cur_idx

#define re_string_cur_idx (   pstr)    ((pstr)->cur_idx)

Definition at line 417 of file regex_internal.h.

◆ re_string_eoi

#define re_string_eoi (   pstr)    ((pstr)->stop <= (pstr)->cur_idx)

Definition at line 416 of file regex_internal.h.

◆ re_string_fetch_byte

#define re_string_fetch_byte (   pstr)     ((pstr)->mbs[(pstr)->cur_idx++])

Definition at line 409 of file regex_internal.h.

◆ re_string_first_byte

#define re_string_first_byte (   pstr,
  idx 
)     ((idx) == (pstr)->valid_len || (pstr)->wcs[idx] != WEOF)

Definition at line 411 of file regex_internal.h.

◆ re_string_get_buffer

#define re_string_get_buffer (   pstr)    ((pstr)->mbs)

Definition at line 418 of file regex_internal.h.

◆ re_string_is_single_byte_char

#define re_string_is_single_byte_char (   pstr,
  idx 
)
Value:
((pstr)->wcs[idx] != WEOF && ((pstr)->valid_len == (idx) + 1 \
|| (pstr)->wcs[(idx) + 1] != WEOF))
FT_UInt idx
Definition: cffcmap.c:135

Definition at line 413 of file regex_internal.h.

◆ re_string_length

#define re_string_length (   pstr)    ((pstr)->len)

Definition at line 419 of file regex_internal.h.

◆ re_string_peek_byte

#define re_string_peek_byte (   pstr,
  offset 
)     ((pstr)->mbs[(pstr)->cur_idx + offset])

Definition at line 407 of file regex_internal.h.

◆ re_string_set_index

#define re_string_set_index (   pstr,
  idx 
)    ((pstr)->cur_idx = (idx))

Definition at line 422 of file regex_internal.h.

◆ re_string_skip_bytes

#define re_string_skip_bytes (   pstr,
  idx 
)    ((pstr)->cur_idx += (idx))

Definition at line 421 of file regex_internal.h.

◆ SBC_MAX

#define SBC_MAX   256

Definition at line 113 of file regex_internal.h.

◆ SIZE_MAX

#define SIZE_MAX   ((size_t) -1)

Definition at line 98 of file regex_internal.h.

◆ WIDE_NEWLINE_CHAR

#define WIDE_NEWLINE_CHAR   L'\n'

Definition at line 119 of file regex_internal.h.

◆ WORD_DELIM_CONSTRAINT

#define WORD_DELIM_CONSTRAINT   0x0100

Definition at line 172 of file regex_internal.h.

Typedef Documentation

◆ bin_tree_storage_t

Definition at line 404 of file regex_internal.h.

◆ bin_tree_t

typedef struct bin_tree_t bin_tree_t

Definition at line 404 of file regex_internal.h.

◆ bitset_t

typedef bitset_word_t bitset_t[(256/(sizeof(bitset_word_t) *CHAR_BIT))]

Definition at line 150 of file regex_internal.h.

◆ bitset_word_t

typedef unsigned long int bitset_word_t

Definition at line 143 of file regex_internal.h.

◆ re_bitset_ptr_t

Definition at line 151 of file regex_internal.h.

◆ re_const_bitset_ptr_t

Definition at line 152 of file regex_internal.h.

◆ re_dfa_t

typedef struct re_dfa_t re_dfa_t

Definition at line 152 of file regex_internal.h.

◆ re_dfastate_t

typedef struct re_dfastate_t re_dfastate_t

Definition at line 404 of file regex_internal.h.

◆ re_string_t

typedef struct re_string_t re_string_t

Definition at line 152 of file regex_internal.h.

Enumeration Type Documentation

◆ bool

enum bool
Enumerator
false 
true 

Definition at line 50 of file regex_internal.h.

◆ bracket_elem_type

Enumerator
SB_CHAR 
MB_CHAR 
EQUIV_CLASS 
COLL_SYM 
CHAR_CLASS 

Definition at line 683 of file regex_internal.h.

◆ re_context_type

Enumerator
INSIDE_WORD 
WORD_FIRST 
WORD_LAST 
INSIDE_NOTWORD 
LINE_FIRST 
LINE_LAST 
BUF_FIRST 
BUF_LAST 
WORD_DELIM 
NOT_WORD_DELIM 

Definition at line 175 of file regex_internal.h.

◆ re_token_type_t

Enumerator
NON_TYPE 
CHARACTER 
END_OF_RE 
SIMPLE_BRACKET 
OP_BACK_REF 
OP_PERIOD 
OP_OPEN_SUBEXP 
OP_CLOSE_SUBEXP 
OP_ALT 
OP_DUP_ASTERISK 
ANCHOR 
CONCAT 
SUBEXP 
OP_DUP_PLUS 
OP_DUP_QUESTION 
OP_OPEN_BRACKET 
OP_CLOSE_BRACKET 
OP_CHARSET_RANGE 
OP_OPEN_DUP_NUM 
OP_CLOSE_DUP_NUM 
OP_NON_MATCH_LIST 
OP_OPEN_COLL_ELEM 
OP_CLOSE_COLL_ELEM 
OP_OPEN_EQUIV_CLASS 
OP_CLOSE_EQUIV_CLASS 
OP_OPEN_CHAR_CLASS 
OP_CLOSE_CHAR_CLASS 
OP_WORD 
OP_NOTWORD 
OP_SPACE 
OP_NOTSPACE 
BACK_SLASH 

Definition at line 196 of file regex_internal.h.

Function Documentation

◆ bitset_mask()

static void bitset_mask ( bitset_t  dest,
const bitset_t  src 
)
static

Definition at line 722 of file regex_internal.h.

References BITSET_WORDS, dest, and link_confs::src.

Referenced by build_charclass_op(), and parse_bracket_exp().

◆ bitset_merge()

static void bitset_merge ( bitset_t  dest,
const bitset_t  src 
)
static

Definition at line 714 of file regex_internal.h.

References BITSET_WORDS, dest, and link_confs::src.

Referenced by build_trtable(), and group_nodes_into_DFAstates().

◆ bitset_not()

static void bitset_not ( bitset_t  set)
static

Definition at line 706 of file regex_internal.h.

References BITSET_WORDS.

Referenced by build_charclass_op(), and parse_bracket_exp().

◆ build_upper_buffer()

static void build_upper_buffer ( re_string_t pstr)
static

◆ re_string_context_at()

static unsigned int re_string_context_at ( const re_string_t input,
int  idx,
int  eflags 
)
static

◆ re_string_realloc_buffers()

static reg_errcode_t re_string_realloc_buffers ( re_string_t pstr,
int  new_buf_len 
)
static

◆ re_string_translate_buffer()

static void re_string_translate_buffer ( re_string_t pstr)
static

Variable Documentation

◆ __re_error_msgid

const char __re_error_msgid[]
extern

Referenced by re_compile_pattern(), and regerror().

◆ __re_error_msgid_idx

const size_t __re_error_msgid_idx
extern
Initial value:
=
{
0 ,
( 0 + sizeof "Success") ,
( ( 0 + sizeof "Success") + sizeof "No match") ,
( ( ( 0 + sizeof "Success") + sizeof "No match") + sizeof "Invalid regular expression") ,
( ( ( ( 0 + sizeof "Success") + sizeof "No match") + sizeof "Invalid regular expression") + sizeof "Invalid collation character") ,
( ( ( ( ( 0 + sizeof "Success") + sizeof "No match") + sizeof "Invalid regular expression") + sizeof "Invalid collation character") + sizeof "Invalid character class name") ,
( ( ( ( ( ( 0 + sizeof "Success") + sizeof "No match") + sizeof "Invalid regular expression") + sizeof "Invalid collation character") + sizeof "Invalid character class name") + sizeof "Trailing backslash") ,
( ( ( ( ( ( ( 0 + sizeof "Success") + sizeof "No match") + sizeof "Invalid regular expression") + sizeof "Invalid collation character") + sizeof "Invalid character class name") + sizeof "Trailing backslash") + sizeof "Invalid back reference") ,
( ( ( ( ( ( ( ( 0 + sizeof "Success") + sizeof "No match") + sizeof "Invalid regular expression") + sizeof "Invalid collation character") + sizeof "Invalid character class name") + sizeof "Trailing backslash") + sizeof "Invalid back reference") + sizeof "Unmatched [ or [^") ,
( ( ( ( ( ( ( ( ( 0 + sizeof "Success") + sizeof "No match") + sizeof "Invalid regular expression") + sizeof "Invalid collation character") + sizeof "Invalid character class name") + sizeof "Trailing backslash") + sizeof "Invalid back reference") + sizeof "Unmatched [ or [^") + sizeof "Unmatched ( or \\(") ,
( ( ( ( ( ( ( ( ( ( 0 + sizeof "Success") + sizeof "No match") + sizeof "Invalid regular expression") + sizeof "Invalid collation character") + sizeof "Invalid character class name") + sizeof "Trailing backslash") + sizeof "Invalid back reference") + sizeof "Unmatched [ or [^") + sizeof "Unmatched ( or \\(") + sizeof "Unmatched \\{") ,
( ( ( ( ( ( ( ( ( ( ( 0 + sizeof "Success") + sizeof "No match") + sizeof "Invalid regular expression") + sizeof "Invalid collation character") + sizeof "Invalid character class name") + sizeof "Trailing backslash") + sizeof "Invalid back reference") + sizeof "Unmatched [ or [^") + sizeof "Unmatched ( or \\(") + sizeof "Unmatched \\{") + sizeof "Invalid content of \\{\\}") ,
( ( ( ( ( ( ( ( ( ( ( ( 0 + sizeof "Success") + sizeof "No match") + sizeof "Invalid regular expression") + sizeof "Invalid collation character") + sizeof "Invalid character class name") + sizeof "Trailing backslash") + sizeof "Invalid back reference") + sizeof "Unmatched [ or [^") + sizeof "Unmatched ( or \\(") + sizeof "Unmatched \\{") + sizeof "Invalid content of \\{\\}") + sizeof "Invalid range end") ,
( ( ( ( ( ( ( ( ( ( ( ( ( 0 + sizeof "Success") + sizeof "No match") + sizeof "Invalid regular expression") + sizeof "Invalid collation character") + sizeof "Invalid character class name") + sizeof "Trailing backslash") + sizeof "Invalid back reference") + sizeof "Unmatched [ or [^") + sizeof "Unmatched ( or \\(") + sizeof "Unmatched \\{") + sizeof "Invalid content of \\{\\}") + sizeof "Invalid range end") + sizeof "Memory exhausted") ,
( ( ( ( ( ( ( ( ( ( ( ( ( ( 0 + sizeof "Success") + sizeof "No match") + sizeof "Invalid regular expression") + sizeof "Invalid collation character") + sizeof "Invalid character class name") + sizeof "Trailing backslash") + sizeof "Invalid back reference") + sizeof "Unmatched [ or [^") + sizeof "Unmatched ( or \\(") + sizeof "Unmatched \\{") + sizeof "Invalid content of \\{\\}") + sizeof "Invalid range end") + sizeof "Memory exhausted") + sizeof "Invalid preceding regular expression") ,
( ( ( ( ( ( ( ( ( ( ( ( ( ( ( 0 + sizeof "Success") + sizeof "No match") + sizeof "Invalid regular expression") + sizeof "Invalid collation character") + sizeof "Invalid character class name") + sizeof "Trailing backslash") + sizeof "Invalid back reference") + sizeof "Unmatched [ or [^") + sizeof "Unmatched ( or \\(") + sizeof "Unmatched \\{") + sizeof "Invalid content of \\{\\}") + sizeof "Invalid range end") + sizeof "Memory exhausted") + sizeof "Invalid preceding regular expression") + sizeof "Premature end of regular expression") ,
( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( 0 + sizeof "Success") + sizeof "No match") + sizeof "Invalid regular expression") + sizeof "Invalid collation character") + sizeof "Invalid character class name") + sizeof "Trailing backslash") + sizeof "Invalid back reference") + sizeof "Unmatched [ or [^") + sizeof "Unmatched ( or \\(") + sizeof "Unmatched \\{") + sizeof "Invalid content of \\{\\}") + sizeof "Invalid range end") + sizeof "Memory exhausted") + sizeof "Invalid preceding regular expression") + sizeof "Premature end of regular expression") + sizeof "Regular expression too big")
}

Definition at line 183 of file regcomp.c.

Referenced by re_compile_pattern(), and regerror().