]> granicus.if.org Git - clang/commitdiff
Simplify further.
authorRafael Espindola <rafael.espindola@gmail.com>
Mon, 20 Jan 2014 20:13:11 +0000 (20:13 +0000)
committerRafael Espindola <rafael.espindola@gmail.com>
Mon, 20 Jan 2014 20:13:11 +0000 (20:13 +0000)
Thanks to David Blaikie for the push.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@199685 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/CodeGenModule.cpp

index a3d575c6e5991b35e43e95fc8a563b55b2cccb33..88e6e66f9c0b3821fa963f2ddfb3a8d2907a8309 100644 (file)
@@ -2420,8 +2420,7 @@ CodeGenModule::GetAddrOfConstantCFString(const StringLiteral *Literal) {
   GV = new llvm::GlobalVariable(getModule(), C->getType(), true,
                                 llvm::GlobalVariable::PrivateLinkage, C,
                                 "_unnamed_cfstring_");
-  const char *CFStringSection = "__DATA,__cfstring";
-  GV->setSection(CFStringSection);
+  GV->setSection("__DATA,__cfstring");
   Entry.setValue(GV);
 
   return GV;
@@ -2534,12 +2533,11 @@ CodeGenModule::GetAddrOfConstantString(const StringLiteral *Literal) {
                                 "_unnamed_nsstring_");
   const char *NSStringSection = "__OBJC,__cstring_object,regular,no_dead_strip";
   const char *NSStringNonFragileABISection =
-      "__DATA, __objc_stringobj, regular, no_dead_strip";
+      "__DATA,__objc_stringobj,regular,no_dead_strip";
   // FIXME. Fix section.
-  const char *Sect = LangOpts.ObjCRuntime.isNonFragile()
-                         ? NSStringNonFragileABISection
-                         : NSStringSection;
-  GV->setSection(Sect);
+  GV->setSection(LangOpts.ObjCRuntime.isNonFragile()
+                     ? NSStringNonFragileABISection
+                     : NSStringSection);
   Entry.setValue(GV);
   
   return GV;