[clang] [HLSL] (DRAFT) Another way to implement #92071: [HLSL] Default linkage of HLSL function should be internal (PR #95331)
via cfe-commits
cfe-commits at lists.llvm.org
Wed Jun 12 16:29:28 PDT 2024
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 5d87ba1c1f584dfbd5afaf187099b43681b2206d f4fdb0eb680ab1ddf4f289bde30b1a72872b2f8d -- clang/lib/AST/ASTContext.cpp clang/lib/AST/Decl.cpp clang/lib/CodeGen/CGHLSLRuntime.cpp clang/lib/CodeGen/CGHLSLRuntime.h clang/lib/CodeGen/CodeGenFunction.cpp clang/lib/Sema/Sema.cpp
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/clang/lib/AST/Decl.cpp b/clang/lib/AST/Decl.cpp
index a06e7a2d19..041667ecbd 100644
--- a/clang/lib/AST/Decl.cpp
+++ b/clang/lib/AST/Decl.cpp
@@ -688,7 +688,7 @@ LinkageComputer::getLVForNamespaceScopeDecl(const NamedDecl *D,
return LinkageInfo::internal();
}
if (Context.getLangOpts().HLSL) {
- return LinkageInfo::internal();
+ return LinkageInfo::internal();
}
// Set up the defaults.
diff --git a/clang/lib/Sema/Sema.cpp b/clang/lib/Sema/Sema.cpp
index b3ddb88be4..1186a055c9 100644
--- a/clang/lib/Sema/Sema.cpp
+++ b/clang/lib/Sema/Sema.cpp
@@ -953,7 +953,7 @@ static void checkUndefinedButUsed(Sema &S) {
Func->getIdentifier()->isMangledOpenMPVariantName();
}
}
- // Do not warn on undefined internal functions in HLSL, they will get
+ // Do not warn on undefined internal functions in HLSL, they will get
// external linkage assigned during CodeGen
if (S.getLangOpts().HLSL)
continue;
``````````
</details>
https://github.com/llvm/llvm-project/pull/95331
More information about the cfe-commits
mailing list