instead of looking up super at startup time,
just check for it when needed. It doesn't incur real cost
in any hot paths.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@59708 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Sema/SemaExpr.cpp b/lib/Sema/SemaExpr.cpp
index 147b4c8..12f059e 100644
--- a/lib/Sema/SemaExpr.cpp
+++ b/lib/Sema/SemaExpr.cpp
@@ -400,7 +400,7 @@
}
}
// Needed to implement property "super.method" notation.
- if (SD == 0 && II == SuperID) {
+ if (SD == 0 && II->isStr("super")) {
QualType T = Context.getPointerType(Context.getObjCInterfaceType(
getCurMethodDecl()->getClassInterface()));
return new ObjCSuperExpr(Loc, T);