Skip to content

Optimize calls to std::string::find() and friends for a single char.#19139

Merged
opencv-pushbot merged 1 commit intoopencv:3.4from
vrabaud:find1
Dec 17, 2020
Merged

Optimize calls to std::string::find() and friends for a single char.#19139
opencv-pushbot merged 1 commit intoopencv:3.4from
vrabaud:find1

Conversation

@vrabaud
Copy link
Copy Markdown
Contributor

@vrabaud vrabaud commented Dec 16, 2020

The character literal overload is more efficient. More info at:

http://clang.llvm.org/extra/clang-tidy/checks/performance-faster-string-find.html

Pull Request Readiness Checklist

See details at https://github.com/opencv/opencv/wiki/How_to_contribute#making-a-good-pull-request

  • I agree to contribute to the project under Apache 2 License.
  • To the best of my knowledge, the proposed patch is not based on a code under GPL or other license that is incompatible with OpenCV
  • The PR is proposed to proper branch

@vrabaud vrabaud changed the base branch from master to 3.4 December 17, 2020 08:38
Copy link
Copy Markdown
Member

@alalek alalek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@opencv-pushbot opencv-pushbot merged commit 99d750d into opencv:3.4 Dec 17, 2020
@alalek alalek mentioned this pull request Dec 17, 2020
@vrabaud vrabaud deleted the find1 branch December 19, 2020 07:12
@alalek alalek mentioned this pull request Apr 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants