Re: Schedule constructor - no "isRegular" - crash with FixedRateLeg::operator Leg()

Posted by Luigi Ballabio on
URL: http://quantlib.414.s1.nabble.com/Building-with-Microsoft-Visual-C-2010-tp8402p8409.html

On Fri, 2010-06-25 at 07:17 -0300, Lucio Dinoto wrote:

> I have found that by creating a simple schedule as following:
>
> QuantLib::Schedule schedule = QuantLib::Schedule (dates, QuantLib::NullCalendar(), QuantLib::Unadjusted);
>
> The lib fails after:
>
> QuantLib::FixedRateLeg(schedule)
>
> As the isRegular was never initialized. I think the solution could be
> to initialize in the constructor

Not really a solution, since the schedule would still be missing
information that FixedRateLeg would request after the isRegular check.
I think the solution should be to add a constructor that sets all the
Schedule data members besides the dates. Would you have time to try and
code it?

Luigi


--

Olmstead's Law:
After all is said and done, a hell of a lot more is said
than done.



------------------------------------------------------------------------------
This SF.net email is sponsored by Sprint
What will you do first with EVO, the first 4G phone?
Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users