Conversion between Handles
Posted by Luigi Ballabio-2 on Feb 11, 2003; 2:14am
URL: http://quantlib.414.s1.nabble.com/Conversion-between-Handles-tp10225.html
Hi all,
at the present time,
Handle<CashFlow> c = ...;
Handle<TermStructure> h = c;
will store in h a null pointer. h can be checked with h.isNull(), but in
general a failed conversion will bite one far from the point where it
actually happened (I just had to debug such a case, and it was not pretty).
I'd rather have the failed conversion throw immediately. Is it OK for
everybody?
Bye,
Luigi