]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/config/winnt-c.c
c-target.def: New hook
[thirdparty/gcc.git] / gcc / config / winnt-c.c
CommitLineData
88b0e79e
JC
1/* Default C-family target hooks initializer.
2 Copyright (C) 2013
3 Free Software Foundation, Inc.
4
5This file is part of GCC.
6
7GCC is free software; you can redistribute it and/or modify it under
8the terms of the GNU General Public License as published by the Free
9Software Foundation; either version 3, or (at your option) any later
10version.
11
12GCC is distributed in the hope that it will be useful, but WITHOUT ANY
13WARRANTY; without even the implied warranty of MERCHANTABILITY or
14FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
15for more details.
16
17You should have received a copy of the GNU General Public License
18along with GCC; see the file COPYING3. If not see
19<http://www.gnu.org/licenses/>. */
20
21#include "config.h"
22#include "system.h"
23#include "coretypes.h"
24#include "c-family/c-target.h"
25#include "c-family/c-target-def.h"
26
27static bool
28winnt_implicit_extern_c (const char *ident)
29{
30 return !strcmp(ident, "wmain")
31 || !strcmp(ident, "DllMain")
32 || !strcmp(ident, "WinMain")
33 || !strcmp(ident, "wWinMain");
34}
35
36#undef TARGET_CXX_IMPLICIT_EXTERN_C
37#define TARGET_CXX_IMPLICIT_EXTERN_C winnt_implicit_extern_c
38
39struct gcc_targetcm targetcm = TARGETCM_INITIALIZER;