ccls
Keeping pace with LLVM: compatibility strategies
LLVM's C++ API doesn't offer a stability guarantee. This means function signatures can change or be removed between versions, forcing projects to adapt.
On the other hand, LLVM has an extensive API surface. When a library like llvm/lib/Y relies functionality from another library, the API is often exported in header files under llvm/include/llvm/X/, even if it is not intended to be user-facing.
To be compatible with multiple LLVM versions, many projects rely on #if directives based on the LLVM_VERSION_MAJOR macro.
This post explores the specific techniques used by ccls to ensure compatibility with LLVM versions 7 to 19.
For the latest release (ccls 0.20241108), support for LLVM versions 7 to 9 has been discontinued.
Given the tight coupling between LLVM and Clang, the LLVM_VERSION_MAJOR macro can be used for both version detection. There's no need to check CLANG_VERSION_MAJOR.
Real World CTF 2018 ccls-fringe命题报告
上周日给Real World CTF 2018出了一道forensics题ccls-fringe,向解出此题的31支队伍表达祝贺。
…