MCPcopy Create free account

hub / github.com/dlclark/regexp2 / functions

Functions1,027 in github.com/dlclark/regexp2

↓ 1 callersFunctioncanCombineCounts
(nodeMin, nodeMax, nextMin, nextMax int)
syntax/tree.go:1566
↓ 1 callersMethodcanJoinLengthCheck
()
syntax/tree.go:2353
↓ 1 callersFunctioncaptureSlotsInUse
captureSlotsInUse returns the capture slots whose values can affect matching. Group 0 is always retained as the success marker. Ordinary captures that
syntax/code.go:140
↓ 1 callersMethodcodeFromTree
The top level RegexCode generator. It does a depth-first walk through the tree and calls EmitFragment to emits code before and after each child of an
syntax/writer.go:112
↓ 1 callersFunctioncommonPrefixLen
commonPrefixLen returns the length of the common prefix of two strings.
syntax/prefixanalyzer.go:359
↓ 1 callersFunctioncompileASCIIStringSetPrefixFilter
compileASCIIStringSetPrefixFilter builds a byte-oriented multi-prefix scanner for the narrow shape where it beats running strings.Index once per prefi
stringprefixfilter.go:225
↓ 1 callersFunctioncompileRawPattern
(t *testing.T, pattern string)
regexp_corpus_pcre_test.go:192
↓ 1 callersMethodcomputeMaxLength
Computes a maximum length of any string that could possibly match. or -1 if the length may not always be the same.
syntax/tree.go:2051
↓ 1 callersMethodconsume
(properties graphemeProperties)
syntax/grapheme.go:85
↓ 1 callersMethodconsumeCaptureSlot
(capnum int)
syntax/parser.go:372
↓ 1 callersFunctioncontainsEnder
(line string, ender byte, allowFirst bool)
regexp_corpus_pcre_test.go:260
↓ 1 callersFunctioncorpusMatchSubmatchIndex
(m *Match)
regexp_corpus_helpers_test.go:18
↓ 1 callersFunctioncorpusRE2ParseResult
(s string)
regexp_corpus_re2_test.go:148
↓ 1 callersFunctioncorpusRE2UnquoteC
(t *testing.T, file string, lineno int, s string)
regexp_corpus_re2_test.go:139
↓ 1 callersMethodcountCaptures
CountCaptures is a prescanner for deducing the slots used for captures by doing a partial tokenization of the pattern.
syntax/parser.go:380
↓ 1 callersMethoddisjointAtomicBranchSets
disjointAtomicBranchSets returns the first-character sets when an alternation can select a branch without leaving a backtracking choice.
syntax/tree.go:735
↓ 1 callersMethoddispatchCandidates
dispatchCandidates returns disjoint branch sets and the leading nodes that can be folded into a consuming Dispatch instruction.
syntax/tree.go:744
↓ 1 callersMethoddispatchCode
(sets []*CharSet)
syntax/writer.go:532
↓ 1 callersFunctiondispatchTablesEqual
(left, right []DispatchTable)
syntax/writer.go:79
↓ 1 callersMethoddump
()
syntax/tree.go:2236
↓ 1 callersMethoddumpState
debug
runner.go:2146
↓ 1 callersMethodemit2
Emits a two-argument operation.
syntax/writer.go:655
↓ 1 callersMethodemitCapture
(node *RegexNode)
syntax/writer.go:480
↓ 1 callersMethodemitFragment
The main RegexCode generator. It does a depth-first walk through the tree and calls EmitFragment to emits code before and after each child of an inter
syntax/writer.go:224
↓ 1 callersMethodemptyOptionsStack
True if options stack is empty.
syntax/parser.go:2394
↓ 1 callersMethodemptyStack
True if the group stack is empty.
syntax/parser.go:2572
↓ 1 callersMethodemptyStack
Returns true if the stack is empty.
syntax/writer.go:498
↓ 1 callersFunctionequalInts
(left, right []int)
runner_codegen_test.go:37
↓ 1 callersFunctionexecuteDefault
(r *Runner)
runner.go:230
↓ 1 callersFunctionextendClock
extendClock ensures that clock is live and will run until at least end.
fastclock.go:71
↓ 1 callersMethodextractCommonPrefixOneNotoneSet
This function optimizes out prefix nodes from alternation branches that are the same across multiple contiguous branches. e.g. \w12|\d34|\d56|\w78|\w9
syntax/tree.go:1277
↓ 1 callersMethodextractCommonPrefixText
Analyzes all the branches of the alternation for text that's identical at the beginning of every branch. That text is then pulled out into its own on
syntax/tree.go:1162
↓ 1 callersFunctionextractRequiredLandmark
(node *RegexNode)
syntax/prefixanalyzer.go:1348
↓ 1 callersFunctionextractRequiredLandmarkAlternative
(node *RegexNode)
syntax/prefixanalyzer.go:1373
↓ 1 callersMethodfcIsEmpty
True if the stack is empty.
syntax/prefix.go:135
↓ 1 callersMethodfinalOptimize
Performs additional optimizations on an entire tree prior to being used. Some optimizations are performed by the parser while parsing, and others are
syntax/tree.go:306
↓ 1 callersMethodfindAndMakeLoopsAtomic
Finds {one/notone/set}loop nodes in the concatenation that can be automatically upgraded to {one/notone/set}loopatomic nodes. Such changes avoid pote
syntax/tree.go:374
↓ 1 callersFunctionfindFixedDistanceCharLeftToRight
(r *Runner, ch rune, distance int)
runner.go:1699
↓ 1 callersFunctionfindFixedDistanceSets
arbitrary cut-off to avoid generating lots of sets unnecessarily Finds sets at fixed-offsets from the beginning of the pattern/</summary> set "thoroug
syntax/prefixanalyzer.go:701
↓ 1 callersFunctionfindFixedDistanceSetsLeftToRight
(r *Runner, sets []syntax.FixedDistanceSet)
runner.go:1751
↓ 1 callersFunctionfindFixedDistanceString
Analyzes a list of fixed-distance sets to extract a case-sensitive string at a fixed distance.</summary>
syntax/optimizations.go:632
↓ 1 callersFunctionfindFixedDistanceStringLeftToRight
(r *Runner, literal []rune, distance int)
runner.go:1723
↓ 1 callersFunctionfindLeadingOrTrailingAnchor
(node *RegexNode, leading bool)
syntax/prefix.go:883
↓ 1 callersFunctionfindLeadingPositiveLookahead
Returns a leading positive lookahead if found and whether to keep examining subsequent nodes in a concatenation.
syntax/prefixanalyzer.go:1459
↓ 1 callersFunctionfindLeadingStringLeftToRight
(r *Runner, prefix []rune, ignoreCase bool)
runner.go:1606
↓ 1 callersFunctionfindLiteralAfterLoopLeftToRight
(r *Runner, literal *syntax.LiteralAfterLoop)
runner.go:1781
↓ 1 callersFunctionfindLiteralFollowingLeadingLoop
The above table was generated programmatically with the following. This can be augmented to incorporate additional data sources, though it is only in
syntax/prefixanalyzer.go:1152
↓ 1 callersFunctionfindNextRequiredLandmarkRunes
(input []rune, startAt, endAt int, landmark syntax.RequiredLandmark)
runner.go:1856
↓ 1 callersFunctionfindPrefixesCore
Updates the results list with found prefixes. All existing strings in the list are treated as existing discovered prefixes prior to the node being pro
syntax/prefixanalyzer.go:451
↓ 1 callersFunctionfindRequiredLandmarkChain
(node *RegexNode)
syntax/prefixanalyzer.go:1283
↓ 1 callersFunctionfindRequiredLandmarkChainLeftToRight
(r *Runner, chain *syntax.RequiredLandmarkChain)
runner.go:1809
↓ 1 callersFunctionfindTrailingFixedLengthEnd
(r *Runner, fixedLength int)
runner.go:1596
↓ 1 callersFunctionfixedDistanceSetDescription
(set FixedDistanceSet)
syntax/optimizations.go:272
↓ 1 callersFunctionfixedDistanceSetsMatchAt
(r *Runner, sets []syntax.FixedDistanceSet, start int)
runner.go:1963
↓ 1 callersMethodget
(neededSize, maxSize int)
bufferpool.go:38
↓ 1 callersFunctiongetAnchors
(tree *RegexTree)
syntax/prefix.go:785
↓ 1 callersFunctiongetCharSetFromCategoryString
(negateSet bool, negateCat bool, cats ...string)
syntax/charclass.go:97
↓ 1 callersFunctiongetCharSetFromOldString
(setText []rune, negate bool)
syntax/charclass.go:116
↓ 1 callersMethodgetDispatchCandidates
(node *RegexNode)
syntax/writer.go:523
↓ 1 callersFunctiongetEngineRegexp
(pattern string, c compileConfig)
regexp_codegen.go:52
↓ 1 callersFunctiongetFindMode
(rtl bool, t NodeType)
syntax/optimizations.go:603
↓ 1 callersMethodgetFirstChars
()
syntax/prefix.go:286
↓ 1 callersFunctiongetFirstCharsPrefix
It takes a RegexTree and computes the set of chars that can start it.
syntax/prefix.go:18
↓ 1 callersFunctiongetPrefix
This is a related computation: it takes a RegexTree and computes the leading substring if it sees one. It's quite trivial and gives up easily.
syntax/prefix.go:321
↓ 1 callersFunctiongetRangeLength
(r *SingleRange, negated bool)
syntax/prefixanalyzer.go:1020
↓ 1 callersMethodgetReplacerData
(replacement string)
regexp.go:210
↓ 1 callersFunctiongetRunes
(s string)
regexp.go:510
↓ 1 callersMethodgoTo
(newpos int)
runner.go:1089
↓ 1 callersMethodgrowTrack
()
runner.go:1139
↓ 1 callersMethodhasDisjointStartingSets
hasDisjointStartingSets reports whether every branch is non-nullable and begins with a character set that cannot overlap any other branch. In that cas
syntax/tree.go:709
↓ 1 callersFunctionhasExtendedPictographicZWJBefore
(text []rune, pos int)
syntax/grapheme.go:199
↓ 1 callersFunctionhasHighFrequencyChars
(set FixedDistanceSet)
syntax/prefixanalyzer.go:1043
↓ 1 callersFunctionhasIndicConjunctBefore
(text []rune, pos int)
syntax/grapheme.go:181
↓ 1 callersFunctionhexDigit
Returns n <= 0xF for a hex digit.
regexp_corpus_pcre_test.go:362
↓ 1 callersMethodindex
(input string)
stringprefixfilter.go:128
↓ 1 callersFunctionindexASCIIByteIgnoreCase
(s string, ch byte)
helpers/indexof.go:270
↓ 1 callersFunctionindexOfAnyRunes
(input, find []rune)
runner.go:1684
↓ 1 callersFunctionindexOfLiteralAfterLoop
(r *Runner, literal *syntax.LiteralAfterLoop, searchStart int)
runner.go:1907
↓ 1 callersFunctionindexOfSet
(chars []rune, set syntax.FixedDistanceSet)
runner.go:1945
↓ 1 callersMethodinitMatch
(textInfo *matchText)
runner.go:2006
↓ 1 callersMethodinitTrackCount
()
runner.go:2242
↓ 1 callersMethodintIsEmpty
True if the stack is empty.
syntax/prefix.go:111
↓ 1 callersFunctionisASCIIRunes
(in []rune)
runner.go:1936
↓ 1 callersFunctionisAsciiRunes
(in []rune)
syntax/charclass.go:1374
↓ 1 callersFunctionisGraphemeBoundary
(text []rune, pos int)
syntax/grapheme.go:147
↓ 1 callersFunctionisGraphemeBoundaryForward
(previous graphemeBreakClass, current graphemeProperties, state graphemeForwardState)
syntax/grapheme.go:119
↓ 1 callersMethodisIntrinsicallyAtomic
isIntrinsicallyAtomic reports whether a successful match of this node has no alternative input-consuming path to explore if something later fails.
syntax/tree.go:783
↓ 1 callersFunctionisOnlyTopOption
Returns true for options allowed only at the top level
syntax/parser.go:2050
↓ 1 callersFunctionisQuantifier
Returns true for those characters that begin a quantifier.
syntax/parser.go:2632
↓ 1 callersFunctionisRustRegexQuote
(c byte)
regexp_corpus_rust_test.go:550
↓ 1 callersFunctionisSpace
(ch rune)
syntax/parser.go:2617
↓ 1 callersFunctionisSpecial
Returns true for those characters that terminate a string of ordinary chars.
syntax/parser.go:2622
↓ 1 callersFunctionisStopperX
Returns true for those characters that terminate a string of ordinary chars.
syntax/parser.go:2627
↓ 1 callersMethodisTrueQuantifier
()
syntax/parser.go:2636
↓ 1 callersFunctionisUnboundedSetLoop
(node *RegexNode)
syntax/prefixanalyzer.go:1341
↓ 1 callersMethodisUseful
()
syntax/optimizations.go:578
↓ 1 callersFunctionisZeroWidthLandmarkGap
(node *RegexNode)
syntax/prefixanalyzer.go:1319
↓ 1 callersFunctionkeepCacheBytes
(maxBytes, actualBytes int)
options.go:89
↓ 1 callersFunctionknownDistinctSets
(set1, set2 *CharSet)
syntax/charclass.go:1183
↓ 1 callersFunctionlandmarkChainDescription
(chain *RequiredLandmarkChain)
syntax/optimizations.go:303
← previousnext →401–500 of 1,027, ranked by callers