Skip to content

Commit be5d271

Browse files
committed
Add missing includes and reference
1 parent 2de6d74 commit be5d271

6 files changed

Lines changed: 11 additions & 3 deletions

File tree

QuantExt/qle/cashflows/averageonindexedcoupon.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
#include <ql/cashflows/couponpricer.hpp>
2424
#include <ql/cashflows/fixedratecoupon.hpp>
2525
#include <ql/termstructures/yieldtermstructure.hpp>
26+
#include <ql/time/calendars/weekendsonly.hpp>
2627
#include <ql/utilities/vectors.hpp>
2728

2829
using namespace QuantLib;

QuantExt/qle/cashflows/overnightindexedcoupon.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@
4242
#include <ql/cashflows/cashflowvectors.hpp>
4343
#include <ql/cashflows/couponpricer.hpp>
4444
#include <ql/termstructures/yieldtermstructure.hpp>
45+
#include <ql/time/calendars/weekendsonly.hpp>
4546
#include <ql/utilities/vectors.hpp>
4647

4748
using std::vector;

QuantExt/qle/math/computeenvironment.hpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424

2525
#include <ql/patterns/singleton.hpp>
2626

27+
#include <cstdint>
2728
#include <set>
2829

2930
namespace QuantExt {

QuantExt/qle/math/openclenvironment.hpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,8 @@
2424

2525
#include <qle/math/computeenvironment.hpp>
2626

27+
#include <map>
28+
2729
namespace QuantExt {
2830

2931
class OpenClFramework : public ComputeFramework {

QuantExt/qle/math/randomvariable_opcodes.hpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,9 @@
1818

1919
#pragma once
2020

21+
#include <string>
22+
#include <vector>
23+
2124
namespace QuantExt {
2225

2326
struct RandomVariableOpCode {

QuantExt/qle/pricingengines/numericalintegrationindexcdsoptionengine.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,7 @@ void NumericalIntegrationIndexCdsOptionEngine::doCalc() const {
227227
brent.setLowerBound(1.0E-8);
228228
try {
229229
fepAdjustedForwardSpread = brent.solve(target, 1.0E-7, arguments_.swap->fairSpreadClean(), 0.0001);
230-
} catch (const std::exception e) {
230+
} catch (const std::exception& e) {
231231
QL_FAIL(
232232
"NumericalIntegrationIndexCdsOptionEngine::doCalc(): failed to calibrate forward spread: " << e.what());
233233
}
@@ -248,7 +248,7 @@ void NumericalIntegrationIndexCdsOptionEngine::doCalc() const {
248248
Brent brent2;
249249
try {
250250
exerciseBoundary = brent2.solve(payoff, 1.0E-7, 0.0, 0.0001);
251-
} catch (const std::exception e) {
251+
} catch (const std::exception& e) {
252252
QL_FAIL(
253253
"NumericalIntegrationIndexCdsOptionEngine::doCalc(): failed to find exercise boundary: " << e.what());
254254
}
@@ -276,7 +276,7 @@ void NumericalIntegrationIndexCdsOptionEngine::doCalc() const {
276276
std::exp(-0.5 * x * x) / boost::math::constants::root_two_pi<Real>();
277277
},
278278
lowerIntegrationBound, upperIntegrationBound);
279-
} catch (const std::exception e) {
279+
} catch (const std::exception& e) {
280280
QL_FAIL(
281281
"NumericalIntegrationIndexCdsOptionEngine::doCalc(): failed to compute option payoff: " << e.what());
282282
}

0 commit comments

Comments
 (0)