@@ -630,7 +630,7 @@ factorize(CheckedIndexer<char_type> needle,
630
630
* @tparam char_type Type of the characters in the string.
631
631
*/
632
632
template <typename char_type>
633
- struct search_prep_data {
633
+ struct prework {
634
634
CheckedIndexer<char_type> needle; // /< Indexer for the needle (substring).
635
635
Py_ssize_t len_needle; // /< Length of the needle.
636
636
Py_ssize_t cut; // /< Critical factorization cut point.
@@ -660,7 +660,7 @@ struct search_prep_data {
660
660
template <typename char_type>
661
661
static void
662
662
preprocess (CheckedIndexer<char_type> needle, Py_ssize_t len_needle,
663
- search_prep_data <char_type> *p)
663
+ prework <char_type> *p)
664
664
{
665
665
// Store the needle and its length, find the cut point and period.
666
666
p->needle = needle;
@@ -743,7 +743,7 @@ preprocess(CheckedIndexer<char_type> needle, Py_ssize_t len_needle,
743
743
template <typename char_type>
744
744
static Py_ssize_t
745
745
two_way (CheckedIndexer<char_type> haystack, Py_ssize_t len_haystack,
746
- search_prep_data <char_type> *p)
746
+ prework <char_type> *p)
747
747
{
748
748
// Initialize key variables for search.
749
749
const Py_ssize_t len_needle = p->len_needle ;
@@ -901,7 +901,7 @@ two_way_find(CheckedIndexer<char_type> haystack, Py_ssize_t len_haystack,
901
901
CheckedIndexer<char_type> needle, Py_ssize_t len_needle)
902
902
{
903
903
LOG (" ###### Finding \" %s\" in \" %s\" .\n " , needle, haystack);
904
- search_prep_data <char_type> p;
904
+ prework <char_type> p;
905
905
preprocess (needle, len_needle, &p);
906
906
return two_way (haystack, len_haystack, &p);
907
907
}
@@ -931,7 +931,7 @@ two_way_count(CheckedIndexer<char_type> haystack, Py_ssize_t len_haystack,
931
931
Py_ssize_t max_count)
932
932
{
933
933
LOG (" ###### Counting \" %s\" in \" %s\" .\n " , needle, haystack);
934
- search_prep_data <char_type> p;
934
+ prework <char_type> p;
935
935
preprocess (needle, len_needle, &p);
936
936
Py_ssize_t index = 0 , count = 0 ;
937
937
while (1 ) {
0 commit comments