This patch introduces declaration of getter methods for ObjC2's
properties. Couple of property tests will fail with this patch.
Will fix them next.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@50818 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/Driver/ASTConsumers.cpp b/Driver/ASTConsumers.cpp
index d8acc0d..3276228 100644
--- a/Driver/ASTConsumers.cpp
+++ b/Driver/ASTConsumers.cpp
@@ -273,16 +273,16 @@
   for (ObjCInterfaceDecl::classprop_iterator I = OID->classprop_begin(),
        E = OID->classprop_end(); I != E; ++I)
     PrintObjCPropertyDecl(*I);
-  
+  bool eol_needed = false;
   for (ObjCInterfaceDecl::classmeth_iterator I = OID->classmeth_begin(),
        E = OID->classmeth_end(); I != E; ++I)
-    PrintObjCMethodDecl(*I);
+    eol_needed = true, PrintObjCMethodDecl(*I);
   
   for (ObjCInterfaceDecl::instmeth_iterator I = OID->instmeth_begin(),
        E = OID->instmeth_end(); I != E; ++I)
-    PrintObjCMethodDecl(*I);
+    eol_needed = true, PrintObjCMethodDecl(*I);
   
-  Out << "@end\n";
+  Out << (eol_needed ? "\n@end\n" : "@end\n");
   // FIXME: implement the rest...
 }