Skip to content

Conversation

asopov-here
Copy link
Collaborator

Currently, SDK requires C++11 minimum.
So, boost::optional type is used for optional values. For C++17 and above more convenient is to use std::optional instead. The task NLAM-23 is about making this type configurable. This commit makes the boost::optional default even for C++17 builds. The std::optional usage shall be switched on explicitly using OLP_SDK_USE_STD_OPTIONAL=ON flag.

Relates-To: NLAM-23

@asopov-here asopov-here marked this pull request as ready for review August 12, 2025 12:37
@rustam-gamidov-here
Copy link
Collaborator

Proper PR name will make it easier to read log in future

Copy link

codecov bot commented Aug 12, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 80.33%. Comparing base (ccdd33b) to head (11df58b).
⚠️ Report is 1 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1631      +/-   ##
==========================================
+ Coverage   80.30%   80.33%   +0.03%     
==========================================
  Files         349      349              
  Lines       13951    13952       +1     
  Branches     1492     1492              
==========================================
+ Hits        11202    11207       +5     
+ Misses       2150     2146       -4     
  Partials      599      599              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Currently, SDK requires C++11 minimum.
So, boost::optional type is used for optional values.
For C++17 and above more convenient is to use std::optional instead.
The task NLAM-23 is about making this type configurable.
This commit makes the boost::optional default even for C++17 builds.
The std::optional usage shall be switched on explicitly using
OLP_SDK_USE_STD_OPTIONAL=ON flag.

Relates-To: NLAM-23
Signed-off-by: sopov <ext-alexander.sopov@here.com>
@asopov-here asopov-here force-pushed the NLAM-23-std-optional branch from f9719c0 to 11df58b Compare August 12, 2025 12:55
@asopov-here asopov-here changed the title Use std::optional if available. Make boost::optional as default regardless of C++ version. Aug 12, 2025
@asopov-here asopov-here merged commit 7c47304 into master Aug 12, 2025
25 checks passed
@asopov-here asopov-here deleted the NLAM-23-std-optional branch August 12, 2025 13:09
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