Hi,
I am writing my own extension of QLAddin but I face an error never faced before while trying to expose the MC engine for Asian options (the native one). I have added in pricingengine.cpp a function with the following body: libraryObject_ = boost::shared_ptr<QuantLib::PricingEngine>(new QuantLib::MCDiscreteArithmeticAPEngine<QuantLib::PseudoRandom> (process, maxTimeStepsPerYear, brownianBridge, antitheticVariate, controlVariate, requiredSamples, requiredTolerance, maxSamples, isBiased, seed)); Why compiling I get the quantLib error (not QLAddin error): 2>../QuantLib\ql/pricingengines/asian/mc_discr_arith_av_price.hpp(77) : error C2989: 'QuantLib::MCDiscreteArithmeticAPEngine' : class template has already been declared as a non-class template 2> .\qlo/pricingengines.hpp(62) : see declaration of 'QuantLib::MCDiscreteArithmeticAPEngine' I am struggling to see where it goes wrong. Even if I use MakeMCDiscreteArithmeticAPEngine, the error remains the same. Any ideas? Cheers |
On Thu, 2009-11-12 at 03:51 -0800, Yomi wrote:
> error C2989: 'QuantLib::MCDiscreteArithmeticAPEngine' : class template has > already been declared as a non-class template > 2> .\qlo/pricingengines.hpp(62) : see declaration of > 'QuantLib::MCDiscreteArithmeticAPEngine' It's telling you that you somewhat redeclared QuantLib::MCDiscreteArithmeticAPEngine in qlo/pricingengines.hpp at line 62. What's there? Luigi -- Poets have been mysteriously silent on the subject of cheese. -- Gilbert K. Chesterton ------------------------------------------------------------------------------ Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ QuantLib-users mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-users |
Thansk Luigi,
Time for me to change my glasses or go in holidays... That was a bumb question. Thanks for looking at it.
|
Free forum by Nabble | Edit this page |