Skip to content

Commit

Permalink
Restore changes where parameter is actually copied
Browse files Browse the repository at this point in the history
  • Loading branch information
lballabio committed May 28, 2024
1 parent c521592 commit 04ca4e7
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions ql/indexes/bmaindex.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,15 +40,15 @@ namespace QuantLib {

}

BMAIndex::BMAIndex(const Handle<YieldTermStructure>& h)
BMAIndex::BMAIndex(Handle<YieldTermStructure> h)
: InterestRateIndex("BMA",
1 * Weeks,
1,
USDCurrency(),
UnitedStates(UnitedStates::GovernmentBond),
ActualActual(ActualActual::ISDA)),
termStructure_(h) {
registerWith (h);
termStructure_(std::move(h)) {
registerWith(termStructure_);
}

bool BMAIndex::isValidFixingDate(const Date& date) const {
Expand Down
2 changes: 1 addition & 1 deletion ql/indexes/bmaindex.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ namespace QuantLib {
*/
class BMAIndex : public InterestRateIndex {
public:
explicit BMAIndex(const Handle<YieldTermStructure>& h = {});
explicit BMAIndex(Handle<YieldTermStructure> h = {});
//! \name Index interface
//@{
/*! BMA is fixed weekly on Wednesdays.
Expand Down

0 comments on commit 04ca4e7

Please sign in to comment.