[clang] daebf2c - [clang] Make config-related options CoreOptions

Michał Górny via cfe-commits cfe-commits at lists.llvm.org
Mon Sep 19 09:58:20 PDT 2022


Author: Michał Górny
Date: 2022-09-19T18:58:09+02:00
New Revision: daebf2c13ce27ac6a7403525cc7fcbc063eb892e

URL: https://github.com/llvm/llvm-project/commit/daebf2c13ce27ac6a7403525cc7fcbc063eb892e
DIFF: https://github.com/llvm/llvm-project/commit/daebf2c13ce27ac6a7403525cc7fcbc063eb892e.diff

LOG: [clang] Make config-related options CoreOptions

Make `--config`, `--no-default-config` and `--config-*-dir` CoreOptions
to enable their availability to all clang driver modes.  This improves
consistency given that the default set of configuration files is
processed independently of mode anyway.

Differential Revision: https://reviews.llvm.org/D134191

Added: 
    

Modified: 
    clang/include/clang/Driver/Options.td

Removed: 
    


################################################################################
diff  --git a/clang/include/clang/Driver/Options.td b/clang/include/clang/Driver/Options.td
index 8dea1a01c1f89..67ceaf5bf0f2a 100644
--- a/clang/include/clang/Driver/Options.td
+++ b/clang/include/clang/Driver/Options.td
@@ -899,13 +899,13 @@ def cl_ext_EQ : CommaJoined<["-"], "cl-ext=">, Group<opencl_Group>, Flags<[CC1Op
 def client__name : JoinedOrSeparate<["-"], "client_name">;
 def combine : Flag<["-", "--"], "combine">, Flags<[NoXarchOption, Unsupported]>;
 def compatibility__version : JoinedOrSeparate<["-"], "compatibility_version">;
-def config : Separate<["--"], "config">, Flags<[NoXarchOption]>,
+def config : Separate<["--"], "config">, Flags<[NoXarchOption, CoreOption]>,
   HelpText<"Specifies configuration file">;
-def no_default_config : Flag<["--"], "no-default-config">, Flags<[NoXarchOption]>,
+def no_default_config : Flag<["--"], "no-default-config">, Flags<[NoXarchOption, CoreOption]>,
   HelpText<"Disable loading default configuration files">;
-def config_system_dir_EQ : Joined<["--"], "config-system-dir=">, Flags<[NoXarchOption, HelpHidden]>,
+def config_system_dir_EQ : Joined<["--"], "config-system-dir=">, Flags<[NoXarchOption, CoreOption, HelpHidden]>,
   HelpText<"System directory for configuration files">;
-def config_user_dir_EQ : Joined<["--"], "config-user-dir=">, Flags<[NoXarchOption, HelpHidden]>,
+def config_user_dir_EQ : Joined<["--"], "config-user-dir=">, Flags<[NoXarchOption, CoreOption, HelpHidden]>,
   HelpText<"User directory for configuration files">;
 def coverage : Flag<["-", "--"], "coverage">, Group<Link_Group>, Flags<[CoreOption]>;
 def cpp_precomp : Flag<["-"], "cpp-precomp">, Group<clang_ignored_f_Group>;


        


More information about the cfe-commits mailing list