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

Better handling of OPENTELEMETRY_STL_VERSION. #2490

Closed
wants to merge 9 commits into from
14 changes: 14 additions & 0 deletions api/include/opentelemetry/version.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,20 @@
#include "opentelemetry/common/macros.h"
#include "opentelemetry/detail/preprocessor.h"

#if defined(OPENTELEMETRY_STL_VERSION)
# if (!defined(_MSVC_LANG) && OPENTELEMETRY_STL_VERSION > (__cplusplus / 100)) || \
(defined(_MSVC_LANG) && OPENTELEMETRY_STL_VERSION > (_MSVC_LANG / 100))
# if defined(_MSVC_LANG)
# pragma message OPENTELEMETRY_STRINGIFY( \
OPENTELEMETRY_STL_VERSION) " vs. " OPENTELEMETRY_STRINGIFY(_MSVC_LANG)
# else
# pragma message OPENTELEMETRY_STRINGIFY( \
OPENTELEMETRY_STL_VERSION) " vs. " OPENTELEMETRY_STRINGIFY(__cplusplus)
# endif
# error "OPENTELEMETRY_STL_VERSION is set to a version newer than the curent C++ version."
# endif
#endif

#ifndef OPENTELEMETRY_ABI_VERSION_NO
# define OPENTELEMETRY_ABI_VERSION_NO 1
#endif
Expand Down
Loading