Enable '-analyzer-opt-analyze-nested-blocks' by default for testing.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90812 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Driver/Tools.cpp b/lib/Driver/Tools.cpp
index b10ad1e..a89806a 100644
--- a/lib/Driver/Tools.cpp
+++ b/lib/Driver/Tools.cpp
@@ -647,6 +647,9 @@
// Enable region store model by default.
CmdArgs.push_back("-analyzer-store=region");
+ // Treat blocks as analysis entry points.
+ CmdArgs.push_back("-analyzer-opt-analyze-nested-blocks");
+
// Add default argument set.
if (!Args.hasArg(options::OPT__analyzer_no_default_checks)) {
CmdArgs.push_back("-warn-dead-stores");
diff --git a/tools/scan-build/ccc-analyzer b/tools/scan-build/ccc-analyzer
index 25b9800..8e3e26c 100755
--- a/tools/scan-build/ccc-analyzer
+++ b/tools/scan-build/ccc-analyzer
@@ -159,6 +159,7 @@
push @CmdArgs,'-analyze';
push @CmdArgs,"-analyzer-display-progress";
push @CmdArgs,"-analyzer-eagerly-assume";
+ push @CmdArgs,"-analyzer-opt-analyze-nested-blocks";
push @CmdArgs,(split /\s/,$Analyses);
if (defined $ENV{"CCC_EXPERIMENTAL_CHECKS"}) {