git: fffb96e9e514 - main - devel/rapidfuzz-cpp: update 3.0.5 → 3.1.1
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sat, 09 Nov 2024 02:50:39 UTC
The branch main has been updated by yuri: URL: https://cgit.FreeBSD.org/ports/commit/?id=fffb96e9e5148bb7b3471dd6e541750017cd6085 commit fffb96e9e5148bb7b3471dd6e541750017cd6085 Author: Yuri Victorovich <yuri@FreeBSD.org> AuthorDate: 2024-11-09 02:48:50 +0000 Commit: Yuri Victorovich <yuri@FreeBSD.org> CommitDate: 2024-11-09 02:50:29 +0000 devel/rapidfuzz-cpp: update 3.0.5 → 3.1.1 --- devel/rapidfuzz-cpp/Makefile | 3 +- devel/rapidfuzz-cpp/distinfo | 6 +- .../files/patch-bench_bench-jarowinkler.cpp | 14 ---- .../rapidfuzz-cpp/files/patch-bench_bench-lcs.cpp | 14 ---- .../files/patch-bench_bench-levenshtein.cpp | 14 ---- .../files/patch-extras_rapidfuzz__amalgamated.hpp | 53 ------------- ...uzzing_fuzz__damerau__levenshtein__distance.cpp | 33 -------- .../files/patch-fuzzing_fuzz__indel__distance.cpp | 20 ----- .../files/patch-fuzzing_fuzz__indel__editops.cpp | 11 --- .../files/patch-fuzzing_fuzz__jaro__similarity.cpp | 48 ------------ .../files/patch-fuzzing_fuzz__lcs__similarity.cpp | 27 ------- .../patch-fuzzing_fuzz__levenshtein__distance.cpp | 40 ---------- .../patch-fuzzing_fuzz__levenshtein__editops.cpp | 20 ----- .../files/patch-fuzzing_fuzz__osa__distance.cpp | 33 -------- .../rapidfuzz-cpp/files/patch-fuzzing_fuzzing.hpp | 45 ----------- .../files/patch-rapidfuzz_distance.hpp | 53 ------------- devel/rapidfuzz-cpp/files/patch-test_common.hpp | 23 ------ .../files/patch-test_distance_examples_ocr.cpp | 19 ----- .../files/patch-test_distance_examples_ocr.hpp | 12 --- ...t_distance_examples_pythonLevenshteinIssue9.cpp | 20 ----- ...t_distance_examples_pythonLevenshteinIssue9.hpp | 14 ---- .../files/patch-test_distance_tests-Hamming.cpp | 18 ----- .../files/patch-test_distance_tests-Indel.cpp | 11 --- .../patch-test_distance_tests-Levenshtein.cpp | 88 ---------------------- 24 files changed, 4 insertions(+), 635 deletions(-) diff --git a/devel/rapidfuzz-cpp/Makefile b/devel/rapidfuzz-cpp/Makefile index 09ced77a4000..6ddcbfd354ac 100644 --- a/devel/rapidfuzz-cpp/Makefile +++ b/devel/rapidfuzz-cpp/Makefile @@ -1,7 +1,6 @@ PORTNAME= rapidfuzz-cpp DISTVERSIONPREFIX= v -DISTVERSION= 3.0.5 -PORTREVISION= 1 +DISTVERSION= 3.1.1 CATEGORIES= devel MAINTAINER= yuri@FreeBSD.org diff --git a/devel/rapidfuzz-cpp/distinfo b/devel/rapidfuzz-cpp/distinfo index 3e36522fe569..6e7594b40d30 100644 --- a/devel/rapidfuzz-cpp/distinfo +++ b/devel/rapidfuzz-cpp/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1725345171 -SHA256 (rapidfuzz-rapidfuzz-cpp-v3.0.5_GH0.tar.gz) = e32936cc66333a12f659553b5fdd6d0c22257d32ac3b7a806ac9031db8dea5a1 -SIZE (rapidfuzz-rapidfuzz-cpp-v3.0.5_GH0.tar.gz) = 309782 +TIMESTAMP = 1731116280 +SHA256 (rapidfuzz-rapidfuzz-cpp-v3.1.1_GH0.tar.gz) = 5a72811a9f5a890c69cb479551c19517426fb793a10780f136eb482c426ec3c8 +SIZE (rapidfuzz-rapidfuzz-cpp-v3.1.1_GH0.tar.gz) = 310477 diff --git a/devel/rapidfuzz-cpp/files/patch-bench_bench-jarowinkler.cpp b/devel/rapidfuzz-cpp/files/patch-bench_bench-jarowinkler.cpp deleted file mode 100644 index 40fb6f859f8a..000000000000 --- a/devel/rapidfuzz-cpp/files/patch-bench_bench-jarowinkler.cpp +++ /dev/null @@ -1,14 +0,0 @@ ---- bench/bench-jarowinkler.cpp.orig 2024-07-02 14:50:14 UTC -+++ bench/bench-jarowinkler.cpp -@@ -19,9 +19,9 @@ template <typename T> - } - - template <typename T> --std::basic_string<T> str_multiply(std::basic_string<T> a, unsigned int b) -+std::vector<T> str_multiply(std::vector<T> a, unsigned int b) - { -- std::basic_string<T> output; -+ std::vector<T> output; - while (b--) - output += a; - diff --git a/devel/rapidfuzz-cpp/files/patch-bench_bench-lcs.cpp b/devel/rapidfuzz-cpp/files/patch-bench_bench-lcs.cpp deleted file mode 100644 index b75a965d642a..000000000000 --- a/devel/rapidfuzz-cpp/files/patch-bench_bench-lcs.cpp +++ /dev/null @@ -1,14 +0,0 @@ ---- bench/bench-lcs.cpp.orig 2024-07-02 14:50:14 UTC -+++ bench/bench-lcs.cpp -@@ -20,9 +20,9 @@ template <typename T> - } - - template <typename T> --std::basic_string<T> str_multiply(std::basic_string<T> a, unsigned int b) -+std::vector<T> str_multiply(std::vector<T> a, unsigned int b) - { -- std::basic_string<T> output; -+ std::vector<T> output; - while (b--) - output += a; - diff --git a/devel/rapidfuzz-cpp/files/patch-bench_bench-levenshtein.cpp b/devel/rapidfuzz-cpp/files/patch-bench_bench-levenshtein.cpp deleted file mode 100644 index b5c9e6930b71..000000000000 --- a/devel/rapidfuzz-cpp/files/patch-bench_bench-levenshtein.cpp +++ /dev/null @@ -1,14 +0,0 @@ ---- bench/bench-levenshtein.cpp.orig 2024-07-02 14:50:14 UTC -+++ bench/bench-levenshtein.cpp -@@ -19,9 +19,9 @@ template <typename T> - } - - template <typename T> --std::basic_string<T> str_multiply(std::basic_string<T> a, unsigned int b) -+std::vector<T> str_multiply(std::vector<T> a, unsigned int b) - { -- std::basic_string<T> output; -+ std::vector<T> output; - while (b--) - output += a; - diff --git a/devel/rapidfuzz-cpp/files/patch-extras_rapidfuzz__amalgamated.hpp b/devel/rapidfuzz-cpp/files/patch-extras_rapidfuzz__amalgamated.hpp deleted file mode 100644 index f9a80b0e964f..000000000000 --- a/devel/rapidfuzz-cpp/files/patch-extras_rapidfuzz__amalgamated.hpp +++ /dev/null @@ -1,53 +0,0 @@ ---- extras/rapidfuzz_amalgamated.hpp.orig 2024-07-02 14:50:14 UTC -+++ extras/rapidfuzz_amalgamated.hpp -@@ -9152,13 +9152,13 @@ template <typename CharT, typename InputIt1, typename - namespace rapidfuzz { - - template <typename CharT, typename InputIt1, typename InputIt2> --std::basic_string<CharT> editops_apply(const Editops& ops, InputIt1 first1, InputIt1 last1, InputIt2 first2, -- InputIt2 last2) -+std::vector<CharT> editops_apply(const Editops& ops, InputIt1 first1, InputIt1 last1, InputIt2 first2, -+ InputIt2 last2) - { - auto len1 = static_cast<size_t>(std::distance(first1, last1)); - auto len2 = static_cast<size_t>(std::distance(first2, last2)); - -- std::basic_string<CharT> res_str; -+ std::vector<CharT> res_str; - res_str.resize(len1 + len2); - size_t src_pos = 0; - size_t dest_pos = 0; -@@ -9198,20 +9198,20 @@ template <typename CharT, typename Sentence1, typename - } - - template <typename CharT, typename Sentence1, typename Sentence2> --std::basic_string<CharT> editops_apply(const Editops& ops, const Sentence1& s1, const Sentence2& s2) -+std::vector<CharT> editops_apply(const Editops& ops, const Sentence1& s1, const Sentence2& s2) - { - return editops_apply<CharT>(ops, detail::to_begin(s1), detail::to_end(s1), detail::to_begin(s2), - detail::to_end(s2)); - } - - template <typename CharT, typename InputIt1, typename InputIt2> --std::basic_string<CharT> opcodes_apply(const Opcodes& ops, InputIt1 first1, InputIt1 last1, InputIt2 first2, -- InputIt2 last2) -+std::vector<CharT> opcodes_apply(const Opcodes& ops, InputIt1 first1, InputIt1 last1, InputIt2 first2, -+ InputIt2 last2) - { - auto len1 = static_cast<size_t>(std::distance(first1, last1)); - auto len2 = static_cast<size_t>(std::distance(first2, last2)); - -- std::basic_string<CharT> res_str; -+ std::vector<CharT> res_str; - res_str.resize(len1 + len2); - size_t dest_pos = 0; - -@@ -9237,7 +9237,7 @@ template <typename CharT, typename Sentence1, typename - } - - template <typename CharT, typename Sentence1, typename Sentence2> --std::basic_string<CharT> opcodes_apply(const Opcodes& ops, const Sentence1& s1, const Sentence2& s2) -+std::vector<CharT> opcodes_apply(const Opcodes& ops, const Sentence1& s1, const Sentence2& s2) - { - return opcodes_apply<CharT>(ops, detail::to_begin(s1), detail::to_end(s1), detail::to_begin(s2), - detail::to_end(s2)); diff --git a/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__damerau__levenshtein__distance.cpp b/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__damerau__levenshtein__distance.cpp deleted file mode 100644 index 5b21c94399a4..000000000000 --- a/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__damerau__levenshtein__distance.cpp +++ /dev/null @@ -1,33 +0,0 @@ ---- fuzzing/fuzz_damerau_levenshtein_distance.cpp.orig 2024-07-02 14:50:14 UTC -+++ fuzzing/fuzz_damerau_levenshtein_distance.cpp -@@ -8,8 +8,8 @@ - #include <stdexcept> - #include <string> - --void validate_distance(size_t reference_dist, const std::basic_string<uint8_t>& s1, -- const std::basic_string<uint8_t>& s2, size_t score_cutoff) -+void validate_distance(size_t reference_dist, const std::vector<uint8_t>& s1, -+ const std::vector<uint8_t>& s2, size_t score_cutoff) - { - if (reference_dist > score_cutoff) reference_dist = score_cutoff + 1; - -@@ -26,7 +26,7 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* d - - extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) - { -- std::basic_string<uint8_t> s1, s2; -+ std::vector<uint8_t> s1, s2; - if (!extract_strings(data, size, s1, s2)) return 0; - - size_t reference_dist = rapidfuzz_reference::damerau_levenshtein_distance(s1, s2); -@@ -40,8 +40,8 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* d - - /* test long sequences */ - for (unsigned int i = 2; i < 9; ++i) { -- std::basic_string<uint8_t> s1_ = str_multiply(s1, pow<size_t>(2, i)); -- std::basic_string<uint8_t> s2_ = str_multiply(s2, pow<size_t>(2, i)); -+ std::vector<uint8_t> s1_ = str_multiply(s1, pow<size_t>(2, i)); -+ std::vector<uint8_t> s2_ = str_multiply(s2, pow<size_t>(2, i)); - - if (s1_.size() > 10000 || s2_.size() > 10000) break; - diff --git a/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__indel__distance.cpp b/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__indel__distance.cpp deleted file mode 100644 index f398a1eae0a3..000000000000 --- a/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__indel__distance.cpp +++ /dev/null @@ -1,20 +0,0 @@ ---- fuzzing/fuzz_indel_distance.cpp.orig 2024-07-02 14:50:14 UTC -+++ fuzzing/fuzz_indel_distance.cpp -@@ -8,7 +8,7 @@ - #include <stdexcept> - #include <string> - --void validate_distance(const std::basic_string<uint8_t>& s1, const std::basic_string<uint8_t>& s2, -+void validate_distance(const std::vector<uint8_t>& s1, const std::vector<uint8_t>& s2, - size_t score_cutoff) - { - auto dist = rapidfuzz::indel_distance(s1, s2, score_cutoff); -@@ -25,7 +25,7 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* d - - extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) - { -- std::basic_string<uint8_t> s1, s2; -+ std::vector<uint8_t> s1, s2; - if (!extract_strings(data, size, s1, s2)) return 0; - - validate_distance(s1, s2, 0); diff --git a/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__indel__editops.cpp b/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__indel__editops.cpp deleted file mode 100644 index 5c9003765235..000000000000 --- a/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__indel__editops.cpp +++ /dev/null @@ -1,11 +0,0 @@ ---- fuzzing/fuzz_indel_editops.cpp.orig 2024-07-02 14:50:14 UTC -+++ fuzzing/fuzz_indel_editops.cpp -@@ -9,7 +9,7 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* d - - extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) - { -- std::basic_string<uint8_t> s1, s2; -+ std::vector<uint8_t> s1, s2; - if (!extract_strings(data, size, s1, s2)) return 0; - - size_t score = rapidfuzz_reference::indel_distance(s1, s2); diff --git a/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__jaro__similarity.cpp b/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__jaro__similarity.cpp deleted file mode 100644 index d3ceee29e568..000000000000 --- a/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__jaro__similarity.cpp +++ /dev/null @@ -1,48 +0,0 @@ ---- fuzzing/fuzz_jaro_similarity.cpp.orig 2024-07-02 14:50:14 UTC -+++ fuzzing/fuzz_jaro_similarity.cpp -@@ -14,7 +14,7 @@ template <size_t MaxLen> - } - - template <size_t MaxLen> --void validate_simd(const std::basic_string<uint8_t>& s1, const std::basic_string<uint8_t>& s2) -+void validate_simd(const std::vector<uint8_t>& s1, const std::vector<uint8_t>& s2) - { - #ifdef RAPIDFUZZ_SIMD - size_t count = s1.size() / MaxLen + ((s1.size() % MaxLen) != 0); -@@ -22,7 +22,7 @@ void validate_simd(const std::basic_string<uint8_t>& s - - rapidfuzz::experimental::MultiJaro<MaxLen> scorer(count); - -- std::vector<std::basic_string<uint8_t>> strings; -+ std::vector<std::vector<uint8_t>> strings; - - for (auto it1 = s1.begin(); it1 != s1.end(); it1 += MaxLen) { - if (std::distance(it1, s1.end()) < static_cast<ptrdiff_t>(MaxLen)) { -@@ -59,7 +59,7 @@ void validate_simd(const std::basic_string<uint8_t>& s - #endif - } - --void validate_distance(const std::basic_string<uint8_t>& s1, const std::basic_string<uint8_t>& s2) -+void validate_distance(const std::vector<uint8_t>& s1, const std::vector<uint8_t>& s2) - { - double reference_sim = rapidfuzz_reference::jaro_similarity(s1, s2); - double sim = rapidfuzz::jaro_similarity(s1, s2); -@@ -80,15 +80,15 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* d - - extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) - { -- std::basic_string<uint8_t> s1, s2; -+ std::vector<uint8_t> s1, s2; - if (!extract_strings(data, size, s1, s2)) return 0; - - validate_distance(s1, s2); - - /* test long sequences */ - for (unsigned int i = 2; i < 9; ++i) { -- std::basic_string<uint8_t> s1_ = str_multiply(s1, pow<size_t>(2, i)); -- std::basic_string<uint8_t> s2_ = str_multiply(s2, pow<size_t>(2, i)); -+ std::vector<uint8_t> s1_ = str_multiply(s1, pow<size_t>(2, i)); -+ std::vector<uint8_t> s2_ = str_multiply(s2, pow<size_t>(2, i)); - - if (s1_.size() > 10000 || s2_.size() > 10000) break; - diff --git a/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__lcs__similarity.cpp b/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__lcs__similarity.cpp deleted file mode 100644 index 8ec292fd13d7..000000000000 --- a/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__lcs__similarity.cpp +++ /dev/null @@ -1,27 +0,0 @@ ---- fuzzing/fuzz_lcs_similarity.cpp.orig 2024-07-02 14:50:14 UTC -+++ fuzzing/fuzz_lcs_similarity.cpp -@@ -9,13 +9,13 @@ template <size_t MaxLen> - #include <string> - - template <size_t MaxLen> --void validate_simd(const std::basic_string<uint8_t>& s1, const std::basic_string<uint8_t>& s2) -+void validate_simd(const std::vector<uint8_t>& s1, const std::vector<uint8_t>& s2) - { - #ifdef RAPIDFUZZ_SIMD - size_t count = s1.size() / MaxLen + ((s1.size() % MaxLen) != 0); - rapidfuzz::experimental::MultiLCSseq<MaxLen> scorer(count); - -- std::vector<std::basic_string<uint8_t>> strings; -+ std::vector<std::vector<uint8_t>> strings; - - for (auto it1 = s1.begin(); it1 != s1.end(); it1 += MaxLen) { - if (std::distance(it1, s1.end()) < static_cast<ptrdiff_t>(MaxLen)) { -@@ -51,7 +51,7 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* d - - extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) - { -- std::basic_string<uint8_t> s1, s2; -+ std::vector<uint8_t> s1, s2; - if (!extract_strings(data, size, s1, s2)) { - return 0; - } diff --git a/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__levenshtein__distance.cpp b/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__levenshtein__distance.cpp deleted file mode 100644 index bcc00b61344e..000000000000 --- a/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__levenshtein__distance.cpp +++ /dev/null @@ -1,40 +0,0 @@ ---- fuzzing/fuzz_levenshtein_distance.cpp.orig 2024-07-02 14:50:14 UTC -+++ fuzzing/fuzz_levenshtein_distance.cpp -@@ -9,7 +9,7 @@ template <size_t MaxLen> - #include <string> - - template <size_t MaxLen> --void validate_simd(const std::basic_string<uint8_t>& s1, const std::basic_string<uint8_t>& s2) -+void validate_simd(const std::vector<uint8_t>& s1, const std::vector<uint8_t>& s2) - { - #ifdef RAPIDFUZZ_SIMD - size_t count = s1.size() / MaxLen + ((s1.size() % MaxLen) != 0); -@@ -17,7 +17,7 @@ void validate_simd(const std::basic_string<uint8_t>& s - - rapidfuzz::experimental::MultiLevenshtein<MaxLen> scorer(count); - -- std::vector<std::basic_string<uint8_t>> strings; -+ std::vector<std::vector<uint8_t>> strings; - - for (auto it1 = s1.begin(); it1 != s1.end(); it1 += MaxLen) { - if (std::distance(it1, s1.end()) < static_cast<ptrdiff_t>(MaxLen)) { -@@ -52,8 +52,8 @@ void validate_simd(const std::basic_string<uint8_t>& s - #endif - } - --void validate_distance(size_t reference_dist, const std::basic_string<uint8_t>& s1, -- const std::basic_string<uint8_t>& s2, size_t score_cutoff) -+void validate_distance(size_t reference_dist, const std::vector<uint8_t>& s1, -+ const std::vector<uint8_t>& s2, size_t score_cutoff) - { - if (reference_dist > score_cutoff) reference_dist = score_cutoff + 1; - -@@ -75,7 +75,7 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* d - - extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) - { -- std::basic_string<uint8_t> s1, s2; -+ std::vector<uint8_t> s1, s2; - if (!extract_strings(data, size, s1, s2)) return 0; - - size_t reference_dist = rapidfuzz_reference::levenshtein_distance(s1, s2); diff --git a/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__levenshtein__editops.cpp b/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__levenshtein__editops.cpp deleted file mode 100644 index 74eb0be61c4c..000000000000 --- a/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__levenshtein__editops.cpp +++ /dev/null @@ -1,20 +0,0 @@ ---- fuzzing/fuzz_levenshtein_editops.cpp.orig 2024-07-02 14:50:14 UTC -+++ fuzzing/fuzz_levenshtein_editops.cpp -@@ -7,7 +7,7 @@ - #include <stdexcept> - #include <string> - --void validate_editops(const std::basic_string<uint8_t>& s1, const std::basic_string<uint8_t>& s2, -+void validate_editops(const std::vector<uint8_t>& s1, const std::vector<uint8_t>& s2, - size_t score, size_t score_hint = std::numeric_limits<size_t>::max()) - { - rapidfuzz::Editops ops = rapidfuzz::levenshtein_editops(s1, s2, score_hint); -@@ -17,7 +17,7 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* d - - extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) - { -- std::basic_string<uint8_t> s1, s2; -+ std::vector<uint8_t> s1, s2; - if (!extract_strings(data, size, s1, s2)) return 0; - - /* hirschbergs algorithm is only used for very long sequences which are apparently not generated a lot by diff --git a/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__osa__distance.cpp b/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__osa__distance.cpp deleted file mode 100644 index b199831b77ed..000000000000 --- a/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzz__osa__distance.cpp +++ /dev/null @@ -1,33 +0,0 @@ ---- fuzzing/fuzz_osa_distance.cpp.orig 2024-07-02 14:50:14 UTC -+++ fuzzing/fuzz_osa_distance.cpp -@@ -8,8 +8,8 @@ - #include <stdexcept> - #include <string> - --void validate_distance(size_t reference_dist, const std::basic_string<uint8_t>& s1, -- const std::basic_string<uint8_t>& s2, size_t score_cutoff) -+void validate_distance(size_t reference_dist, const std::vector<uint8_t>& s1, -+ const std::vector<uint8_t>& s2, size_t score_cutoff) - { - if (reference_dist > score_cutoff) reference_dist = score_cutoff + 1; - -@@ -26,7 +26,7 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* d - - extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) - { -- std::basic_string<uint8_t> s1, s2; -+ std::vector<uint8_t> s1, s2; - if (!extract_strings(data, size, s1, s2)) return 0; - - size_t reference_dist = rapidfuzz_reference::osa_distance(s1, s2); -@@ -40,8 +40,8 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* d - - /* test long sequences */ - for (unsigned int i = 2; i < 9; ++i) { -- std::basic_string<uint8_t> s1_ = str_multiply(s1, pow<size_t>(2, i)); -- std::basic_string<uint8_t> s2_ = str_multiply(s2, pow<size_t>(2, i)); -+ std::vector<uint8_t> s1_ = str_multiply(s1, pow<size_t>(2, i)); -+ std::vector<uint8_t> s2_ = str_multiply(s2, pow<size_t>(2, i)); - - if (s1_.size() > 10000 || s2_.size() > 10000) break; - diff --git a/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzzing.hpp b/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzzing.hpp deleted file mode 100644 index 1f22c173aca1..000000000000 --- a/devel/rapidfuzz-cpp/files/patch-fuzzing_fuzzing.hpp +++ /dev/null @@ -1,45 +0,0 @@ ---- fuzzing/fuzzing.hpp.orig 2024-07-02 14:50:14 UTC -+++ fuzzing/fuzzing.hpp -@@ -3,8 +3,8 @@ - #include <rapidfuzz/distance/Levenshtein.hpp> - #include <string> - --static inline bool extract_strings(const uint8_t* data, size_t size, std::basic_string<uint8_t>& s1, -- std::basic_string<uint8_t>& s2) -+static inline bool extract_strings(const uint8_t* data, size_t size, std::vector<uint8_t>& s1, -+ std::vector<uint8_t>& s2) - { - if (size <= sizeof(uint32_t)) { - return false; -@@ -17,8 +17,8 @@ static inline bool extract_strings(const uint8_t* data - - data += sizeof(len1); - size -= sizeof(len1); -- s1 = std::basic_string<uint8_t>(data, len1); -- s2 = std::basic_string<uint8_t>(data + len1, size - len1); -+ s1 = std::vector<uint8_t>(data, len1); -+ s2 = std::vector<uint8_t>(data + len1, size - len1); - return true; - } - -@@ -36,9 +36,9 @@ template <typename T> - } - - template <typename T> --std::basic_string<T> str_multiply(std::basic_string<T> a, size_t b) -+std::vector<T> str_multiply(std::vector<T> a, size_t b) - { -- std::basic_string<T> output; -+ std::vector<T> output; - while (b--) - output += a; - -@@ -46,7 +46,7 @@ template <typename T> - } - - template <typename T> --void print_seq(const std::string& name, const std::basic_string<T>& seq) -+void print_seq(const std::string& name, const std::vector<T>& seq) - { - std::cout << name << " len: " << seq.size() << " content: "; - for (const auto& ch : seq) diff --git a/devel/rapidfuzz-cpp/files/patch-rapidfuzz_distance.hpp b/devel/rapidfuzz-cpp/files/patch-rapidfuzz_distance.hpp deleted file mode 100644 index 691c972a8753..000000000000 --- a/devel/rapidfuzz-cpp/files/patch-rapidfuzz_distance.hpp +++ /dev/null @@ -1,53 +0,0 @@ ---- rapidfuzz/distance.hpp.orig 2024-07-02 14:50:14 UTC -+++ rapidfuzz/distance.hpp -@@ -16,13 +16,13 @@ template <typename CharT, typename InputIt1, typename - namespace rapidfuzz { - - template <typename CharT, typename InputIt1, typename InputIt2> --std::basic_string<CharT> editops_apply(const Editops& ops, InputIt1 first1, InputIt1 last1, InputIt2 first2, -- InputIt2 last2) -+std::vector<CharT> editops_apply(const Editops& ops, InputIt1 first1, InputIt1 last1, InputIt2 first2, -+ InputIt2 last2) - { - auto len1 = static_cast<size_t>(std::distance(first1, last1)); - auto len2 = static_cast<size_t>(std::distance(first2, last2)); - -- std::basic_string<CharT> res_str; -+ std::vector<CharT> res_str; - res_str.resize(len1 + len2); - size_t src_pos = 0; - size_t dest_pos = 0; -@@ -62,20 +62,20 @@ template <typename CharT, typename Sentence1, typename - } - - template <typename CharT, typename Sentence1, typename Sentence2> --std::basic_string<CharT> editops_apply(const Editops& ops, const Sentence1& s1, const Sentence2& s2) -+std::vector<CharT> editops_apply(const Editops& ops, const Sentence1& s1, const Sentence2& s2) - { - return editops_apply<CharT>(ops, detail::to_begin(s1), detail::to_end(s1), detail::to_begin(s2), - detail::to_end(s2)); - } - - template <typename CharT, typename InputIt1, typename InputIt2> --std::basic_string<CharT> opcodes_apply(const Opcodes& ops, InputIt1 first1, InputIt1 last1, InputIt2 first2, -- InputIt2 last2) -+std::vector<CharT> opcodes_apply(const Opcodes& ops, InputIt1 first1, InputIt1 last1, InputIt2 first2, -+ InputIt2 last2) - { - auto len1 = static_cast<size_t>(std::distance(first1, last1)); - auto len2 = static_cast<size_t>(std::distance(first2, last2)); - -- std::basic_string<CharT> res_str; -+ std::vector<CharT> res_str; - res_str.resize(len1 + len2); - size_t dest_pos = 0; - -@@ -101,7 +101,7 @@ template <typename CharT, typename Sentence1, typename - } - - template <typename CharT, typename Sentence1, typename Sentence2> --std::basic_string<CharT> opcodes_apply(const Opcodes& ops, const Sentence1& s1, const Sentence2& s2) -+std::vector<CharT> opcodes_apply(const Opcodes& ops, const Sentence1& s1, const Sentence2& s2) - { - return opcodes_apply<CharT>(ops, detail::to_begin(s1), detail::to_end(s1), detail::to_begin(s2), - detail::to_end(s2)); diff --git a/devel/rapidfuzz-cpp/files/patch-test_common.hpp b/devel/rapidfuzz-cpp/files/patch-test_common.hpp deleted file mode 100644 index 796389a0213d..000000000000 --- a/devel/rapidfuzz-cpp/files/patch-test_common.hpp +++ /dev/null @@ -1,23 +0,0 @@ ---- test/common.hpp.orig 2024-07-02 14:50:14 UTC -+++ test/common.hpp -@@ -59,9 +59,18 @@ template <typename T> - }; - - template <typename T> --std::basic_string<T> str_multiply(std::basic_string<T> a, size_t b) -+std::vector<T> str_multiply(std::vector<T> a, size_t b) - { -- std::basic_string<T> output; -+ std::vector<T> output; -+ while (b--) -+ output.insert(output.end(), a.begin(), a.end()); -+ -+ return output; -+} -+ -+std::string str_multiply(std::string a, size_t b) -+{ -+ std::string output; - while (b--) - output += a; - diff --git a/devel/rapidfuzz-cpp/files/patch-test_distance_examples_ocr.cpp b/devel/rapidfuzz-cpp/files/patch-test_distance_examples_ocr.cpp deleted file mode 100644 index ef9f4ff5a6dd..000000000000 --- a/devel/rapidfuzz-cpp/files/patch-test_distance_examples_ocr.cpp +++ /dev/null @@ -1,19 +0,0 @@ ---- test/distance/examples/ocr.cpp.orig 2024-07-02 14:50:14 UTC -+++ test/distance/examples/ocr.cpp -@@ -1,6 +1,6 @@ - #include "ocr.hpp" - --std::basic_string<uint8_t> ocr_example1 = { -+std::vector<uint8_t> ocr_example1 = { - 22, 18, 27, 22, 8, 23, 23, 18, 29, 27, 8, 23, 28, 18, 29, 27, 8, 24, 18, 27, 31, - 8, 24, 18, 29, 22, 8, 24, 24, 18, 31, 24, 8, 23, 24, 18, 25, 25, 8, 24, 26, 18, - 30, 24, 8, 23, 26, 18, 25, 30, 8, 29, 11, 2, 22, 18, 27, 22, 8, 23, 23, 18, 29, -@@ -5075,7 +5075,7 @@ std::basic_string<uint8_t> ocr_example1 = { - 27, 8, 29, 7, 8, 39, 61, 80, 8, 27, 28, 22, 21, 8, 65, 79, 68, 61, 72, 81, 65, - 74, 2}; - --std::basic_string<uint8_t> ocr_example2 = { -+std::vector<uint8_t> ocr_example2 = { - 22, 18, 27, 22, 8, 23, 23, 18, 29, 27, 8, 23, 28, 18, 29, 27, 8, 24, 18, 27, 31, - 8, 24, 18, 29, 22, 8, 24, 24, 18, 31, 24, 8, 23, 24, 18, 25, 25, 8, 24, 26, 18, - 30, 24, 8, 23, 26, 18, 25, 30, 11, 2, 22, 18, 27, 22, 8, 23, 23, 18, 29, 27, 8, diff --git a/devel/rapidfuzz-cpp/files/patch-test_distance_examples_ocr.hpp b/devel/rapidfuzz-cpp/files/patch-test_distance_examples_ocr.hpp deleted file mode 100644 index 4d17479472e0..000000000000 --- a/devel/rapidfuzz-cpp/files/patch-test_distance_examples_ocr.hpp +++ /dev/null @@ -1,12 +0,0 @@ ---- test/distance/examples/ocr.hpp.orig 2024-07-02 14:50:14 UTC -+++ test/distance/examples/ocr.hpp -@@ -1,6 +1,6 @@ - #pragma once - #include <cstdint> --#include <string> -+#include <vector> - --extern std::basic_string<uint8_t> ocr_example1; --extern std::basic_string<uint8_t> ocr_example2; -+extern std::vector<uint8_t> ocr_example1; -+extern std::vector<uint8_t> ocr_example2; diff --git a/devel/rapidfuzz-cpp/files/patch-test_distance_examples_pythonLevenshteinIssue9.cpp b/devel/rapidfuzz-cpp/files/patch-test_distance_examples_pythonLevenshteinIssue9.cpp deleted file mode 100644 index 8a84f4847734..000000000000 --- a/devel/rapidfuzz-cpp/files/patch-test_distance_examples_pythonLevenshteinIssue9.cpp +++ /dev/null @@ -1,20 +0,0 @@ ---- test/distance/examples/pythonLevenshteinIssue9.cpp.orig 2024-07-02 14:50:14 UTC -+++ test/distance/examples/pythonLevenshteinIssue9.cpp -@@ -2,7 +2,7 @@ namespace pythonLevenshteinIssue9 { - - namespace pythonLevenshteinIssue9 { - --std::basic_string<uint8_t> example1 = { -+std::vector<uint8_t> example1 = { - 8, 14, 4, 2, 3, 7, 15, 6, 4, 5, 8, 2, 3, 4, 5, 6, 7, 8, 9, 10, 2, 10, 11, 12, 13, 8, - 2, 8, 14, 4, 2, 3, 7, 15, 6, 4, 5, 8, 6, 7, 16, 7, 13, 17, 2, 4, 16, 14, 7, 14, 18, 19, - 8, 20, 14, 4, 21, 13, 20, 22, 8, 2, 3, 4, 5, 6, 20, 8, 9, 10, 2, 10, 11, 12, 13, 8, 18, 14, -@@ -206,7 +206,7 @@ std::basic_string<uint8_t> example1 = { - 9, 8, 6, 7, 3, 7, 23, 4, 41, 7, 51, 8, 48, 69, 43, 6, 4, 9, 11, 20, 2, 13, 32, 5, 8, 18, - 16}; - --std::basic_string<uint8_t> example2 = { -+std::vector<uint8_t> example2 = { - 3, 4, 5, 6, 7, 8, 9, 10, 2, 10, 11, 12, 13, 8, 2, 8, 41, 7, 9, 7, 13, 3, 18, 10, 5, 2, - 4, 16, 14, 7, 14, 18, 19, 8, 20, 14, 4, 21, 13, 20, 22, 8, 2, 3, 4, 5, 6, 20, 8, 9, 10, 2, - 10, 11, 12, 13, 8, 18, 14, 10, 7, 23, 17, 13, 4, 8, 11, 4, 14, 8, 15, 7, 12, 8, 14, 18, 16, 7, diff --git a/devel/rapidfuzz-cpp/files/patch-test_distance_examples_pythonLevenshteinIssue9.hpp b/devel/rapidfuzz-cpp/files/patch-test_distance_examples_pythonLevenshteinIssue9.hpp deleted file mode 100644 index 5c6c7a97e615..000000000000 --- a/devel/rapidfuzz-cpp/files/patch-test_distance_examples_pythonLevenshteinIssue9.hpp +++ /dev/null @@ -1,14 +0,0 @@ ---- test/distance/examples/pythonLevenshteinIssue9.hpp.orig 2024-07-02 14:50:14 UTC -+++ test/distance/examples/pythonLevenshteinIssue9.hpp -@@ -1,8 +1,8 @@ - #pragma once - #include <cstdint> --#include <string> -+#include <vector> - - namespace pythonLevenshteinIssue9 { --extern std::basic_string<uint8_t> example1; --extern std::basic_string<uint8_t> example2; -+extern std::vector<uint8_t> example1; -+extern std::vector<uint8_t> example2; - } // namespace pythonLevenshteinIssue9 diff --git a/devel/rapidfuzz-cpp/files/patch-test_distance_tests-Hamming.cpp b/devel/rapidfuzz-cpp/files/patch-test_distance_tests-Hamming.cpp deleted file mode 100644 index fc4ebde2d4ff..000000000000 --- a/devel/rapidfuzz-cpp/files/patch-test_distance_tests-Hamming.cpp +++ /dev/null @@ -1,18 +0,0 @@ ---- test/distance/tests-Hamming.cpp.orig 2024-07-02 14:50:14 UTC -+++ test/distance/tests-Hamming.cpp -@@ -110,13 +110,13 @@ TEST_CASE("Hamming_editops") - - { - rapidfuzz::Editops ops = rapidfuzz::hamming_editops(s, d); -- REQUIRE(d == rapidfuzz::editops_apply<char>(ops, s, d)); -+ REQUIRE(std::vector<char>{d.begin(), d.end()} == rapidfuzz::editops_apply<char>(ops, s, d)); - REQUIRE(ops.get_src_len() == s.size()); - REQUIRE(ops.get_dest_len() == d.size()); - } - { - rapidfuzz::Editops ops = rapidfuzz::hamming_editops(d, s); -- REQUIRE(s == rapidfuzz::editops_apply<char>(ops, d, s)); -+ REQUIRE(std::vector<char>{s.begin(), s.end()} == rapidfuzz::editops_apply<char>(ops, d, s)); - REQUIRE(ops.get_src_len() == d.size()); - REQUIRE(ops.get_dest_len() == s.size()); - } diff --git a/devel/rapidfuzz-cpp/files/patch-test_distance_tests-Indel.cpp b/devel/rapidfuzz-cpp/files/patch-test_distance_tests-Indel.cpp deleted file mode 100644 index 7be40d59f043..000000000000 --- a/devel/rapidfuzz-cpp/files/patch-test_distance_tests-Indel.cpp +++ /dev/null @@ -1,11 +0,0 @@ ---- test/distance/tests-Indel.cpp.orig 2024-07-02 14:50:14 UTC -+++ test/distance/tests-Indel.cpp -@@ -277,7 +277,7 @@ TEST_CASE("Indel") - REQUIRE(indel_distance(s1, s2) == 231); - - rapidfuzz::Editops ops = rapidfuzz::indel_editops(s1, s2); -- REQUIRE(s2 == rapidfuzz::editops_apply<char>(ops, s1, s2)); -+ REQUIRE(std::vector<char>{s2.begin(), s2.end()} == rapidfuzz::editops_apply<char>(ops, s1, s2)); - } - } - } diff --git a/devel/rapidfuzz-cpp/files/patch-test_distance_tests-Levenshtein.cpp b/devel/rapidfuzz-cpp/files/patch-test_distance_tests-Levenshtein.cpp deleted file mode 100644 index 513a15ffd91f..000000000000 --- a/devel/rapidfuzz-cpp/files/patch-test_distance_tests-Levenshtein.cpp +++ /dev/null @@ -1,88 +0,0 @@ ---- test/distance/tests-Levenshtein.cpp.orig 2024-07-02 14:50:14 UTC -+++ test/distance/tests-Levenshtein.cpp -@@ -63,9 +63,9 @@ template <typename T> - } - - template <typename T> --std::basic_string<T> get_subsequence(const std::basic_string<T>& s, ptrdiff_t pos, ptrdiff_t len) -+std::vector<T> get_subsequence(const std::vector<T>& s, ptrdiff_t pos, ptrdiff_t len) - { -- return std::basic_string<T>(std::begin(s) + pos, std::begin(s) + pos + len); -+ return std::vector<T>(std::begin(s) + pos, std::begin(s) + pos + len); - } - - template <typename Sentence1, typename Sentence2> -@@ -233,7 +233,7 @@ TEST_CASE("Levenshtein_editops") - std::string d = "XYZLorem ABC iPsum"; - - rapidfuzz::Editops ops = rapidfuzz::levenshtein_editops(s, d); -- REQUIRE(d == rapidfuzz::editops_apply<char>(ops, s, d)); -+ REQUIRE(std::vector<char>{d.begin(), d.end()} == rapidfuzz::editops_apply<char>(ops, s, d)); - REQUIRE(ops.get_src_len() == s.size()); - REQUIRE(ops.get_dest_len() == d.size()); - } -@@ -293,21 +293,21 @@ TEST_CASE("Levenshtein_editops[fuzzing_regressions]") - std::string s1 = "b"; - std::string s2 = "aaaaaaaaaaaaaaaabbaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"; - rapidfuzz::Editops ops = rapidfuzz::levenshtein_editops(s1, s2); -- REQUIRE(s2 == rapidfuzz::editops_apply<char>(ops, s1, s2)); -+ REQUIRE(std::vector<char>{s2.begin(), s2.end()} == rapidfuzz::editops_apply<char>(ops, s1, s2)); - } - - { - std::string s1 = "aa"; - std::string s2 = "abb"; - rapidfuzz::Editops ops = rapidfuzz::levenshtein_editops(s1, s2); -- REQUIRE(s2 == rapidfuzz::editops_apply<char>(ops, s1, s2)); -+ REQUIRE(std::vector<char>{s2.begin(), s2.end()} == rapidfuzz::editops_apply<char>(ops, s1, s2)); - } - - { - std::string s1 = str_multiply(std::string("abb"), 8 * 64); - std::string s2 = str_multiply(std::string("ccccca"), 8 * 64); - rapidfuzz::Editops ops = rapidfuzz::levenshtein_editops(s1, s2); -- REQUIRE(s2 == rapidfuzz::editops_apply<char>(ops, s1, s2)); -+ REQUIRE(std::vector<char>{s2.begin(), s2.end()} == rapidfuzz::editops_apply<char>(ops, s1, s2)); - } - } - -@@ -352,7 +352,7 @@ TEST_CASE("Levenshtein small band") - rapidfuzz::Editops ops1; - rapidfuzz::detail::levenshtein_align(ops1, rapidfuzz::detail::Range(s1), - rapidfuzz::detail::Range(s2)); -- REQUIRE(s2 == rapidfuzz::editops_apply<char>(ops1, s1, s2)); -+ REQUIRE(std::vector<char>{s2.begin(), s2.end()} == rapidfuzz::editops_apply<char>(ops1, s1, s2)); - rapidfuzz::Editops ops2; - rapidfuzz::detail::levenshtein_align(ops2, rapidfuzz::detail::Range(s1), rapidfuzz::detail::Range(s2), - ops1.size()); -@@ -400,7 +400,7 @@ TEST_CASE("Levenshtein small band") - rapidfuzz::Editops ops1; - rapidfuzz::detail::levenshtein_align(ops1, rapidfuzz::detail::Range(s1), - rapidfuzz::detail::Range(s2)); -- REQUIRE(s2 == rapidfuzz::editops_apply<char>(ops1, s1, s2)); -+ REQUIRE(std::vector<char>{s2.begin(), s2.end()} == rapidfuzz::editops_apply<char>(ops1, s1, s2)); - rapidfuzz::Editops ops2; - rapidfuzz::detail::levenshtein_align(ops2, rapidfuzz::detail::Range(s1), rapidfuzz::detail::Range(s2), - ops1.size()); -@@ -416,8 +416,8 @@ TEST_CASE("Levenshtein large band (python-Levenshtein - REQUIRE(example2.size() == 5569); - - { -- std::basic_string<uint8_t> s1 = get_subsequence(example1, 3718, 1509); -- std::basic_string<uint8_t> s2 = get_subsequence(example2, 2784, 2785); -+ std::vector<uint8_t> s1 = get_subsequence(example1, 3718, 1509); -+ std::vector<uint8_t> s2 = get_subsequence(example2, 2784, 2785); - - REQUIRE(rapidfuzz::levenshtein_distance(s1, s2) == 1587); - -@@ -440,8 +440,8 @@ TEST_CASE("Levenshtein large band (ocr example)") - REQUIRE(ocr_example2.size() == 107244); - - { -- std::basic_string<uint8_t> s1 = get_subsequence(ocr_example1, 51, 6541); -- std::basic_string<uint8_t> s2 = get_subsequence(ocr_example2, 51, 6516); -+ std::vector<uint8_t> s1 = get_subsequence(ocr_example1, 51, 6541); -+ std::vector<uint8_t> s2 = get_subsequence(ocr_example2, 51, 6516); - - rapidfuzz::Editops ops1; - rapidfuzz::detail::levenshtein_align(ops1, rapidfuzz::detail::Range(s1),