diff options
author | Daniel Jasper <djasper@google.com> | 2016-02-10 12:42:58 +0000 |
---|---|---|
committer | Daniel Jasper <djasper@google.com> | 2016-02-10 12:42:58 +0000 |
commit | 36e979af73c7e184e899fda40338927558ac1597 (patch) | |
tree | 621886ba4077fa732886f70369b20e7c30424eb1 /lldb/packages/Python/lldbsuite/test/expression_command/call-function/TestCallStopAndContinue.py | |
parent | 5bfd4d00086e07d06e28f6a88ce1b07a3521ec3d (diff) | |
download | bcm5719-llvm-36e979af73c7e184e899fda40338927558ac1597.tar.gz bcm5719-llvm-36e979af73c7e184e899fda40338927558ac1597.zip |
clang-format sort include use the source file name to determine the
"main include" that will be the 1st include (category 0).
Because the clang-format visual studio extension does not pass the file
name and use the standard input, sort include cannot find a "main
include":
Testing fix on llvm\tools\clang\lib\Format\Format.cpp:
Original file:
#include "clang/Format/Format.h"
...
#include "clang/Basic/SourceManager.h"
#include "clang/Lex/Lexer.h"
Without fix, selecting the includes and running visual studio
clang-format:
...
#include "clang/Basic/SourceManager.h"
#include "clang/Format/Format.h"
#include "clang/Lex/Lexer.h"
With fix, selecting the includes and running visual studio clang-format:
#include "clang/Format/Format.h"
...
#include "clang/Basic/SourceManager.h"
#include "clang/Lex/Lexer.h"
Test 2 with main header not at the start:
Original file:
...
#include "clang/Format/Format.h"
#include "clang/Basic/SourceManager.h"
#include "clang/Lex/Lexer.h"
Without fix, selecting the includes and running visual studio
clang-format:
...
#include "clang/Basic/SourceManager.h"
#include "clang/Format/Format.h"
#include "clang/Lex/Lexer.h"
With fix, selecting the includes and running visual studio clang-format:
#include "clang/Format/Format.h"
...
#include "clang/Basic/SourceManager.h"
#include "clang/Lex/Lexer.h"
Patch by Jean-Philippe Dufraigne, thank you.
Review: http://reviews.llvm.org/D16524
llvm-svn: 260378
Diffstat (limited to 'lldb/packages/Python/lldbsuite/test/expression_command/call-function/TestCallStopAndContinue.py')
0 files changed, 0 insertions, 0 deletions