diff --git a/ql/instruments/basketoption.hpp b/ql/instruments/basketoption.hpp index fd0ee4bd12..3e8c483765 100644 --- a/ql/instruments/basketoption.hpp +++ b/ql/instruments/basketoption.hpp @@ -80,7 +80,7 @@ namespace QuantLib { a.begin(), Real(0.0)); } - Array weights() const { return weights_; } + const Array& weights() const { return weights_; } private: Array weights_;