1 #include<windows.h>
2 
3 // deliberately don't get MY_ICON from resource.h so that depfile generation can
4 // be exercised in the WindowsTests.test_rc_depends_files unit test
5 #define MY_ICON 1
6 
7 int APIENTRY
WinMain(HINSTANCE hInstance,HINSTANCE hPrevInstance,LPSTR lpszCmdLine,int nCmdShow)8 WinMain(
9     HINSTANCE hInstance,
10     HINSTANCE hPrevInstance,
11     LPSTR lpszCmdLine,
12     int nCmdShow) {
13     HICON hIcon;
14     hIcon = LoadIcon(GetModuleHandle(NULL), MAKEINTRESOURCE(MY_ICON));
15 // avoid unused argument error while matching template
16     ((void)hInstance);
17     ((void)hPrevInstance);
18     ((void)lpszCmdLine);
19     ((void)nCmdShow);
20     return hIcon ? 0 : 1;
21 }
22