Changeset View
Changeset View
Standalone View
Standalone View
clang/lib/Serialization/ASTWriterDecl.cpp
Context not available. | |||||
// definition in the module interface is provided by the compilation of | // definition in the module interface is provided by the compilation of | ||||
// that module interface unit, not by its users. (Inline variables are | // that module interface unit, not by its users. (Inline variables are | ||||
// still emitted in module users.) | // still emitted in module users.) | ||||
// Similarly if a PCH is built with codegen and its own object file. | |||||
ModulesCodegen = | ModulesCodegen = | ||||
(((Writer.WritingModule && | (((Writer.WritingModule && | ||||
Writer.WritingModule->Kind == Module::ModuleInterfaceUnit) || | Writer.WritingModule->Kind == Module::ModuleInterfaceUnit) || | ||||
Writer.Context->getLangOpts().BuildingPCHWithObjectFile) && | (Writer.Context->getLangOpts().BuildingPCHWithObjectFile && | ||||
Writer.Context->getLangOpts().ModulesCodegen)) && | |||||
Writer.Context->GetGVALinkageForVariable(D) == GVA_StrongExternal); | Writer.Context->GetGVALinkageForVariable(D) == GVA_StrongExternal); | ||||
} | } | ||||
Record.push_back(ModulesCodegen); | Record.push_back(ModulesCodegen); | ||||
Context not available. | |||||
bool ModulesCodegen = false; | bool ModulesCodegen = false; | ||||
if (!FD->isDependentContext()) { | if (!FD->isDependentContext()) { | ||||
Optional<GVALinkage> Linkage; | Optional<GVALinkage> Linkage; | ||||
if ((Writer->WritingModule && | if (Writer->WritingModule && | ||||
Writer->WritingModule->Kind == Module::ModuleInterfaceUnit) || | Writer->WritingModule->Kind == Module::ModuleInterfaceUnit) { | ||||
Writer->Context->getLangOpts().BuildingPCHWithObjectFile) { | |||||
// When building a C++ Modules TS module interface unit, a strong | // When building a C++ Modules TS module interface unit, a strong | ||||
// definition in the module interface is provided by the compilation of | // definition in the module interface is provided by the compilation of | ||||
// that module interface unit, not by its users. (Inline functions are | // that module interface unit, not by its users. (Inline functions are | ||||
Context not available. |