[cfe-commits] [PATCH] Only add common tool options when CommonOptionsParser is used.
Alexander Kornienko
alexfh at google.com
Mon Aug 27 11:31:28 PDT 2012
Ping.
On Fri, Aug 24, 2012 at 8:41 PM, Alexander Kornienko <
reviews at llvm-reviews.chandlerc.com> wrote:
> Hi chandlerc, klimek, djasper,
>
> Subj.
>
> http://llvm-reviews.chandlerc.com/D29
>
> Files:
> tools/clang/lib/Tooling/CommonOptionsParser.cpp
>
> Index: tools/clang/lib/Tooling/CommonOptionsParser.cpp
> ===================================================================
> --- tools/clang/lib/Tooling/CommonOptionsParser.cpp
> +++ tools/clang/lib/Tooling/CommonOptionsParser.cpp
> @@ -53,13 +53,13 @@
> "\tsuffix of a path in the compile command database.\n"
> "\n";
>
> -static cl::opt<std::string> BuildPath(
> - "p", cl::desc("Build path"), cl::Optional);
> +CommonOptionsParser::CommonOptionsParser(int &argc, const char **argv) {
> + static cl::opt<std::string> BuildPath(
> + "p", cl::desc("Build path"), cl::Optional);
>
> -static cl::list<std::string> SourcePaths(
> - cl::Positional, cl::desc("<source0> [... <sourceN>]"), cl::OneOrMore);
> + static cl::list<std::string> SourcePaths(
> + cl::Positional, cl::desc("<source0> [... <sourceN>]"),
> cl::OneOrMore);
>
> -CommonOptionsParser::CommonOptionsParser(int &argc, const char **argv) {
> Compilations.reset(FixedCompilationDatabase::loadFromCommandLine(argc,
> argv));
> cl::ParseCommandLineOptions(argc, argv);
>
--
Alexander Kornienko | Software Engineer | alexfh at google.com | +49 151 221
77 957
Google Germany GmbH | Dienerstr. 12 | 80331 München
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20120827/8cd8fef5/attachment.html>
More information about the cfe-commits
mailing list