compile problem of boost::accumulators
hi,
I am a newbie in this forum. I just installed boost and want to solve some
statistic problems. My system is Windows Vista and compiler is MSVC 6.0
At first I try to compile the "hello world" program in the
boost::accumulators user guide page, but I got some compiler errors:
The program is
#include <iostream>
#include
AMDG Ivy Ye wrote:
I am a newbie in this forum. I just installed boost and want to solve some statistic problems. My system is Windows Vista and compiler is MSVC 6.0
<snip>
can someone tell me what is wrong?
msvc 6.0 is a very old compiler and is not supported. In Christ, Steven Watanabe
Ivy Ye wrote:
hi,
I am a newbie in this forum. I just installed boost and want to solve some statistic problems. My system is Windows Vista and compiler is MSVC 6.0
I'm sorry, that compiler version is not supported. Accumulators should work with MSVC 7.1 and greater. -- Eric Niebler BoostPro Computing http://www.boostpro.com
If you are student u can legal download msvc 2008 on https://downloads.channel8.msdn.com/ Have fun with regards, Kim Tang Ivy Ye schrieb:
hi,
I am a newbie in this forum. I just installed boost and want to solve some statistic problems. My system is Windows Vista and compiler is MSVC 6.0
At first I try to compile the "hello world" program in the boost::accumulators user guide page, but I got some compiler errors:
The program is
#include <iostream> #include
#include #include #include using namespace boost::accumulators; int main() { // Define an accumulator set for calculating the mean and the // 2nd moment ... accumulator_set > > acc; // push in some data ... acc(1.2); acc(2.3); acc(3.4); acc(4.5); // Display the results ... std::cout << "Mean: " << mean(acc) << std::endl; std::cout << "Moment: " << moment<2>(acc) << std::endl; return 0; } The error I get from compiler is
s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(43) : error C2989: 'tag<T>' : template class has already been defined as a non-template class s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(43) : error C2908: explicit specialization; 'tag<T>' has already been instantiated from the primary template s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(43) : error C2988: unrecognizable template declaration/definition s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(48) : error C2989: 'tag<T>' : template class has already been defined as a non-template class s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(43) : see declaration of 'tag<T>' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(48) : error C2908: explicit specialization; 'tag<T>' has already been instantiated from the primary template s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(48) : error C2988: unrecognizable template declaration/definition s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(53) : error C2989: 'tag<T>' : template class has already been defined as a non-template class s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(48) : see declaration of 'tag<T>' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(53) : error C2908: explicit specialization; 'tag<T>' has already been instantiated from the primary template s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(53) : error C2988: unrecognizable template declaration/definition s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(107) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(107) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(108) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(108) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(109) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(109) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(110) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(110) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(111) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(111) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(112) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(112) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(113) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(113) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(114) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(114) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(115) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(115) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(116) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(116) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(117) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(117) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(119) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(119) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(120) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(120) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(121) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(121) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(122) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(122) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(123) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(123) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(124) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(124) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(126) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(127) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(128) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(129) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(137) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(139) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(141) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(143) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(145) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(147) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(149) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(151) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\numeric\functional_fwd.hpp(198) : error C2039: 'type' : is not a member of 'lazy_disable_if
' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(82) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(82) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(98) : error C2182: '__formal' : illegal use of type 'void' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(120) : error C2039: 'apply' : is not a member of 'mpl' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(120) : error C2143: syntax error : missing ';' before '<' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(120) : error C2501: 'apply' : missing storage-class or type specifiers s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(120) : error C2059: syntax error : ';' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(120) : error C2059: syntax error : '<' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(120) : error C2039: 'type' : is not a member of '`global namespace'' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(124) : error C2039: 'apply' : is not a member of 'mpl' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(124) : error C2039: 'type' : is not a member of '`global namespace'' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(127) : error C2954: template definitions cannot nest s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(128) : error C2039: 'apply' : is not a member of 'mpl' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(128) : error C2143: syntax error : missing ';' before '<' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(128) : error C2501: 'apply' : missing storage-class or type specifiers s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(128) : error C2086: 'apply' : redefinition s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(128) : error C2059: syntax error : ';' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(128) : error C2059: syntax error : '<' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(128) : error C2039: 'type' : is not a member of '`global namespace'' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2039: 'apply' : is not a member of 'mpl' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2039: 'type' : is not a member of '`global namespace'' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2954: template definitions cannot nest s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2039: 'apply' : is not a member of 'mpl' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2143: syntax error : missing ';' before '<' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2501: 'apply' : missing storage-class or type specifiers s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2086: 'apply' : redefinition s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2059: syntax error : ';' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2059: syntax error : '<' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2039: 'type' : is not a member of '`global namespace'' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2039: 'apply' : is not a member of 'mpl' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2039: 'type' : is not a member of '`global namespace'' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2954: template definitions cannot nest s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2039: 'apply' : is not a member of 'mpl' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2143: syntax error : missing ';' before '<' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2501: 'apply' : missing storage-class or type specifiers s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2086: 'apply' : redefinition s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2059: syntax error : ';' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2059: syntax error : '<' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2039: 'type' : is not a member of '`global namespace'' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2039: 'apply' : is not a member of 'mpl' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2039: 'type' : is not a member of '`global namespace'' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2954: template definitions cannot nest s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2039: 'apply' : is not a member of 'mpl' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2143: syntax error : missing ';' before '<' s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : error C2501: 'apply' : missing storage-class or type specifiers s:\program files\boost\boost_1_36_0\boost\accumulators\accumulators_fwd.hpp(154) : fatal error C1003: error count exceeds 100; stopping compilation Error executing cl.exe. accExam.obj - 102 error(s), 0 warning(s) --------------------------- can someone tell me what is wrong?
Many thanks, Ivy
------------------------------------------------------------------------
_______________________________________________ Boost-users mailing list Boost-users@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users
participants (4)
-
Eric Niebler
-
Ivy Ye
-
Kim Kuen Tang
-
Steven Watanabe