From 72b9049b43c1ce9a8b39e9e0aa9869ecf90503e8 Mon Sep 17 00:00:00 2001 From: Jan Korous Date: Tue, 24 Sep 2019 00:37:25 +0000 Subject: [PATCH] [static analyzer] Remove --analyze-auto Differential Revision: https://reviews.llvm.org/D67934 llvm-svn: 372680 --- clang/docs/ClangCommandLineReference.rst | 2 -- clang/include/clang/Driver/Options.td | 1 - clang/lib/Driver/Driver.cpp | 5 ++--- clang/lib/Driver/Types.cpp | 2 +- 4 files changed, 3 insertions(+), 7 deletions(-) diff --git a/clang/docs/ClangCommandLineReference.rst b/clang/docs/ClangCommandLineReference.rst index 80b0cb3..385b70a 100644 --- a/clang/docs/ClangCommandLineReference.rst +++ b/clang/docs/ClangCommandLineReference.rst @@ -86,8 +86,6 @@ Pass to the target offloading toolchain identified by . Run the static analyzer -.. option:: --analyze-auto - .. option:: --analyzer-no-default-checks .. option:: --analyzer-output diff --git a/clang/include/clang/Driver/Options.td b/clang/include/clang/Driver/Options.td index 90720e4..569891c 100644 --- a/clang/include/clang/Driver/Options.td +++ b/clang/include/clang/Driver/Options.td @@ -2762,7 +2762,6 @@ def _mhwdiv : Separate<["--"], "mhwdiv">, Alias; def _CLASSPATH_EQ : Joined<["--"], "CLASSPATH=">, Alias; def _CLASSPATH : Separate<["--"], "CLASSPATH">, Alias; def _all_warnings : Flag<["--"], "all-warnings">, Alias; -def _analyze_auto : Flag<["--"], "analyze-auto">, Flags<[DriverOption]>; def _analyzer_no_default_checks : Flag<["--"], "analyzer-no-default-checks">, Flags<[DriverOption]>; def _analyzer_output : JoinedOrSeparate<["--"], "analyzer-output">, Flags<[DriverOption]>, HelpText<"Static analyzer report output format (html|plist|plist-multi-file|plist-html|text).">; diff --git a/clang/lib/Driver/Driver.cpp b/clang/lib/Driver/Driver.cpp index 861372e..94d50d7 100644 --- a/clang/lib/Driver/Driver.cpp +++ b/clang/lib/Driver/Driver.cpp @@ -287,8 +287,7 @@ phases::ID Driver::getFinalPhase(const DerivedArgList &DAL, (PhaseArg = DAL.getLastArg(options::OPT_rewrite_legacy_objc)) || (PhaseArg = DAL.getLastArg(options::OPT__migrate)) || (PhaseArg = DAL.getLastArg(options::OPT_emit_iterface_stubs)) || - (PhaseArg = DAL.getLastArg(options::OPT__analyze, - options::OPT__analyze_auto)) || + (PhaseArg = DAL.getLastArg(options::OPT__analyze)) || (PhaseArg = DAL.getLastArg(options::OPT_emit_ast))) { FinalPhase = phases::Compile; @@ -3501,7 +3500,7 @@ Action *Driver::ConstructPhaseAction( if (Args.hasArg(options::OPT_rewrite_legacy_objc)) return C.MakeAction(Input, types::TY_RewrittenLegacyObjC); - if (Args.hasArg(options::OPT__analyze, options::OPT__analyze_auto)) + if (Args.hasArg(options::OPT__analyze)) return C.MakeAction(Input, types::TY_Plist); if (Args.hasArg(options::OPT__migrate)) return C.MakeAction(Input, types::TY_Remap); diff --git a/clang/lib/Driver/Types.cpp b/clang/lib/Driver/Types.cpp index d83935c..da01e1a 100644 --- a/clang/lib/Driver/Types.cpp +++ b/clang/lib/Driver/Types.cpp @@ -328,7 +328,7 @@ void types::getCompilationPhases(const clang::driver::Driver &Driver, DAL.getLastArg(options::OPT_rewrite_legacy_objc) || DAL.getLastArg(options::OPT__migrate) || DAL.getLastArg(options::OPT_emit_iterface_stubs) || - DAL.getLastArg(options::OPT__analyze, options::OPT__analyze_auto) || + DAL.getLastArg(options::OPT__analyze) || DAL.getLastArg(options::OPT_emit_ast)) llvm::copy_if(PhaseList, std::back_inserter(P), [](phases::ID Phase) { return Phase <= phases::Compile; }); -- 2.7.4