Skip to content

Commit

Permalink
AK: Make a couple of GenericLexer helper methods protected
Browse files Browse the repository at this point in the history
We will want to use the exact behavior of these methods in JsonParser.

(cherry picked from commit c39a3fef17e913da944c35d57541298232bcea53)
  • Loading branch information
trflynn89 authored and nico committed Jul 7, 2024
1 parent ebaa9f9 commit c56a965
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions AK/GenericLexer.h
Original file line number Diff line number Diff line change
Expand Up @@ -224,14 +224,13 @@ class GenericLexer {
}

protected:
StringView m_input;
size_t m_index { 0 };

private:
#ifndef KERNEL
Result<u32, UnicodeEscapeError> decode_code_point();
Result<u32, UnicodeEscapeError> decode_single_or_paired_surrogate(bool combine_surrogate_pairs);
Result<u32, UnicodeEscapeError> decode_single_or_paired_surrogate(bool combine_surrogate_pairs = true);
#endif

StringView m_input;
size_t m_index { 0 };
};

class LineTrackingLexer : public GenericLexer {
Expand Down

0 comments on commit c56a965

Please sign in to comment.