#136 Build error when comiling with VC11

closed-fixed
None
5
2012-09-03
2011-09-29
No

1>------ Build started: Project: QuantLib, Configuration: Debug Win32 ------
1>Build started 9/29/2011 3:09:10 PM.
1>ClCompile:
1> symmetricschurdecomposition.cpp
1>ql\math\matrixutilities\symmetricschurdecomposition.cpp(123): error C2664: 'std::make_pair' : cannot convert parameter 1 from 'QuantLib::Real' to 'QuantLib::Real &&'
1> You cannot bind an lvalue to an rvalue reference
1>
1>Build FAILED.
1>
1>Time Elapsed 00:00:03.09
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

I modified this code:
temp[col] = std::make_pair<Real, std::vector<Real> >(
diagonal_[col], eigenVector);

to this:
temp[col] = std::make_pair<Real, std::vector<Real> >(
(Real&&)diagonal_[col], (std::vector<Real>&&)eigenVector);

and it built ok.

Discussion

  • Luigi Ballabio

    Luigi Ballabio - 2012-09-03
    • assigned_to: nobody --> lballabio
    • status: open --> closed-fixed
     
  • Luigi Ballabio

    Luigi Ballabio - 2012-09-03

    Alvin's patch was applied to the Subversion repository.
    Thank you for the report and the fix.

     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks