#ifdef UNSAFE_BUFFERS_BUILD
#pragma allow_unsafe_buffers
#endif
#include "third_party/blink/renderer/core/editing/state_machines/state_machine_test_util.h"
#include <algorithm>
#include "third_party/blink/renderer/core/editing/state_machines/backward_grapheme_boundary_state_machine.h"
#include "third_party/blink/renderer/core/editing/state_machines/forward_grapheme_boundary_state_machine.h"
#include "third_party/blink/renderer/core/editing/state_machines/text_segmentation_machine_state.h"
#include "third_party/blink/renderer/platform/wtf/text/string_builder.h"
namespace blink {
namespace {
char MachineStateToChar(TextSegmentationMachineState state) { … }
Vector<UChar> CodePointsToCodeUnits(const Vector<UChar32>& code_points) { … }
template <typename StateMachine>
String ProcessSequence(StateMachine* machine,
const Vector<UChar32>& preceding,
const Vector<UChar32>& following) { … }
}
String GraphemeStateMachineTestBase::ProcessSequenceBackward(
BackwardGraphemeBoundaryStateMachine* machine,
const Vector<UChar32>& preceding) { … }
String GraphemeStateMachineTestBase::ProcessSequenceForward(
ForwardGraphemeBoundaryStateMachine* machine,
const Vector<UChar32>& preceding,
const Vector<UChar32>& following) { … }
}