on 3/29/02 11:05 AM, David Brownell at david_brownell@hotmail.com wrote:
I have the following code that doesn't compile using VC 7.0. I am getting many errors in crc.hpp. Am I missing something simple here? I have just glanced at the manual, so please be gentle with the RTFM responses :)
TIA, David Brownell
#include<iostream> #include "boost\crc.hpp"
int main(void) { const unsigned char DATA[] = { 1, 2, 3, 4, 5 };
boost::crc_32_type crc;
crc.reset(); crc.process_bytes(DATA, sizeof(DATA) / sizeof(*DATA));
std::cout << crc.checksum() << std::endl; return(true); }
I ran it just fine (and got "1191942644" printed). There may be some VC++ 7 quirks. Did you try it with VC++ 6? What error messages did you get? -- Daryle Walker Mac, Internet, and Video Game Junkie darylew AT mac DOT com
Daryle, thanks for your response. The code does work on VC6. Here is the crc.hpp related errors I get when I compile with VC7. Thanks! David Brownell c:\vss\Helpers\3rdParty\boost_1_27_0\boost\crc.hpp(71) : error C2059: syntax error : '' c:\vss\Helpers\3rdParty\boost_1_27_0\boost\crc.hpp(94) : error C2977: 'boost::crc_optimal' : too many template arguments c:\vss\Helpers\3rdParty\boost_1_27_0\boost\crc.hpp(75) : see declaration of 'boost::crc_optimal' c:\vss\Helpers\3rdParty\boost_1_27_0\boost\crc.hpp(95) : error C2977: 'boost::crc_optimal' : too many template arguments c:\vss\Helpers\3rdParty\boost_1_27_0\boost\crc.hpp(75) : see declaration of 'boost::crc_optimal' c:\vss\Helpers\3rdParty\boost_1_27_0\boost\crc.hpp(96) : error C2977: 'boost::crc_optimal' : too many template arguments c:\vss\Helpers\3rdParty\boost_1_27_0\boost\crc.hpp(75) : see declaration of 'boost::crc_optimal' c:\vss\Helpers\3rdParty\boost_1_27_0\boost\crc.hpp(98) : error C2977: 'boost::crc_optimal' : too many template arguments c:\vss\Helpers\3rdParty\boost_1_27_0\boost\crc.hpp(75) : see declaration of 'boost::crc_optimal' c:\vss\Helpers\3rdParty\boost_1_27_0\boost\crc.hpp(258) : error C2983: 'boost::crc_optimal' : new template parameter list has more parameters than the previous declaration c:\vss\Helpers\3rdParty\boost_1_27_0\boost\crc.hpp(258) : see declaration of 'boost::crc_optimal' c:\vss\Helpers\3rdParty\boost_1_27_0\boost\crc.hpp(214) : error C2062: type '' unexpected c:\vss\Helpers\3rdParty\boost_1_27_0\boost\crc.hpp(258) : see reference to class template instantiation 'boost::crc_optimal<,TruncPoly,InitRem,FinalXor,,>' being compiled -----Original Message----- From: Daryle Walker [mailto:darylew@mac.com] Sent: Wednesday, April 03, 2002 3:29 PM To: Boost-Users@yahoogroups.com Subject: [Boost-Users] Re: Compiling CRC on 3/29/02 11:05 AM, David Brownell at david_brownell@hotmail.com wrote:
I have the following code that doesn't compile using VC 7.0. I am getting many errors in crc.hpp. Am I missing something simple here? I have just glanced at the manual, so please be gentle with the RTFM responses :)
TIA, David Brownell
#include<iostream> #include "boost\crc.hpp"
int main(void) { const unsigned char DATA[] = { 1, 2, 3, 4, 5 };
boost::crc_32_type crc;
crc.reset(); crc.process_bytes(DATA, sizeof(DATA) / sizeof(*DATA));
std::cout << crc.checksum() << std::endl; return(true); }
I ran it just fine (and got "1191942644" printed). There may be some VC++ 7 quirks. Did you try it with VC++ 6? What error messages did you get? -- Daryle Walker Mac, Internet, and Video Game Junkie darylew AT mac DOT com Info: http://www.boost.org Wiki: http://www.crystalclearsoftware.com/cgi-bin/boost_wiki/wiki.pl Unsubscribe: mailto:boost-users-unsubscribe@yahoogroups.com Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
participants (2)
-
Daryle Walker
-
David Brownell