Lines Matching full:for

4  *  See doc/regexp.rst for a discussion of the compilation approach and
16 * input string size (assuming an upper bound can be computed for number
40 /* Number of characters that the atom matches (e.g. 3 for 'abc'),
69 * larger than expected (or at least assert for it). Many things in the
82 /* XXX: return type should probably be duk_size_t, or explicit checks are needed for
113 /* special helper for emitting u16 lists (used for character ranges for built-in char classes) */
145 * variable length UTF-8 encoding. See doc/regexp.rst for discussion.
167 * duk_re_range_callback for generating character class ranges.
170 * We don't, for instance, eliminate duplicates or overlapping
178 * time execution time (see doc/regexp.rst for discussion).
211 for (i = r1 + 1; i <= r2; i++) { in duk__generate_ranges()
251 * Appends the bytecode for the disjunction matcher to the end of the temp
268 * disjunction are separate matters. For instance, the disjunction
274 * and it would be possible to expand it. For instance, captures
279 * main for loop collectively for atoms. Assertions, quantifiers,
307 for (;;) { in duk__parse_disjunction()
311 * new_atom_char_length etc are for the atom parsed on this round; in duk__parse_disjunction()
337 * we have a pending split1 and a pending jump (for a previous match). These in duk__parse_disjunction()
338 * need to be back-patched carefully. See docs for a detailed example. in duk__parse_disjunction()
360 unpatched_disjunction_split = entry_offset + 1; /* +1 for opcode */ in duk__parse_disjunction()
362 /* add a new pending match jump for latest finished alternative */ in duk__parse_disjunction()
381 * If atom_char_length is zero, we'll have unbounded execution time for e.g. in duk__parse_disjunction()
383 * side effects (for instance, if we allowed captures in simple atoms, the in duk__parse_disjunction()
430 * NOTE: there is no current solution for empty atoms in complex in duk__parse_disjunction()
476 /* insert code for matching the remainder - infinite or finite */ in duk__parse_disjunction()
478 /* reuse last emitted atom for remaining 'infinite' quantifier */ in duk__parse_disjunction()
493 duk__append_jump_offset(re_ctx, -atom_code_length - 1); /* -1 for opcode */ in duk__parse_disjunction()
520 offset + 1, /* +1 for opcode */ in duk__parse_disjunction()
562 offset + 1, /* +1 for opcode */ in duk__parse_disjunction()
579 * but this is not trivial (consider e.g. '/xyz+/); see docs for in duk__parse_disjunction()
661 * us for every range parsed. This is different from how rest of in duk__parse_disjunction()
666 * case insensitive matching is used (see docs for discussion). in duk__parse_disjunction()
738 /* finish up pending jump and split for last alternative */ in duk__parse_disjunction()
821 * Note that normalization does not seem to be necessary for
826 * for expressions like 'new Regexp("...", "")' however.
861 for (i = 0; i < n; i++) { in duk__create_escaped_source()
889 * An escaped version of the regexp source, suitable for use as a RegExp instance
932 DUK_LEXER_INITCTX(&re_ctx.lex); /* duplicate zeroing, expect for (possible) NULL inits */ in duk_regexp_compile()
968 * Check for invalid backreferences; note that it is NOT an error in duk_regexp_compile()
973 * for such references only after parsing is complete. in duk_regexp_compile()