|
From: Ferdinando A. <na...@am...> - 2009-10-12 14:42:57
|
Hi Eric and Plamen
I am unable to provide zero days as default value for Period in the XML
specification file.
The problem is that the autogenerated code has two different constructs
requiring different values ("0D" or 0*QuantLib::Days) so they cannot be
satisfied at the same time.
std::string ForwardStartCpp = ObjectHandler::convert2<std::string>(
ObjectHandler::ConvertOper(*ForwardStart), "ForwardStart",
"0D");
[...]
QuantLib::Period ForwardStartLib =
ObjectHandler::convert2<QuantLib::Period>(
ObjectHandler::ConvertOper(*ForwardStart), "ForwardStart",
0*QuantLib::Days);
I could provide a non-explicit string constructor for
QuantLib::Period(std::string s) as solution, but something tells me Luigi
might frown at this (or God forbid, even balk at this ;-)
Any suggestion or quick fix ?
ciao -- Nando
RSS feed: http://www.google.com/reader/shared/ferdinando.ametrano
|