This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG16aa00b62285: [clang][cli] Port FileSystem options to new option parsing system (authored by jansvoboda11).
Changed prior to commit: https://reviews.llvm.org/D84188?vs=279295&id=311514#toc Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D84188/new/ https://reviews.llvm.org/D84188 Files: clang/include/clang/Driver/Options.td clang/lib/Frontend/CompilerInvocation.cpp Index: clang/lib/Frontend/CompilerInvocation.cpp =================================================================== --- clang/lib/Frontend/CompilerInvocation.cpp +++ clang/lib/Frontend/CompilerInvocation.cpp @@ -1876,10 +1876,6 @@ return Success; } -static void ParseFileSystemArgs(FileSystemOptions &Opts, ArgList &Args) { - Opts.WorkingDir = std::string(Args.getLastArgValue(OPT_working_directory)); -} - /// Parse the argument to the -ftest-module-file-extension /// command-line argument. /// @@ -3839,7 +3835,6 @@ Success &= ParseDiagnosticArgs(Res.getDiagnosticOpts(), Args, &Diags, /*DefaultDiagColor=*/false); ParseCommentArgs(LangOpts.CommentOpts, Args); - ParseFileSystemArgs(Res.getFileSystemOpts(), Args); // FIXME: We shouldn't have to pass the DashX option around here InputKind DashX = ParseFrontendArgs(Res.getFrontendOpts(), Args, Diags, LangOpts.IsHeaderFile); Index: clang/include/clang/Driver/Options.td =================================================================== --- clang/include/clang/Driver/Options.td +++ clang/include/clang/Driver/Options.td @@ -3354,7 +3354,8 @@ Flags<[CC1Option, NoXarchOption]>; def working_directory : JoinedOrSeparate<["-"], "working-directory">, Flags<[CC1Option]>, - HelpText<"Resolve file paths relative to the specified directory">; + HelpText<"Resolve file paths relative to the specified directory">, + MarshallingInfoString<"FileSystemOpts.WorkingDir">; def working_directory_EQ : Joined<["-"], "working-directory=">, Flags<[CC1Option]>, Alias<working_directory>;
Index: clang/lib/Frontend/CompilerInvocation.cpp =================================================================== --- clang/lib/Frontend/CompilerInvocation.cpp +++ clang/lib/Frontend/CompilerInvocation.cpp @@ -1876,10 +1876,6 @@ return Success; } -static void ParseFileSystemArgs(FileSystemOptions &Opts, ArgList &Args) { - Opts.WorkingDir = std::string(Args.getLastArgValue(OPT_working_directory)); -} - /// Parse the argument to the -ftest-module-file-extension /// command-line argument. /// @@ -3839,7 +3835,6 @@ Success &= ParseDiagnosticArgs(Res.getDiagnosticOpts(), Args, &Diags, /*DefaultDiagColor=*/false); ParseCommentArgs(LangOpts.CommentOpts, Args); - ParseFileSystemArgs(Res.getFileSystemOpts(), Args); // FIXME: We shouldn't have to pass the DashX option around here InputKind DashX = ParseFrontendArgs(Res.getFrontendOpts(), Args, Diags, LangOpts.IsHeaderFile); Index: clang/include/clang/Driver/Options.td =================================================================== --- clang/include/clang/Driver/Options.td +++ clang/include/clang/Driver/Options.td @@ -3354,7 +3354,8 @@ Flags<[CC1Option, NoXarchOption]>; def working_directory : JoinedOrSeparate<["-"], "working-directory">, Flags<[CC1Option]>, - HelpText<"Resolve file paths relative to the specified directory">; + HelpText<"Resolve file paths relative to the specified directory">, + MarshallingInfoString<"FileSystemOpts.WorkingDir">; def working_directory_EQ : Joined<["-"], "working-directory=">, Flags<[CC1Option]>, Alias<working_directory>;
_______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits