Daniel Jasper 03a04fe95f clang-format: Separate out a language kind for ObjC.
While C(++) and ObjC are generally formatted the same way and can be
mixed, people might want to choose different styles based on the
language. This patch recognizes .m and .mm files as ObjC and also
implements a very crude detection of whether or not a .h file contains
ObjC code. This can be improved over time.

Also move most of the ObjC tests into their own test file to keep file
size maintainable.

llvm-svn: 289428
2016-12-12 12:42:29 +00:00

24 lines
382 B
CMake

set(LLVM_LINK_COMPONENTS
Support
)
add_clang_unittest(FormatTests
CleanupTest.cpp
FormatTest.cpp
FormatTestJava.cpp
FormatTestJS.cpp
FormatTestObjC.cpp
FormatTestProto.cpp
FormatTestSelective.cpp
SortImportsTestJS.cpp
SortIncludesTest.cpp
)
target_link_libraries(FormatTests
clangBasic
clangFormat
clangFrontend
clangRewrite
clangToolingCore
)