We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 97c46ad commit 900c02fCopy full SHA for 900c02f
ql/time/ecb.cpp
@@ -152,9 +152,8 @@ namespace QuantLib {
152
ecbCode << " is not a valid ECB code");
153
154
char upperMonthCode[3];
155
- to_upper_copy(upperMonthCode, ecbCode);
156
- const boost::string_view monthString(upperMonthCode, 3);
157
- const auto it = std::find(MONTHS.begin(), MONTHS.end(), monthString);
+ to_upper_copy(upperMonthCode, boost::string_view(ecbCode.data(), 3));
+ const auto it = std::find(MONTHS.begin(), MONTHS.end(), boost::string_view(upperMonthCode, 3));
158
QL_ASSERT(it != MONTHS.end() ,"not an ECB month (and it should have been). code: " + ecbCode);
159
160
// QuantLib::Month is 1-based!
0 commit comments