summaryrefslogtreecommitdiffstats
path: root/clang/lib/AST/Linkage.h
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2017-09-22 04:25:05 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2017-09-22 04:25:05 +0000
commitc95d2c5dda635af5edfc7a6634605b99e3bcecd3 (patch)
tree7c52f5ea2e3ca8059c850f87769e8b2fdf9eb04a /clang/lib/AST/Linkage.h
parent83e2838d03e17e3ee5b73ab91c47660e4a8daf3c (diff)
downloadbcm5719-llvm-c95d2c5dda635af5edfc7a6634605b99e3bcecd3.tar.gz
bcm5719-llvm-c95d2c5dda635af5edfc7a6634605b99e3bcecd3.zip
Give external linkage and mangling to lambdas inside inline variables and variable templates.
This implements the proposed approach in https://github.com/itanium-cxx-abi/cxx-abi/issues/33 This reinstates r313827, reverted in r313856, with a fix for the 'out-of-bounds enumeration value' ubsan error in that change. llvm-svn: 313955
Diffstat (limited to 'clang/lib/AST/Linkage.h')
-rw-r--r--clang/lib/AST/Linkage.h9
1 files changed, 6 insertions, 3 deletions
diff --git a/clang/lib/AST/Linkage.h b/clang/lib/AST/Linkage.h
index b577901f3a0..e6489c7ef2b 100644
--- a/clang/lib/AST/Linkage.h
+++ b/clang/lib/AST/Linkage.h
@@ -117,10 +117,12 @@ class LinkageComputer {
LVComputationKind computation);
LinkageInfo getLVForNamespaceScopeDecl(const NamedDecl *D,
- LVComputationKind computation);
+ LVComputationKind computation,
+ bool IgnoreVarTypeLinkage);
LinkageInfo getLVForClassMember(const NamedDecl *D,
- LVComputationKind computation);
+ LVComputationKind computation,
+ bool IgnoreVarTypeLinkage);
LinkageInfo getLVForClosure(const DeclContext *DC, Decl *ContextDecl,
LVComputationKind computation);
@@ -135,7 +137,8 @@ class LinkageComputer {
public:
LinkageInfo computeLVForDecl(const NamedDecl *D,
- LVComputationKind computation);
+ LVComputationKind computation,
+ bool IgnoreVarTypeLinkage = false);
LinkageInfo getLVForDecl(const NamedDecl *D, LVComputationKind computation);
OpenPOWER on IntegriCloud