|
@@ -1901,7 +1901,7 @@ void CGMSHLSLRuntime::addResource(Decl *D) {
|
|
if (VD->hasInit() && resClass != DXIL::ResourceClass::Invalid)
|
|
if (VD->hasInit() && resClass != DXIL::ResourceClass::Invalid)
|
|
return;
|
|
return;
|
|
// skip static global.
|
|
// skip static global.
|
|
- if (!VD->isExternallyVisible()) {
|
|
|
|
|
|
+ if (!VD->hasExternalFormalLinkage()) {
|
|
if (VD->hasInit() && VD->getType().isConstQualified()) {
|
|
if (VD->hasInit() && VD->getType().isConstQualified()) {
|
|
Expr* InitExp = VD->getInit();
|
|
Expr* InitExp = VD->getInit();
|
|
GlobalVariable *GV = cast<GlobalVariable>(CGM.GetAddrOfGlobalVar(VD));
|
|
GlobalVariable *GV = cast<GlobalVariable>(CGM.GetAddrOfGlobalVar(VD));
|