Skip to content

Fix build fail due missing operator= in popup #10881

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Sep 8, 2022

Conversation

baderouaich
Copy link
Contributor

Fix build failure after PR #10809 in Windows and Linux due missing operator= in common/viewer.h#16 which is required by std::vector::erase when having const members.

Workaround

this can also be solved by making the struct popup's members header, message and custom_command non-const instead of using const_cast.

@Nir-Az Nir-Az requested a review from maloel September 7, 2022 19:08
@Nir-Az
Copy link
Collaborator

Nir-Az commented Sep 7, 2022

@baderouaich Thanks for the quick catch!
Will be fixed soon.

If an operator=() is needed then objects can't be const. Using a `const_cast` is not a good idea, IMO.
@maloel maloel merged commit 0501678 into IntelRealSense:development Sep 8, 2022
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.

3 participants