如果你学习C++,请不要选择DevCpp

作者:朱金灿
来源:http://blog.csdn.net/clever101/


      有网友发信给我,说使用DevCpp编译一个MTL库的测试程序出现一堆莫名其妙的错误。


      DevCpp我听说过,以前也下载使用过,据说号称Windows平台下的gcc。结果我用DevCpp一编译网友的程序,感觉此编译器不堪大用。


      网友的测试程序是这样的:

#include #include int main(int argc, char* argv[]) { using namespace mtl; // Define dense vector of doubles with 10 elements all set to 0.0. dense_vector v(10, 0.0); // Set element 7 to 3.0. v[7]= 3.0; std::cout << "v is " << v << "/n"; return 0; }


     结果出现莫名其妙的错误,说实话它的编译错误提示极为晦涩,我基本看不懂,只好以图为证:



但是我用VS 2008 + sp1编译这个程序,则一点问题都没有。看看网友怎么评论DevCpp的吧:


        Get rid of Dev-C++ and download VC++ 2008 Express. If you have any difficulties after that, let us know.
Dev-C++ has not been supported by its creators for a long time. It is horribly out of date. You might be able to just update your version of the compiler and keep the IDE as-is, but you get a really good debugger integrated with VC++ 2008 Express that really blows the competition away.


评论来自:
http://bbs.prog365.com/c-programming-on-using-mtl-matrix-template-library-in-dev-c-4.9.8.0-190-1-1.html


        所以在Windows平台下学习C++,我建议你选择VS 2005及更高版本的VS,或者选择开源的CodeBlocks。







你可能感兴趣的:(c++,compiler,express,windows,download,vector,C/C++)