]> granicus.if.org Git - clang/commit
[Basic] Move DiagnosticsEngine::dump from .h to .cpp
authorFangrui Song <maskray@google.com>
Sat, 1 Dec 2018 01:43:05 +0000 (01:43 +0000)
committerFangrui Song <maskray@google.com>
Sat, 1 Dec 2018 01:43:05 +0000 (01:43 +0000)
commit41ed251debe6c5fb09d724b79e081450c1b68c73
treed824e15f89983bce4ecc69d589553f096ba2ee80
parent8840577923331aa191582a37dfd57f24c029fd22
[Basic] Move DiagnosticsEngine::dump from .h to .cpp

The two LLVM_DUMP_METHOD methods have a undefined reference on clang::DiagnosticsEngine::DiagStateMap::dump.

tools/clang/tools/extra/clangd/benchmarks/IndexBenchmark links in
clangDaemon but does not link in clangBasic explicitly, which causes a
linker error "undefined symbol" in !NDEBUG + -DBUILD_SHARED_LIBS=on builds.

Move LLVM_DUMP_METHOD methods to .cpp to fix IndexBenchmark. They should
be unconditionally defined as they are also used by non-dump-method #pragma clang __debug diag_mapping

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@348065 91177308-0d34-0410-b5e6-96231b3b80d8
include/clang/Basic/Diagnostic.h
lib/Basic/Diagnostic.cpp