From e765a932dd6809ba587c29c4e713357a56a7f60f Mon Sep 17 00:00:00 2001 From: Evgeny Mankov Date: Mon, 10 Jul 2023 16:36:36 +0200 Subject: [PATCH] [HIPIFY][build][#724][cleanup] Remove SWDEV_375013 related guards from `CMakeLists.txt` and `HipifyAction.cpp` [Reason] LLVM 16.0.0 was released a long ago, so the guard is not used anymore --- CMakeLists.txt | 6 ------ src/HipifyAction.cpp | 3 +-- 2 files changed, 1 insertion(+), 8 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index a92a5e9b..f61c36b4 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -119,12 +119,6 @@ else() endif() endif() -# [ToDo] Remove SWDEV_375013 related guards from CMakeLists.txt and HipifyAction.cpp along with the LLVM 16.0.0 official release -option (SWDEV_375013 "Enables SWDEV-375013 blocker workaround for the clang's change https://reviews.llvm.org/D140332" OFF) -if(SWDEV_375013) - add_definitions(-DSWDEV_375013) -endif() - if(MSVC) target_link_libraries(hipify-clang PRIVATE version) target_compile_options(hipify-clang PRIVATE ${STD} /Od /GR- /EHs- /EHc-) diff --git a/src/HipifyAction.cpp b/src/HipifyAction.cpp index 7e252a9b..2c635d58 100644 --- a/src/HipifyAction.cpp +++ b/src/HipifyAction.cpp @@ -1199,12 +1199,11 @@ class PPCallbackProxy : public clang::PPCallbacks { public: explicit PPCallbackProxy(HipifyAction &action): hipifyAction(action) {} - // [ToDo] Remove SWDEV_375013 related guards from CMakeLists.txt and HipifyAction.cpp along with the LLVM 16.0.0 official release void InclusionDirective(clang::SourceLocation hash_loc, const clang::Token &include_token, StringRef file_name, bool is_angled, clang::CharSourceRange filename_range, #if LLVM_VERSION_MAJOR < 15 const clang::FileEntry *file, -#elif (LLVM_VERSION_MAJOR == 15) || (LLVM_VERSION_MAJOR == 16 && SWDEV_375013) +#elif LLVM_VERSION_MAJOR == 15 Optional file, #else clang::OptionalFileEntryRef file,