forked from chromium/chromium
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove many string conversions in BlinkAXTreeSource.
Given a WebString there's no reason to convert to string16 (copy) to then convert to std::string for utf8 (another copy). Instead we can just call utf8() directly avoiding at least one copy, sometimes two since utf8() uses StringUTF8Adaptor to not allocate a new buffer for ascii strings, which is most attribute names, values, tag names and other markup related strings. Review URL: https://codereview.chromium.org/1438273003 Cr-Commit-Position: refs/heads/master@{#359589}
- Loading branch information
Showing
1 changed file
with
25 additions
and
36 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters