Skip to content

Commit 90c1d9a

Browse files
pcaspersGitlab CI
authored andcommitted
Merge branch 'feature/QPR-13714' into 'master'
QPR-13714: explicitly turn on QL_ENABLE_SESSIONS in QuantLib Closes QPR-13714 See merge request qs/oreplus!3136
1 parent e096718 commit 90c1d9a

3 files changed

Lines changed: 5 additions & 3 deletions

File tree

ORE-SWIG/setup.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -184,9 +184,11 @@ def finalize_options(self):
184184
self.define += [('__WIN32__', None), ('WIN32', None),
185185
('NDEBUG', None), ('_WINDOWS', None),
186186
('NOMINMAX', None)]
187+
# ORE and QuantLib specific flags
188+
self.define += [('QL_ENABLE_SESSIONS', None), ('QL_USE_STD_ANY', None), ('QL_FASTER_LAZY_OBJECTS', None), ('QL_USE_STD_OPTIONAL', None)]
187189
if 'ORE_USE_ZLIB' in os.environ:
188190
self.define += [('ORE_USE_ZLIB', None)]
189-
extra_compile_args = ['/GR', '/FD', '/Zm250', '/EHsc', '/bigobj', '/std:c++17', '/wd4996' ]
191+
extra_compile_args = ['/GR', '/FD', '/Zm250', '/EHsc', '/bigobj', '/std:c++20', '/wd4996' ]
190192
extra_link_args = ['/subsystem:windows', machinetype]
191193
self.libraries = [ 'advapi32' ]
192194

OREData/ored/marketdata/yieldcurve.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1497,7 +1497,7 @@ void YieldCurve::buildBootstrappedCurve(const std::set<std::size_t>& indices) {
14971497
auto [minIt, maxIt] =
14981498
std::minmax_element(instrumentsPerSegment[i].begin(), instrumentsPerSegment[i].end(),
14991499
[](const RateHelperData& h, const RateHelperData& j) {
1500-
return h.rateHelper->pillarDate() < h.rateHelper->pillarDate();
1500+
return h.rateHelper->pillarDate() < j.rateHelper->pillarDate();
15011501
});
15021502
minMaxDatePerSegment[i] =
15031503
std::make_pair((*minIt).rateHelper->pillarDate(), (*maxIt).rateHelper->pillarDate());

QuantLib

0 commit comments

Comments
 (0)