This is an archive of the discontinued LLVM Phabricator instance.

[clang] Move a template function definition to header file
AbandonedPublic

Authored by wmi on Jun 29 2020, 8:38 PM.

Details

Summary

Sema::PragmaStack::Act is a template function the definition of which is currently put in SemaAttr.cpp file. Without explicit instantiation, that definition may or may not be generated by compiler depending on inlining so linker may run into the problem of undefined reference when
other module refers to the definition.

The patch moves the definition to header file.

Diff Detail

Repository
rL LLVM

Event Timeline

wmi created this revision.Jun 29 2020, 8:38 PM
wmi abandoned this revision.Jun 29 2020, 9:34 PM

Thanks David!