Skip to content

Use Faster NSTextStorage Substring#6

Merged
mattmassicotte merged 1 commit into
ChimeHQ:mainfrom
thecoolwinter:patch-1
Jun 23, 2025
Merged

Use Faster NSTextStorage Substring#6
mattmassicotte merged 1 commit into
ChimeHQ:mainfrom
thecoolwinter:patch-1

Conversation

@thecoolwinter

Copy link
Copy Markdown
Contributor

Updates NSTextStorage's TextStoring conformance to use the much faster NSString.substring method instead of creating an attributed substring. This avoids any unnecessary attribute fixing, attribute allocation, etc.

Updates the `NSTextStorage` `TextStoring` internals to use the much faster `NSString.substring` instead of finding the attributed substring. This avoids any unnecessary attribute fixing, attribute allocation, etc.
@mattmassicotte

Copy link
Copy Markdown
Contributor

Love it, thank you so much!

And sorry this took me so long, especially since it's such a simple change.

@mattmassicotte mattmassicotte merged commit 91df6fc into ChimeHQ:main Jun 23, 2025
5 checks passed
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