[PATCH] D44764: [clangd] Move GTest printers to separate file
Marc-Andre Laperle via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Mar 21 17:28:35 PDT 2018
malaperle created this revision.
Herald added subscribers: cfe-commits, MaskRay, ioeric, jkorous-apple, ilya-biryukov, klimek.
This mitigates a possible issue in tests that print objects on failure. It is
possible that there will be two different instantiations of the printer template
for a given type and some tests could end up calling the wrong (default) one.
For example, it was seen in CodeCompleteTests.cpp when printing CompletionItems
that it would use the wrong printer because the default is also instantiated in
ClangdTests.cpp.
With this change, all tests that need to use printers can include the new header
so that this issue does not occur.
Signed-off-by: Marc-Andre Laperle <marc-andre.laperle at ericsson.com>
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D44764
Files:
unittests/clangd/ClangdTests.cpp
unittests/clangd/ClangdUnitTests.cpp
unittests/clangd/CodeCompleteTests.cpp
unittests/clangd/CodeCompletionStringsTests.cpp
unittests/clangd/ContextTests.cpp
unittests/clangd/FileIndexTests.cpp
unittests/clangd/FuzzyMatchTests.cpp
unittests/clangd/HeadersTests.cpp
unittests/clangd/IndexTests.cpp
unittests/clangd/JSONExprTests.cpp
unittests/clangd/Matchers.h
unittests/clangd/Printers.h
unittests/clangd/SourceCodeTests.cpp
unittests/clangd/SymbolCollectorTests.cpp
unittests/clangd/TUSchedulerTests.cpp
unittests/clangd/TestFS.cpp
unittests/clangd/TraceTests.cpp
unittests/clangd/URITests.cpp
unittests/clangd/XRefsTests.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D44764.139401.patch
Type: text/x-patch
Size: 10994 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20180322/2bbd18ed/attachment.bin>
More information about the cfe-commits
mailing list