Is there a quick way to determine whether a Visual Studio C++ project is written in plain C++ or Visual C++?
+1
A:
No -- Visual C++ will compile most plain C++ without any problems. If you want to check for use of Windows-specific "stuff", checking for inclusion (directly or indirectly) of <windows.h>
would probably be a reasonable start.
Jerry Coffin
2010-03-09 21:26:37
A:
If is Visual C++ it usually has a project.sln or project.vcproj file in the project directory.
clyfe
2010-03-09 21:27:08
Yes but you can have plain C++ *.vcproj files as well.
emddudley
2010-03-10 19:21:37
+1
A:
If any files include the lines #pragma once
or #include "stdafx.h"
, it's very likely Visual C++.
(Are there any other compilers that implement #pragma once
?)
Mark Ransom
2010-03-09 21:39:21
If I'm not mistaken, `#pragma once` originated on (and is still supported by) gcc.
Jerry Coffin
2010-03-10 03:04:34