summaryrefslogtreecommitdiff
path: root/Userland
diff options
context:
space:
mode:
authorTimothy Flynn <trflynn89@pm.me>2023-02-15 10:15:19 -0500
committerLinus Groh <mail@linusgroh.de>2023-02-16 11:18:53 +0100
commit32a01a60e7cc482c9d2fd837c8d91833c2255740 (patch)
tree4f19b01e578039a5b7c80d25bc3ad1414dc90961 /Userland
parent6ce7ec2eb362da4395151d9aea06db333a071093 (diff)
downloadserenity-32a01a60e7cc482c9d2fd837c8d91833c2255740.zip
LibUnicode: Remove non-iterative text segmentation algorithms
They are now unused.
Diffstat (limited to 'Userland')
-rw-r--r--Userland/Libraries/LibUnicode/Segmentation.h40
1 files changed, 0 insertions, 40 deletions
diff --git a/Userland/Libraries/LibUnicode/Segmentation.h b/Userland/Libraries/LibUnicode/Segmentation.h
index 126e5db78c..95a0ed321a 100644
--- a/Userland/Libraries/LibUnicode/Segmentation.h
+++ b/Userland/Libraries/LibUnicode/Segmentation.h
@@ -12,7 +12,6 @@
#include <AK/IterationDecision.h>
#include <AK/Optional.h>
#include <AK/Types.h>
-#include <AK/Vector.h>
namespace Unicode {
@@ -23,19 +22,6 @@ void for_each_grapheme_segmentation_boundary(Utf16View const&, SegmentationCallb
void for_each_grapheme_segmentation_boundary(Utf32View const&, SegmentationCallback);
template<typename ViewType>
-Vector<size_t> find_grapheme_segmentation_boundaries(ViewType const& view)
-{
- Vector<size_t> boundaries;
-
- for_each_grapheme_segmentation_boundary(view, [&](auto boundary) {
- boundaries.append(boundary);
- return IterationDecision::Continue;
- });
-
- return boundaries;
-}
-
-template<typename ViewType>
Optional<size_t> next_grapheme_segmentation_boundary(ViewType const& view, size_t index)
{
Optional<size_t> result;
@@ -74,19 +60,6 @@ void for_each_word_segmentation_boundary(Utf16View const&, SegmentationCallback)
void for_each_word_segmentation_boundary(Utf32View const&, SegmentationCallback);
template<typename ViewType>
-Vector<size_t> find_word_segmentation_boundaries(ViewType const& view)
-{
- Vector<size_t> boundaries;
-
- for_each_word_segmentation_boundary(view, [&](auto boundary) {
- boundaries.append(boundary);
- return IterationDecision::Continue;
- });
-
- return boundaries;
-}
-
-template<typename ViewType>
Optional<size_t> next_word_segmentation_boundary(ViewType const& view, size_t index)
{
Optional<size_t> result;
@@ -125,19 +98,6 @@ void for_each_sentence_segmentation_boundary(Utf16View const&, SegmentationCallb
void for_each_sentence_segmentation_boundary(Utf32View const&, SegmentationCallback);
template<typename ViewType>
-Vector<size_t> find_sentence_segmentation_boundaries(ViewType const& view)
-{
- Vector<size_t> boundaries;
-
- for_each_sentence_segmentation_boundary(view, [&](auto boundary) {
- boundaries.append(boundary);
- return IterationDecision::Continue;
- });
-
- return boundaries;
-}
-
-template<typename ViewType>
Optional<size_t> next_sentence_segmentation_boundary(ViewType const& view, size_t index)
{
Optional<size_t> result;