You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Error msg:
1> Boost.Cpp11.2013.x64.vcxproj -> C:\dev\tapescript_vs2015\bin\vc120-x64-debug\libboost_unit_test_framework-vc120-mt-gd-1_57.lib
2>------ Rebuild All started: Project: Cl.Tape.Cpp11.2013.x64, Configuration: Debug x64 ------
3>------ Rebuild All started: Project: Cl.Tape.Examples.Cpp11.2013.x64, Configuration: Debug x64 ------
3> tape_other_translation_line.cpp
3> tape_example.cpp
3>c:\dev\tapescript_vs2015\tapescript\cpp\cl\tape\examples\impl\quadratic_regression_examples.hpp(209): error C2280: 'cl::tape_innercl::tape_array &cl::tape_innercl::tape_array::operator =(const cl::tape_innercl::tape_array &)': attempting to reference a deleted function
3> c:\dev\tapescript_vs2015\tapescript\cpp\cl\tape\impl\inner\tape_inner.hpp(289): note: compiler has generated 'cl::tape_innercl::tape_array::operator =' here
3> Generating Code...
========== Rebuild All: 2 succeeded, 1 failed, 0 skipped ==========
Reason: tape_inner has declared move constructor but not copy constructor. The source code above requires a copy constructor to compile.
In C++11 standard, a copy constructor should not be automatically generated if a move constructor is available. So above code should not compile. In this sense, VS2015 behaves correctly.
VS2013 is known not implementing such C++11 standard.
Error msg:
1> Boost.Cpp11.2013.x64.vcxproj -> C:\dev\tapescript_vs2015\bin\vc120-x64-debug\libboost_unit_test_framework-vc120-mt-gd-1_57.lib
2>------ Rebuild All started: Project: Cl.Tape.Cpp11.2013.x64, Configuration: Debug x64 ------
3>------ Rebuild All started: Project: Cl.Tape.Examples.Cpp11.2013.x64, Configuration: Debug x64 ------
3> tape_other_translation_line.cpp
3> tape_example.cpp
3>c:\dev\tapescript_vs2015\tapescript\cpp\cl\tape\examples\impl\quadratic_regression_examples.hpp(209): error C2280: 'cl::tape_innercl::tape_array &cl::tape_innercl::tape_array::operator =(const cl::tape_innercl::tape_array &)': attempting to reference a deleted function
3> c:\dev\tapescript_vs2015\tapescript\cpp\cl\tape\impl\inner\tape_inner.hpp(289): note: compiler has generated 'cl::tape_innercl::tape_array::operator =' here
3> Generating Code...
========== Rebuild All: 2 succeeded, 1 failed, 0 skipped ==========
Reason: tape_inner has declared move constructor but not copy constructor. The source code above requires a copy constructor to compile.
In C++11 standard, a copy constructor should not be automatically generated if a move constructor is available. So above code should not compile. In this sense, VS2015 behaves correctly.
VS2013 is known not implementing such C++11 standard.
See links here:
https://msdn.microsoft.com/en-us/library/hh567368%28v=vs.120%29.aspx#rvref (on Rvalue references 3.0)
https://msdn.microsoft.com/en-ca/library/dn457344%28v=vs.120%29.aspx
The text was updated successfully, but these errors were encountered: