clang  6.0.0svn
Platform.h
Go to the documentation of this file.
1 /*===-- clang-c/Platform.h - C Index platform decls -------------*- C -*-===*\
2 |* *|
3 |* The LLVM Compiler Infrastructure *|
4 |* *|
5 |* This file is distributed under the University of Illinois Open Source *|
6 |* License. See LICENSE.TXT for details. *|
7 |* *|
8 |*===----------------------------------------------------------------------===*|
9 |* *|
10 |* This header provides platform specific macros (dllimport, deprecated, ...) *|
11 |* *|
12 \*===----------------------------------------------------------------------===*/
13 
14 #ifndef LLVM_CLANG_C_PLATFORM_H
15 #define LLVM_CLANG_C_PLATFORM_H
16 
17 #ifdef __cplusplus
18 extern "C" {
19 #endif
20 
21 /* MSVC DLL import/export. */
22 #ifdef _MSC_VER
23  #ifdef _CINDEX_LIB_
24  #define CINDEX_LINKAGE __declspec(dllexport)
25  #else
26  #define CINDEX_LINKAGE __declspec(dllimport)
27  #endif
28 #else
29  #define CINDEX_LINKAGE
30 #endif
31 
32 #ifdef __GNUC__
33  #define CINDEX_DEPRECATED __attribute__((deprecated))
34 #else
35  #ifdef _MSC_VER
36  #define CINDEX_DEPRECATED __declspec(deprecated)
37  #else
38  #define CINDEX_DEPRECATED
39  #endif
40 #endif
41 
42 #ifdef __cplusplus
43 }
44 #endif
45 #endif