I am so frustrated with the Microsoft C++ compiler (not Visual). I am really annoyed at how it uses
int _tmain(
and
_TCHAR* argv[]
as well as many other things. I just want to use straight C++ like you would in GCC. Is there an alternative?
Thanks to all the responses. I was really just looking for a way of not using Microsoft Style code. This is what helped me –
- Remove
#include "stdafx.h" - Rename main method to –
int main (int argc, char* argv[])
{
return 0;
}
And it works!
You don’t have to use
_tmain()andTCHARif you do not want to. Just create an empty project, add an empty source file to it and start writingOn VC++ 2010 Express you can just compile and execute it straight away. I don’t remember if previous versions require that you set the project type.