Skip to content

Conversation

@kojiishi
Copy link
Collaborator

@kojiishi kojiishi commented Aug 12, 2023

This patch adds Parser.parseBoundaries, which returns a list of boundaries instead of phrases as strings. Parser.parse is changed to call this function.

Before this chagne, the HTMLProcessor computes the list of boudaries from the list of phrase strings. This chagne makes it more efficient by not computing substrings. Also, Parser.parse is slightly more efficient by computing substrings instead of adding one character at a time.

This patch has no behavior changes to existing functions.

@kojiishi kojiishi requested a review from tushuhei August 12, 2023 10:32
@tushuhei
Copy link
Member

LGTM! Thank you for this change.

@tushuhei tushuhei merged commit b4d4998 into google:main Aug 13, 2023
@kojiishi kojiishi deleted the parseBoundaries branch August 14, 2023 10:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants