[PATCH] D134337: [clang] [Driver] More flexible rules for loading default configs

Michał Górny via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Sep 29 03:27:08 PDT 2022


mgorny added inline comments.


================
Comment at: clang/include/clang/Driver/Driver.h:758
+  /// Return the typical executable name for the specified driver \p Mode.
+  static const char *getExecutableForDriverMode(DriverMode Mode);
 };
----------------
MaskRay wrote:
> This should be private
No opinion but will do.


================
Comment at: clang/lib/Driver/Driver.cpp:1094
+  //    (e.g. i386-pc-linux-gnu-clang++.cfg).
+  // 2. <triple>-<mode>.cfg using executable suffix
+  //    (e.g. i386-pc-linux-gnu-clang-g++.cfg).
----------------
MaskRay wrote:
> "executable suffix" is less clear. An example will help.
Added `for *clang-g++` below. Hope that's good enough.


================
Comment at: clang/lib/Driver/Driver.cpp:1101
+
+  // Try loading full config (variants 1. and 2.)
   llvm::SmallString<128> CfgFilePath;
----------------
MaskRay wrote:
> Mention "first part" ? (And what does "first part refer to")
I don't understand this comment.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D134337/new/

https://reviews.llvm.org/D134337



More information about the cfe-commits mailing list