Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
Kitware
GitHub Repository: Kitware/CMake
Path: blob/master/Tests/CMakeCommands/target_include_directories/consumer.c
3157 views
1
2
// Visual Studio allows only one set of flags for C and C++.
3
// In a target using C++ we pick the C++ flags even for C sources.
4
#ifdef TEST_LANG_DEFINES_FOR_VISUAL_STUDIO_OR_XCODE
5
# include "cxx_only.h"
6
7
# ifndef CXX_ONLY_DEFINE
8
# error Expected CXX_ONLY_DEFINE
9
# endif
10
#else
11
# include "c_only.h"
12
13
# ifndef C_ONLY_DEFINE
14
# error Expected C_ONLY_DEFINE
15
# endif
16
#endif
17
18
int consumer_c(void)
19
{
20
return 0;
21
}
22
23