================ @@ -5596,6 +5587,42 @@ void CGDebugInfo::EmitGlobalVariable(const ValueDecl *VD, const APValue &Init) { TemplateParameters, Align)); } +void CGDebugInfo::EmitGlobalVariable(const VarDecl *VD) { + assert(VD->hasInit()); + assert(CGM.getCodeGenOpts().hasReducedDebugInfo()); + if (VD->hasAttr<NoDebugAttr>()) + return; + + auto &GV = DeclCache[VD]; ---------------- adrian-prantl wrote:
is it intentional that we cache nullptr here if the next condition fails? https://github.com/llvm/llvm-project/pull/71780 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits