Skip to content
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

std::result_of removed in C++20 #115

Merged
merged 4 commits into from
Jun 16, 2020

Conversation

maxgolov
Copy link
Contributor

Fix for #104 : when OpenTelemetry is compiled with latest update of Visual Studio 2019 in C++17 mode - it'd generate a warning, and in C++20 it won't compile because std::result_of has been removed in C++20. Adjust the header to stop using a compiler feature that's been removed from standard.

Copy link
Member

@reyang reyang left a comment

Choose a reason for hiding this comment

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

LGTM.

CMakeLists.txt Show resolved Hide resolved
@g-easy
Copy link
Contributor

g-easy commented Jun 16, 2020

Failing test:

[ RUN      ] RandomTest.GenerateRandomBuffer
sdk/test/common/random_test.cc:30: Failure
Value of: std::equal(std::begin(buf1), std::end(buf1), std::begin(buf2))
  Actual: true
Expected: false
[  FAILED  ] RandomTest.GenerateRandomBuffer (0 ms)

cc @pyohannes

Address code review comment to document what /Zc:__cplusplus option is doing
@reyang
Copy link
Member

reyang commented Jun 16, 2020

@maxgolov please rebase, thanks.

@maxgolov maxgolov requested a review from a team June 16, 2020 21:14
@reyang reyang merged commit 49eee20 into open-telemetry:master Jun 16, 2020
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.

4 participants