[clang] [clang] Updates for support for Ubunutu, Debian and RHEL (PR #162796)
via cfe-commits
cfe-commits at lists.llvm.org
Fri Oct 10 01:09:13 PDT 2025
github-actions[bot] wrote:
<!--LLVM CODE FORMAT COMMENT: {clang-format}-->
:warning: C/C++ code formatter, clang-format found issues in your code. :warning:
<details>
<summary>
You can test this locally with the following command:
</summary>
``````````bash
git-clang-format --diff origin/main HEAD --extensions h,cpp -- clang/include/clang/Driver/Distro.h clang/lib/Driver/Distro.cpp
``````````
:warning:
The reproduction instructions above might return results for more than one PR
in a stack if you are using a stacked PR workflow. You can limit the results by
changing `origin/main` to the base branch/commit you want to compare against.
:warning:
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/clang/lib/Driver/Distro.cpp b/clang/lib/Driver/Distro.cpp
index b6210888b..96dc83a66 100644
--- a/clang/lib/Driver/Distro.cpp
+++ b/clang/lib/Driver/Distro.cpp
@@ -114,8 +114,9 @@ static Distro::DistroType DetectDistro(llvm::vfs::FileSystem &VFS) {
StringRef Data = File.get()->getBuffer();
if (Data.starts_with("Fedora release"))
return Distro::Fedora;
- if (Data.starts_with("Red Hat Enterprise Linux") || Data.starts_with("CentOS") ||
- Data.starts_with("Alma Linux") || Data.starts_with("Rocky Linux") ||
+ if (Data.starts_with("Red Hat Enterprise Linux") ||
+ Data.starts_with("CentOS") || Data.starts_with("Alma Linux") ||
+ Data.starts_with("Rocky Linux") ||
Data.starts_with("Scientific Linux")) {
if (Data.contains("release 10"))
return Distro::RHEL10;
``````````
</details>
https://github.com/llvm/llvm-project/pull/162796
More information about the cfe-commits
mailing list