From f88827c33e2b5325fbfa0853ae7cfa71a585e13d Mon Sep 17 00:00:00 2001 From: Luigi Ballabio Date: Sun, 24 May 2020 18:55:49 +0200 Subject: [PATCH] Avoid Codacy warnings. --- ql/experimental/credit/randomdefaultlatentmodel.hpp | 10 +++++----- .../volatility/atmadjustedsmilesection.hpp | 6 +++--- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/ql/experimental/credit/randomdefaultlatentmodel.hpp b/ql/experimental/credit/randomdefaultlatentmodel.hpp index 6635e9bf0d4..c9f1b2f7eeb 100644 --- a/ql/experimental/credit/randomdefaultlatentmodel.hpp +++ b/ql/experimental/credit/randomdefaultlatentmodel.hpp @@ -828,11 +828,11 @@ namespace QuantLib { Real accuracy_; public: // \todo: Allow a constructor building its own default latent model. - RandomDefaultLM(const ext::shared_ptr >& model, - const std::vector& recoveries = std::vector(), - Size nSims = 0, // stats will crash on div by zero, FIX ME. - Real accuracy = 1.e-6, - BigNatural seed = 2863311530UL) + explicit RandomDefaultLM(const ext::shared_ptr >& model, + const std::vector& recoveries = std::vector(), + Size nSims = 0, // stats will crash on div by zero, FIX ME. + Real accuracy = 1.e-6, + BigNatural seed = 2863311530UL) : RandomLM< ::QuantLib::RandomDefaultLM, copulaPolicy, USNG>( model->numFactors(), model->size(), model->copula(), nSims, seed), model_(model), diff --git a/ql/termstructures/volatility/atmadjustedsmilesection.hpp b/ql/termstructures/volatility/atmadjustedsmilesection.hpp index 83f88a17a52..0a0ba17c1ac 100644 --- a/ql/termstructures/volatility/atmadjustedsmilesection.hpp +++ b/ql/termstructures/volatility/atmadjustedsmilesection.hpp @@ -32,9 +32,9 @@ namespace QuantLib { class AtmAdjustedSmileSection : public SmileSection { public: - AtmAdjustedSmileSection(const ext::shared_ptr& source, - Real atm = Null(), - bool recenterSmile = false); + explicit AtmAdjustedSmileSection(const ext::shared_ptr& source, + Real atm = Null(), + bool recenterSmile = false); Real minStrike() const { return source_->minStrike(); } Real maxStrike() const { return source_->maxStrike(); }