summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGObjCGNU.cpp
diff options
context:
space:
mode:
authorJohn McCall <rjmccall@apple.com>2016-11-30 20:46:55 +0000
committerJohn McCall <rjmccall@apple.com>2016-11-30 20:46:55 +0000
commitf00e2c09bea89c73aa6501ff5430586d35372fca (patch)
tree565f4224c471976eb5d73881951cd9fd847c4997 /clang/lib/CodeGen/CGObjCGNU.cpp
parente109ef854a15326c4a818b42e5b6b15adfd730f5 (diff)
downloadbcm5719-llvm-f00e2c09bea89c73aa6501ff5430586d35372fca.tar.gz
bcm5719-llvm-f00e2c09bea89c73aa6501ff5430586d35372fca.zip
Prospective MSVC workaround.
llvm-svn: 288272
Diffstat (limited to 'clang/lib/CodeGen/CGObjCGNU.cpp')
-rw-r--r--clang/lib/CodeGen/CGObjCGNU.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/CGObjCGNU.cpp b/clang/lib/CodeGen/CGObjCGNU.cpp
index 69e84d10238..3fd8dabd017 100644
--- a/clang/lib/CodeGen/CGObjCGNU.cpp
+++ b/clang/lib/CodeGen/CGObjCGNU.cpp
@@ -2450,7 +2450,8 @@ llvm::Function *CGObjCGNU::ModuleInitFunction() {
llvm::GlobalVariable *selectorList = [&] {
ConstantInitBuilder builder(CGM);
auto selectors = builder.beginArray(selStructTy);
- for (auto &entry : SelectorTable) {
+ auto &table = SelectorTable; // MSVC workaround
+ for (auto &entry : table) {
std::string selNameStr = entry.first.getAsString();
llvm::Constant *selName = ExportUniqueString(selNameStr, ".objc_sel_name");
OpenPOWER on IntegriCloud