Skip to content

Support string_view in caffe_importer#26596

Merged
asmorkalov merged 1 commit intoopencv:4.xfrom
y-guyon:4.x_absl_str
Dec 9, 2024
Merged

Support string_view in caffe_importer#26596
asmorkalov merged 1 commit intoopencv:4.xfrom
y-guyon:4.x_absl_str

Conversation

@y-guyon
Copy link
Copy Markdown
Contributor

@y-guyon y-guyon commented Dec 9, 2024

An upcoming change in Protobuf will change the return types of various methods like Descriptor::name() and Message::GetTypeName() from const std::string& or std::string to absl::string_view. This CL fixes users of those methods to work both before and after the change.

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 another license that is incompatible with OpenCV
  • The PR is proposed to the proper branch
  • There is a reference to the original bug report and related work
  • There is accuracy test, performance test and test data in opencv_extra repository, if applicable
    Patch to opencv_extra has the same branch name.
  • The feature is well documented and sample code can be built with the project CMake

An upcoming change in Protobuf will change the return types of various
methods like Descriptor::name() and Message::GetTypeName() from const
std::string& or std::string to absl::string_view. This CL fixes users
of those methods to work both before and after the change.
@vrabaud vrabaud requested a review from asmorkalov December 9, 2024 09:47
@asmorkalov asmorkalov self-assigned this Dec 9, 2024
@asmorkalov asmorkalov added this to the 4.11.0 milestone Dec 9, 2024
@asmorkalov asmorkalov merged commit 0a2669d into opencv:4.x Dec 9, 2024
@asmorkalov asmorkalov mentioned this pull request Jan 15, 2025
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.

2 participants