Update for Clang API change and move ClangTidyDiagnosticRenderer into an anonymous namespace while there.

git-svn-id: https://llvm.org/svn/llvm-project/clang-tools-extra/trunk@208471 91177308-0d34-0410-b5e6-96231b3b80d8
Change the behavior of clang-tidy -checks=, remove -disable-checks.

Summary:
Make checks filtering more intuitive and easy to use. Remove
-disable-checks and change the format of -checks= to a comma-separated list of
globs with optional '-' prefix to denote exclusion. The -checks= option is now
cumulative, so it modifies defaults, not overrides them. Each glob adds or
removes to the current set of checks, so the filter can be refined or overriden
by adding globs.

Example:
  The default value for -checks= is
  '*,-clang-analyzer-alpha*,-llvm-include-order,-llvm-namespace-comment,-google-*',
  which allows all checks except for the ones named clang-analyzer-alpha* and
  others specified with the leading '-'. To allow all google-* checks one can
  write:
    clang-tidy -checks=google-* ...
  If one needs only google-* checks, we first need to remove everything (-*):
    clang-tidy -checks=-*,google-*
  etc.

I'm not sure if we need to change something here, so I didn't touch the docs
yet.

Reviewers: klimek, alexfh

Reviewed By: alexfh

Subscribers: cfe-commits

Differential Revision: http://reviews.llvm.org/D3770

git-svn-id: https://llvm.org/svn/llvm-project/clang-tools-extra/trunk@208883 91177308-0d34-0410-b5e6-96231b3b80d8
Fixed incorrect StringRef::find usage.

git-svn-id: https://llvm.org/svn/llvm-project/clang-tools-extra/trunk@208898 91177308-0d34-0410-b5e6-96231b3b80d8
Initial version of clang-tidy check to use override instead of virual.

Review: http://reviews.llvm.org/D3688

git-svn-id: https://llvm.org/svn/llvm-project/clang-tools-extra/trunk@208954 91177308-0d34-0410-b5e6-96231b3b80d8
Update clang-tidy documentation.

Summary:
Updated the help message, updated description of -checks=, removed
mentions of -disable-checks.

Reviewers: klimek

Reviewed By: klimek

Subscribers: cfe-commits

Differential Revision: http://reviews.llvm.org/D3793

git-svn-id: https://llvm.org/svn/llvm-project/clang-tools-extra/trunk@208979 91177308-0d34-0410-b5e6-96231b3b80d8
clang-tidy/misc/UseOverride.cpp: Appease targeting msvc.

With IsLateTemplateParsed, FunctionDecl::doesThisDeclarationHaveABody() returns True regardless of Body.

git-svn-id: https://llvm.org/svn/llvm-project/clang-tools-extra/trunk@208985 91177308-0d34-0410-b5e6-96231b3b80d8
Initializer list is unavailable. Use the constructor instead.

git-svn-id: https://llvm.org/svn/llvm-project/clang-tools-extra/trunk@208986 91177308-0d34-0410-b5e6-96231b3b80d8
Track clang changes from r209061

git-svn-id: https://llvm.org/svn/llvm-project/clang-tools-extra/trunk@209062 91177308-0d34-0410-b5e6-96231b3b80d8
Address review comments on r208954. No functional changes.

git-svn-id: https://llvm.org/svn/llvm-project/clang-tools-extra/trunk@209111 91177308-0d34-0410-b5e6-96231b3b80d8
Improved llvm-namespace-comment check.

Summary:
Handle various forms of existing namespace closing comments, fix
existing comments with wrong namespace name, ignore short namespaces.

The state of this check now seems to be enough to enable it by default to gather
user feedback ;)

Reviewers: klimek

Reviewed By: klimek

Subscribers: cfe-commits

Differential Revision: http://reviews.llvm.org/D3825

git-svn-id: https://llvm.org/svn/llvm-project/clang-tools-extra/trunk@209141 91177308-0d34-0410-b5e6-96231b3b80d8
Added a comment

git-svn-id: https://llvm.org/svn/llvm-project/clang-tools-extra/trunk@209146 91177308-0d34-0410-b5e6-96231b3b80d8
Fix clang-query on Windows: flush llvm::outs() after each command.

git-svn-id: https://llvm.org/svn/llvm-project/clang-tools-extra/trunk@209313 91177308-0d34-0410-b5e6-96231b3b80d8
Updating branches/google/testing to r209252

git-svn-id: https://llvm.org/svn/llvm-project/clang-tools-extra/branches/google/testing@209350 91177308-0d34-0410-b5e6-96231b3b80d8
Updating branches/google/testing to r209387

git-svn-id: https://llvm.org/svn/llvm-project/clang-tools-extra/branches/google/testing@209401 91177308-0d34-0410-b5e6-96231b3b80d8