================
@@ -4461,8 +4461,14 @@ void CodeGenModule::EmitGlobalDefinition(GlobalDecl GD, 
llvm::GlobalValue *GV) {
     return EmitGlobalFunctionDefinition(GD, GV);
   }
 
-  if (const auto *VD = dyn_cast<VarDecl>(D))
+  if (const auto *VD = dyn_cast<VarDecl>(D)) {
+    if (VD->isStaticLocal() && !getContext().shouldExternalize(D)) {
----------------
rjmccall wrote:

Alright, I'm happy with that. Just leave a comment explaining what's going on 
to the best of your ability, please.

https://github.com/llvm/llvm-project/pull/156933
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to