Skip to content

Fixed warnings produced by clang-9.0.0#13705

Merged
opencv-pushbot merged 1 commit intoopencv:masterfrom
mshabunin:clang-warnings
Feb 1, 2019
Merged

Fixed warnings produced by clang-9.0.0#13705
opencv-pushbot merged 1 commit intoopencv:masterfrom
mshabunin:clang-warnings

Conversation

@mshabunin
Copy link
Copy Markdown
Contributor

@mshabunin mshabunin commented Jan 28, 2019

Merge with opencv/opencv_contrib#1980

This pullrequest changes

  • warning: declaration shadows a static data member of 'cv::FileStorage' [-Wshadow]
  • warning: local variable xxxxx will be copied despite being returned by name [-Wreturn-std-move]
  • warning: explicitly assigning value of variable of type 'Ptr<opencv_test::(anonymous namespace)::anonymous namespace)::Reporter>' to itself [-Wself-assign-overloaded]
force_builders=Custom
buildworker:Custom=linux-1,linux-2,linux-4
docker_image:Custom=ubuntu-clang:18.04
buildworker:Win64 OpenCL=windows-2

struct tuple_wrap_helper<std::tuple<Objs...>>
{
static std::tuple<Objs...> get(std::tuple<Objs...>&& objs) { return objs; }
static std::tuple<Objs...> get(std::tuple<Objs...>&& objs) { return std::forward<std::tuple<Objs...>>(objs); }
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

/cc @dmatveev

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Basically I am ok with this (tests pass means it works)

Copy link
Copy Markdown
Contributor

@dmatveev dmatveev left a comment

Choose a reason for hiding this comment

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

+1

struct tuple_wrap_helper<std::tuple<Objs...>>
{
static std::tuple<Objs...> get(std::tuple<Objs...>&& objs) { return objs; }
static std::tuple<Objs...> get(std::tuple<Objs...>&& objs) { return std::forward<std::tuple<Objs...>>(objs); }
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Basically I am ok with this (tests pass means it works)

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.

Looks good to me 👍

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.

4 participants