diff --git a/ql/instruments/overnightindexedswap.cpp b/ql/instruments/overnightindexedswap.cpp index b93a1946690..bb128372885 100644 --- a/ql/instruments/overnightindexedswap.cpp +++ b/ql/instruments/overnightindexedswap.cpp @@ -29,7 +29,7 @@ namespace QuantLib { OvernightIndexedSwap::OvernightIndexedSwap(Type type, Real nominal, - Schedule schedule, + const Schedule& schedule, Rate fixedRate, DayCounter fixedDC, const ext::shared_ptr& overnightIndex, @@ -41,7 +41,7 @@ namespace QuantLib { RateAveraging::Type averagingMethod) : OvernightIndexedSwap(type, std::vector(1, nominal), - std::move(schedule), + schedule, fixedRate, std::move(fixedDC), overnightIndex, diff --git a/ql/instruments/overnightindexedswap.hpp b/ql/instruments/overnightindexedswap.hpp index 58b27756510..72b3c036c2d 100644 --- a/ql/instruments/overnightindexedswap.hpp +++ b/ql/instruments/overnightindexedswap.hpp @@ -43,7 +43,7 @@ namespace QuantLib { public: OvernightIndexedSwap(Type type, Real nominal, - Schedule schedule, + const Schedule& schedule, Rate fixedRate, DayCounter fixedDC, const ext::shared_ptr& overnightIndex,