]> granicus.if.org Git - clang/commit
clang-format: Fix access to uninitialized memory.
authorDaniel Jasper <djasper@google.com>
Tue, 3 Mar 2015 13:59:49 +0000 (13:59 +0000)
committerDaniel Jasper <djasper@google.com>
Tue, 3 Mar 2015 13:59:49 +0000 (13:59 +0000)
commitace92c4e2bb94f3f8914588c94a91fe93c75d42f
tree6dd919e3b29aacd7d62f90aa8d917d9d18f66521
parenteb4587857f7386aad6a8ad083bda0f1e401f250d
clang-format: Fix access to uninitialized memory.

With incomplete code, we aren't guaranteed to generated changes for
every token. In that case, we need to assume that even the very first
change can continue a preprocessor directive and initialize values
accordingly.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@231066 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Format/WhitespaceManager.cpp
unittests/Format/FormatTest.cpp